diff --git a/AY2324S1-CS2113-T17-2_tp_master/authorship.json b/AY2324S1-CS2113-T17-2_tp_master/authorship.json index 543fc09..158e6e7 100644 --- a/AY2324S1-CS2113-T17-2_tp_master/authorship.json +++ b/AY2324S1-CS2113-T17-2_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":" mainClass.set(\"seedu.cafectrl.CafeCtrl\")","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" archiveBaseName.set(\"cafectrl\")","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"DextheChik3n":3,"-":44}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"Display | Name | Github Profile | Portfolio ","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"--------|:--------:|:----------------------------------------:|:---------:","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Shanice | [Github](https://github.com/ShaniceTang) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Naychi | [Github](https://github.com/NaychiMin/tp) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"![](https://www.google.com/url?sa\u003di\u0026url\u003dhttps%3A%2F%2Fwww.scmp.com%2Fweek-asia%2Fpolitics%2Farticle%2F3095228%2Fmalaysia-najibs-cheesy-super-ring-jibe-comes-back-bite-him-after\u0026psig\u003dAOvVaw2ohFjBBhoZxtARfOKEnTXE\u0026ust\u003d1696586245977000\u0026source\u003dimages\u0026cd\u003dvfe\u0026opi\u003d89978449\u0026ved\u003d0CBEQjRxqFwoTCJiboLbS3oEDFQAAAAAdAAAAABAE) | Zi Yi | [Github](https://github.com/ziyi105) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Dexter Hoon | [Github](https://github.com/DextheChik3n) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Chua Zhong Heng | [Github](https://github.com/Cazh1/tp) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"NaychiMin":1,"DextheChik3n":1,"Cazh1":1,"ziyi105":1,"ShaniceTang":2,"-":3}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"* Table of Contents","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"* [Developer Guide](#developer-guide)","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" * [**Acknowledgements**](#acknowledgements)","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" * [**Setting up, getting started**](#setting-up-getting-started)","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" * [**Design**](#design)","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" * [Architecture](#architecture)","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" * [Ui Component](#ui-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" * [Parser Component](#parser-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" * [Storage Component](#storage-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" * [Data Component](#data-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" * [**Feature**](#feature)","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" * [Add Dish](#add-dish)","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" * [Adding a Dish](#adding-a-dish)","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" * [List Menu](#list-menu)","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" * [Add Order](#add-order)","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" * [Next Day](#next-day)","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" * [Previous Day](#previous-day)","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" * [List Ingredients](#list-ingredients)","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" * [Delete Dish](#delete-dish)","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" * [Edit Price](#edit-price)","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" * [Help](#help)","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" * [**Product scope**](#product-scope)","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" * [Target user profile](#target-user-profile)","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" * [Value proposition](#value-proposition)","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" * [User stories](#user-stories)","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"## **Acknowledgements**","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"[addressbook-level2](https://github.com/se-edu/addressbook-level2) \u003cbr\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"[addressbook-level3](https://github.com/se-edu/addressbook-level3)","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":"## **Setting up, getting started**","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":"Refer to the guide [_UserGuide_](UserGuide.md).","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":"-------------------------------------------------------------------------------------------------------------------- ","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":"## **Design**","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"ziyi105"},"content":"### Architecture","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":"![Architecture Diagram](images/ArchitectureDiagram.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"NaychiMin"},"content":"*Figure 1: Architecture Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"ziyi105"},"content":"The ***Architecture Diagram*** given above explains the high-level design of the App.","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":"Listed below is a brief summary outlining the primary components and their interrelationships.","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":"In summary, the user interacts with the Ui components, initiating a sequence that involves:","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":"- `Parser` component for command interpretation","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":"- `Command` component for execution ","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":"- `Data` component for managing application data","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ziyi105"},"content":"The `Storage` component mainly handles interaction with external text files and main coordinates the interactions between the various Components.","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":"The bulk of the app’s work is done by the following components:","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ziyi105"},"content":"- `Ui` : The UI of the App.","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":"- `Storage` : Reads data from, and writes data to, the text files.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":"- `Data` : Consists of all the classes that are involved in execution of commands.","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":"- `Parser` : Makes sense of user input to return the appropriate command","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":"- `Command` : Executes the command requested by the user.","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":"**How the architecture components interact with each other:**","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":"The Sequence Diagram below shows how the components interact with each other for the scenario where the user issues the command `delete 1`.","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":"![Architecture Encode Data](images/sequence/Architecture_Encode_Data.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":"*Figure 2: Architecture Encode Sequence Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":"### Ui Component","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":"API: [Ui.java]({repoURL}src/main/java/seedu/cafectrl/ui/Ui.java)","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":"![Ui Class Diagram](images/class/Ui.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":"\u003cbr\u003e*Figure 3: Ui Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":"The `Ui` component is responsible for interacting with the user. Within CafeCtrl, `Ui` is instantiated by `Parser`, `Command`, `Main`, `Data`, and `Storage` components to access the print methods in `Ui.java`.","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":"In the Ui component,","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":"- `Ui.java` consists of multiple methods that received the user input and prints messages to the system console for users to see","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":"- `Messages.java` consists of multiple strings that contains greeting, command, and goodbye messages to be shown to user","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":"- `ErrorMessages.java` consists of multiple strings that contain error messages to be shown to user when an incorrect command or exception has been returned","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":"### Parser Component","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":"API: [Parser.java]({repoURL}src/main/java/seedu/cafectrl/parser/Parser.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":89,"author":{"gitId":"ziyi105"},"content":"![Parser Class Diagram](images/class/Parser.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":"*Figure 4: Parser Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":"The `Parser` component is respnsible for making sense of the user\u0027s input and return appropriate `Command` for execution. If the input is unrecognisable, `Parser` will return an `IncorrectCommand` which will display error message to the user through `Ui`.","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"ziyi105"},"content":"\u003cdiv markdown\u003d\"span\" class\u003d\"alert alert-info\"\u003e**Note:** `CafeCtrl` only have access to the interface `ParserUtil` although the run-time type object is `Parser`. With this, we are able to decrease coupling between `CafeCtrl` and `Parser`, allowing for easier maintenance. This also ensures the testability as we could provide mock or stub dependencies during testing, we could isolate the behavior of the class and focus on unit testing without external dependencies.\u003c/div\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"ziyi105"},"content":"Below is the sequence diagram of a parser which shows how `Parser` parses user input:","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"ziyi105"},"content":"![Parser Parsing User Input Sequence Diagram](images/sequence/Parser.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":"*Figure 5: Parser Parsing User Input Sequence Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":"When user input a string to `Main`, it passes the full user input to `Parser` via `parseCommand`. In `parseCommand`, it finds the matching keyword for different command from the user input, it calls the respective `prepareCommand` method within itself. `prepareCommand` then generates the corresponding command class and return it to `parseCommand`, which returns the `Command` back to `Main` for execution.","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":"### Storage Component","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"DextheChik3n"},"content":"API: [Storage.java]({repoURL}src/main/java/seedu/cafectrl/storage/Storage.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"DextheChik3n"},"content":"![Storage Class Diagram](images/class/Storage.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":"*Figure 6: Storage Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"DextheChik3n"},"content":"The `Storage` class,","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"DextheChik3n"},"content":"- loads and saves the list of dishes on the `Menu`, available ingredient stock in `Pantry` and orders for the day in `OrderList` in a text file.","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"DextheChik3n"},"content":"- depends on `Menu`, `Pantry` and `Sales` objects (which are found in the data package).","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"DextheChik3n"},"content":"- is composed of `FileManager` object as the text file needs to be located first before reading or writing.","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":"### Data Component","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":"Folder: [Data]({repoURL}src/main/java/seedu/cafectrl/data)","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"NaychiMin"},"content":"![Data Class Diagram](images/class/Data.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"NaychiMin"},"content":"*Figure 7: Data Package Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"NaychiMin"},"content":"The \u0027Data\u0027 package consists of all the classes that the commands interact with to perform various functions.","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"NaychiMin"},"content":"A summary of the class diagram is as listed below:","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"NaychiMin"},"content":"- Each `Dish` within the `Menu` is constructed with a set of `Ingredient` instances, forming a one-to-many relationship with `Ingredient`.","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"NaychiMin"},"content":"- `Pantry` is instantiated with an ArrayList of `Ingredients` (`pantryStock`), forming a one-to-many relationship with `Ingredient`.","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"NaychiMin"},"content":"- The `Chef` class has a one-to-one relationship with `Pantry`, ensuring access to necessary ingredients for dish preparation.","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"NaychiMin"},"content":"- When an order is placed, the `Order` class is instantiated with an ArrayList of `Ingredient` (`ingredientList`), forming a one-to-many relationship with `Ingredient`.","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"NaychiMin"},"content":"- `OrderList` is instantiated with an ArrayList of `Order`, forming a one-to-many relationship with `Order`.","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"NaychiMin"},"content":"- `Sales` is instantiated with an ArrayList of `OrderList`, forming a one-to-many relationship with `OrderList`.","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":"- Lastly, the `CurrentDate` class keeps track of the current operating day of the cafe.","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"ziyi105"},"content":"## **Feature**","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":135,"author":{"gitId":"DextheChik3n"},"content":"### Add Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":136,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":137,"author":{"gitId":"Cazh1"},"content":"![Add Dish Execution](images/sequence/AddDishCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":"*Figure 8: Execution of add_dish command*","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":140,"author":{"gitId":"DextheChik3n"},"content":"API: [AddDishCommand.java](https://github.com/AY2324S1-CS2113-T17-2/tp/blob/master/src/main/java/seedu/cafectrl/command/AddDishCommand.java)","lastModifiedDate":"2023-10-25"},{"lineNumber":141,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":142,"author":{"gitId":"DextheChik3n"},"content":"The `add_dish` command, add a dish to the `Menu` object and prints out a formatted message to state the name, price and ingredients entered for the dish.","lastModifiedDate":"2023-10-25"},{"lineNumber":143,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":144,"author":{"gitId":"DextheChik3n"},"content":"when the `execute()` method from `AddDishCommand` is called in the main class `CafeCtrl`, the `addDish()` method is first called to add the `Dish` object to the `Menu`. It will then call the `printAddDishMessage()` method, which gets all the parameters of the `Dish` object (dishName, dishPrice, dishIngredients) and passes them to the `Ui` to then be printed out to the User.","lastModifiedDate":"2023-10-25"},{"lineNumber":145,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"DextheChik3n"},"content":"Separation of Concerns was applied to ensure the `Ui` is only responsible with only displaying messages while the `Menu` deals with the logic of adding dish to the menu. This implementation also encapsulates the details of adding a dish and displaying messages. For example, The `AddDishCommand` class doesn\u0027t need to know how the internal details of the dish adding and message printing are performed.","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":"### Adding a Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":"### List Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"Cazh1"},"content":"A `list_menu` command can be used to display all the `Dish` objects stored in `Menu`.","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of a list_menu command.","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":"![List Menu Execution](images/class/ListMenuCommandClass.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":"![List Menu Execution](images/sequence/ListMenuCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":158,"author":{"gitId":"NaychiMin"},"content":"Figure 9: Execution of list_menu command","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":"API: [ListMenuCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-10-26"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of ListMenuCommand is invoked in Main, it checks if the size of the menu by running `menu.getSize()`. ","lastModifiedDate":"2023-10-26"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":164,"author":{"gitId":"Cazh1"},"content":"1) If the menu is empty, it will call its `printEmptyMenu()` method to display to the user a `MENU_EMPTY_MESSAGE` in the Ui object and returns afterward.","lastModifiedDate":"2023-10-26"},{"lineNumber":165,"author":{"gitId":"Cazh1"},"content":"2) If the menu is not empty, it will call its `printFullMenu()` method.","lastModifiedDate":"2023-10-26"},{"lineNumber":166,"author":{"gitId":"Cazh1"},"content":"`printFullMenu()` will first print the top portion of the menu using the Ui object. ","lastModifiedDate":"2023-10-26"},{"lineNumber":167,"author":{"gitId":"Cazh1"},"content":"It then iterates through the `Dish` objects in `Menu` in a \"for\" loop, using `menu.getDishFromId()` to retrieve the Dish object.","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"Cazh1"},"content":"The `dishName` and `dishPrice` are both access from `Dish` Class using `getName()` and `getPrice()` respectively.","lastModifiedDate":"2023-10-26"},{"lineNumber":169,"author":{"gitId":"Cazh1"},"content":"The data are then packaged nicely in a `leftAlignFormat`, with (indexNum + \". \" + dishName,\" $\" + dishPrice) such that","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"Cazh1"},"content":" e.g. (1. Chicken Rice $2.50) is shown.","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"Cazh1"},"content":"### Add Order","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"Cazh1"},"content":"A add_order command can be used to add `order` to an `orderList` in `Sales`.","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of an add_order command.","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"Cazh1"},"content":"![Add_Order Execution](images/class/AddOrderCommandClass.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":"![Add_order Execution](images/sequence/AddOrderCommand_execute.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"NaychiMin"},"content":"*Figure 10: Execution of add_order command*","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"Cazh1"},"content":"API: [AddOrderCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of AddOrderCommand is invoked in Main, the parsed `order` object is added to the `orderList`.","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"Cazh1"},"content":"A `Chef` object is then created to process the order by running `cookDish()`. ","lastModifiedDate":"2023-10-31"},{"lineNumber":187,"author":{"gitId":"Cazh1"},"content":"This method first checks if the order has already been completed by running `order.getIsCompleted()`.","lastModifiedDate":"2023-10-31"},{"lineNumber":188,"author":{"gitId":"Cazh1"},"content":"If the order has not been completed, the `showDeleteMesage()` in the Ui component is triggered to display a message to show the user that the dish is being \u0027prepared\u0027.","lastModifiedDate":"2023-10-31"},{"lineNumber":189,"author":{"gitId":"Cazh1"},"content":"An ArrayList of Ingredients, ingredientList, is retrieved from the `order` object by `order.getIngredientList()`. ","lastModifiedDate":"2023-10-31"},{"lineNumber":190,"author":{"gitId":"Cazh1"},"content":"This ingredientList is passed into the `pantry` object in `pantry.decreaseIngredientsStock()` to process the ingredients used from the pantry stock.","lastModifiedDate":"2023-10-31"},{"lineNumber":191,"author":{"gitId":"Cazh1"},"content":"The order is then marked as completed by `order.setComplete()`","lastModifiedDate":"2023-10-31"},{"lineNumber":192,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":193,"author":{"gitId":"Cazh1"},"content":"Returning to the AddOrderCommand, the `order` object is checked to be completed again by running `order.getIsCompleted()`.","lastModifiedDate":"2023-10-31"},{"lineNumber":194,"author":{"gitId":"Cazh1"},"content":"This verifies that the ingredientList has been successfully retrieved and passed into `pantry.decreaseIngredientsStock()` to run without errors.","lastModifiedDate":"2023-10-31"},{"lineNumber":195,"author":{"gitId":"Cazh1"},"content":"After verifying that the order has been completed, the cost of the order is added to the total order by `orderList.addCost()`. ","lastModifiedDate":"2023-10-31"},{"lineNumber":196,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":197,"author":{"gitId":"Cazh1"},"content":"The total sum of orders in the `orderList` object is retrieved using `orderList.getTotalCost()`.","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"Cazh1"},"content":"This is then passed into Ui using `ui.showTotalCost()` to display a message to the user with the total order cost.","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"Cazh1"},"content":"### Next Day","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"Cazh1"},"content":"A `next_day` command can be used advance the current day.","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of a next_day command.","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"Cazh1"},"content":"![Next_Day Execution](images/class/NextDayCommandClass.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"Cazh1"},"content":"![Next_Day Execution](images/sequence/NextDayCommand_execute.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"NaychiMin"},"content":"*Figure 11: Execution of next_day command*","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"Cazh1"},"content":"API: [NextDayCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of NextDayCommand is invoked in Main, the day in the program is advanced by 1 day, by running `currentDate.nextDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"Cazh1"},"content":"The next day data is retrieved from the `CurrentDate` object using `currentDate.getCurrentDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"Cazh1"},"content":"This next day data is compared with the days accounted for in the `Sales` object, retrieved using `sales.getDaysAccounted()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"Cazh1"},"content":"If the next day is more than the number of days accounted in sales, this means that there is no `orderList` prepared for the coming day.","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"Cazh1"},"content":"A new `OrderList` object is created using `new OrderList()`, and added into the `Sales` object by running `sales.addOrderList()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"Cazh1"},"content":"Following this, the day has been accounted and this is updated through `sales.nextDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"Cazh1"},"content":"To end off the command, `ui.showNextDay()` is run to display a message to the user a prepared message for advancing the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"Cazh1"},"content":"The user is also shown the advanced day number.","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"Cazh1"},"content":"### Previous Day","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"Cazh1"},"content":"A `previous_day` command can be used to recede the current day.","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of a next_day command.","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"Cazh1"},"content":"![Previous_Day Execution](images/class/PreviousDayCommandClass.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"Cazh1"},"content":"![Previous_Day Execution](images/sequence/PreviousDayCommand_execute.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"NaychiMin"},"content":"*Figure 12: Execution of previous_day command*","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"Cazh1"},"content":"API: [PreviousDayCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of PreviousDayCommand is invoked in Main, the day in the program is receded by 1 day, by running `currentDate.previousDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"Cazh1"},"content":"To end off the command, `ui.showPreviousDay()` is run to display a message to the user a prepared message for receding the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"Cazh1"},"content":"The user is also shown the receded day number.","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"NaychiMin"},"content":"### List Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":242,"author":{"gitId":"Cazh1"},"content":"![List Ingredient Execution](images/sequence/ListIngredientCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":243,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":244,"author":{"gitId":"NaychiMin"},"content":"*Figure 13: Execution of list_ingredient command*","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":246,"author":{"gitId":"NaychiMin"},"content":"API: [ListIngredientCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListIngredientCommand.java)","lastModifiedDate":"2023-10-25"},{"lineNumber":247,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":248,"author":{"gitId":"NaychiMin"},"content":"| No | Step | Description |","lastModifiedDate":"2023-10-25"},{"lineNumber":249,"author":{"gitId":"NaychiMin"},"content":"|----|-------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-25"},{"lineNumber":250,"author":{"gitId":"NaychiMin"},"content":"| 1 | Initialization | The sequence begins with the `Main` class invoking the `execute` method of the `ListIngredientCommand` after parsing a user command. |","lastModifiedDate":"2023-10-25"},{"lineNumber":251,"author":{"gitId":"NaychiMin"},"content":"| 2-3 | Interaction with \u0027Menu\u0027 | The `ListIngredientCommand` communicates with the `Menu` class, invoking the `getMenuItemsList()` method to retrieve a list of menu items. The function returns an ArrayList of objects of \u0027Dish\u0027 type. |","lastModifiedDate":"2023-10-25"},{"lineNumber":252,"author":{"gitId":"NaychiMin"},"content":"| 4 | Interaction with \u0027Ui\u0027 | The `ListIngredientCommand` communicates with the `Ui` class, invoking the `printIngredients()` method to print out the list of ingredients used for the selected dish. \u003cbr/\u003e * The function returns an ArrayList of objects of \u0027Dish\u0027 type. The `get()` method is then invoked to get the dish of the specified index. However, this is ommitted to prevent unnecessary sophistication. |","lastModifiedDate":"2023-10-25"},{"lineNumber":253,"author":{"gitId":"NaychiMin"},"content":"| 5-6 | Interaction with \u0027Dish\u0027 | The `Ui` class communicates with the `Dish` class, invoking the `getIngredients()` method to obtain the list of ingredients for the selected dish. The `Dish` class responds with an ArrayList of objects of \u0027Ingredient\u0027 type to the `Ui` class. |","lastModifiedDate":"2023-10-25"},{"lineNumber":254,"author":{"gitId":"NaychiMin"},"content":"| 7-8 | Iteration through Ingredients | There is a loop that iterates through each ingredient in the list. The `Ui` class interacts with the `Ingredients` class, converting each ingredient to a string containing the ingredient and quantity needed. |","lastModifiedDate":"2023-10-25"},{"lineNumber":255,"author":{"gitId":"NaychiMin"},"content":"| 9-10 | Display to User | The `Ui` class showcases the information to the user through the `showToUser()` method. |","lastModifiedDate":"2023-10-25"},{"lineNumber":256,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":257,"author":{"gitId":"NaychiMin"},"content":"### Delete Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":258,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":259,"author":{"gitId":"Cazh1"},"content":"![Delete Dish Execution](images/sequence/DeleteDishCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":260,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"NaychiMin"},"content":"*Figure 14: Execution of delete dish command*","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":263,"author":{"gitId":"ShaniceTang"},"content":"API: [DeleteDishCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/DeleteDishCommand.java)","lastModifiedDate":"2023-10-25"},{"lineNumber":264,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":265,"author":{"gitId":"ShaniceTang"},"content":"When the `execute()` method of `DeleteDishCommand` is invoked in `Main`, it subsequently calls `getMenuItemsList().get(dishIndexToBeDeleted)` method on the `Menu` object to retrieve the `Dish` object to be deleted.","lastModifiedDate":"2023-10-25"},{"lineNumber":266,"author":{"gitId":"ShaniceTang"},"content":"Following this, the `showDeleteMesage()` method in the Ui component is triggered to display a message to show the user which dish is about to be deleted.","lastModifiedDate":"2023-10-25"},{"lineNumber":267,"author":{"gitId":"ShaniceTang"},"content":"Afterward, `DeleteDishCommand` calls `removeDish(dishIndexToBeDeleted)` of the `Menu` object to remove the selected dish at the index indicated by the user.","lastModifiedDate":"2023-10-25"},{"lineNumber":268,"author":{"gitId":"ShaniceTang"},"content":"This sequence of actions orchestrates the flow of information and operations between `Main`, `DeleteDishCommand`, `Menu`, and `Ui` components, ensuring the seamless handling of the dish deleting functionality within the application.","lastModifiedDate":"2023-10-25"},{"lineNumber":269,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":270,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":271,"author":{"gitId":"ShaniceTang"},"content":"`DeleteDishCommand` is implemented in such a way because:","lastModifiedDate":"2023-10-25"},{"lineNumber":272,"author":{"gitId":"ShaniceTang"},"content":"1. It promotes loose coupling between components. For instance, `Main` doesn\u0027t need to know the details of how the `execute()` of `DeleteDishCommand` is executed or how the message is displayed in `Ui`.","lastModifiedDate":"2023-10-25"},{"lineNumber":273,"author":{"gitId":"ShaniceTang"},"content":"2. Each component has a specific role and responsibility. `Main` is responsible for receiving user input and invoking `execute()`, `DeleteDishCommand` is responsible for encapsulating the delete operation, `Menu` is responsible for managing the menu items, and `Ui` is responsible for displaying messages to the user. This separation of concerns makes the code more maintainable and easier to understand.","lastModifiedDate":"2023-10-25"},{"lineNumber":274,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":275,"author":{"gitId":"ziyi105"},"content":"### Edit Price","lastModifiedDate":"2023-10-24"},{"lineNumber":276,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":277,"author":{"gitId":"Cazh1"},"content":"![Edit Price Execution](images/sequence/EditPriceCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":278,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":279,"author":{"gitId":"NaychiMin"},"content":"*Figure 15: Execution of edit_price command*","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":281,"author":{"gitId":"ziyi105"},"content":"API: [EditPriceCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/EditPriceCommand.java)","lastModifiedDate":"2023-10-24"},{"lineNumber":282,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":283,"author":{"gitId":"ziyi105"},"content":"When the `execute()` method of `EditPriceCommand` is invoked in `Main`, it subsequently calls the `setPrice()` method on the `Dish` object to modify the price of the specific dish. Following this, the `showEditPriceMessages()` method in the `Ui` component is triggered to retrieve and display a message from `Messages` related to the successful execution of the price modification process. This sequence of actions orchestrates the flow of information and operations between the `Main`, `EditPriceCommand`, `Dish`, and `Ui` components, ensuring the seamless handling of the price editing functionality within the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":284,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":285,"author":{"gitId":"ziyi105"},"content":"### Help","lastModifiedDate":"2023-10-31"},{"lineNumber":286,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":287,"author":{"gitId":"ziyi105"},"content":"![Help Execution](images/sequence/HelpCommand_execute.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":288,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":289,"author":{"gitId":"NaychiMin"},"content":"*Figure 16: Execution of help command*","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":291,"author":{"gitId":"ziyi105"},"content":"API: [HelpCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/HelpCommand.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":292,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":293,"author":{"gitId":"ziyi105"},"content":"When the `execute()` method of `HelpCommand` is invoked in `Main`, it subsequently calls the `showHelp()` method in `Ui`. In `showHelp()`, messages related to command usage will be retrieved and be printed out using by self-invoking `showToUserWithSpaceInBetweenLines(messages: String...)`.","lastModifiedDate":"2023-10-31"},{"lineNumber":294,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":295,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":296,"author":{"gitId":"ziyi105"},"content":"## **Product scope**","lastModifiedDate":"2023-11-02"},{"lineNumber":297,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":298,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":299,"author":{"gitId":"ziyi105"},"content":"Café proprietors who ***love*** typing on CLI and are seeking for a software solution to optimize the management of their café\u0027s operations.","lastModifiedDate":"2023-11-02"},{"lineNumber":300,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":301,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":302,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":303,"author":{"gitId":"DextheChik3n"},"content":"Our product aims to optimize managing of inventory and cash flow in a restaurant. Our CLI platform empowers users to streamline stock inventory, menu and orders. Users will also briefly be able to gain valuable insights through comprehensive sales reporting, enabling them to analyze sales trends and calculate revenue/profit margins, eliminating the need for cross-platform management.","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":305,"author":{"gitId":"ziyi105"},"content":"### User stories","lastModifiedDate":"2023-11-02"},{"lineNumber":306,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":307,"author":{"gitId":"ziyi105"},"content":"| Priority | As a …​ | I want to …​ | So that I can…​ |","lastModifiedDate":"2023-11-02"},{"lineNumber":308,"author":{"gitId":"ziyi105"},"content":"|----------|-----------------------------------------------------------|---------------------------------------------------------|-----------------------------------------------------------------------------------------|","lastModifiedDate":"2023-11-02"},{"lineNumber":309,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who is responsible for coming up with new dish | add dish to the menu | add new dish to the menu |","lastModifiedDate":"2023-11-02"},{"lineNumber":310,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe manager is responsible for managing pantry stock | track the inventory levels for ingredients and supplies | know what ingredients I need to restock |","lastModifiedDate":"2023-11-02"},{"lineNumber":311,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe manager is responsible for managing pantry stock | buy ingredients | restock low stock ingredients |","lastModifiedDate":"2023-11-02"},{"lineNumber":312,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who is also the chef | view the ingredients needed for a dish | know what ingredients to use when cooking a dish |","lastModifiedDate":"2023-11-02"},{"lineNumber":313,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who wants to maximise profit | edit the price of the dish | increase the price of the dish when there is inflation |","lastModifiedDate":"2023-11-02"},{"lineNumber":314,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who cares about the sales of the cafe | view the sales of the cafe | know whether my cafe is profiting |","lastModifiedDate":"2023-11-02"},{"lineNumber":315,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who works 7 days a week | save the menu, pantry stock and order | have access to the same menu, pantry stock and orders when I go back to work |","lastModifiedDate":"2023-11-02"},{"lineNumber":316,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who is responsible for placing order | add order | ask the chef to cook the order |","lastModifiedDate":"2023-11-02"},{"lineNumber":317,"author":{"gitId":"ziyi105"},"content":"| `* *` | cafe manager who is responsible for drafting the menu | view the menu | keep track of what dish we have |","lastModifiedDate":"2023-11-02"},{"lineNumber":318,"author":{"gitId":"ziyi105"},"content":"| `* *` | cafe owner who working 7 days a week | fast forward to the next day | close the cafe and call it a day when I am tired |","lastModifiedDate":"2023-11-02"},{"lineNumber":319,"author":{"gitId":"ziyi105"},"content":"| `* *` | clumsy cafe owner who works 7 days a week | go back to the previous day | still accept order from the previous day if I accidentally fast forward to the next day | ","lastModifiedDate":"2023-11-02"},{"lineNumber":320,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":321,"author":{"gitId":"ziyi105"},"content":"*{More to be added}*","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"NaychiMin":67,"DextheChik3n":23,"Cazh1":84,"ziyi105":98,"ShaniceTang":25,"-":24}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"# CafeCTRL","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"CafeCTRL aims to optimize managing of inventory and cash flow in a restaurant. Our CLI platform empowers Café proprietors to streamline inventory and menu management.","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"DextheChik3n":2,"-":6}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# User Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"* Table of Contents","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"* [User Guide](#user-guide)","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" * [Introduction](#introduction)","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" * [Quick Start](#quick-start)","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" * [Features](#features-)","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" * [Viewing help : `help`](#viewing-help--help)","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" * [Adding a dish : `add`](#adding-a-dish--add)","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" * [Listing all menu items : `list_menu`](#listing-all-menu-items--listmenu)","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" * [Listing ingredients needed for the selected dish : `list_ingredients`](#listing-ingredients-needed-for-the-selected-dish--listingredients)","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" * [Deleting a menu item : `delete`](#deleting-a-menu-item--delete)","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" * [Editing price of menu item : `edit_price`](#editing-price-of-menu-item--editprice)","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" * [Viewing the total stock of ingredients : `view_stock`](#viewing-the-total-stock-of-ingredients--viewstock)","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" * [Buying an ingredient : `buy_ingredient`](#buying-an-ingredient--buyingredient)","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" * [Showing all sales : `show_sales`](#showing-all-sales--showsales)","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" * [Showing sales for a chosen day : `show_sale`](#showing-sales-for-a-chosen-day--showsale)","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" * [Adding an order : `add_order`](#adding-an-order--addorder)","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" * [Returning to the previous day: `previous_day`](#returning-to-the-previous-day-previousday)","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" * [Advancing to the next day: `next_day`](#advancing-to-the-next-day-nextday)","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" * [Exiting the program : `bye`](#exiting-the-program--bye)","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" * [Known Issues](#known-issues)","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" * [Command Summary](#command-summary)","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"---------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"CafeCTRL aims to optimize managing of inventory and cash flow in a restaurant. Our CLI platform empowers Café proprietors to streamline inventory and menu management.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"---------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":"1. Ensure that you have Java `11` or above installed. ","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":"2. Down the latest version of `CafeCtrl` from [here](https://github.com/AY2324S1-CS2113-T17-2/tp/releases).","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":"3. Copy the file to the folder you want to use as the home folder for your Cafe Manager CLI Application.","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"4. Open a command terminal, `cd` into the folder you put the jar file in, and use the `java -jar tp.jar` command to run the application.","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":"5. If the setup is correct, you should see something like the below as the output:","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":"Hello! Welcome to CafeCTRL!","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":"\u003e ","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":"---------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":"## Features ","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":"\u003e **Notes about command format:**","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Words in `UPPER_CASE` are the arguments to be supplied by user. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" e.g. in add name/NAME, NAME is a parameter that can be used as add name/Chicken.","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Parameters need to be in the exact format as specified. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" e.g. `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY`,\u003cbr\u003e `name/` must come before `price/`.","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Items in square brackets with …​ can be used multiple times including zero times. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" e.g. `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY [, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]` \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":" can be used as \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":" `add name/Christmas Ham price/50.00 ingredient/Ham qty/1000g`\u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"DextheChik3n"},"content":" or as \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" `add name/chicken rice price/2.00 ingredient/rice qty/100g, ingredient/chicken qty/200g, ingredient/garlic qty/100g`","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Extraneous parameters for commands that do not take in parameters (such as `help`, `list_menu`, `bye`) will be ignored. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" e.g. if the command specifies `help 123`, it will be interpreted as `help`.","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":"### Viewing help : `help`","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":"Shows a message explaining how to use all the commands","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":62,"author":{"gitId":"DextheChik3n"},"content":"Format: `help`","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"ziyi105"},"content":"Output:","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":"These are all the commands I recognise: ","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":"(- Words in UPPER_CASE are the parameters to be supplied by the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":"e.g. in add name/NAME, NAME is a parameter that can be used as add name/Chicken.","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":"- Parameters in [] are optional.)","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":"Command Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":"add name/DISH_NAME price/DISH_PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME, qty/INGREDIENT2_QTY...]","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":"(Items in square brackets [] are optional)","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":"Example:","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":"add name/chicken rice price/3.00 ingredient/rice qty/200g, ingredient/chicken qty/100g","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"ziyi105"},"content":"list_ingredients: Lists out the ingredients needed along with the quantity for a specific dish.","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":"Parameters: INDEX","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":"Example: list_ingredients 1","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"ziyi105"},"content":"To list out all dishes on the menu: list_menu","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"ziyi105"},"content":"To delete a menu item: delete DISH_INDEX","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"ziyi105"},"content":"Example: delete 1","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":"edit_priceTo edit price of a menu item: edit_price index/DISH_INDEX price/NEW_PRICE","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":"Example: edit_price index/1 price/4.50","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"DextheChik3n"},"content":"\u003c!---@@author DextheChik3n---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"DextheChik3n"},"content":"### Adding a dish : `add`","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"DextheChik3n"},"content":"Adds a dish consisting of its ingredients to the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":93,"author":{"gitId":"DextheChik3n"},"content":"Format: `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":95,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":96,"author":{"gitId":"DextheChik3n"},"content":"* The `PRICE` must be a positive 2 decimal place number.","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"DextheChik3n"},"content":"* The `IMGREDIENT_QTY` must contain the unit ml or g specifically.","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"DextheChik3n"},"content":" * e.g. `qty/50g` or `qty/1000ml`","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":100,"author":{"gitId":"DextheChik3n"},"content":"Example:","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"DextheChik3n"},"content":"\u003e add name/chicken rice price/2.00 ingredient/rice qty/100g, ingredient/chicken qty/200g, ingredient/soup qty/50ml","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"DextheChik3n"},"content":"You have added the following dish...","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"DextheChik3n"},"content":"Dish Name: chicken rice","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"DextheChik3n"},"content":"Dish Price: $2.00","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"DextheChik3n"},"content":"chicken rice Ingredients: ","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"DextheChik3n"},"content":"rice - 100g","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"DextheChik3n"},"content":"chicken - 200g","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"DextheChik3n"},"content":"soup - 50ml","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":112,"author":{"gitId":"Cazh1"},"content":"\u003c!---@@author Cazh1---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"Cazh1"},"content":"### Listing all menu items : `list_menu`","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"Cazh1"},"content":"Shows a list of all dishes on the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":116,"author":{"gitId":"Cazh1"},"content":"Format: `list_menu`","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":118,"author":{"gitId":"Cazh1"},"content":"Example:","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"Cazh1"},"content":"+-----------------------------------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"Cazh1"},"content":"| Ah, behold, the grand menu of delights! |","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"Cazh1"},"content":"+--------------------------+--------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"Cazh1"},"content":"| Dish Name | Price |","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"Cazh1"},"content":"+--------------------------+--------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"Cazh1"},"content":"| 1. chicken rice | $2.50 |","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"Cazh1"},"content":"| 2. chicken curry | $4.30 |","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"Cazh1"},"content":"+-----------------------------------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":"\u003c!---@@author NaychiMin---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":"### Listing ingredients needed for the selected dish : `list_ingredients`","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"NaychiMin"},"content":"Lists out the ingredients needed along with the quantity for a specific dish","lastModifiedDate":"2023-10-30"},{"lineNumber":133,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":134,"author":{"gitId":"NaychiMin"},"content":"Format: `list_ingredients DISH_INDEX`","lastModifiedDate":"2023-10-30"},{"lineNumber":135,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":136,"author":{"gitId":"NaychiMin"},"content":"Example:","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"NaychiMin"},"content":"- list followed by list_ingredients 1 lists the ingredients of the 1st dish on the menu","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"NaychiMin"},"content":"chicken salad Ingredients: ","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"NaychiMin"},"content":"pasta - 100g","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"NaychiMin"},"content":"chicken - 200g","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"NaychiMin"},"content":"lettuce - 200g","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":"tomatoes - 100g","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":"feta cheese - 20g","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"NaychiMin"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":"list followed by list_ingredients 1 lists the ingredients of the 1st dish on the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":151,"author":{"gitId":"ShaniceTang"},"content":"\u003c!---@@author ShaniceTang---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"ShaniceTang"},"content":"### Deleting a menu item : `delete`","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"ShaniceTang"},"content":"Deletes a specific dish from the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"ShaniceTang"},"content":"Format: `delete DISH_INDEX`","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"ShaniceTang"},"content":"* Deletes the dish at the specified DISH_INDEX","lastModifiedDate":"2023-10-30"},{"lineNumber":158,"author":{"gitId":"ShaniceTang"},"content":"* The index refers to the index number shown in the menu list ","lastModifiedDate":"2023-10-30"},{"lineNumber":159,"author":{"gitId":"ShaniceTang"},"content":"* The index must be a positive integer","lastModifiedDate":"2023-10-30"},{"lineNumber":160,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":161,"author":{"gitId":"ShaniceTang"},"content":"Example: `delete 1`","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"ShaniceTang"},"content":"Okay! chicken rice is deleted! :)","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":168,"author":{"gitId":"ziyi105"},"content":"\u003c!---@@author ziyi105---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"ziyi105"},"content":"### Editing price of menu item : `edit_price`","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"ziyi105"},"content":"Edits the price of an existing dish on the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":172,"author":{"gitId":"ziyi105"},"content":"Format: `edit_price index/DISH_INDEX price/NEW_PRICE`","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":174,"author":{"gitId":"ziyi105"},"content":"Example: `edit_price index/1 price/4.50`","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":176,"author":{"gitId":"ziyi105"},"content":"Output: ","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"ziyi105"},"content":"Price modified for the following dish: ","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"ziyi105"},"content":"Chicken rice - $4.50","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":182,"author":{"gitId":"ShaniceTang"},"content":"\u003c!---@@author ShaniceTang---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"ShaniceTang"},"content":"### Viewing the total stock of ingredients : `view_stock`","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"ShaniceTang"},"content":"Displays the available stock of all the ingredients found in the pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"ShaniceTang"},"content":"Format: `view_stock`","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"ShaniceTang"},"content":"You have the following ingredients in pantry:","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"ShaniceTang"},"content":"Ingredients\t\tQty","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"ShaniceTang"},"content":"chicken\t\t\t500g","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"ShaniceTang"},"content":"milk\t\t\t1000ml","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":196,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":197,"author":{"gitId":"ShaniceTang"},"content":"### Buying an ingredient : `buy_ingredient`","lastModifiedDate":"2023-10-30"},{"lineNumber":198,"author":{"gitId":"ShaniceTang"},"content":"Adds one or more ingredients to the pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"ShaniceTang"},"content":"Format: `buy_ingredient ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"ShaniceTang"},"content":"Example: `buy_ingredient ingredient/chicken qty/500g, ingredient/milk qty/1000ml`","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":204,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ShaniceTang"},"content":"Added to stock:","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"ShaniceTang"},"content":"Ingredient: chicken\t\tQty: 500g","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"ShaniceTang"},"content":"Ingredient: milk\t\tQty: 1000ml","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"ShaniceTang"},"content":"### Showing all sales : `show_sales`","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"ShaniceTang"},"content":"Displays the dishes sold and total sales for each from Day 1 to the current day that ","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"ShaniceTang"},"content":"the cafe is operating on.","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"ShaniceTang"},"content":"Format: `show_sales`","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"ShaniceTang"},"content":"Example: `show_sales`","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"ShaniceTang"},"content":"- show_sales lists the dishes sold along with the total sales for every operating day of the cafe.","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"ShaniceTang"},"content":"Day 1:","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"ShaniceTang"},"content":"Dish Name Dish Qty Total Cost Price ","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"ShaniceTang"},"content":"chicken rice 4 12.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"ShaniceTang"},"content":"Total for day: $12.00","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"ShaniceTang"},"content":"Day 2:","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"ShaniceTang"},"content":"Dish Name Dish Qty Total Cost Price ","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"ShaniceTang"},"content":"chicken chop 5 21.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"ShaniceTang"},"content":"chicken rice 3 9.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"ShaniceTang"},"content":"Total for day: $30.00","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"ShaniceTang"},"content":"### Showing sales for a chosen day : `show_sale`","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"ShaniceTang"},"content":"Displays the dishes sold along with the total sales for any chosen day.","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":246,"author":{"gitId":"ShaniceTang"},"content":"Format: `show_sale day/DAY_TO_DISPLAY`","lastModifiedDate":"2023-11-01"},{"lineNumber":247,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":248,"author":{"gitId":"ShaniceTang"},"content":"Example: `show_sale day/1`","lastModifiedDate":"2023-11-01"},{"lineNumber":249,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":250,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":251,"author":{"gitId":"ShaniceTang"},"content":"- show_sale day/1 lists the dishes sold along with the total sales for day 1.","lastModifiedDate":"2023-11-01"},{"lineNumber":252,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":253,"author":{"gitId":"ShaniceTang"},"content":"Day 1:","lastModifiedDate":"2023-11-01"},{"lineNumber":254,"author":{"gitId":"ShaniceTang"},"content":"Dish Name Dish Qty Total Cost Price ","lastModifiedDate":"2023-11-01"},{"lineNumber":255,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":256,"author":{"gitId":"ShaniceTang"},"content":"chicken rice 4 12.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":257,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":258,"author":{"gitId":"ShaniceTang"},"content":"Total for day: $12.00","lastModifiedDate":"2023-11-01"},{"lineNumber":259,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":260,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"Cazh1"},"content":"\u003c!---@@author Cazh1---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"Cazh1"},"content":"### Adding an order : `add_order`","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"Cazh1"},"content":"Adds an order consisting of dishes off the menu to an order list","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"Cazh1"},"content":"Format: `add_order name/DISH_NAME qty/DISH_QTY`","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"Cazh1"},"content":"Example:","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":269,"author":{"gitId":"Cazh1"},"content":"\u003e add_order name/chicken rice qty/2","lastModifiedDate":"2023-11-01"},{"lineNumber":270,"author":{"gitId":"Cazh1"},"content":"I\u0027m busy crafting your selected dish in the virtual kitchen of your dreams. Bon appétit!","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"Cazh1"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"Cazh1"},"content":"Order is ready!","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"Cazh1"},"content":"Total order cost: $5.00","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"Cazh1"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"Cazh1"},"content":"Listed below are the availability of the dishes for the next order!","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"Cazh1"},"content":"Dish: chicken rice","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"Cazh1"},"content":"Available Dishes: 8","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"Cazh1"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":279,"author":{"gitId":"Cazh1"},"content":"Dish: chicken curry","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"Cazh1"},"content":"Available Dishes: 4","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":282,"author":{"gitId":"Cazh1"},"content":"* The `DISH_QTY` must be a positive integer number.","lastModifiedDate":"2023-11-01"},{"lineNumber":283,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":284,"author":{"gitId":"Cazh1"},"content":"Adds an order to the current business day","lastModifiedDate":"2023-11-01"},{"lineNumber":285,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":286,"author":{"gitId":"Cazh1"},"content":"Format: `add_order name/DISH_NAME qty/QUANTITY`","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"Cazh1"},"content":"Example: `add_order name/chicken rice qty/2`","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"Cazh1"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":291,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":292,"author":{"gitId":"Cazh1"},"content":"I\u0027m busy crafting your selected dish in the virtual kitchen of your dreams. Bon appétit!","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"Cazh1"},"content":"Is order completed?: true","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"Cazh1"},"content":"Total orderList cost: $4.00","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"Cazh1"},"content":"### Returning to the previous day: `previous_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":300,"author":{"gitId":"Cazh1"},"content":"Goes back to the previous business day","lastModifiedDate":"2023-11-01"},{"lineNumber":301,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":302,"author":{"gitId":"Cazh1"},"content":"Format: `previous_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":303,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"Cazh1"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":305,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":306,"author":{"gitId":"Cazh1"},"content":"Sure thing! Let\u0027s rev up the virtual DeLorean and take a spin to the previous day. Buckle up, it\u0027s time to hit that rewind button!","lastModifiedDate":"2023-11-01"},{"lineNumber":307,"author":{"gitId":"Cazh1"},"content":"Today is Day 1","lastModifiedDate":"2023-11-01"},{"lineNumber":308,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":309,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":310,"author":{"gitId":"Cazh1"},"content":"### Advancing to the next day: `next_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":311,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":312,"author":{"gitId":"Cazh1"},"content":"Proceeds to the next business day","lastModifiedDate":"2023-11-01"},{"lineNumber":313,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":314,"author":{"gitId":"Cazh1"},"content":"Format: `next_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":315,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":316,"author":{"gitId":"Cazh1"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":317,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":318,"author":{"gitId":"Cazh1"},"content":"Prepare for liftoff! We\u0027re about to fast-forward to the next day. Hold onto your hats; here we go!","lastModifiedDate":"2023-11-01"},{"lineNumber":319,"author":{"gitId":"Cazh1"},"content":"Today is Day 2","lastModifiedDate":"2023-11-01"},{"lineNumber":320,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":321,"author":{"gitId":"Cazh1"},"content":"\u003c!---@@author---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":322,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":323,"author":{"gitId":"DextheChik3n"},"content":"### Exiting the program : `bye`","lastModifiedDate":"2023-10-30"},{"lineNumber":324,"author":{"gitId":"DextheChik3n"},"content":"Exits the program.","lastModifiedDate":"2023-10-30"},{"lineNumber":325,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":326,"author":{"gitId":"DextheChik3n"},"content":"Format: `bye`","lastModifiedDate":"2023-10-30"},{"lineNumber":327,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":328,"author":{"gitId":"ziyi105"},"content":"----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":329,"author":{"gitId":"NaychiMin"},"content":"## Known Issues","lastModifiedDate":"2023-11-01"},{"lineNumber":330,"author":{"gitId":"DextheChik3n"},"content":"- The application is unable to read the data text files if they have been edited directly in the wrong decoding format","lastModifiedDate":"2023-11-01"},{"lineNumber":331,"author":{"gitId":"DextheChik3n"},"content":"- For edit price command, special characters can be entered in the price argument","lastModifiedDate":"2023-11-01"},{"lineNumber":332,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":333,"author":{"gitId":"ziyi105"},"content":"----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":334,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2023-10-30"},{"lineNumber":335,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":336,"author":{"gitId":"DextheChik3n"},"content":"| Action | Format, Examples |","lastModifiedDate":"2023-10-30"},{"lineNumber":337,"author":{"gitId":"DextheChik3n"},"content":"|---------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-30"},{"lineNumber":338,"author":{"gitId":"DextheChik3n"},"content":"| **Add** | `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY [, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr/\u003e`add name/chicken rice price/3.00 ingredient/rice qty/50g, ingredient/chicken qty/100g` |","lastModifiedDate":"2023-10-30"},{"lineNumber":339,"author":{"gitId":"DextheChik3n"},"content":"| **List Menu** | `list_menu` |","lastModifiedDate":"2023-10-30"},{"lineNumber":340,"author":{"gitId":"ziyi105"},"content":"| **List Ingredients** | `list_ingredients DISH_INDEX`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`list_ingredients 1` |","lastModifiedDate":"2023-11-03"},{"lineNumber":341,"author":{"gitId":"ziyi105"},"content":"| **Delete** | `delete DISH_INDEX`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`delete 1` |","lastModifiedDate":"2023-11-03"},{"lineNumber":342,"author":{"gitId":"ziyi105"},"content":"| **Edit Price** | `edit_price index/DISH_INDEX price/NEW_PRICE`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`edit_price index/1 price/4.50` |","lastModifiedDate":"2023-11-03"},{"lineNumber":343,"author":{"gitId":"NaychiMin"},"content":"| **Show Sale** | `show_sales` |","lastModifiedDate":"2023-11-01"},{"lineNumber":344,"author":{"gitId":"ziyi105"},"content":"| **Show Sale by Day** | `show_sale day/DAY_TO_DISPLAY` \u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`show_sale day/ 1` |","lastModifiedDate":"2023-11-03"},{"lineNumber":345,"author":{"gitId":"ShaniceTang"},"content":"| **View Ingredient Stock** | `view_stock` |","lastModifiedDate":"2023-11-01"},{"lineNumber":346,"author":{"gitId":"ziyi105"},"content":"| **Buy Ingredients** | `buy_ingredient ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`\u003cbr\u003e\u003cbr/\u003eExample\u003cbr\u003e`buy_ingredient ingredient/chicken qty/500g, ingredient/milk qty/1000ml` |","lastModifiedDate":"2023-11-03"},{"lineNumber":347,"author":{"gitId":"ziyi105"},"content":"| **Add Order** | `add_order name/DISH_NAME qty/QUANTITY`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`add_order name/chicken rice qty/2` |","lastModifiedDate":"2023-11-03"},{"lineNumber":348,"author":{"gitId":"ShaniceTang"},"content":"| **Previous Day** | `previous_day` |","lastModifiedDate":"2023-11-01"},{"lineNumber":349,"author":{"gitId":"ShaniceTang"},"content":"| **Next Day** | `next_day` |","lastModifiedDate":"2023-11-01"},{"lineNumber":350,"author":{"gitId":"DextheChik3n"},"content":"| **Help** | `help` |","lastModifiedDate":"2023-10-30"},{"lineNumber":351,"author":{"gitId":"DextheChik3n"},"content":"| **Exit Program** | `bye` |","lastModifiedDate":"2023-10-30"},{"lineNumber":352,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"NaychiMin":23,"DextheChik3n":62,"Cazh1":79,"ziyi105":73,"ShaniceTang":99,"-":16}},{"path":"docs/diagrams/ArchitectureDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"\u0027https://plantuml.com/deployment-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"actor User","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"rectangle {","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"rectangle Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"rectangle Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"rectangle Command","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"rectangle Main","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"rectangle Data","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"rectangle Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"folder TextFiles","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"User ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"Ui --\u003e Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"Parser --\u003e Command","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"Parser ..\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"Command --\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"Command ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"Storage --\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"Storage ...\u003e TextFiles","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"Ui \u003c- Main","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"Main --\u003e Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"Main --\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"Main --\u003e Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":31}},{"path":"docs/diagrams/class/AddOrderCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `add_order` Command","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" UI","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- AddOrderCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" AddOrderCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"Parser ..\u003e CurrentDate","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"Parser ..\u003e Sales","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand --\u003e OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand \"1\" --\u003e \"1\" Chef","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand --\u003e Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand ..\u003e Order","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"OrderList --\u003e \"*\" Order","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"Sales --\u003e \"1...*\" OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"Chef ..\u003e Pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"class UI {","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"+ showToUser() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"+ showChefMessage() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"+ showTotalCost(dollarCost : String) : void","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"class AddOrderCommand {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"# pantry : Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"# orderList : OrderList","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"# menu : Menu","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"- order : Order","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"{static} - prepareOrder(menu : Menu, arguments : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"{static} - setOrderList(currentDate : CurrentDate, sales : Sales)","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":"class OrderList {","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"- orderList : ArrayList\u003cOrder\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"- totalOrderListCost : float","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":"+ addOrder() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":"+ addCost() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":"+ getTotalCost() : float","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"class Order {","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"- orderedDish : Dish","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":"- dishQty : int","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":"- ingredientList : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":"- isComplete : boolean","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"- totalOrderCost : float","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":"- getDishPrice() : float","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":"- setIngredientList() : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":"+ getIngredientList() : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":"+ getTotalOrderCost() : float","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"Cazh1"},"content":"+ setComplete() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"Cazh1"},"content":"+ getIsComplete() : boolean","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":"class Chef {","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":"- order : Order","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":"- pantry : Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":"+ cookDish() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"Cazh1"},"content":"class Pantry {","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"Cazh1"},"content":"- pantryStock : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"Cazh1"},"content":"- menuItems : ArrayList\u003cDish\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"Cazh1"},"content":"+ isDishCooked( :ArrayList\u003cIngredient\u003e) : boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"Cazh1"},"content":"+ calculateDishAvailability(menu : Menu) : void","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"Cazh1"},"content":"class Sales {","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"Cazh1"},"content":"- orderLists : ArrayList\u003cOrderList\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"Cazh1"},"content":"+ getOrderList(index : int) : OrderList","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"Cazh1"},"content":"class CurrentDate {","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":"- currentDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":"+ getCurrentDay() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":104,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":105}},{"path":"docs/diagrams/class/Data.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"class Menu {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"+ getMenuItemsList(): ArrayList\u003cDish\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"+ getSize(): int","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"+ getDishFromId(menuID: int): Dish","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"+ getDishFromName(dishName: String): Dish","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"+ removeDish(menuID: int): void","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"+ addDish(dish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"+ isValidDishIndex(dishIndex: int): boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"class Dish {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"- name: String","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"- price: float","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"+ getName(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"+ getIngredients(): ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"+ getPrice(): float","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"+ setPrice(newPrice: float): void","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"class Ingredient {","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"- name: String","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"- qty: int","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"- unit: String","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"+ getName(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"+ getQty(): int","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"+ getUnit(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"+ setQty(qty:int): void","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":"class Pantry {","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"+ getPantryStock():ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":"+ addIngredientToStock(name: String, qty: int, unit: String): Ingredient","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":"+ isDishCooked(dishIngredients: ArrayList\u003cIngredient\u003e): boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":"- getIngredient(dishIngredient: Ingredient): Ingredient","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":"+ calculateDishAvailability(menu: Menu): void","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"+ calculateMaxDishes(dish: Dish, menu: Menu)","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":"- calculateMaxDishForEachIngredient(dishIngredient: Ingredient): int","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":"- handleRestock(dishIngredient: Ingredient): void","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":"+ retrieveIngredientsForDish(orderedDish: String, menu: Menu): ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":"class Chef {","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"- dollarValue: DecimalFormat","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":"+ cookDish(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":"class Order {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"- dollarValue: DecimalFormat","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":"- dishQty: int","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":"- isComplete: boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":"- totalOrderCost: float","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":"+ calculateTotalOrderCost(): float","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":"class OrderList {","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":"- dollarValue: DecimalFormat","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":"- HEADER_FORMAT: String","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":"- totalOrderListCost","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":"+ addOrder(order: Order): void","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":"+ addCost(order: Order): void","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":"+ printOrderList(menu: Menu, ui: Ui): void","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":"- aggregateOrder(order: Order, aggregatedOrder: ArrayList\u003cOrder\u003e): void","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":"- getIndexByDishName(aggregatedOrders: ArrayList\u003cOrder\u003e, dishName: String): int","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":"- calculateTotalCost(orders: ArrayList\u003cOrder\u003e): float","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":"class Sales {","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":"- HEADER_FORMAT: String","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":"- daysAccounted: int","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":"+ addOrderList(orderList: OrderList): void","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":"+ nextDay(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":"+ printSales(ui: Ui, menu Menu): void","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":"+ printSaleByDay(ui: Ui, menu: Menu, day: int): void","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":"class CurrentDate {","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":"- currentDay: int","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":"+ nextDay(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":"+ previousDay(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":"+ getCurrentDay(): int","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ShaniceTang"},"content":"class Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"ShaniceTang"},"content":"note bottom of Ui: Classes in ui package: \\nUi, Messages, and ErrorMessages","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"ShaniceTang"},"content":"Ingredient \"*\" \u003c--* \"1\" Dish : ingredients","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"ShaniceTang"},"content":"Dish \"*\" \u003c--* \"1\" Menu : menuItems","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"ShaniceTang"},"content":"Ingredient \"*\" \u003c--* \"1\" Pantry : pantryStock","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"ShaniceTang"},"content":"Dish \u003c.. Pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"ShaniceTang"},"content":"Chef \"1\" \u003c-- Pantry : pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"ShaniceTang"},"content":"Pantry ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"ShaniceTang"},"content":"Chef ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"ShaniceTang"},"content":"Ingredient \"*\" \u003c--* \"1\" Order : ingredientList","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"ShaniceTang"},"content":"Order \"*\" \u003c--* \"1\" OrderList : orderList","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"ShaniceTang"},"content":"Order \"1\" \u003c-- Chef : order","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"ShaniceTang"},"content":"OrderList \"*\" \u003c--* \"1\" Sales : orderLists","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":104}},{"path":"docs/diagrams/class/ListMenuCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `list_menu` Command","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" UI","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- ListMenuCommand","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" ListMenuCommand","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"ListMenuCommand --\u003e Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"Menu -- \"*\" Dish","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"class UI {","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"+ showMenuTop() : void","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"+ showMenuBottom() : void","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"+ showEmptyMenu() : void","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"+ showMenuDish(indexNum : String, dishName : String, dishPrice : String) : void","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"class ListMenuCommand {","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"- menu : Menu","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"+ printEmptyMenu(ui : Ui) : void","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"+ printFullMenu(menu : Menu, ui : Ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, orderList : OrderList) : Command","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"{static} - prepareListMenu(menu : Menu, ui : Ui) : Command","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"class Menu {","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"- menuItems : ArrayList\u003cDish\u003e","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"+ getDishFromId(menuID : int) : Dish","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"class Dish {","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"- name : String","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":"- price : float","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":"+ getName() : String","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":"+ getPrice() : float","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Cazh1":60}},{"path":"docs/diagrams/class/NextDayCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `next_day` Command","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" UI","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"NextDayCommand ..\u003e OrderList : Creates \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"NextDayCommand --\u003e CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"NextDayCommand --\u003e Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"Sales --\u003e \"1...*\" OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"class UI {","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"+ showToUser() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"+ printLine() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"+ showNextDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"class NextDayCommand {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"- sales : Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"- currentDate : CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"{static} - prepareNextDay(ui : Ui, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"class OrderList {","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"- orderList : ArrayList\u003cOrder\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"class Sales {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"- orderLists : ArrayList\u003cOrderList\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"- daysAccounted : int","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":"+ getDaysAccounted() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":"+ addOrderList(orderList : OrderList)","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":"+ nextDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":"class CurrentDate {","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":"- currentDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":"+ getCurrentDay() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"+ nextDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":67}},{"path":"docs/diagrams/class/Parser.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"interface ParserUtil {","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":" +parseCommand(): Command","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"class Parser {","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" -{static}INPUT_REGEX: String","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" +parseCommand(): Command","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" -prepareXYZCommand(): Command","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" -parsePriceToFloat(priceText: String): float","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" -parseIngredient(ingredientsListString: String): ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"abstract class Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" +execute(): void","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":"class XYZCommand {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" +execute(): void","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"class Ui {","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" +showToUser(textToShow: String): void","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"CafeCtrl ..\u003e ParserUtil: use","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"XYZCommand --|\u003e Command","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"CafeCtrl ..\u003e Command: execute","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":"ParserUtil \u003c|.. Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"Parser ..\u003e XYZCommand: create","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"XYZCommand *-- data: use","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":"note left: Classes in data package: Dish, Ingredient, \\nCurrentData, Menu, Order, Pantry and Sales","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"Command *-- Ui: use","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ziyi105":34}},{"path":"docs/diagrams/class/PreviousDayCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `previous_day` Command","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- PreviousDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" PreviousDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"PreviousDayCommand --\u003e CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"class Ui {","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"+ showToUser() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"+ printLine() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"+ showPreviousDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"class PreviousDayCommand {","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"- currentDate : CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"{static} - prepareNextDay(ui : Ui, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"class CurrentDate {","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"- currentDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"+ getCurrentDay() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"+ previousDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":51}},{"path":"docs/diagrams/class/Storage.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"class Storage {","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":" # fileManager: FileManager","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":" + loadMenu(): Menu","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":" - saveMenu(menu: Menu): void","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" + loadPantryStock(): Pantry","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" - savePantryStock(pantry: Pantry): void","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":" + loadOrderList(menu: menu): Sales","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" - saveOrderList(sales: Sales): void","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" + saveAll(menu: Menu, sales: Sales, pantry: Pantry): void","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":"class Data","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"note bottom of Data: Classes in data package: \\nMenu, Pantry and Sales","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"class Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"class FilePath {","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" + MENU_FILE_PATH: String","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" + PANTRY_STOCK_FILE_PATH: String","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" + ORDERS_FILE_PATH: String","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"class FileManager {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" + openTextFile(:FilePath): String","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" + readTextFile(:FilePath): ArrayList\u003cString\u003e): void","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" + overwriteFile(:FilePath, :ArrayList\u003cString\u003e): void","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":"class Decoder {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" + {static} decodeData(encodedData: ArrayList\u003cString\u003e): Data","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":" + {static} decodeSales(encodedOrderList: ArrayList\u003cString\u003e, menu: Menu): Data","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"note top of Decoder: decodeData function for\\nMenu and PantryStock data","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":"class Encoder {","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":" + {static} encodeData(data: Data): ArrayList\u003cString\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":"CafeCtrl *-- \"1\" Storage: initializes","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":"FileManager \"1\" --* Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":"Storage ..\u003e Data: stores \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":"Ui \"1\" --* FileManager : uses \u003c","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":"FileManager ..\u003e FilePath: reads from \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":"Encoder ..\u003e Data: encodes \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":"Decoder ..\u003e Data: decodes \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"DextheChik3n":53}},{"path":"docs/diagrams/class/Ui.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"class Ui {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"+ OFFSET_LIST_INDEX: int","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"- scanner: Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"+ receiveUserInput(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"+ showToUser(message: String)","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"+ printAddDishMessage(dish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"+ printIngredients(selectedDish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"+ printDeleteMessage(selectedDish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"+ showEditPriceMessage(menuItem: String): void","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"+ showHelp(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"class Messages","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"class ErrorMessages","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"class Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"class Command","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"class Main","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"class Data","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"class Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"Messages \u003c. Ui : prints \u003c","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"Ui .\u003e ErrorMessages : prints \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"Parser ..\u003e Ui : uses \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"*\" Command : ui","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"1\" Main : ui","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"*\" Data : ui","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"*\" Storage :ui","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":32}},{"path":"docs/diagrams/sequence/AddDishCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"autonumber","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"-\u003e AddDishCommand: execute()","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"activate AddDishCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"AddDishCommand -\u003e Menu: addDish(dish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"AddDishCommand -\u003e Ui: printAddDishMessage(dish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Dish: getName()","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":"activate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"Dish --\u003e Ui: dishNameString: String","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"deactivate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Dish: getPrice()","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"activate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"Dish --\u003e Ui: dishPrice: float","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":"deactivate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":"loop ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Ingredients: toString()","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"activate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"Ingredients --\u003e Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":"deactivate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"end loop","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Ui: showToUser(message: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"DextheChik3n":36}},{"path":"docs/diagrams/sequence/AddOrderCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"-\u003e \":AddOrderCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" activate \":AddOrderCommand\"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":OrderList\" : addOrder(order : Order)","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" activate \":OrderList\"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":Chef\" : new Chef(order : Order, pantry : Pantry, ui : Ui)","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" activate \":Chef\"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" return chef : Chef","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":Chef\" : cookDish()","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" activate \":Chef\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" opt !order.getIsComplete()","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Ui\" : showChefMessage()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Order\" : getIngredientList()","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" activate \":Order\"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" return :ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Pantry\" : isDishCooked(:ArrayList\u003cIngredient\u003e)","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" activate \":Pantry\"","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" return isComplete : boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Order\" : setComplete(isComplete : boolean)","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" activate \":Order\"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Ui\" : showOrderStatus(args : String)","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Pantry\" : calculateDishAvailability(menu : Menu)","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" activate \":Pantry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" opt order.getIsComplete()","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":OrderList\" : addCost(order : Order)","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" activate \":OrderList\"","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":49}},{"path":"docs/diagrams/sequence/Architecture_Encode_Data.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"!define COMMAND class ListIngredientCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"!define UI class Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"!define MAIN class Main","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"!define STORAGE class Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"!define DATA class Data","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"!define PARSER class Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"!define COMMAND class Command","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"autonumber","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":"Actor user","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"loop userInput !\u003d \"bye\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":"user-\u003eUi : \u0027delete 1\u0027","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":"activate Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":"Ui-\u003e Main : userInput : String","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"activate Main","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"Main -\u003e Parser : parseCommand()","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"Activate Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":"Parser -\u003e Main : command: Command","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":"Deactivate Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":"Main -\u003e Command : delete.execute()","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":"Activate Command","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"Command -\u003e Data : menu.remove()","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":"Activate Data","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":"user -\u003e Ui: \u0027bye\u0027","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"Ui-\u003e Main : userInput : String","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":"end loop","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":"Main-\u003eStorage : saveMenu()","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":"Activate Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"NaychiMin"},"content":"Storage -\u003e Storage: encodeMenu()","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"Activate Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"NaychiMin":40}},{"path":"docs/diagrams/sequence/DeleteDishCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"!define COMMAND class ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"!define UI class Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"!define MENU class Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"autonumber","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"-\u003e DeleteDishCommand : execute()","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"activate DeleteDishCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"DeleteDishCommand -\u003e Menu : getMenuItemsList().get(dishIndexToBeDeleted: int)","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"return (selectedDish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"DeleteDishCommand -\u003e Ui : showDeleteMessage(selectedDish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"DeleteDishCommand -\u003e Menu : removeDish(dishIndexToBeDeleted: int)","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"ShaniceTang":26}},{"path":"docs/diagrams/sequence/EditPriceCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"autonumber","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"participant \":Main\" as Main","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"participant \":EditPriceCommand\" as EditPriceCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"participant \":Menu\" as Menu","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"participant \":Dish\" as Dish","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"participant \":Ui\" as Ui","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"participant \":Messages\" as Messages","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"Main -\u003e EditPriceCommand: execute()","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"activate EditPriceCommand","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"EditPriceCommand -\u003e Menu:getDishFromId(menuID: int)","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"activate Menu","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"Menu --\u003e EditPriceCommand: (dish: Dish)","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"deactivate Menu","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":"EditPriceCommand -\u003e Dish: setPrice(newPrice: float)","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"activate Dish","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"EditPriceCommand -\u003e Ui: showEditPriceMessages(dishString: String)","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"deactivate Dish","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"activate Messages","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"Ui -\u003e Messages: + PRICE_MODIFIED_MESSAGE: String","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"Messages --\u003e Ui: \"Price modified for the following dish: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"deactivate Messages","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"Ui -\u003e Ui: showToUser(\"Price modified for the following dish: \", dishString: String)","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":"deactivate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"deactivate EditPriceCommand","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"deactivate Dish","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ziyi105":32}},{"path":"docs/diagrams/sequence/HelpCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"autonumber","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"Main -\u003e HelpCommand: execute()","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"activate HelpCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"HelpCommand -\u003e Ui: showHelp()","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"Ui -\u003e Ui: showToUserWithSpaceBetweenLines(messages: String...)","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"deactivate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ziyi105":14}},{"path":"docs/diagrams/sequence/ListIngredientCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"!define COMMAND class ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"!define UI class Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"!define MENU class Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"!define DISH class Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"!define PARSER class Parser","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"autonumber","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" -\u003e ListIngredientCommand: execute()","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":"activate ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"ListIngredientCommand -\u003e Menu : getMenuItemsList()","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":"Menu --\u003e ListIngredientCommand: selectedDish : Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":"deactivate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"ListIngredientCommand -\u003e Ui : printIngredients(selectedDish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"Ui -\u003e Dish : selectedDish.getIngredients()","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":"activate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":"Dish --\u003e Ui : ingredients: Ingredient","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":"deactivate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":"loop ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"Ui -\u003e Ingredients: ingredient.toString()","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":"activate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":"Ingredients --\u003e Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"deactivate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":"end loop","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":"Ui -\u003e Ui: showToUser(message: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"NaychiMin"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"Ui --\u003e Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":"deactivate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":"Ui --\u003e ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":"deactivate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":"deactivate ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"NaychiMin"},"content":"\u003c-- ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"NaychiMin"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"NaychiMin":41}},{"path":"docs/diagrams/sequence/ListMenuCommandSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"hide footbox","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"activate \": CafeCtrl\"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"\": CafeCtrl\" -\u003e \"Ui\" : receiveUserInput()","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"\"Ui\" --\u003e \": CafeCtrl\" : userInput : String","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"deactivate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"\": CafeCtrl\" -\u003e \"Parser\" : Parser.parseCommand(userInput)","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"activate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"alt commandWord","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \"Parser\" -\u003e \"Parser\" : prepareListMenu(menu, ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \"Parser\" --\u003e \": CafeCtrl\" : new ListMenuCommand(menu, ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" deactivate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"else other command","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"\": CafeCtrl\" --\u003e \"ListMenuCommand\" : execute()","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" activate \"ListMenuCommand\"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" alt menu.getSize() \u003d\u003d 0","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"ListMenuCommand\" : printEmptyMenu(ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : showToUser(MENU_EMPTY_MESSAGE : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" else","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"ListMenuCommand\" : printFullMenu(menu, ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : showToUser(MENU_FULL_MESSAGE : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" loop Dish : Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Menu\" : getDishFromId(id)","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" activate Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" \"Menu\" --\u003e \"ListMenuCommand\" : (selectedDish : Dish)","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" deactivate Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Dish\" : selectedDish.getName()","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" activate \"Dish\"","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" \"Dish\" --\u003e \"ListMenuCommand\" : (dishName : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Dish\" : selectedDish.getPrice()","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" \"Dish\" --\u003e \"ListMenuCommand\" : (dishPrice : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" deactivate \"Dish\"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : formatListMenu(indexNum + \". \" + dishName,\" $\" + dishPrice)","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : showToUser(MENU_FULL_END_MESSAGE : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":"\"Parser\" --\u003e \": CafeCtrl\" : command : Command","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"deactivate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":"else other command","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":"deactivate \": CafeCtrl\"","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Cazh1":72}},{"path":"docs/diagrams/sequence/ListMenuCommand_executeSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"-\u003e \":ListMenuCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" activate \":ListMenuCommand\"","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" alt menu.getSize() \u003d\u003d 0","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":ListMenuCommand\" : printEmptyMenu(ui)","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showEmptyMenu()","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" else","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":ListMenuCommand\" : printFullMenu(menu, ui)","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showMenuTop()","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" loop Dish : Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Menu\" : getDishFromId(id)","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" activate \":Menu\"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" \":Menu\" --\u003e \":ListMenuCommand\" : (selectedDish : Dish)","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" deactivate \":Menu\"","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Dish\" : selectedDish.getName()","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" activate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" \":Dish\" --\u003e \":ListMenuCommand\" : (dishName : String)","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" deactivate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Dish\" : selectedDish.getPrice()","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" activate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" \":Dish\" --\u003e \":ListMenuCommand\" : (dishPrice : String)","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" deactivate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showMenuDish()","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showMenuBottom() : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Cazh1":55}},{"path":"docs/diagrams/sequence/NextDayCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"-\u003e \":NextDayCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" activate \":NextDayCommand\"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Ui\" : printLine()","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":CurrentDate\" : nextDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" activate \":CurrentDate\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":CurrentDate\" : getCurrentDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \":CurrentDate\"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" return nextDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Sales\" : getDaysAccounted()","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" activate \":Sales\"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" return daysAccounted : int","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" opt nextDay \u003e daysAccounted","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":OrderList\" : new OrderList()","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" activate \":OrderList\"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" return newOrderList : OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Sales\" : addOrderList(newOrderList)","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" activate \":Sales\"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Sales\" : nextDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" activate \":Sales\"","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Ui\" : showNextDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":44}},{"path":"docs/diagrams/sequence/Parser.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"actor User","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"Participant \":Main\" as Main","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"Participant \":Parser\" as Parser","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"Participant \":XYZCommand\" as XYZCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"User -\u003e Main: fullUserInput: String","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"activate Main","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"Main -\u003e Parser: parseCommand(fullUserInput: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"activate Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"alt XYZCOMMAND_WORD","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"Parser -\u003e Parser: prepareXYZCommand(requiredArguments)","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"activate Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"Parser -\u003e XYZCommand: XYZCommand(requiredArguments)","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":"activate XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"XYZCommand --\u003e Parser: XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"deactivate XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"deactivate Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"end alt","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"Parser --\u003e Main: XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"deactivate Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"Main -\u003e XYZCommand: execute()","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"activate XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ziyi105":28}},{"path":"docs/diagrams/sequence/PreviousDayCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"-\u003e \":PreviousDayCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" activate \":PreviousDayCommand\"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":Ui\" : printLine()","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":CurrentDate\" : previousDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" activate \":CurrentDate\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":Ui\" : showPreviousDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":27}},{"path":"src/main/java/seedu/cafectrl/CafeCtrl.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.parser.Parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.parser.ParserUtil;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.storage.Storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" * CafeCtrl application\u0027s entry point.","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" * Initializes the application and starts the interaction with the user.","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"public class CafeCtrl {","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" private Menu menu;","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" private Command command;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" private Pantry pantry;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" private Sales sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" private CurrentDate currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" private Storage storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" * Private constructor for the CafeCtrl class, used for initializing the user interface and menu list.","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" private CafeCtrl() {","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d new Ui();","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" this.storage \u003d new Storage(this.ui);","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" this.currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" this.sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" this.menu \u003d this.storage.loadMenu();","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" this.pantry \u003d this.storage.loadPantryStock();","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":" this.sales \u003d this.storage.loadOrderList(menu);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":" ","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":" * The main loop of the CafeCtrl application.","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"DextheChik3n"},"content":" * \u003cp\u003e This method consistently receives user input, parses commands, and executes the respective command","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":" * until the user enters a \"bye\" command, terminating the application.\u003c/p\u003e","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" private void run() {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" ui.showWelcome();","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" ui.printLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" do {","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" String fullUserInput \u003d ui.receiveUserInput();","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" command \u003d parserUtil.parseCommand(menu, fullUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" command.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" } finally {","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"DextheChik3n"},"content":" ui.printLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":" } while (!command.isExit());","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"ziyi105"},"content":" this.storage.saveAll(this.menu, this.sales, this.pantry);","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"DextheChik3n"},"content":" public static void main(String[] args) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" CafeCtrl cafeCtrl \u003d new CafeCtrl();","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" cafeCtrl.run();","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"NaychiMin":1,"DextheChik3n":51,"Cazh1":8,"ziyi105":10,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/command/AddDishCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"//@@author DextheChik3n","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" * Adds a menu item to the user","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"public class AddDishCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" public static final String COMMAND_WORD \u003d \"add\";","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" public static final String MESSAGE_USAGE \u003d \"To add a new dish to the menu: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" + COMMAND_WORD + \" name/DISH_NAME price/DISH_PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY\"","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" + \"[, ingredient/INGREDIENT2_NAME, qty/INGREDIENT2_QTY...]\\n\"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" + \"Example:\"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" + COMMAND_WORD + \" name/chicken rice price/3.00 ingredient/rice qty/200g, ingredient/chicken qty/100g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" private final Dish dish;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" public AddDishCommand(Dish dish, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" this.dish \u003d dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" ui.printAddDishMessage(dish);","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":31,"Cazh1":1}},{"path":"src/main/java/seedu/cafectrl/command/AddOrderCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Chef;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"public class AddOrderCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"add_order\";","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To add a new order: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \" name/DISH_NAME qty/QUANTITY\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" + \"name/chicken rice qty/2\";","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" protected OrderList orderList;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" protected Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" private final Order order;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" public AddOrderCommand(Order order, Ui ui, Pantry pantry, OrderList orderList, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" this.order \u003d order;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" this.orderList \u003d orderList;","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" orderList.addOrder(order);","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" Chef chef \u003d new Chef(order, pantry, ui, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" chef.cookDish();","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" if (order.getIsComplete()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" orderList.addCost(order);","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"NaychiMin":7,"Cazh1":32,"ziyi105":3}},{"path":"src/main/java/seedu/cafectrl/command/BuyIngredientCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"//@@author ShaniceTang","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":" * The BuyIngredientCommand class represents a command to buy ingredients and add them to the pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":" * It executes the command, adds the ingredients, and displays the results to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"public class BuyIngredientCommand extends Command {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" public static final String COMMAND_WORD \u003d \"buy_ingredient\";","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" public static final String MESSAGE_USAGE \u003d \"\\nTo buy ingredient:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" + COMMAND_WORD + \" ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY\"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" + \"[, ingredient/INGREDIENT2_NAME, qty/INGREDIENT2_QTY...]\\n\"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" + \"Example:\"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" + COMMAND_WORD + \" ingredient/rice qty/200g, ingredient/chicken qty/100g\";","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" private ArrayList\u003cIngredient\u003e ingredients;","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" private String ingredientString \u003d \"\"; // Used to store the message about the bought ingredients","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" * Constructs a BuyIngredientCommand with the specified ingredients, user interface, and pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredients The list of ingredients to be bought and added to the pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" * @param ui The user interface to interact with the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" * @param pantry The pantry to which the ingredients will be added.","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" public BuyIngredientCommand(ArrayList\u003cIngredient\u003e ingredients, Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" this.ingredients \u003d ingredients;","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" * Executes the command to buy ingredients, adds them to the pantry, and displays the results to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" addIngredient();","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" ui.printBuyIngredientHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(ingredientString);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" } catch (RuntimeException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" * Adds the specified ingredients to the pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" * This method is called during command execution.","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" private void addIngredient() {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":" for(int i \u003d 0; i \u003c ingredients.size(); i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" Ingredient ingredient \u003d ingredients.get(i);","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":" ingredient \u003d pantry.addIngredientToStock(ingredient.getName(),","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" ingredient.getQty(),","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":" ingredient.getUnit());","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":" buildBuyIngredientMessage(ingredient, i);","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":" * Builds a message about the bought ingredient and appends it to the result message.","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredient The Ingredient object to build the message for.","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" * @param index The index of the ingredient in the list.","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":" private void buildBuyIngredientMessage(Ingredient ingredient, int index) {","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":" ingredientString +\u003d \"Ingredient: \" + ingredient.getName()","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":" + \"\\t\\tQty: \" + ingredient.getQty()","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"ShaniceTang"},"content":" + ingredient.getUnit();","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":" //append new line if current ingredient is not last","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":" if(index \u003c ingredients.size() - ui.OFFSET_LIST_INDEX) {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":" ingredientString +\u003d \"\\n\";","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ShaniceTang":85}},{"path":"src/main/java/seedu/cafectrl/command/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":" * Represents an executable command.","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"public class Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":" public int index;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" public void setIndex(int index) {","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" this.index \u003d index;","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" * check whether this command is an exit command (user input \"bye\")","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" * default returns false, this method will be overridden in ExitCommand","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" public boolean isExit() {","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" * Executes the command and returns the result.","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" throw new UnsupportedOperationException(\"This method is to be implemented by child classes\");","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"NaychiMin":1,"DextheChik3n":10,"Cazh1":17}},{"path":"src/main/java/seedu/cafectrl/command/DeleteDishCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" * Deletes a menu item identified using it\u0027s last displayed index from the menu.","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"public class DeleteDishCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" public static final String COMMAND_WORD \u003d \"delete\";","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To delete a menu item:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" + \"Parameters: INDEX\\n\"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Example: \" + COMMAND_WORD + \" 1\";","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" public DeleteDishCommand(int listIndex, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" this.index \u003d listIndex;","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" int dishIndexToBeDeleted \u003d index - Ui.OFFSET_LIST_INDEX;","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" Dish selectedDish \u003d menu.getMenuItemsList().get(dishIndexToBeDeleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" ui.printDeleteMessage(selectedDish);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" menu.removeDish(dishIndexToBeDeleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.INVALID_DISH_INDEX);","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" throw new IndexOutOfBoundsException();","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":4,"Cazh1":17,"ziyi105":6,"ShaniceTang":12}},{"path":"src/main/java/seedu/cafectrl/command/EditPriceCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" * Edit the price of a dish of a certain index","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"public class EditPriceCommand extends Command {","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" public static final String COMMAND_WORD \u003d \"edit_price\";","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To edit price of a menu item: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + \"edit_price index/DISH_INDEX price/NEW_PRICE\\n\"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \"Example: edit_price index/1 price/4.50\";","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" private final int menuID;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" private final float newPrice;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" public EditPriceCommand(int menuID, float newPrice, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" this.menuID \u003d menuID;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" this.newPrice \u003d newPrice;","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" * Set new price of the dish and show edit price message","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" Dish dish \u003d menu.getDishFromId(this.menuID - Ui.OFFSET_LIST_INDEX);","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" dish.setPrice(this.newPrice);","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":" ui.showEditPriceMessage(dish.toString());","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"ziyi105":38}},{"path":"src/main/java/seedu/cafectrl/command/ExitCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"public class ExitCommand extends Command {","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"bye\";","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To exit:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" public ExitCommand(Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" * Overrides the isExit() method which returns false","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" * @return true","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":" public boolean isExit() {","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" ui.printLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":" ui.showGoodbye();","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":16,"Cazh1":15,"ziyi105":2,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/command/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" public static final String COMMAND_WORD \u003d \"help\";","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To view all commands:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public HelpCommand(Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" ui.printLine();","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" ui.showHelp();","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"ziyi105":22}},{"path":"src/main/java/seedu/cafectrl/command/IncorrectCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":" * Represents an incorrect command. Upon execution, produces some feedback to the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"public class IncorrectCommand extends Command{","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" public IncorrectCommand(String feedbackToUser, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" ui.showToUser(feedbackToUser);","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":3,"Cazh1":18}},{"path":"src/main/java/seedu/cafectrl/command/ListIngredientCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" * Lists all ingredients used in the selected dish to the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"public class ListIngredientCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"list_ingredients\";","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To list out the ingredients needed \"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + \"along with the quantity for a specific dish:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \"Parameters: DISH_INDEX\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Example: \" + COMMAND_WORD + \" 1\";","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" public ListIngredientCommand(int listIndex, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" this.index \u003d listIndex;","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" Dish selectedDish \u003d menu.getMenuItemsList().get(index - Ui.OFFSET_LIST_INDEX);","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" ui.printIngredients(selectedDish);","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" throw new IllegalArgumentException(ErrorMessages.INVALID_DISH_INDEX);","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"NaychiMin":10,"DextheChik3n":4,"Cazh1":17,"ziyi105":5}},{"path":"src/main/java/seedu/cafectrl/command/ListMenuCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" * Lists all dishes in the menu to the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"public class ListMenuCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"list_menu\";","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To view menu:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" private final Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" * Constructor for the ListMenuCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" * @param menu The menu object of the current session","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" public ListMenuCommand(Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" * Iterates through the menu arraylist, outputting the dish name and dish price.","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" * Calls printEmptyMenu() when (menu.getSize() \u003d\u003d 0), printFullMenu() otherwise.","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" if (menu.getSize() \u003d\u003d 0) {","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" printEmptyMenu(ui);","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" } else {","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" printFullMenu(menu, ui);","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" * Shows empty menu message to user","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" * Called only when the menu is empty","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" public void printEmptyMenu(Ui ui) {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" ui.showEmptyMenu();","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" * Prints the dishes in the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" * Called only when the menu is not empty","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" * @param menu The menu object of the current session","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" public void printFullMenu(Menu menu, Ui ui) {","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" ui.showMenuTop();","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" for (int i \u003d 0; i \u003c menu.getSize(); i++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" String indexNum \u003d String.valueOf(i + 1);","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" Dish selectedDish \u003d menu.getDishFromId(i);","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":" String dishName \u003d selectedDish.getName();","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":" String dishPrice \u003d dollarValue.format(selectedDish.getPrice());","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" ui.showMenuDish(indexNum, dishName, dishPrice);","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":" ui.showMenuBottom();","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":3,"Cazh1":68,"ziyi105":1,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/command/NextDayCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"public class NextDayCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"next_day\";","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To travel to next day:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" private final Sales sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" private final CurrentDate currentDate;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public NextDayCommand(Ui ui, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" this.sales \u003d sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" this.currentDate \u003d currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" * Changes the current day to the next day.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" * Checks if an orderList exist in Sales by comparing","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" * the intended Day vs the number of days accounted for in Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" * If orderList does not exist, new OrderList is added to Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" * The days accounted for in Sales is incremented","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" ui.printLine();","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" currentDate.nextDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" int nextDay \u003d currentDate.getCurrentDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" if (nextDay \u003e sales.getDaysAccounted()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" OrderList newOrderList \u003d new OrderList();","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" sales.addOrderList(newOrderList);","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" sales.nextDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" ui.showNextDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" ui.showToUser(\"Today is Day \" + (currentDate.getCurrentDay() + 1));","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Cazh1":43,"ziyi105":2}},{"path":"src/main/java/seedu/cafectrl/command/PreviousDayCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"public class PreviousDayCommand extends Command{","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"previous_day\";","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To go back to previous day:\\n\" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" protected CurrentDate currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" public PreviousDayCommand(Ui ui, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" this.currentDate \u003d currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" ui.printLine();","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" currentDate.previousDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" ui.showPreviousDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" ui.showToUser(\"Today is Day \" + (currentDate.getCurrentDay() + 1));","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Cazh1":24,"ziyi105":1}},{"path":"src/main/java/seedu/cafectrl/command/ShowSalesByDayCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"public class ShowSalesByDayCommand extends Command {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":" public static final String COMMAND_WORD \u003d \"show_sale\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" public static final String MESSAGE_USAGE \u003d \"To show sales for a chosen day:\\n \"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":" + \"Command Format:\" + COMMAND_WORD + \" day/DAY_TO_DISPLAY\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" + \"Example: \" + COMMAND_WORD + \" day/1\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":" private final int day;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" private final Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" private final Sales sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" private final Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" public ShowSalesByDayCommand(int day, Ui ui, Sales sales, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" this.day \u003d day;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" this.sales \u003d sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" public void execute() {","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" sales.printSaleByDay(ui, menu, day);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"NaychiMin":29}},{"path":"src/main/java/seedu/cafectrl/command/ShowSalesCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"public class ShowSalesCommand extends Command {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":" public static final String COMMAND_WORD \u003d \"show_sales\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" public static final String MESSAGE_USAGE \u003d \"To show sales for all days:\\n\" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":" private Sales sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" private Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" public ShowSalesCommand(Sales sales, Ui ui, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" this.sales \u003d sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" public void execute() {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" sales.printSales(ui, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"NaychiMin":24}},{"path":"src/main/java/seedu/cafectrl/command/ViewTotalStockCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"public class ViewTotalStockCommand extends Command {","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":" public static final String COMMAND_WORD \u003d \"view_stock\";","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To view pantry stock:\\n\" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" private ArrayList\u003cIngredient\u003e pantryStock;","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public ViewTotalStockCommand(Pantry pantry, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(Messages.VIEW_STOCK);","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" pantryStock \u003d pantry.getPantryStock();","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" for (Ingredient ingredient : pantryStock) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(ingredient.getName() + \"\\t\\t\\t\" + ingredient.getQty() + ingredient.getUnit());","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"Cazh1":6,"ziyi105":1,"ShaniceTang":25}},{"path":"src/main/java/seedu/cafectrl/data/Chef.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"public class Chef {","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" private final Order order;","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" private final Pantry pantry;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":" private final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" public Chef(Order order, Pantry pantry, Ui ui, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" this.order \u003d order;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" public void cookDish() {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" try {","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" if (!order.getIsComplete()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" ui.showChefMessage();","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" boolean isComplete \u003d pantry.isDishCooked(order.getIngredientList());","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" order.setComplete(isComplete);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" String orderStatus \u003d order.getIsComplete() ? Messages.COMPLETE_ORDER : Messages.INCOMPLETE_ORDER;","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" String totalCost \u003d dollarValue.format(order.getTotalOrderCost());","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" ui.showOrderStatus(orderStatus, totalCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" pantry.calculateDishAvailability(menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"NaychiMin":16,"Cazh1":23}},{"path":"src/main/java/seedu/cafectrl/data/CurrentDate.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"public class CurrentDate {","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":" private int currentDay;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":" public CurrentDate() {","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" currentDay \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" public void nextDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" currentDay +\u003d 1;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" public void previousDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" currentDay -\u003d 1;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public int getCurrentDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" return currentDay;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Cazh1":21}},{"path":"src/main/java/seedu/cafectrl/data/Menu.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"public class Menu {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" private ArrayList\u003cDish\u003e menuItems;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" public Menu() {","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" this.menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" public Menu(ArrayList\u003cDish\u003e menuItems) {","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" this.menuItems \u003d menuItems;","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" public ArrayList\u003cDish\u003e getMenuItemsList() {","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" return menuItems;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" public int getSize() {","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" return menuItems.size();","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" public Dish getDishFromId(int menuID) {","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" return menuItems.get(menuID);","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" * Checks if the ordered dish exist in the menu and returns the menu index if exist","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" * @param dishName Name of the ordered dish","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" * @return index of the dish in menu if exists, null if not found","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" public Dish getDishFromName(String dishName) {","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" String formattedDishName \u003d dishName.toLowerCase().trim();","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" for (int i \u003d 0; i \u003c getSize(); i++) {","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" String menuDishName \u003d getDishFromId(i).getName();","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" String formattedMenuDishName \u003d menuDishName.toLowerCase().trim();","lastModifiedDate":"2023-10-24"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" if (formattedMenuDishName.equals(formattedDishName)){","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" return getDishFromId(i);","lastModifiedDate":"2023-10-24"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" return null;","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" public void removeDish(int menuID) {","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" menuItems.remove(menuID);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" public void addDish(Dish dish) {","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" menuItems.add(dish);","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" public boolean isValidDishIndex(int dishIndex) {","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":" int offSetDishIndex \u003d dishIndex - Ui.OFFSET_LIST_INDEX;","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":" return offSetDishIndex \u003e\u003d 0 \u0026\u0026 offSetDishIndex \u003c this.getSize();","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" * Retrieves an ArrayList of Order objects representing aggregated orders for each menu item.","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" * Each Order object is initialized with a dish from the menu and a quantity of 0.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" * Used in the print_sales function under Sales class.","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" * @return An ArrayList of Order objects representing aggregated orders for each menu item.","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"NaychiMin"},"content":" public ArrayList\u003cOrder\u003e getAggregatedOrders() {","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrder\u003e aggregatedOrders \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":" for (int i \u003d 0; i \u003c menuItems.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":" Order order \u003d new Order(menuItems.get(i), 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrders.add(order);","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":" return aggregatedOrders;","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"NaychiMin":22,"DextheChik3n":17,"Cazh1":19,"ziyi105":16}},{"path":"src/main/java/seedu/cafectrl/data/Order.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"public class Order {","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" private final Dish orderedDish;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private int dishQty;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" private final ArrayList\u003cIngredient\u003e ingredientList;","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" private boolean isComplete \u003d false;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" private float totalOrderCost;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" public Order(Dish orderedDish, int dishQty) {","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" this.dishQty \u003d dishQty;","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.orderedDish \u003d orderedDish;","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" this.ingredientList \u003d setIngredientList();","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" this.totalOrderCost \u003d calculateTotalOrderCost();","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":" public Order(Dish orderedDish, int dishQty, float orderCost, boolean isComplete) {","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" this.dishQty \u003d dishQty;","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" this.orderedDish \u003d orderedDish;","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" this.ingredientList \u003d setIngredientList();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" this.totalOrderCost \u003d orderCost;","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" this.isComplete \u003d isComplete;","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" return \"Order: \" + getDishName() + \" Quantity: \"+ dishQty","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" + \"\\nIngredientList: \" + ingredientList","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" + \"\\nTotal Order Cost: $\" + dollarValue.format(totalOrderCost);","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-24"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" * Calculates the total price of the order","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" * Multiplies cost per dish by number of dishes","lastModifiedDate":"2023-10-24"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" * @return Total calculated cost","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" public float calculateTotalOrderCost() {","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" float dishCost \u003d orderedDish.getPrice();","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" return dishCost * dishQty;","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" * Gets and prepares the ingredients used in the dish.","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" * Calculates the total ingredient used and stores in an Ingredient ArrayList","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" * @return Arraylist of Ingredients","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" private ArrayList\u003cIngredient\u003e setIngredientList() {","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e dishIngredient \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" for (Ingredient ingredient : orderedDish.getIngredients()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" String ingredientName \u003d ingredient.getName();","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" int ingredientQty \u003d ingredient.getQty() * dishQty;","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" String ingredientUnit \u003d ingredient.getUnit();","lastModifiedDate":"2023-10-24"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" dishIngredient.add(new Ingredient(ingredientName, ingredientQty, ingredientUnit));","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" return dishIngredient;","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":" public ArrayList\u003cIngredient\u003e getIngredientList() {","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" return ingredientList;","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" public float getTotalOrderCost() {","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":" return totalOrderCost;","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" public void setComplete(boolean isComplete) {","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" this.isComplete \u003d isComplete;","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":" public boolean getIsComplete() {","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":" return isComplete;","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" public String getDishName() {","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" return orderedDish.getName();","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" public int getQuantity() {","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" return dishQty;","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" public void setQuantity(int quantity) {","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" this.dishQty \u003d quantity;","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" public void setTotalOrderCost(float cost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" this.totalOrderCost \u003d cost;","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"NaychiMin":31,"Cazh1":66,"ShaniceTang":2}},{"path":"src/main/java/seedu/cafectrl/data/OrderList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" * The OrderList class represents a list of orders for a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":" * It manages the collection of orders and calculates the total cost for the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"public class OrderList {","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" private static final String HEADER_FORMAT \u003d \"%-20s %-10s %-20s\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" private ArrayList\u003cOrder\u003e orderList;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" private float totalOrderListCost;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" * Constructs an empty OrderList with no orders and zero total order cost.","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" public OrderList() {","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" this.orderList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.totalOrderListCost \u003d 0;","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" public ArrayList\u003cOrder\u003e getOrderList() {","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" return orderList;","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" public int getSize() {","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" return orderList.size();","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public void addOrder(Order order) {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" orderList.add(order);","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" public void addCost(Order order) {","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" float orderCost \u003d order.getTotalOrderCost();","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" totalOrderListCost +\u003d orderCost;","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"NaychiMin"},"content":" * Prints the order list for a specific day, including dish names, quantities, and total cost prices.","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" public void printOrderList(Menu menu, Ui ui) {","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrder\u003e aggregatedOrders \u003d menu.getAggregatedOrders();","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":" if (orderList.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"No sales for this day.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" for (Order order : getOrderList()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" aggregateOrder(order, aggregatedOrders);","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" for (Order aggregatedOrder : aggregatedOrders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(String.format(HEADER_FORMAT,","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrder.getDishName(),","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrder.getQuantity(),","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrder.calculateTotalOrderCost()));","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Total for day: $\" + dollarValue.format(calculateTotalCost(aggregatedOrders)));","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":" * Aggregates orders by updating quantities and total order costs for the same dish.","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":" * @param order The Order object to be aggregated.","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" * @param aggregatedOrders The ArrayList of aggregated orders.","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"NaychiMin"},"content":" private void aggregateOrder(Order order, ArrayList\u003cOrder\u003e aggregatedOrders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" if (order.getIsComplete()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" int index \u003d getIndexByDishName(aggregatedOrders, order.getDishName());","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrders.get(index).setQuantity(aggregatedOrders.get(index).getQuantity()","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" + order.getQuantity());","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrders.get(index).setTotalOrderCost(aggregatedOrders.get(index).getTotalOrderCost()","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" + order.getTotalOrderCost());","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" * Finds the index of an order in the aggregated orders list based on the dish name.","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" * @param aggregatedOrders The ArrayList of aggregated orders.","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" * @param dishName The dish name to search for.","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" * @return The index of the order with the specified dish name, or -1 if not found.","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" private int getIndexByDishName(ArrayList\u003cOrder\u003e aggregatedOrders, String dishName) {","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" for (int i \u003d 0; i \u003c aggregatedOrders.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" Order order \u003d aggregatedOrders.get(i);","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" String orderDishName \u003d order.getDishName().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" dishName \u003d dishName.trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" if (orderDishName.equalsIgnoreCase(dishName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" return i;","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":" return -1;","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":" * Calculates the total cost of all orders for a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" * @param orders The ArrayList of orders.","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":" * @return The total cost of all orders for the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" private float calculateTotalCost(ArrayList\u003cOrder\u003e orders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":" float totalCost \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" for (Order order : orders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"NaychiMin"},"content":" totalCost +\u003d order.getTotalOrderCost();","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"NaychiMin"},"content":" return totalCost;","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"NaychiMin":87,"Cazh1":30}},{"path":"src/main/java/seedu/cafectrl/data/Pantry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"public class Pantry {","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" private ArrayList\u003cIngredient\u003e pantryStock;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private Ui ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" public Pantry(Ui ui, ArrayList\u003cIngredient\u003e pantryStock) {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":" this.pantryStock \u003d pantryStock;","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" public Pantry(Ui ui) {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" this.pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" * Retrieves the current pantry stock from storage, which may include reading from a file (pantry.txt).","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" * @return An ArrayList of Ingredient objects representing the current pantry stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" public ArrayList\u003cIngredient\u003e getPantryStock() {","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" return pantryStock;","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" * Adds or updates an ingredient in the pantry stock based on its name and quantity.","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" * @param name The name of the ingredient to add or update.","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" * @param qty The quantity of the ingredient (e.g., \"100g\").","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" * @param unit The unit of measurement for the quantity.","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" * @return The Ingredient object that was added or updated in the pantry stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" public Ingredient addIngredientToStock (String name, int qty, String unit) {","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" pantryStock \u003d getPantryStock(); //get latest pantry stock from pantry.txt","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" int ingredientIndex \u003d getIndexOfIngredient(name);","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" //if ingredient exists in pantry, add quantity of that ingredient","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" if (ingredientIndex !\u003d -1) {","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" return addIngredientQuantity(qty, ingredientIndex, unit);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" //else, add new ingredient to pantry","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" Ingredient ingredient \u003d new Ingredient(name, qty, unit);","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" pantryStock.add(ingredient);","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" return ingredient;","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":" * Updates an ingredient\u0027s quantity in the pantry stock or adds a new ingredient if it doesn\u0027t exist.","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":" * @param qty The quantity of the ingredient (e.g., \"100g\").","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredientIndex The index of the ingredient in the pantry stock (-1 if not found).","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":" * @return The Ingredient object that was added or updated in the pantry stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":" private Ingredient addIngredientQuantity(int qty, int ingredientIndex, String unit) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":" Ingredient ingredient \u003d pantryStock.get(ingredientIndex);","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":" if (!unit.equalsIgnoreCase(ingredient.getUnit())) {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":" throw new RuntimeException(ErrorMessages.UNIT_NOT_MATCHING","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":" + \"\\nUnit used previously: \" + ingredient.getUnit());","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":" qty +\u003d ingredient.getQty(); //adds new qty to current qty","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" ingredient.setQty(qty);","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":" return ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"ShaniceTang"},"content":" * Gets the index of an ingredient in the pantry stock based on its name (case-insensitive comparison).","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":" * @param name The name of the ingredient to search for.","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":" * @return The index of the ingredient in the pantry stock or -1 if not found.","lastModifiedDate":"2023-10-22"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":" private int getIndexOfIngredient(String name) {","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":" for (int i \u003d 0; i \u003c pantryStock.size(); i++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":" String ingredientName \u003d pantryStock.get(i).getName().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":" if (name.equalsIgnoreCase(ingredientName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ShaniceTang"},"content":" return i;","lastModifiedDate":"2023-10-22"},{"lineNumber":87,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":88,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":89,"author":{"gitId":"ShaniceTang"},"content":" return -1;","lastModifiedDate":"2023-10-22"},{"lineNumber":90,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":91,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" * Decreases the stock of ingredients based on the given dish order.","lastModifiedDate":"2023-10-22"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredients Array of ingredients used to make the dish order.","lastModifiedDate":"2023-10-24"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" public boolean isDishCooked(ArrayList\u003cIngredient\u003e dishIngredients) {","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" //for each ingredient that is used in the dish, update the stock of ingredient left.","lastModifiedDate":"2023-10-22"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" for (Ingredient dishIngredient : dishIngredients) {","lastModifiedDate":"2023-10-22"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":" Ingredient usedIngredientFromStock \u003d getIngredient(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":102,"author":{"gitId":"NaychiMin"},"content":" if (usedIngredientFromStock \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":" int stockQuantity \u003d usedIngredientFromStock.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":" int usedQuantity \u003d dishIngredient.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" int finalQuantity \u003d stockQuantity - usedQuantity;","lastModifiedDate":"2023-10-24"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":" if (finalQuantity \u003c 0) {","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":" usedIngredientFromStock.setQty(finalQuantity);","lastModifiedDate":"2023-10-24"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":113,"author":{"gitId":"NaychiMin"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":115,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":116,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":" * Retrieves the ingredient used in the ordered dish from pantryStock.","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":119,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredient The ingredient used in the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"NaychiMin"},"content":" * @return The corresponding ingredient in pantryStock.","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":122,"author":{"gitId":"NaychiMin"},"content":" private Ingredient getIngredient(Ingredient dishIngredient) {","lastModifiedDate":"2023-10-22"},{"lineNumber":123,"author":{"gitId":"NaychiMin"},"content":" return pantryStock.stream()","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"NaychiMin"},"content":" .filter(ingredient -\u003e ingredient.getName().equals(dishIngredient.getName()))","lastModifiedDate":"2023-10-22"},{"lineNumber":125,"author":{"gitId":"NaychiMin"},"content":" .findFirst()","lastModifiedDate":"2023-10-22"},{"lineNumber":126,"author":{"gitId":"NaychiMin"},"content":" .orElse(null);","lastModifiedDate":"2023-10-22"},{"lineNumber":127,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":128,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":" * Checks the availability of dishes based on ingredient stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":132,"author":{"gitId":"NaychiMin"},"content":" public void calculateDishAvailability(Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"NaychiMin"},"content":" int menuSize \u003d menu.getSize();","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"NaychiMin"},"content":" for (int i \u003d 0; i \u003c menuSize; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"NaychiMin"},"content":" Dish dish \u003d menu.getDishFromId(i);","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Dish: \" + dish.getName());","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"NaychiMin"},"content":" int numberOfDishes \u003d calculateMaxDishes(dish, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":" ui.showDishAvailability(numberOfDishes);","lastModifiedDate":"2023-10-24"},{"lineNumber":139,"author":{"gitId":"NaychiMin"},"content":" if (i !\u003d menuSize - 1) {","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"NaychiMin"},"content":" ui.printLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":" //@@author","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":146,"author":{"gitId":"NaychiMin"},"content":" * Calculates the number of dishes that can be prepared with the available ingredients.","lastModifiedDate":"2023-10-24"},{"lineNumber":147,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":" * @param dish The dish being ordered.","lastModifiedDate":"2023-10-22"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":" public int calculateMaxDishes(Dish dish, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"NaychiMin"},"content":" int maxNumofDish \u003d Integer.MAX_VALUE;","lastModifiedDate":"2023-10-22"},{"lineNumber":152,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cIngredient\u003e dishIngredients \u003d retrieveIngredientsForDish(dish.getName(), menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"NaychiMin"},"content":" for (Ingredient dishIngredient : dishIngredients) {","lastModifiedDate":"2023-10-22"},{"lineNumber":155,"author":{"gitId":"NaychiMin"},"content":" int numOfDish \u003d calculateMaxDishForEachIngredient(dishIngredient);","lastModifiedDate":"2023-10-24"},{"lineNumber":156,"author":{"gitId":"NaychiMin"},"content":" maxNumofDish \u003d Math.min(numOfDish, maxNumofDish);","lastModifiedDate":"2023-10-22"},{"lineNumber":157,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":158,"author":{"gitId":"NaychiMin"},"content":" if (numOfDish \u003d\u003d 0) {","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"NaychiMin"},"content":" handleRestock(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":160,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":161,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":162,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":163,"author":{"gitId":"NaychiMin"},"content":" return maxNumofDish;","lastModifiedDate":"2023-10-22"},{"lineNumber":164,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":165,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":166,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":167,"author":{"gitId":"NaychiMin"},"content":" * Calculates the number of dishes that can be prepared with the provided ingredients.","lastModifiedDate":"2023-10-24"},{"lineNumber":168,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":169,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredient The ingredient used in the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":170,"author":{"gitId":"NaychiMin"},"content":" * @return The number of dishes that can be prepared.","lastModifiedDate":"2023-10-22"},{"lineNumber":171,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":172,"author":{"gitId":"NaychiMin"},"content":" private int calculateMaxDishForEachIngredient(Ingredient dishIngredient) {","lastModifiedDate":"2023-10-24"},{"lineNumber":173,"author":{"gitId":"NaychiMin"},"content":" Ingredient usedIngredientFromStock \u003d getIngredient(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":174,"author":{"gitId":"NaychiMin"},"content":" if (usedIngredientFromStock \u003d\u003d null) {","lastModifiedDate":"2023-10-22"},{"lineNumber":175,"author":{"gitId":"NaychiMin"},"content":" return 0;","lastModifiedDate":"2023-10-22"},{"lineNumber":176,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":177,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"NaychiMin"},"content":" int currentQuantity \u003d usedIngredientFromStock.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":179,"author":{"gitId":"NaychiMin"},"content":" int usedQuantity \u003d dishIngredient.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":180,"author":{"gitId":"NaychiMin"},"content":" return currentQuantity / usedQuantity;","lastModifiedDate":"2023-10-22"},{"lineNumber":181,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":182,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":183,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":184,"author":{"gitId":"NaychiMin"},"content":" * Handles the case when restocking is required for a specific ingredient.","lastModifiedDate":"2023-10-22"},{"lineNumber":185,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":186,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredient The ingredient for which restocking is needed.","lastModifiedDate":"2023-10-22"},{"lineNumber":187,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":188,"author":{"gitId":"NaychiMin"},"content":" private void handleRestock(Ingredient dishIngredient) {","lastModifiedDate":"2023-10-22"},{"lineNumber":189,"author":{"gitId":"NaychiMin"},"content":" String dishIngredientName \u003d dishIngredient.getName();","lastModifiedDate":"2023-10-22"},{"lineNumber":190,"author":{"gitId":"NaychiMin"},"content":" Ingredient stockIngredient \u003d getIngredient(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":191,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":192,"author":{"gitId":"NaychiMin"},"content":" int currentQuantity \u003d (stockIngredient \u003d\u003d null) ? 0 : stockIngredient.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":193,"author":{"gitId":"NaychiMin"},"content":" String unit \u003d dishIngredient.getUnit();","lastModifiedDate":"2023-10-24"},{"lineNumber":194,"author":{"gitId":"NaychiMin"},"content":" String neededIngredient \u003d dishIngredient.toString();","lastModifiedDate":"2023-10-24"},{"lineNumber":195,"author":{"gitId":"NaychiMin"},"content":" ui.showNeededRestock(dishIngredientName, currentQuantity, unit, neededIngredient);","lastModifiedDate":"2023-10-24"},{"lineNumber":196,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":197,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":198,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":199,"author":{"gitId":"NaychiMin"},"content":" * Retrieves the ingredients for a specific ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":200,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":201,"author":{"gitId":"NaychiMin"},"content":" * @param orderedDish The name of the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":202,"author":{"gitId":"NaychiMin"},"content":" * @return The list of ingredients for the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":203,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":204,"author":{"gitId":"NaychiMin"},"content":" public ArrayList\u003cIngredient\u003e retrieveIngredientsForDish(String orderedDish, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cIngredient\u003e dishIngredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":206,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":207,"author":{"gitId":"NaychiMin"},"content":" //retrieving the ingredients for orderedDish","lastModifiedDate":"2023-10-22"},{"lineNumber":208,"author":{"gitId":"NaychiMin"},"content":" for (Dish dish : menu.getMenuItemsList()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"NaychiMin"},"content":" if (dish.getName().equals(orderedDish)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":210,"author":{"gitId":"NaychiMin"},"content":" dishIngredients.addAll(dish.getIngredients());","lastModifiedDate":"2023-10-22"},{"lineNumber":211,"author":{"gitId":"NaychiMin"},"content":" break;","lastModifiedDate":"2023-10-22"},{"lineNumber":212,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":213,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":214,"author":{"gitId":"NaychiMin"},"content":" return dishIngredients;","lastModifiedDate":"2023-10-22"},{"lineNumber":215,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":216,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-22"},{"lineNumber":217,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":218,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"NaychiMin":145,"ShaniceTang":73}},{"path":"src/main/java/seedu/cafectrl/data/Sales.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":" * The Sales class represents sales data over a period of time, maintaining a collection of order lists.","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"public class Sales {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private static final String HEADER_FORMAT \u003d \"%-20s %-10s %-20s\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":" private static ArrayList\u003cOrderList\u003e orderLists;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" private int daysAccounted;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" public Sales() {","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" this.orderLists \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" orderLists.add(new OrderList());","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" public Sales(ArrayList\u003cOrderList\u003e orderLists) {","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.orderLists \u003d orderLists;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" //TODO: @Zhong Heng, Remove this method if not used","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" public Sales(OrderList orderList) {","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" this.orderLists \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" orderLists.add(orderList);","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" public void addOrderList(OrderList orderList) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" orderLists.add(orderList);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":" //TODO: @Zhong Heng, Remove this method if not used","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" public void removeOrderList(int orderListId) {","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" orderLists.remove(orderListId);","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" public void nextDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted +\u003d 1;","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" public int getDaysAccounted() {","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" return daysAccounted;","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" public ArrayList\u003cOrderList\u003e getOrderLists() {","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" return orderLists;","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" public OrderList getOrderList(int index) {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" return orderLists.get(index);","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" * Prints all sales data, organized by day, including dish names, quantities, and total cost prices.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"NaychiMin"},"content":" public void printSales(Ui ui, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" if (orderLists.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"No orders for the day!\");","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":" for (int day \u003d 0; day \u003c orderLists.size(); day++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" OrderList orderList \u003d orderLists.get(day);","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Day \" + (day + 1) + \":\");","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(String.format(HEADER_FORMAT, \"Dish Name\", \"Dish Qty\", \"Total Cost Price\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" orderList.printOrderList(menu, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" * Prints sales data for a specific day, including dish names, quantities, and total cost prices.","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" * @param day The day for which sales data is to be printed.","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" public void printSaleByDay(Ui ui, Menu menu, int day) {","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" int orderListIndex \u003d day - 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" OrderList orderList \u003d orderLists.get(orderListIndex);","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Day \" + (day) + \":\");","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(String.format(HEADER_FORMAT, \"Dish Name\", \"Dish Qty\", \"Total Cost Price\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" orderList.printOrderList(menu, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"An error occurred while printing sales for the specified day.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" //@@author","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"NaychiMin":51,"Cazh1":50}},{"path":"src/main/java/seedu/cafectrl/data/dish/Dish.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data.dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"public class Dish {","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" private String name;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" private ArrayList\u003cIngredient\u003e ingredients;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" private float price;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" public Dish(String name, ArrayList\u003cIngredient\u003e ingredients, float price) {","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" this.ingredients \u003d ingredients;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" this.price \u003d price;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public Dish(String name, float price) {","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" this.ingredients \u003d null;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" this.price \u003d price;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" public String getName() {","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" return name;","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":" public ArrayList\u003cIngredient\u003e getIngredients() {","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" return ingredients;","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" public float getPrice() {","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" return price;","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" public void setPrice(float newPrice) {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" this.price \u003d newPrice;","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":" public String toString() {","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" return this.name + \" $\" + this.price;","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"DextheChik3n":13,"Cazh1":5,"ziyi105":22,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/data/dish/Ingredient.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data.dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"public class Ingredient {","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":" private String name;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":" private int qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":" private String unit;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public Ingredient(String name) {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":" this.qty \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":" this.unit \u003d null;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":" public Ingredient(String name, int qty, String unit) {","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" this.qty \u003d qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" this.unit \u003d unit;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" public String getName() {","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" return name;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" public int getQty() {","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" return qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" public String getUnit() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" return unit;","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" public void setQty(int qty) {","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" this.qty \u003d qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":" public String toString() {","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" return name + \" - \" + qty + unit;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"NaychiMin":7,"DextheChik3n":14,"ziyi105":7,"ShaniceTang":13}},{"path":"src/main/java/seedu/cafectrl/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.AddDishCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.AddOrderCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.BuyIngredientCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.DeleteDishCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.EditPriceCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ExitCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.HelpCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.IncorrectCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListIngredientCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListMenuCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.NextDayCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.PreviousDayCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.command.ShowSalesCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.command.ShowSalesByDayCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.ViewTotalStockCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.parser.exception.ParserException;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"import java.text.ParseException;","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":" * Parse everything received from the users on terminal","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":" * into a format that can be interpreted by other core classes","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"ziyi105"},"content":"public class Parser implements ParserUtil {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"ziyi105"},"content":" private static final String COMMAND_ARGUMENT_REGEX \u003d \"(?\u003ccommandWord\u003e[a-z_]+)\\\\s*(?\u003carguments\u003e.*)\";","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" //@@author DextheChik3n","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" /** Add Dish Command Handler Patterns*/","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" private static final String ADD_ARGUMENT_STRING \u003d \"name/(?\u003cdishName\u003e[A-Za-z0-9\\\\s]+) \"","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" + \"price/\\\\s*(?\u003cdishPrice\u003e[0-9]*\\\\.[0-9]{0,2}|[0-9]+)\\\\s+\"","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":" + \"(?\u003cingredients\u003eingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+\"","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":" + \"(?:,\\\\s*ingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+)*)\";","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"DextheChik3n"},"content":" private static final String DISH_NAME_MATCHER_GROUP_LABEL \u003d \"dishName\";","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" private static final String PRICE_MATCHER_GROUP_LABEL \u003d \"dishPrice\";","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENTS_MATCHER_GROUP_LABEL \u003d \"ingredients\";","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_ARGUMENT_STRING \u003d \"\\\\s*ingredient/(?\u003cingredientName\u003e[A-Za-z0-9\\\\s]+) \"","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"DextheChik3n"},"content":" + \"qty/\\\\s*(?\u003cingredientQty\u003e[0-9]+)\\\\s*(?\u003cingredientUnit\u003eg|ml)\\\\s*\";","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_NAME_REGEX_GROUP_LABEL \u003d \"ingredientName\";","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_QTY_REGEX_GROUP_LABEL \u003d \"ingredientQty\";","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_UNIT_REGEX_GROUP_LABEL \u003d \"ingredientUnit\";","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_DIVIDER_REGEX \u003d \",\";","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"DextheChik3n"},"content":" /** Add Order Command Handler Patterns*/","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"DextheChik3n"},"content":" private static final int DISH_NAME_MATCHER_GROUP_NUM \u003d 1;","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" private static final int ORDER_QTY_MATCHER_GROUP_NUM \u003d 2;","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" private static final String ADD_ORDER_ARGUMENT_STRING \u003d \"name/([A-Za-z0-9\\\\s]+) \"","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" + \"qty/([A-Za-z0-9\\\\s]+)\";","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":" /** The rest of Command Handler Patterns*/","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":" private static final String LIST_INGREDIENTS_ARGUMENT_STRING \u003d \"(\\\\d+)\";","lastModifiedDate":"2023-10-17"},{"lineNumber":72,"author":{"gitId":"DextheChik3n"},"content":" private static final String DELETE_ARGUMENT_STRING \u003d \"(\\\\d+)\";","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"DextheChik3n"},"content":" private static final String EDIT_PRICE_ARGUMENT_STRING \u003d \"index/(\\\\d+) price/(\\\\d+(\\\\.\\\\d+)?)\";","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"DextheChik3n"},"content":" private static final String BUY_INGREDIENT_ARGUMENT_STRING \u003d \"(ingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+\"","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"DextheChik3n"},"content":" + \"(?:, ingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+)*)\";","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"DextheChik3n"},"content":" private static final String SHOW_SALE_BY_DAY_ARGUMENT_STRING \u003d \"day/(\\\\d+)\";","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":" * Parse userInput and group it under commandWord and arguments","lastModifiedDate":"2023-10-17"},{"lineNumber":81,"author":{"gitId":"ziyi105"},"content":" * use commandWord to find the matching command and prepare the command","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"ziyi105"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"ziyi105"},"content":" * @param menu The arraylist object created that stores current tasks","lastModifiedDate":"2023-10-17"},{"lineNumber":84,"author":{"gitId":"ziyi105"},"content":" * @param userInput The full user input String","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"ziyi105"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":" * @param pantry The arraylist object created that stores current ingredients in stock","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":" * @return command requested by the user","lastModifiedDate":"2023-10-17"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":89,"author":{"gitId":"ziyi105"},"content":" public Command parseCommand(Menu menu, String userInput, Ui ui,","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"ziyi105"},"content":" Pantry pantry, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"ziyi105"},"content":" Pattern userInputPattern \u003d Pattern.compile(COMMAND_ARGUMENT_REGEX);","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"ziyi105"},"content":" final Matcher matcher \u003d userInputPattern.matcher(userInput.trim());","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":94,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(\"Incorrect command format!\", ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":95,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":96,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":97,"author":{"gitId":"ziyi105"},"content":" final String commandWord \u003d matcher.group(\"commandWord\");","lastModifiedDate":"2023-10-17"},{"lineNumber":98,"author":{"gitId":"ziyi105"},"content":" final String arguments \u003d matcher.group(\"arguments\");","lastModifiedDate":"2023-10-17"},{"lineNumber":99,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":100,"author":{"gitId":"ziyi105"},"content":" switch (commandWord) {","lastModifiedDate":"2023-10-17"},{"lineNumber":101,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":" case AddDishCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":" return prepareAdd(arguments, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" case DeleteDishCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":106,"author":{"gitId":"ziyi105"},"content":" return prepareDelete(menu, arguments, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":108,"author":{"gitId":"ziyi105"},"content":" case ListIngredientCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":109,"author":{"gitId":"ziyi105"},"content":" return prepareListIngredient(menu, arguments, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":110,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":111,"author":{"gitId":"ziyi105"},"content":" case ListMenuCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":112,"author":{"gitId":"ziyi105"},"content":" return prepareListMenu(menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":114,"author":{"gitId":"ziyi105"},"content":" case EditPriceCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":115,"author":{"gitId":"ziyi105"},"content":" return prepareEditPriceCommand(menu, arguments, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":117,"author":{"gitId":"ziyi105"},"content":" case ViewTotalStockCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":" return prepareViewTotalStock(ui, pantry);","lastModifiedDate":"2023-10-25"},{"lineNumber":119,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"ziyi105"},"content":" case BuyIngredientCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"ziyi105"},"content":" return prepareBuyIngredient(arguments, ui, pantry);","lastModifiedDate":"2023-10-24"},{"lineNumber":122,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":123,"author":{"gitId":"ziyi105"},"content":" case HelpCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"ziyi105"},"content":" return prepareHelpCommand(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":125,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":126,"author":{"gitId":"ziyi105"},"content":" case ExitCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":127,"author":{"gitId":"ziyi105"},"content":" return new ExitCommand(ui, pantry);","lastModifiedDate":"2023-10-24"},{"lineNumber":128,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":129,"author":{"gitId":"ziyi105"},"content":" case AddOrderCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":130,"author":{"gitId":"ziyi105"},"content":" return prepareOrder(menu, arguments, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":131,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":132,"author":{"gitId":"ziyi105"},"content":" case NextDayCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-29"},{"lineNumber":133,"author":{"gitId":"ziyi105"},"content":" return prepareNextDay(ui, sales, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":134,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"ziyi105"},"content":" case PreviousDayCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-29"},{"lineNumber":136,"author":{"gitId":"ziyi105"},"content":" return preparePreviousDay(ui, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"ziyi105"},"content":" case ShowSalesCommand.COMMAND_WORD:","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"ziyi105"},"content":" return prepareShowSales(sales, menu, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"ziyi105"},"content":" case ShowSalesByDayCommand.COMMAND_WORD:","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"ziyi105"},"content":" return prepareShowSalesByDay(arguments, ui, sales, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":144,"author":{"gitId":"ziyi105"},"content":" default:","lastModifiedDate":"2023-10-17"},{"lineNumber":145,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.UNKNOWN_COMMAND_MESSAGE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":147,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":148,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":149,"author":{"gitId":"ziyi105"},"content":" //All prepareCommand Classes","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-10-28"},{"lineNumber":151,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"Cazh1"},"content":" * Prepares the ListMenuCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":" * @param ui ui of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":" * @return new ListMenuCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":158,"author":{"gitId":"Cazh1"},"content":" private static Command prepareListMenu(Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":" return new ListMenuCommand(menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":162,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-28"},{"lineNumber":163,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":164,"author":{"gitId":"ziyi105"},"content":" * Parse argument in the context of edit price command","lastModifiedDate":"2023-10-17"},{"lineNumber":165,"author":{"gitId":"ziyi105"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-18"},{"lineNumber":166,"author":{"gitId":"ziyi105"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-17"},{"lineNumber":167,"author":{"gitId":"ziyi105"},"content":" * @return new EditDishCommand","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"ziyi105"},"content":" private static Command prepareEditPriceCommand(Menu menu, String arguments, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":170,"author":{"gitId":"ziyi105"},"content":" Pattern editDishArgumentsPattern \u003d Pattern.compile(EDIT_PRICE_ARGUMENT_STRING);","lastModifiedDate":"2023-10-17"},{"lineNumber":171,"author":{"gitId":"ziyi105"},"content":" Matcher matcher \u003d editDishArgumentsPattern.matcher(arguments);","lastModifiedDate":"2023-10-17"},{"lineNumber":172,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":173,"author":{"gitId":"ziyi105"},"content":" // Checks whether the overall pattern of edit price arguments is correct","lastModifiedDate":"2023-10-17"},{"lineNumber":174,"author":{"gitId":"ziyi105"},"content":" if (!matcher.find()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":175,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_EDIT_PRICE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":176,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":177,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":178,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":179,"author":{"gitId":"ziyi105"},"content":" int dishIndexGroup \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":180,"author":{"gitId":"ziyi105"},"content":" int newPriceGroup \u003d 2;","lastModifiedDate":"2023-10-18"},{"lineNumber":181,"author":{"gitId":"ziyi105"},"content":" int dishIndex \u003d Integer.parseInt(matcher.group(dishIndexGroup));","lastModifiedDate":"2023-10-18"},{"lineNumber":182,"author":{"gitId":"ziyi105"},"content":" float newPrice \u003d parsePriceToFloat(matcher.group(newPriceGroup));","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":184,"author":{"gitId":"ziyi105"},"content":" // Check whether the dish index is valid","lastModifiedDate":"2023-10-18"},{"lineNumber":185,"author":{"gitId":"ziyi105"},"content":" if (!menu.isValidDishIndex(dishIndex)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DISH_INDEX, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":188,"author":{"gitId":"ziyi105"},"content":" return new EditPriceCommand(dishIndex, newPrice, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":189,"author":{"gitId":"ziyi105"},"content":" } catch (ParserException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.WRONG_ARGUMENT_TYPE_FOR_EDIT_PRICE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":192,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":193,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"DextheChik3n"},"content":" //@@author DextheChik3n","lastModifiedDate":"2023-10-27"},{"lineNumber":195,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":196,"author":{"gitId":"DextheChik3n"},"content":" * Parses the user input text into ingredients to form a \u003ccode\u003eDish\u003c/code\u003e that is added to the \u003ccode\u003eMenu\u003c/code\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":197,"author":{"gitId":"DextheChik3n"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"DextheChik3n"},"content":" * @return new AddDishCommand","lastModifiedDate":"2023-10-23"},{"lineNumber":199,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":200,"author":{"gitId":"DextheChik3n"},"content":" private static Command prepareAdd(String arguments, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":201,"author":{"gitId":"DextheChik3n"},"content":" final Pattern addArgumentPatter \u003d Pattern.compile(ADD_ARGUMENT_STRING);","lastModifiedDate":"2023-10-17"},{"lineNumber":202,"author":{"gitId":"DextheChik3n"},"content":" Matcher matcher \u003d addArgumentPatter.matcher(arguments);","lastModifiedDate":"2023-10-17"},{"lineNumber":203,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":204,"author":{"gitId":"DextheChik3n"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":205,"author":{"gitId":"DextheChik3n"},"content":" // Checks whether the overall pattern of add arguments is correct","lastModifiedDate":"2023-10-17"},{"lineNumber":206,"author":{"gitId":"DextheChik3n"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":207,"author":{"gitId":"DextheChik3n"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ADD_DISH_FORMAT_MESSAGE","lastModifiedDate":"2023-10-30"},{"lineNumber":208,"author":{"gitId":"DextheChik3n"},"content":" + AddDishCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":209,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":210,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":211,"author":{"gitId":"DextheChik3n"},"content":" // To retrieve specific arguments from arguments","lastModifiedDate":"2023-10-17"},{"lineNumber":212,"author":{"gitId":"DextheChik3n"},"content":" String dishName \u003d matcher.group(DISH_NAME_MATCHER_GROUP_LABEL).trim();","lastModifiedDate":"2023-10-27"},{"lineNumber":213,"author":{"gitId":"DextheChik3n"},"content":" float price \u003d parsePriceToFloat(matcher.group(PRICE_MATCHER_GROUP_LABEL));","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"DextheChik3n"},"content":" String ingredientsListString \u003d matcher.group(INGREDIENTS_MATCHER_GROUP_LABEL);","lastModifiedDate":"2023-10-24"},{"lineNumber":215,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":216,"author":{"gitId":"DextheChik3n"},"content":" if (isNameLengthInvalid(dishName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_DISH_NAME_LENGTH_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"DextheChik3n"},"content":" if (isRepeatedName(dishName, menu)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(Messages.REPEATED_DISH_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":223,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d parseIngredients(ingredientsListString);","lastModifiedDate":"2023-10-31"},{"lineNumber":225,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":226,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(dishName, ingredients, price);","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":228,"author":{"gitId":"DextheChik3n"},"content":" return new AddDishCommand(dish, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":229,"author":{"gitId":"DextheChik3n"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":230,"author":{"gitId":"DextheChik3n"},"content":" return new IncorrectCommand(ErrorMessages.NULL_NAME_DETECTED_MESSAGE, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"DextheChik3n"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"DextheChik3n"},"content":" return new IncorrectCommand(e.getMessage(), ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":234,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":236,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":237,"author":{"gitId":"DextheChik3n"},"content":" * Parses the user\u0027s input text ingredients.","lastModifiedDate":"2023-10-25"},{"lineNumber":238,"author":{"gitId":"DextheChik3n"},"content":" * @param ingredientsListString user\u0027s input string of ingredients, multiple ingredients seperated by \u0027,\u0027 is allowed","lastModifiedDate":"2023-10-25"},{"lineNumber":239,"author":{"gitId":"DextheChik3n"},"content":" * @return Ingredient objects that consists of the dish","lastModifiedDate":"2023-10-23"},{"lineNumber":240,"author":{"gitId":"DextheChik3n"},"content":" * @throws IllegalArgumentException if the input string of ingredients is in an incorrect format.","lastModifiedDate":"2023-10-23"},{"lineNumber":241,"author":{"gitId":"DextheChik3n"},"content":" * @throws ParserException if the input string does not match the constraints","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":243,"author":{"gitId":"DextheChik3n"},"content":" private static ArrayList\u003cIngredient\u003e parseIngredients(String ingredientsListString)","lastModifiedDate":"2023-10-31"},{"lineNumber":244,"author":{"gitId":"DextheChik3n"},"content":" throws IllegalArgumentException, ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"DextheChik3n"},"content":" String[] inputIngredientList \u003d {ingredientsListString};","lastModifiedDate":"2023-10-27"},{"lineNumber":246,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":247,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":248,"author":{"gitId":"DextheChik3n"},"content":" //check if there is more than 1 ingredient","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"DextheChik3n"},"content":" if (ingredientsListString.contains(INGREDIENT_DIVIDER_REGEX)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":250,"author":{"gitId":"DextheChik3n"},"content":" //split the whole string of ingredients into separate individual ingredients","lastModifiedDate":"2023-10-23"},{"lineNumber":251,"author":{"gitId":"DextheChik3n"},"content":" inputIngredientList \u003d ingredientsListString.split(INGREDIENT_DIVIDER_REGEX);","lastModifiedDate":"2023-10-27"},{"lineNumber":252,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":253,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":254,"author":{"gitId":"DextheChik3n"},"content":" //Parsing each ingredient","lastModifiedDate":"2023-10-23"},{"lineNumber":255,"author":{"gitId":"DextheChik3n"},"content":" for (String inputIngredient: inputIngredientList) {","lastModifiedDate":"2023-10-27"},{"lineNumber":256,"author":{"gitId":"DextheChik3n"},"content":" final Pattern ingredientPattern \u003d Pattern.compile(INGREDIENT_ARGUMENT_STRING);","lastModifiedDate":"2023-10-18"},{"lineNumber":257,"author":{"gitId":"DextheChik3n"},"content":" Matcher ingredientMatcher \u003d ingredientPattern.matcher(inputIngredient);","lastModifiedDate":"2023-10-27"},{"lineNumber":258,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"DextheChik3n"},"content":" if (!ingredientMatcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":260,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_ADD_DISH_FORMAT_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"DextheChik3n"},"content":" + AddDishCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":263,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":264,"author":{"gitId":"DextheChik3n"},"content":" String ingredientName \u003d ingredientMatcher.group(INGREDIENT_NAME_REGEX_GROUP_LABEL).trim();","lastModifiedDate":"2023-10-27"},{"lineNumber":265,"author":{"gitId":"DextheChik3n"},"content":" String ingredientQtyString \u003d ingredientMatcher.group(INGREDIENT_QTY_REGEX_GROUP_LABEL);","lastModifiedDate":"2023-10-27"},{"lineNumber":266,"author":{"gitId":"DextheChik3n"},"content":" String ingredientUnit \u003d ingredientMatcher.group(INGREDIENT_UNIT_REGEX_GROUP_LABEL);","lastModifiedDate":"2023-10-25"},{"lineNumber":267,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"DextheChik3n"},"content":" int ingredientQty \u003d Integer.parseInt(ingredientQtyString);","lastModifiedDate":"2023-10-27"},{"lineNumber":269,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":270,"author":{"gitId":"DextheChik3n"},"content":" if (isNameLengthInvalid(ingredientName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_INGREDIENT_NAME_LENGTH_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"DextheChik3n"},"content":" if (isRepeatedName(ingredientName, ingredients)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"DextheChik3n"},"content":" continue;","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"DextheChik3n"},"content":" Ingredient ingredient \u003d new Ingredient(ingredientName, ingredientQty, ingredientUnit);","lastModifiedDate":"2023-10-27"},{"lineNumber":279,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":280,"author":{"gitId":"DextheChik3n"},"content":" ingredients.add(ingredient);","lastModifiedDate":"2023-10-18"},{"lineNumber":281,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":282,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":283,"author":{"gitId":"DextheChik3n"},"content":" return ingredients;","lastModifiedDate":"2023-10-23"},{"lineNumber":284,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":285,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":286,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"DextheChik3n"},"content":" * Converts text of price to float while also checking if the price input is within reasonable range","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"DextheChik3n"},"content":" * @param priceText text input for price argument","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"DextheChik3n"},"content":" * @return price in float format","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"DextheChik3n"},"content":" * @throws ArithmeticException if price \u003e 10000000000.00","lastModifiedDate":"2023-11-01"},{"lineNumber":291,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":292,"author":{"gitId":"DextheChik3n"},"content":" static float parsePriceToFloat(String priceText) throws ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"DextheChik3n"},"content":" float price \u003d Float.parseFloat(priceText);","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"DextheChik3n"},"content":" float maxPriceValue \u003d (float) 10000000000.00;","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"DextheChik3n"},"content":" if (price \u003e maxPriceValue) {","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_PRICE_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":300,"author":{"gitId":"DextheChik3n"},"content":" return price;","lastModifiedDate":"2023-11-01"},{"lineNumber":301,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":302,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":303,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"DextheChik3n"},"content":" * Checks in the menu if the dish name already exists in the menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":305,"author":{"gitId":"DextheChik3n"},"content":" * @param inputDishName dish name entered by the user","lastModifiedDate":"2023-11-01"},{"lineNumber":306,"author":{"gitId":"DextheChik3n"},"content":" * @param menu contains all the existing Dishes","lastModifiedDate":"2023-11-01"},{"lineNumber":307,"author":{"gitId":"DextheChik3n"},"content":" * @return true if dish name already exists in menu, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":308,"author":{"gitId":"DextheChik3n"},"content":" * @throws NullPointerException if the input string is null","lastModifiedDate":"2023-11-01"},{"lineNumber":309,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":310,"author":{"gitId":"DextheChik3n"},"content":" static boolean isRepeatedName(String inputDishName, Menu menu) throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":311,"author":{"gitId":"DextheChik3n"},"content":" if (inputDishName \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":312,"author":{"gitId":"DextheChik3n"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-01"},{"lineNumber":313,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":314,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":315,"author":{"gitId":"DextheChik3n"},"content":" for (Dish dish: menu.getMenuItemsList()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":316,"author":{"gitId":"DextheChik3n"},"content":" String menuDishNameLowerCase \u003d dish.getName().toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":317,"author":{"gitId":"DextheChik3n"},"content":" String inputDishNameLowerCase \u003d inputDishName.toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":318,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":319,"author":{"gitId":"DextheChik3n"},"content":" if (menuDishNameLowerCase.equals(inputDishNameLowerCase)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":320,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":321,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":322,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":323,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":324,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":325,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":326,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":327,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":328,"author":{"gitId":"DextheChik3n"},"content":" * Checks in the menu if the dish name already exists in the menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":329,"author":{"gitId":"DextheChik3n"},"content":" * @param inputName dish name entered by the user","lastModifiedDate":"2023-11-01"},{"lineNumber":330,"author":{"gitId":"DextheChik3n"},"content":" * @param ingredients contains all the existing Ingredients","lastModifiedDate":"2023-11-01"},{"lineNumber":331,"author":{"gitId":"DextheChik3n"},"content":" * @return true if ingredient name already exists in menu, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":332,"author":{"gitId":"DextheChik3n"},"content":" * @throws NullPointerException if the input string is null","lastModifiedDate":"2023-11-01"},{"lineNumber":333,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":334,"author":{"gitId":"DextheChik3n"},"content":" static boolean isRepeatedName(String inputName, ArrayList\u003cIngredient\u003e ingredients) throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":335,"author":{"gitId":"DextheChik3n"},"content":" if (inputName \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":336,"author":{"gitId":"DextheChik3n"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-01"},{"lineNumber":337,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":338,"author":{"gitId":"DextheChik3n"},"content":" for (Ingredient ingredient: ingredients) {","lastModifiedDate":"2023-11-01"},{"lineNumber":339,"author":{"gitId":"DextheChik3n"},"content":" String ingredientNameLowerCase \u003d ingredient.getName().toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":340,"author":{"gitId":"DextheChik3n"},"content":" String inputIngredientNameLowerCase \u003d inputName.toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":341,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":342,"author":{"gitId":"DextheChik3n"},"content":" if (ingredientNameLowerCase.equals(inputIngredientNameLowerCase)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":343,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":344,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":345,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":346,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":347,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":348,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":349,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":350,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":351,"author":{"gitId":"DextheChik3n"},"content":" * Checks the length of the name is too long","lastModifiedDate":"2023-11-01"},{"lineNumber":352,"author":{"gitId":"DextheChik3n"},"content":" * @param inputName name","lastModifiedDate":"2023-11-01"},{"lineNumber":353,"author":{"gitId":"DextheChik3n"},"content":" * @return true if the name is more than max character limit set, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":354,"author":{"gitId":"DextheChik3n"},"content":" * @throws NullPointerException if the input string is null","lastModifiedDate":"2023-11-01"},{"lineNumber":355,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":356,"author":{"gitId":"DextheChik3n"},"content":" static boolean isNameLengthInvalid(String inputName) throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":357,"author":{"gitId":"DextheChik3n"},"content":" int maxNameLength \u003d 35;","lastModifiedDate":"2023-11-01"},{"lineNumber":358,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":359,"author":{"gitId":"DextheChik3n"},"content":" if (inputName \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":360,"author":{"gitId":"DextheChik3n"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-01"},{"lineNumber":361,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":362,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":363,"author":{"gitId":"DextheChik3n"},"content":" if (inputName.length() \u003e maxNameLength) {","lastModifiedDate":"2023-11-01"},{"lineNumber":364,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":365,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":366,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":367,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":368,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":369,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":370,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-10-27"},{"lineNumber":371,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":372,"author":{"gitId":"NaychiMin"},"content":" * Parses arguments in the context of the ListIngredient command.","lastModifiedDate":"2023-10-17"},{"lineNumber":373,"author":{"gitId":"NaychiMin"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-18"},{"lineNumber":374,"author":{"gitId":"NaychiMin"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-18"},{"lineNumber":375,"author":{"gitId":"NaychiMin"},"content":" * @return the prepared command","lastModifiedDate":"2023-10-17"},{"lineNumber":376,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":377,"author":{"gitId":"NaychiMin"},"content":" private static Command prepareListIngredient(Menu menu, String arguments, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":378,"author":{"gitId":"NaychiMin"},"content":" final Pattern prepareListPattern \u003d Pattern.compile(LIST_INGREDIENTS_ARGUMENT_STRING);","lastModifiedDate":"2023-10-18"},{"lineNumber":379,"author":{"gitId":"NaychiMin"},"content":" Matcher matcher \u003d prepareListPattern.matcher(arguments.trim());","lastModifiedDate":"2023-10-18"},{"lineNumber":380,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":381,"author":{"gitId":"NaychiMin"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":382,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_LIST_INGREDIENTS, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":383,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":384,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":385,"author":{"gitId":"NaychiMin"},"content":" int dishIndex \u003d Integer.parseInt(matcher.group(1));","lastModifiedDate":"2023-10-18"},{"lineNumber":386,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":387,"author":{"gitId":"NaychiMin"},"content":" if (!menu.isValidDishIndex(dishIndex)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":388,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DISH_INDEX, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":389,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":390,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":391,"author":{"gitId":"NaychiMin"},"content":" return new ListIngredientCommand(dishIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":392,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":393,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":394,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-10-28"},{"lineNumber":395,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":396,"author":{"gitId":"ShaniceTang"},"content":" * Parses arguments in the context of the Delete command.","lastModifiedDate":"2023-10-17"},{"lineNumber":397,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":398,"author":{"gitId":"ShaniceTang"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-18"},{"lineNumber":399,"author":{"gitId":"ShaniceTang"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-18"},{"lineNumber":400,"author":{"gitId":"ShaniceTang"},"content":" * @return DeleteDishCommand if command is valid, IncorrectCommand otherwise","lastModifiedDate":"2023-10-18"},{"lineNumber":401,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":402,"author":{"gitId":"ShaniceTang"},"content":" private static Command prepareDelete(Menu menu, String arguments, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":403,"author":{"gitId":"ShaniceTang"},"content":" Pattern deleteDishArgumentsPattern \u003d Pattern.compile(DELETE_ARGUMENT_STRING);","lastModifiedDate":"2023-10-18"},{"lineNumber":404,"author":{"gitId":"ShaniceTang"},"content":" Matcher matcher \u003d deleteDishArgumentsPattern.matcher(arguments.trim());","lastModifiedDate":"2023-10-18"},{"lineNumber":405,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":406,"author":{"gitId":"ShaniceTang"},"content":" // Checks whether the overall pattern of delete price arguments is correct","lastModifiedDate":"2023-10-18"},{"lineNumber":407,"author":{"gitId":"ShaniceTang"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":408,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_DELETE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":409,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":410,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":411,"author":{"gitId":"ShaniceTang"},"content":" int listIndexArgGroup \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":412,"author":{"gitId":"ShaniceTang"},"content":" int dishIndex \u003d Integer.parseInt(matcher.group(listIndexArgGroup));","lastModifiedDate":"2023-10-18"},{"lineNumber":413,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":414,"author":{"gitId":"ShaniceTang"},"content":" if (!menu.isValidDishIndex(dishIndex)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":415,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DISH_INDEX, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":416,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":417,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":418,"author":{"gitId":"ShaniceTang"},"content":" return new DeleteDishCommand(dishIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":419,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":420,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":421,"author":{"gitId":"ShaniceTang"},"content":" private static Command prepareViewTotalStock(Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-25"},{"lineNumber":422,"author":{"gitId":"ShaniceTang"},"content":" return new ViewTotalStockCommand(pantry, ui);","lastModifiedDate":"2023-10-25"},{"lineNumber":423,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":424,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":425,"author":{"gitId":"ShaniceTang"},"content":" private static Command prepareBuyIngredient(String arguments, Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-24"},{"lineNumber":426,"author":{"gitId":"ShaniceTang"},"content":" Pattern buyIngredientArgumentsPattern \u003d Pattern.compile(BUY_INGREDIENT_ARGUMENT_STRING);","lastModifiedDate":"2023-10-25"},{"lineNumber":427,"author":{"gitId":"ShaniceTang"},"content":" Matcher matcher \u003d buyIngredientArgumentsPattern.matcher(arguments.trim());","lastModifiedDate":"2023-10-22"},{"lineNumber":428,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":429,"author":{"gitId":"ShaniceTang"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":430,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":431,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-10-31"},{"lineNumber":432,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-31"},{"lineNumber":433,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":434,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":435,"author":{"gitId":"ShaniceTang"},"content":" String ingredientsListString \u003d matcher.group(0);","lastModifiedDate":"2023-10-25"},{"lineNumber":436,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":437,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":438,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d parseIngredients(ingredientsListString);","lastModifiedDate":"2023-11-01"},{"lineNumber":439,"author":{"gitId":"ShaniceTang"},"content":" return new BuyIngredientCommand(ingredients, ui, pantry);","lastModifiedDate":"2023-10-25"},{"lineNumber":440,"author":{"gitId":"ShaniceTang"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-22"},{"lineNumber":441,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-10-31"},{"lineNumber":442,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-31"},{"lineNumber":443,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":444,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":445,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":446,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-28"},{"lineNumber":447,"author":{"gitId":"ziyi105"},"content":" private static Command prepareHelpCommand(Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":448,"author":{"gitId":"ziyi105"},"content":" return new HelpCommand(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":449,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":450,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":451,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-11-01"},{"lineNumber":452,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":453,"author":{"gitId":"Cazh1"},"content":" * Parses arguments in the context of the AddOrder command.","lastModifiedDate":"2023-10-30"},{"lineNumber":454,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":455,"author":{"gitId":"Cazh1"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-23"},{"lineNumber":456,"author":{"gitId":"Cazh1"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-23"},{"lineNumber":457,"author":{"gitId":"Cazh1"},"content":" * @param ui","lastModifiedDate":"2023-10-30"},{"lineNumber":458,"author":{"gitId":"Cazh1"},"content":" * @return AddOrderCommand if command is valid, IncorrectCommand otherwise","lastModifiedDate":"2023-10-23"},{"lineNumber":459,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":460,"author":{"gitId":"Cazh1"},"content":" private static Command prepareOrder(Menu menu, String arguments, Ui ui,","lastModifiedDate":"2023-10-30"},{"lineNumber":461,"author":{"gitId":"Cazh1"},"content":" Pantry pantry, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":462,"author":{"gitId":"Cazh1"},"content":" final Pattern addOrderArgumentPatter \u003d Pattern.compile(ADD_ORDER_ARGUMENT_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":463,"author":{"gitId":"Cazh1"},"content":" Matcher matcher \u003d addOrderArgumentPatter.matcher(arguments);","lastModifiedDate":"2023-10-23"},{"lineNumber":464,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":465,"author":{"gitId":"Cazh1"},"content":" // Checks whether the overall pattern of add order arguments is correct","lastModifiedDate":"2023-10-23"},{"lineNumber":466,"author":{"gitId":"Cazh1"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":467,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ADD_ORDER_FORMAT_MESSAGE","lastModifiedDate":"2023-10-30"},{"lineNumber":468,"author":{"gitId":"Cazh1"},"content":" + AddOrderCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":469,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":470,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":471,"author":{"gitId":"Cazh1"},"content":" OrderList orderList \u003d setOrderList(currentDate, sales);","lastModifiedDate":"2023-10-30"},{"lineNumber":472,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":473,"author":{"gitId":"Cazh1"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":474,"author":{"gitId":"Cazh1"},"content":" // To retrieve specific arguments from arguments","lastModifiedDate":"2023-10-23"},{"lineNumber":475,"author":{"gitId":"Cazh1"},"content":" String dishName \u003d matcher.group(DISH_NAME_MATCHER_GROUP_NUM);","lastModifiedDate":"2023-10-23"},{"lineNumber":476,"author":{"gitId":"Cazh1"},"content":" int dishQty \u003d Integer.parseInt(matcher.group(ORDER_QTY_MATCHER_GROUP_NUM));","lastModifiedDate":"2023-10-23"},{"lineNumber":477,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":478,"author":{"gitId":"Cazh1"},"content":" Dish orderedDish \u003d menu.getDishFromName(dishName);","lastModifiedDate":"2023-10-24"},{"lineNumber":479,"author":{"gitId":"Cazh1"},"content":" if (orderedDish \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":480,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(ErrorMessages.DISH_NOT_FOUND, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":481,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":482,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":483,"author":{"gitId":"Cazh1"},"content":" Order order \u003d new Order(orderedDish, dishQty);","lastModifiedDate":"2023-10-24"},{"lineNumber":484,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":485,"author":{"gitId":"Cazh1"},"content":" return new AddOrderCommand(order, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":486,"author":{"gitId":"Cazh1"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":487,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ADD_ORDER_FORMAT_MESSAGE","lastModifiedDate":"2023-10-30"},{"lineNumber":488,"author":{"gitId":"Cazh1"},"content":" + AddOrderCommand.MESSAGE_USAGE + e.getMessage(), ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":489,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":490,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":491,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":492,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":493,"author":{"gitId":"Cazh1"},"content":" * Prepares PreviousDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":494,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":495,"author":{"gitId":"Cazh1"},"content":" * @param ui ui object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":496,"author":{"gitId":"Cazh1"},"content":" * @param currentDate currentDate object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":497,"author":{"gitId":"Cazh1"},"content":" * @return PreviousDayCommand if after day 1, IncorrectCommand if before","lastModifiedDate":"2023-10-30"},{"lineNumber":498,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":499,"author":{"gitId":"Cazh1"},"content":" private static Command preparePreviousDay(Ui ui, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":500,"author":{"gitId":"Cazh1"},"content":" int currentDay \u003d currentDate.getCurrentDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":501,"author":{"gitId":"Cazh1"},"content":" if (currentDay \u003d\u003d 0) {","lastModifiedDate":"2023-10-29"},{"lineNumber":502,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(Messages.PREVIOUS_DAY_TIME_TRAVEL, ui);","lastModifiedDate":"2023-10-29"},{"lineNumber":503,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":504,"author":{"gitId":"Cazh1"},"content":" return new PreviousDayCommand(ui, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":505,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":506,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":507,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":508,"author":{"gitId":"Cazh1"},"content":" * Prepares NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":509,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":510,"author":{"gitId":"Cazh1"},"content":" * @param ui ui object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":511,"author":{"gitId":"Cazh1"},"content":" * @param sales sales object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":512,"author":{"gitId":"Cazh1"},"content":" * @param currentDate currentDate object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":513,"author":{"gitId":"Cazh1"},"content":" * @return NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":514,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":515,"author":{"gitId":"Cazh1"},"content":" private static Command prepareNextDay(Ui ui, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":516,"author":{"gitId":"Cazh1"},"content":" return new NextDayCommand(ui, sales, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":517,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":518,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":519,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":520,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":521,"author":{"gitId":"NaychiMin"},"content":" * Prepares a command to display all sales items.","lastModifiedDate":"2023-11-01"},{"lineNumber":522,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":523,"author":{"gitId":"NaychiMin"},"content":" * @param sale The Sales object containing sales data.","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":526,"author":{"gitId":"NaychiMin"},"content":" * @return A ShowSalesCommand instance for viewing all sales items.","lastModifiedDate":"2023-11-01"},{"lineNumber":527,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":528,"author":{"gitId":"NaychiMin"},"content":" private static Command prepareShowSales(Sales sale, Menu menu, Ui ui) {","lastModifiedDate":"2023-11-01"},{"lineNumber":529,"author":{"gitId":"NaychiMin"},"content":" return new ShowSalesCommand(sale, ui, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":530,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":531,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"NaychiMin"},"content":" * Prepares a command to display sales items for a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":534,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"NaychiMin"},"content":" * @param arguments The arguments containing the day for which sales are to be displayed.","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"NaychiMin"},"content":" * @param sales The Sales object containing sales data.","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"NaychiMin"},"content":" * @return A ShowSalesByDayCommand instance for viewing sales items on a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":540,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"NaychiMin"},"content":" private static Command prepareShowSalesByDay(String arguments, Ui ui, Sales sales, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"NaychiMin"},"content":" final Pattern showSaleByDayPattern \u003d Pattern.compile(SHOW_SALE_BY_DAY_ARGUMENT_STRING);","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"NaychiMin"},"content":" Matcher matcher \u003d showSaleByDayPattern.matcher(arguments.trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"NaychiMin"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":546,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_SHOW_SALE_DAY_FORMAT_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":547,"author":{"gitId":"NaychiMin"},"content":" + ShowSalesByDayCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":548,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":549,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":550,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":551,"author":{"gitId":"NaychiMin"},"content":" int day \u003d Integer.parseInt(matcher.group(1));","lastModifiedDate":"2023-11-01"},{"lineNumber":552,"author":{"gitId":"NaychiMin"},"content":" return new ShowSalesByDayCommand(day, ui, sales, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":553,"author":{"gitId":"NaychiMin"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":554,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DAY_FORMAT, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":555,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":556,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":557,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":558,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-11-01"},{"lineNumber":559,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":560,"author":{"gitId":"Cazh1"},"content":" * Sets the orderList according to the Day","lastModifiedDate":"2023-10-30"},{"lineNumber":561,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":562,"author":{"gitId":"Cazh1"},"content":" * @param currentDate currentDate object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":563,"author":{"gitId":"Cazh1"},"content":" * @param sales sales object of the current session, contains the orderLists","lastModifiedDate":"2023-10-30"},{"lineNumber":564,"author":{"gitId":"Cazh1"},"content":" * @return The respective orderList","lastModifiedDate":"2023-10-30"},{"lineNumber":565,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":566,"author":{"gitId":"Cazh1"},"content":" private static OrderList setOrderList(CurrentDate currentDate, Sales sales) {","lastModifiedDate":"2023-10-30"},{"lineNumber":567,"author":{"gitId":"Cazh1"},"content":" int currentDay \u003d currentDate.getCurrentDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":568,"author":{"gitId":"Cazh1"},"content":" return sales.getOrderList(currentDay);","lastModifiedDate":"2023-10-30"},{"lineNumber":569,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":570,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":571,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-11-01"},{"lineNumber":572,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":573,"author":{"gitId":"Cazh1"},"content":" * Parses the given arguments string to identify task index number.","lastModifiedDate":"2023-10-17"},{"lineNumber":574,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":575,"author":{"gitId":"Cazh1"},"content":" * @param userInput arguments string to parse as index number","lastModifiedDate":"2023-10-17"},{"lineNumber":576,"author":{"gitId":"Cazh1"},"content":" * @param command expected String name of the command called","lastModifiedDate":"2023-10-17"},{"lineNumber":577,"author":{"gitId":"Cazh1"},"content":" * @return the parsed index number","lastModifiedDate":"2023-10-17"},{"lineNumber":578,"author":{"gitId":"Cazh1"},"content":" * @throws ParseException if no region of the args string could be found for the index","lastModifiedDate":"2023-10-17"},{"lineNumber":579,"author":{"gitId":"Cazh1"},"content":" * @throws NumberFormatException the args string region is not a valid number","lastModifiedDate":"2023-10-17"},{"lineNumber":580,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":581,"author":{"gitId":"Cazh1"},"content":" private static int parseArgsAsDisplayedIndex(String userInput, String command)","lastModifiedDate":"2023-10-17"},{"lineNumber":582,"author":{"gitId":"Cazh1"},"content":" throws ParseException, NumberFormatException {","lastModifiedDate":"2023-10-17"},{"lineNumber":583,"author":{"gitId":"Cazh1"},"content":" String formattedString \u003d userInput.replace(command, \"\").trim();","lastModifiedDate":"2023-10-17"},{"lineNumber":584,"author":{"gitId":"Cazh1"},"content":" return Integer.parseInt(formattedString);","lastModifiedDate":"2023-10-17"},{"lineNumber":585,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":586,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":587,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":588,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":589,"author":{"gitId":"ShaniceTang"},"content":" * Extracts the quantity (numeric part) from a given string containing both quantity and unit.","lastModifiedDate":"2023-10-23"},{"lineNumber":590,"author":{"gitId":"ShaniceTang"},"content":" * @param qty A string containing both quantity and unit (e.g., \"100g\").","lastModifiedDate":"2023-10-23"},{"lineNumber":591,"author":{"gitId":"ShaniceTang"},"content":" * @return An integer representing the extracted quantity.","lastModifiedDate":"2023-10-23"},{"lineNumber":592,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":593,"author":{"gitId":"ShaniceTang"},"content":" public static int extractQty(String qty) {","lastModifiedDate":"2023-10-23"},{"lineNumber":594,"author":{"gitId":"ShaniceTang"},"content":" return Integer.parseInt(qty.replaceAll(\"[^0-9]\", \"\"));","lastModifiedDate":"2023-10-23"},{"lineNumber":595,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":596,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":597,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":598,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":599,"author":{"gitId":"ShaniceTang"},"content":" * Extracts the unit (non-numeric part) from a given string containing both quantity and unit.","lastModifiedDate":"2023-10-23"},{"lineNumber":600,"author":{"gitId":"ShaniceTang"},"content":" * @param qty A string containing both quantity and unit (e.g., \"100g\").","lastModifiedDate":"2023-10-23"},{"lineNumber":601,"author":{"gitId":"ShaniceTang"},"content":" * @return A string representing the extracted unit.","lastModifiedDate":"2023-10-23"},{"lineNumber":602,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":603,"author":{"gitId":"ShaniceTang"},"content":" public static String extractUnit(String qty) {","lastModifiedDate":"2023-10-23"},{"lineNumber":604,"author":{"gitId":"ShaniceTang"},"content":" return qty.replaceAll(\"[0-9]\", \"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":605,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":606,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"NaychiMin":67,"DextheChik3n":212,"Cazh1":119,"ziyi105":135,"ShaniceTang":73}},{"path":"src/main/java/seedu/cafectrl/parser/ParserUtil.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" * Parser interface for external class to use Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"public interface ParserUtil {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" Command parseCommand(Menu menu, String userInput, Ui ui,","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" Pantry pantry, Sales sales, CurrentDate currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ziyi105":16}},{"path":"src/main/java/seedu/cafectrl/parser/exception/ParserException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.parser.exception;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":" * Represents a parse error encountered by parser.","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"public class ParserException extends Exception {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":" * @param errorMessage contains relevant information on failed constraint(s)","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" public ParserException(String errorMessage) {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":" super(errorMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"DextheChik3n":12}},{"path":"src/main/java/seedu/cafectrl/storage/Decoder.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" * The Decoder class offers methods to interpret string representations from text files,","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" * decoding them into appropriate data structures. It includes methods to decode a Menu,","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" * Pantry stock, and OrderList, allowing retrieval of data stored in a file.","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"public class Decoder {","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" private static final String DIVIDER \u003d \"\\\\| \";","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" private static final Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" * Decodes an ArrayList of string lines into a Menu object, reconstructing its content.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" * @param textLines An ArrayList of strings representing the encoded Menu data.","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" * @return A Menu object containing the decoded Menu data.","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" public static Menu decodeMenuData(ArrayList\u003cString\u003e textLines) {","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cDish\u003e menuDishList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" for(String dishString : textLines) {","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" String[] dishStringArray \u003d dishString.split(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" String dishName \u003d dishStringArray[0].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" float dishPrice \u003d Float.parseFloat(dishStringArray[1]);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" String[] ingredientStringArray \u003d Arrays.copyOfRange(dishStringArray, 2, dishStringArray.length);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d decodeIngredientData(ingredientStringArray);","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" menuDishList.add(new Dish(dishName, ingredientsList, dishPrice));","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" return new Menu(menuDishList);","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" * Decodes an array of strings representing ingredient data into a list of Ingredient objects.","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredientsStringArray An array of strings containing encoded ingredient data.","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" * @return An ArrayList of Ingredient objects containing the decoded ingredient information.","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" private static ArrayList\u003cIngredient\u003e decodeIngredientData(String[] ingredientsStringArray) {","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" for(String ingredientString : ingredientsStringArray) {","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" String[] array \u003d ingredientString.split(\" \");","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":" String name \u003d array[0].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" int qty \u003d Integer.parseInt(array[1]);","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":" String unit \u003d array[2].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" ingredientList.add(new Ingredient(name, qty, unit));","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" return ingredientList;","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":" * Decodes raw string from pantry stock data file and create ingredient object from the data","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" * @param encodedPantryStock raw string from pantry stock data file","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" * @return a new pantry object with data from the pantry stock data file","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":" public static Pantry decodePantryStockData(ArrayList\u003cString\u003e encodedPantryStock) {","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":" if (encodedPantryStock.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":" return new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"ziyi105"},"content":" for (String encodedData : encodedPantryStock) {","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":" String[] decodedData \u003d encodedData.split(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":" if (!isValidPantryStockFormat(decodedData)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.ERROR_IN_PANTRY_STOCK_DATA);","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"ziyi105"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"ziyi105"},"content":" Ingredient ingredient \u003d new Ingredient(decodedData[0],","lastModifiedDate":"2023-10-28"},{"lineNumber":83,"author":{"gitId":"ziyi105"},"content":" Integer.parseInt(decodedData[1].trim()), decodedData[2]);","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ziyi105"},"content":" pantryStock.add(ingredient);","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":" return new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"ziyi105"},"content":" * Checks whether the pantry stock is in the format of ingredient name | quantity (int) | unit","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"ziyi105"},"content":" * @param decodedPantryStock string array of the raw data string from pantry stock data file","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":" * split with \"|\"","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"ziyi105"},"content":" * @return true if the format is correct, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"ziyi105"},"content":" private static boolean isValidPantryStockFormat(String[] decodedPantryStock) {","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"ziyi105"},"content":" if (decodedPantryStock.length !\u003d 3) {","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.ERROR_IN_PANTRY_STOCK_DATA);","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"ziyi105"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"ziyi105"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-10-28"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":" Integer.parseInt(decodedPantryStock[1].trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.ERROR_IN_PANTRY_STOCK_DATA);","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" return false;","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"ziyi105"},"content":" return true;","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":110,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"NaychiMin"},"content":" * Decodes a list of order data and constructs a Sales object using an array of OrderList objects.","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"NaychiMin"},"content":" * @param textLines List of order strings in the format \"dishName|quantity|totalOrderCost\".","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"NaychiMin"},"content":" * @param menu Menu instance to retrieve Dish objects based on dishName.","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":" * @return Sales object containing OrderList objects decoded from the provided strings.","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"NaychiMin"},"content":" public static Sales decodeSales(ArrayList\u003cString\u003e textLines, Menu menu) {","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrderList\u003e orderLists \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"NaychiMin"},"content":" if(textLines.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"NaychiMin"},"content":" return new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"NaychiMin"},"content":" //for each \u0027order\u0027 in text file","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"NaychiMin"},"content":" for (String line : textLines) {","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"NaychiMin"},"content":" String[] orderData \u003d line.split(DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"NaychiMin"},"content":" int day \u003d Integer.parseInt(orderData[0].trim()) - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"NaychiMin"},"content":" String dishName \u003d orderData[1].trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"NaychiMin"},"content":" int quantity \u003d Integer.parseInt(orderData[2].trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":" float totalOrderCost \u003d Float.parseFloat(orderData[3].trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":" boolean isComplete \u003d \"true\".equals(orderData[4].trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"NaychiMin"},"content":" Order orderedDish \u003d new Order(menu.getDishFromName(dishName), quantity, totalOrderCost, isComplete);","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"NaychiMin"},"content":" //increase size of orderLists if needed","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"NaychiMin"},"content":" //this can be used in the event that the text file\u0027s first order is not day 0","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"NaychiMin"},"content":" while (orderLists.size() \u003c\u003d day) {","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":" orderLists.add(new OrderList());","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":140,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"NaychiMin"},"content":" orderLists.get(day).addOrder(orderedDish);","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":" return new Sales(orderLists);","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"NaychiMin":50,"ziyi105":56,"ShaniceTang":39}},{"path":"src/main/java/seedu/cafectrl/storage/Encoder.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":" * The Encoder class provides methods to encode various data structures into string representations to","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" * be written into their respective text files.","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" * It includes methods to encode a Menu, Pantry stock, and OrderList,","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" * making the data suitable for saving to a file.","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"public class Encoder {","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" private static final String DIVIDER \u003d \" | \";","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" * Encodes a Menu object into a list of strings representing its contents, suitable for saving to a file.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" * @param menu The Menu object to encode into a string representation.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" * @return An ArrayList of strings, where each string represents a Dish in the Menu.","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" public static ArrayList\u003cString\u003e encodeMenu(Menu menu) {","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cString\u003e menuStringList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cDish\u003e menuDishList \u003d menu.getMenuItemsList();","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" for(Dish dish : menuDishList) {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" StringBuilder dishString \u003d new StringBuilder();","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(dish.getName() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(dish.getPrice() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(encodeIngredientList(dish.getIngredients()));","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(System.lineSeparator());","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" menuStringList.add(String.valueOf(dishString));","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" return menuStringList;","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" * Encodes a list of ingredients into a StringBuilder for inclusion in the menu encoding.","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredientList The list of Ingredient objects to encode.","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" * @return A StringBuilder containing the encoded representation of the ingredient list.","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" private static StringBuilder encodeIngredientList(ArrayList\u003cIngredient\u003e ingredientList) {","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" StringBuilder ingredientListString \u003d new StringBuilder();","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" for(Ingredient ingredient : ingredientList) {","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" ingredientListString.append(ingredient.getName() + \" \");","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" ingredientListString.append(ingredient.getQty() + \" \");","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" ingredientListString.append(ingredient.getUnit() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" return ingredientListString;","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ziyi105"},"content":" * Encodes the pantry stock into format ingredient name | quantity | unit","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ziyi105"},"content":" * @param pantry the pantry from current session","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ziyi105"},"content":" * @return an arrayList of string of ecoded pantry stock","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":" public static ArrayList\u003cString\u003e encodePantryStock(Pantry pantry) {","lastModifiedDate":"2023-10-28"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":" // Convert pantry stock to a list of String","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e pantryStockInString \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d pantry.getPantryStock();","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" for (Ingredient ingredient : pantryStock) {","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" StringBuilder encodedIngredient \u003d new StringBuilder();","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(ingredient.getName());","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(ingredient.getQty());","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(ingredient.getUnit());","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ziyi105"},"content":" pantryStockInString.add(encodedIngredient.toString());","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":" return pantryStockInString;","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" * Encodes a Sales object into a list of strings for storage.","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" * Each string represents an order, including day, dish name, quantity, and total cost.","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" * @param sales The Sales object to be encoded.","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" * @return An ArrayList of strings representing the encoded sales data.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" public static ArrayList\u003cString\u003e encodeSales(Sales sales) {","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cString\u003e encodedList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrderList\u003e orderLists \u003d sales.getOrderLists();","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" for (int day \u003d 0; day \u003c orderLists.size(); day++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" //get orderList for each day from list of sales","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" OrderList orderList \u003d sales.getOrderList(day);","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" //get order from each orderList obtained","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" for (Order order : orderList.getOrderList()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" StringBuilder orderString \u003d new StringBuilder();","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" //day of each orderList is index + 1","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" orderString.append((day + 1) + DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.getDishName() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.getQuantity() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.calculateTotalOrderCost() + DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.getIsComplete());","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":" orderString.append(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":" encodedList.add(String.valueOf(orderString));","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" return encodedList;","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"NaychiMin":35,"ziyi105":31,"ShaniceTang":45}},{"path":"src/main/java/seedu/cafectrl/storage/FileManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import java.io.File;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import java.nio.file.Files;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import java.nio.file.Path;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import java.nio.file.Paths;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":"//@@author DextheChik3n","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":" * Manage everything related to file such as writing, reading, opening and creating file","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"public class FileManager {","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" public FileManager(Ui ui) {","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" * Reads the text file from the specified file path and stores each line in an ArrayList.","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" * @return ArrayList that consists of every text line in each element","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" * @throws FileNotFoundException if text file at the specified file path does not exist","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":" public ArrayList\u003cString\u003e readTextFile(String filePath) throws FileNotFoundException {","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" String userWorkingDirectory \u003d System.getProperty(\"user.dir\");","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":" Path dataFilePath \u003d Paths.get(userWorkingDirectory, filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" File textFile \u003d new File(String.valueOf(dataFilePath));","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cString\u003e textLines \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" Scanner s \u003d new Scanner(textFile);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":" textLines.add(s.nextLine());","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":" s.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" return textLines;","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" * Checks if the text file and folder exists in the user\u0027s system and creates them (if needed)","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath the specified path location of the file","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":" public void checkFileExists(String filePath) throws IOException {","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"DextheChik3n"},"content":" String userWorkingDirectory \u003d System.getProperty(\"user.dir\");","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" Path dataFilePath \u003d Paths.get(userWorkingDirectory, filePath);","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":" Path dataFolderPath \u003d dataFilePath.getParent();","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" File textFile \u003d new File(String.valueOf(dataFilePath));","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"DextheChik3n"},"content":" File folder \u003d new File(String.valueOf(dataFolderPath));","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":" //Check if data folder exists","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"DextheChik3n"},"content":" if (!Files.exists(dataFolderPath)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":62,"author":{"gitId":"DextheChik3n"},"content":" folder.mkdir();","lastModifiedDate":"2023-10-28"},{"lineNumber":63,"author":{"gitId":"DextheChik3n"},"content":" ui.showToUser(ErrorMessages.DATA_FOLDER_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":65,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" //Check if the file at the specified file path exists","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" if (!Files.exists(dataFilePath)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" textFile.createNewFile();","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":72,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":73,"author":{"gitId":"DextheChik3n"},"content":" * Writes a list of texts to the text file at the specified file path.","lastModifiedDate":"2023-10-28"},{"lineNumber":74,"author":{"gitId":"DextheChik3n"},"content":" * Will overwrite all text in text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":75,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":76,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath file path of the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":77,"author":{"gitId":"DextheChik3n"},"content":" * @param listOfTextToAdd text to be written to the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"DextheChik3n"},"content":" * @throws IOException If I/O operations are interrupted.","lastModifiedDate":"2023-10-28"},{"lineNumber":79,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":80,"author":{"gitId":"DextheChik3n"},"content":" public void overwriteFile(String filePath, ArrayList\u003cString\u003e listOfTextToAdd) throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"DextheChik3n"},"content":" checkFileExists(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"DextheChik3n"},"content":" FileWriter fw \u003d new FileWriter(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"DextheChik3n"},"content":" for (String line : listOfTextToAdd) {","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"DextheChik3n"},"content":" fw.write(line);","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"DextheChik3n"},"content":" fw.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"DextheChik3n"},"content":" * Writes text to the text file at the specified file path.","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"DextheChik3n"},"content":" * Will overwrite all text in text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath file path of the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"DextheChik3n"},"content":" * @param textToAdd text to be written to the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"DextheChik3n"},"content":" * @throws IOException If I/O operations are interrupted.","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":97,"author":{"gitId":"DextheChik3n"},"content":" public void overwriteFile(String filePath, String textToAdd) throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"DextheChik3n"},"content":" checkFileExists(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"DextheChik3n"},"content":" FileWriter fw \u003d new FileWriter(filePath);","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"DextheChik3n"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-28"},{"lineNumber":101,"author":{"gitId":"DextheChik3n"},"content":" fw.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":102,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":103,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":105,"author":{"gitId":"DextheChik3n"},"content":" * Appends text to the text file at the specified file path.","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"DextheChik3n"},"content":" * Will add text to text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":107,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath file path of the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"DextheChik3n"},"content":" * @param textToAdd text to be added to the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":110,"author":{"gitId":"DextheChik3n"},"content":" * @throws IOException If I/O operations are interrupted.","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":112,"author":{"gitId":"DextheChik3n"},"content":" public void appendToFile(String filePath, String textToAdd) throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":113,"author":{"gitId":"DextheChik3n"},"content":" checkFileExists(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"DextheChik3n"},"content":" FileWriter fw \u003d new FileWriter(filePath, true);","lastModifiedDate":"2023-10-28"},{"lineNumber":115,"author":{"gitId":"DextheChik3n"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-28"},{"lineNumber":116,"author":{"gitId":"DextheChik3n"},"content":" fw.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":117,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":118,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"DextheChik3n":104,"ziyi105":12,"ShaniceTang":2}},{"path":"src/main/java/seedu/cafectrl/storage/FilePath.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"public class FilePath {","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" public static final String MENU_FILE_PATH \u003d \"data/menu.txt\";","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" public static final String PANTRY_STOCK_FILE_PATH \u003d \"data/pantry_stock.txt\";","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" public static final String ORDERS_FILE_PATH \u003d \"data/orders.txt\";","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ziyi105":8}},{"path":"src/main/java/seedu/cafectrl/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" * Handles loading and saving data for menu, orderList, pantryStock","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"public class Storage {","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" protected FileManager fileManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" protected Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" public Storage (Ui ui) {","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" this.fileManager \u003d new FileManager(ui);","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" * Loads menu data from a text file, decodes it, and returns it as a Menu object.","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" * @return A Menu object containing data from the file.","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" public Menu loadMenu() {","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cString\u003e encodedMenu \u003d fileManager.readTextFile(FilePath.MENU_FILE_PATH);","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" return Decoder.decodeMenuData(encodedMenu);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(ErrorMessages.MENU_FILE_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" return new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" * Encodes the provided menu data and writes it to a text file.","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" * @param menu The Menu object to be saved to the file.","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" * @throws IOException if the file is not found in the specified file path.","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" private void saveMenu(Menu menu) throws IOException {","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" fileManager.overwriteFile(FilePath.MENU_FILE_PATH, Encoder.encodeMenu(menu));","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":" * Read and decode pantryStock data from text file and pass it to the menu","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":" * @return pantryStock with data from the file","lastModifiedDate":"2023-10-28"},{"lineNumber":56,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"ziyi105"},"content":" public Pantry loadPantryStock() {","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e encodedPantryStock \u003d this.fileManager.readTextFile(FilePath.PANTRY_STOCK_FILE_PATH);","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"ziyi105"},"content":" return Decoder.decodePantryStockData(encodedPantryStock);","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"ziyi105"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.PANTRY_FILE_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ziyi105"},"content":" return new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" * Encode and write the data from PantryStock to the text file","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" * @param pantry pantry from current session","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":" * @throws IOException if the file is not found in the specified file path","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":" private void savePantryStock(Pantry pantry) throws IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":" this.fileManager.overwriteFile(FilePath.PANTRY_STOCK_FILE_PATH, Encoder.encodePantryStock(pantry));","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" * Loads order lists from a text file, decodes it, and returns it as a Sales object.","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":" * @return An OrderList object containing data from the file.","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" public Sales loadOrderList(Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cString\u003e encodedOrderList \u003d fileManager.readTextFile(FilePath.ORDERS_FILE_PATH);","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" return Decoder.decodeSales(encodedOrderList, menu);","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(ErrorMessages.ORDER_LIST_FILE_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" return new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" * Encodes the provided OrderList data from Sales object and writes it to a text file","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" * @param sales The Sales object containing the order to be saved to the file.","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" * @throws IOException if the file is not found in the specified file path.","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" private void saveOrderList(Sales sales) throws IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" this.fileManager.overwriteFile(FilePath.ORDERS_FILE_PATH, Encoder.encodeSales(sales));","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":" * Encode and write the data from menu, orderList and pantry to the respective text files","lastModifiedDate":"2023-10-28"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" * @param menu menu from current session","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"ziyi105"},"content":" * @param sales sale object from current session","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":" * @param pantry pantry from current session","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"ziyi105"},"content":" public void saveAll(Menu menu, Sales sales, Pantry pantry) {","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"ziyi105"},"content":" saveMenu(menu);","lastModifiedDate":"2023-10-28"},{"lineNumber":112,"author":{"gitId":"ziyi105"},"content":" saveOrderList(sales);","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":" saveMenu(menu);","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"ziyi105"},"content":" savePantryStock(pantry);","lastModifiedDate":"2023-10-28"},{"lineNumber":115,"author":{"gitId":"ziyi105"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":119,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":120,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"NaychiMin":26,"DextheChik3n":8,"ziyi105":59,"ShaniceTang":27}},{"path":"src/main/java/seedu/cafectrl/ui/ErrorMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.ui;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"public class ErrorMessages {","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":" /** Error messages */","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_ADD_DISH_FORMAT_MESSAGE \u003d \"Error: Incorrect format for the add command.\\n\";","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":" public static final String NULL_NAME_DETECTED_MESSAGE \u003d \"Error: Null dish name detected\";","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_PRICE_MESSAGE \u003d \"Error: Price value entered is too big!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" public static final String INVALID_DISH_NAME_LENGTH_MESSAGE \u003d \"Error: Your dish name length is too long!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" public static final String INVALID_INGREDIENT_NAME_LENGTH_MESSAGE \u003d \"Error: Your dish name length is too long!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_EDIT_PRICE \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" + \"for edit price command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_LIST_INGREDIENTS \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" + \"for list ingredients command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_DELETE \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \"for delete command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_BUY_INGREDIENT \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" + \"for buy ingredient command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" public static final String WRONG_ARGUMENT_TYPE_FOR_EDIT_PRICE \u003d \"Error: Invalid dish index. \\n \"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" + \"Make sure dish index is \"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" + \"of type int and price is of type float!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" public static final String UNKNOWN_COMMAND_MESSAGE \u003d \"Error: Unknown command. \"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" + \"Type \u0027help\u0027 to view the accepted list of commands\";","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_DISH_INDEX \u003d \"Error: Invalid dish index.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_ARGUMENT_FOR_BUY_INGREDIENT \u003d \"Error: Invalid arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" + \"for buy ingredient command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_ADD_ORDER_FORMAT_MESSAGE \u003d \"Error: Incorrect format for the add order command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" public static final String DATA_FOLDER_NOT_FOUND_MESSAGE \u003d \"Data Folder was not found!\\nIt\u0027s ok... \"","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":" + \"a new data folder has been created.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":" public static final String DISH_NOT_FOUND \u003d \"I\u0027m sorry, but it appears that dish is so exclusive \"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" + \"it hasn\u0027t even made it to our menu yet!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" public static final String ERROR_IN_PANTRY_STOCK_DATA \u003d \"Error in pantry stock data file! Skipping this \"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" + \"particular ingredient!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" public static final String UNIT_NOT_MATCHING \u003d \"Sorry, you have used a different unit for this ingredient!\";","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":" public static final String MENU_FILE_NOT_FOUND_MESSAGE \u003d \"Menu data was not found!\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" + \"No worries, new menu has been created\";","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" public static final String PANTRY_FILE_NOT_FOUND_MESSAGE \u003d \"Pantry stock data was not found!\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":" + \"No worries, new pantry has been created\";","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" public static final String ORDER_LIST_FILE_NOT_FOUND_MESSAGE \u003d \"Order list data was not found!\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":" + \"No worries, new order list has been created\";","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":" public static final String INVALID_SHOW_SALE_DAY_FORMAT_MESSAGE \u003d \"Error: Incorrect format for the show_sale \"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"NaychiMin"},"content":" + \"command.\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":" public static final String INVALID_DAY_FORMAT \u003d \"Sorry, please enter a valid integer for the \u0027day\u0027 field!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"NaychiMin":5,"DextheChik3n":9,"ziyi105":28,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/ui/Messages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"public class Messages {","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":" /** Greeting messages */","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" public static final String LINE_STRING \u003d \"-----------------------------------------------------\";","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":" public static final String WELCOME_MESSAGE \u003d \"Hello! Welcome to CafeCTRL!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":" public static final String GOODBYE_MESSAGE \u003d \"Goodbye \u003c3 Have a great day ahead!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":" /** Messages for edit price command */","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" public static final String PRICE_MODIFIED_MESSAGE \u003d \"Price modified for the following dish: \";","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" /** Messages for list menu command */","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" public static final String LIST_MENU_MESSAGE \u003d \"| Ah, behold, the grand menu of delights! |\";","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_EMPTY_MESSAGE \u003d \"It seems our menu is currently taking a break. \"","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Let\u0027s give it a wake-up call and fill \u0027er up with delectable delights, shall we?\";","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_END_CAP \u003d \"+-----------------------------------------+\";","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_CORNER \u003d \"+--------------------------+--------------+\";","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_TITLE \u003d \"| Dish Name | Price |\";","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" /** Messages for add dish command */","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" public static final String ADD_DISH_MESSAGE \u003d \"You have added the following dish...\";","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" public static final String REPEATED_DISH_MESSAGE \u003d \"Sorry, this dish name already exists.\";","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" /** Messages for view stock command */","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" public static final String VIEW_STOCK \u003d \"You have the following ingredients in pantry:\"","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" + \"\\nIngredients\\t\\tQty\";","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" /** Messages for help command */","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" public static final String LIST_OF_COMMANDS \u003d \"These are all the commands I recognise: \";","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" public static final String INSTRUCTION_ON_COMMAND_FORMAT \u003d \"- Words in UPPER_CASE are \"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" + \"the parameters to be supplied by the user.\\n\"","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" + \" e.g. in add name/NAME, NAME is a parameter that can be used as add name/Chicken.\\n\"","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" + \"- Parameters in [] are optional.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" /** Messages for order command */","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" public static final String CHEF_MESSAGE \u003d \"I\u0027m busy crafting your selected dish \"","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" + \"in the virtual kitchen of your dreams. Bon appétit!\";","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" public static final String PREVIOUS_DAY_TIME_TRAVEL \u003d \"Whoa there, time traveler! \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" \"Unfortunately, the DeLorean can\u0027t take us back to the previous day because it\u0027s already Day 0, \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" \"and there\u0027s no rewind button in this space-time continuum!\";","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" public static final String PREVIOUS_DAY_COMMAND_MESSAGE \u003d \"Sure thing! \"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" + \"Let\u0027s rev up the virtual DeLorean and take a spin to the previous day. \"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" + \"Buckle up, it\u0027s time to hit that rewind button!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" public static final String NEXT_DAY_COMMAND_MESSAGE \u003d \"Prepare for liftoff! \"","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" + \"We\u0027re about to fast-forward to the next day. \"","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" + \"Hold onto your hats; here we go!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" public static final String INITIALISE_STORAGE_MESSAGE \u003d \"...Downloading data...\";","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":" public static final String AVAILABLE_DISHES \u003d \"Listed below are the availability of the dishes for the next order!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":" public static final String COMPLETE_ORDER \u003d \"Order is ready!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" public static final String INCOMPLETE_ORDER \u003d \"Please restock ingredients before preparing the order :) \";","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"NaychiMin":3,"DextheChik3n":5,"Cazh1":17,"ziyi105":13,"ShaniceTang":15}},{"path":"src/main/java/seedu/cafectrl/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.AddDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.AddOrderCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.BuyIngredientCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.DeleteDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.EditPriceCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ExitCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.HelpCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListIngredientCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListMenuCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.NextDayCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.PreviousDayCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ViewTotalStockCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":"public class Ui {","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" public static final int OFFSET_LIST_INDEX \u003d 1;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":" private final Scanner scanner;","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" * Constructs a UI instance with a Scanner for user input.","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" public Ui() {","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" public void printLine() {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" showToUser(Messages.LINE_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":" public String receiveUserInput() {","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" System.out.print(\"\u003e \");","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"NaychiMin"},"content":" return scanner.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":" public void showWelcome() {","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" showToUser(Messages.WELCOME_MESSAGE);","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"NaychiMin"},"content":" public void showGoodbye() {","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" showToUser(Messages.GOODBYE_MESSAGE);","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":" * Prints out the quantity of each ingredient needed for the","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" * dish that the user selects.","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"NaychiMin"},"content":" * @param selectedDish Dish for ingredients to be listed out.","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" public void printIngredients(Dish selectedDish) {","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" String ingredientsString \u003d selectedDish.getName() + \" Ingredients: \\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" for (Ingredient ingredient : selectedDish.getIngredients()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" ingredientsString +\u003d ingredient.toString() + \"\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" showToUser(ingredientsString.trim());","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" public void printAddDishMessage(Dish dish) {","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" String dishNameString \u003d \"Dish Name: \" + dish.getName();","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"DextheChik3n"},"content":" float dishPrice \u003d dish.getPrice();","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":" String dishPriceString \u003d \"Dish Price: $\" + dollarValue.format(dishPrice);","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" showToUser(Messages.ADD_DISH_MESSAGE,","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"DextheChik3n"},"content":" dishNameString,","lastModifiedDate":"2023-10-17"},{"lineNumber":74,"author":{"gitId":"DextheChik3n"},"content":" dishPriceString);","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"DextheChik3n"},"content":" printIngredients(dish);","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":" * Shows delete message to user","lastModifiedDate":"2023-10-17"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":" * @param selectedDish Dish to be deleted","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":" public void printDeleteMessage(Dish selectedDish) {","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":" showToUser(\"Okay! \" + selectedDish.getName() + \" is deleted! :)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":86,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":88,"author":{"gitId":"ShaniceTang"},"content":" public void printBuyIngredientHeader() {","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"ShaniceTang"},"content":" showToUser(\"Added to stock:\");","lastModifiedDate":"2023-10-25"},{"lineNumber":90,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":93,"author":{"gitId":"DextheChik3n"},"content":" * Shows messages(s) to the user","lastModifiedDate":"2023-10-17"},{"lineNumber":94,"author":{"gitId":"DextheChik3n"},"content":" * @param message string(s) of messages to print","lastModifiedDate":"2023-10-17"},{"lineNumber":95,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":96,"author":{"gitId":"DextheChik3n"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"DextheChik3n"},"content":" for (String m: message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"DextheChik3n"},"content":" System.out.println(m);","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"Cazh1"},"content":" * Shows menu to user is table format","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"Cazh1"},"content":" * @param dishName","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"Cazh1"},"content":" * @param dishPrice","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":" public void formatListMenu(String dishName, String dishPrice) {","lastModifiedDate":"2023-10-22"},{"lineNumber":108,"author":{"gitId":"Cazh1"},"content":" String leftAlignFormat \u003d \"| %-24s | %-12s |%n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"Cazh1"},"content":" System.out.format(leftAlignFormat, dishName, dishPrice);","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"Cazh1"},"content":" //+-----------------+------+","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":114,"author":{"gitId":"ziyi105"},"content":" * show edit price message to user","lastModifiedDate":"2023-10-17"},{"lineNumber":115,"author":{"gitId":"ziyi105"},"content":" * @param menuItem menuItem that has been modified","lastModifiedDate":"2023-10-17"},{"lineNumber":116,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":117,"author":{"gitId":"ziyi105"},"content":" public void showEditPriceMessage(String menuItem) {","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":" this.showToUser(Messages.PRICE_MODIFIED_MESSAGE, menuItem);","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":120,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"ziyi105"},"content":" public void showHelp() {","lastModifiedDate":"2023-10-22"},{"lineNumber":122,"author":{"gitId":"ShaniceTang"},"content":" showToUserWithSpaceBetweenLines(Messages.LIST_OF_COMMANDS,","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"ShaniceTang"},"content":" Messages.INSTRUCTION_ON_COMMAND_FORMAT,","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"ziyi105"},"content":" AddDishCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"ziyi105"},"content":" AddOrderCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"ziyi105"},"content":" BuyIngredientCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"ziyi105"},"content":" DeleteDishCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"ziyi105"},"content":" EditPriceCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"ziyi105"},"content":" ExitCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"ziyi105"},"content":" HelpCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"ziyi105"},"content":" ListIngredientCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ziyi105"},"content":" ListMenuCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"ziyi105"},"content":" NextDayCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"ziyi105"},"content":" PreviousDayCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"ziyi105"},"content":" ViewTotalStockCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":138,"author":{"gitId":"ziyi105"},"content":" public void showToUserWithSpaceBetweenLines(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":139,"author":{"gitId":"ziyi105"},"content":" for (String m: message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":140,"author":{"gitId":"ziyi105"},"content":" System.out.println(m + \"\\n\");","lastModifiedDate":"2023-10-22"},{"lineNumber":141,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":" public void showDishAvailability(int numberOfDishes){","lastModifiedDate":"2023-10-24"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":" showToUser(\"Available Dishes: \" + numberOfDishes);","lastModifiedDate":"2023-10-24"},{"lineNumber":146,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":147,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":" public void showNeededRestock(String ingredientName, int currentQuantity, String unit, String neededIngredient){","lastModifiedDate":"2023-10-24"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":" showToUser(\"Please Restock: \" + ingredientName","lastModifiedDate":"2023-10-24"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":" , \"Current \" + ingredientName + \": \" + currentQuantity + unit","lastModifiedDate":"2023-10-24"},{"lineNumber":151,"author":{"gitId":"NaychiMin"},"content":" , \"Needed \" + ingredientName + \": \" + neededIngredient);","lastModifiedDate":"2023-10-24"},{"lineNumber":152,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":" * Shows the top portion of the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":" public void showMenuTop() {","lastModifiedDate":"2023-10-27"},{"lineNumber":158,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.MENU_END_CAP, Messages.LIST_MENU_MESSAGE,","lastModifiedDate":"2023-10-27"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":" Messages.MENU_CORNER, Messages.MENU_TITLE, Messages.MENU_CORNER);","lastModifiedDate":"2023-10-27"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":" * Shows the bottom portion of the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":164,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":165,"author":{"gitId":"Cazh1"},"content":" public void showMenuBottom() {","lastModifiedDate":"2023-10-27"},{"lineNumber":166,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.MENU_END_CAP);","lastModifiedDate":"2023-10-27"},{"lineNumber":167,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":168,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":169,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":170,"author":{"gitId":"Cazh1"},"content":" * Shows the message for empty menu","lastModifiedDate":"2023-10-27"},{"lineNumber":171,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":172,"author":{"gitId":"Cazh1"},"content":" public void showEmptyMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":173,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.MENU_EMPTY_MESSAGE);","lastModifiedDate":"2023-10-27"},{"lineNumber":174,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":175,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":176,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":177,"author":{"gitId":"Cazh1"},"content":" * Shows the dishes in the menu, formatted in the proper format","lastModifiedDate":"2023-10-27"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":179,"author":{"gitId":"Cazh1"},"content":" * @param indexNum The index number of the dish in the menu print","lastModifiedDate":"2023-10-27"},{"lineNumber":180,"author":{"gitId":"Cazh1"},"content":" * @param dishName The name of the dish in the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":181,"author":{"gitId":"Cazh1"},"content":" * @param dishPrice The price of the dish in the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":182,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":183,"author":{"gitId":"Cazh1"},"content":" public void showMenuDish(String indexNum, String dishName, String dishPrice) {","lastModifiedDate":"2023-10-27"},{"lineNumber":184,"author":{"gitId":"Cazh1"},"content":" formatListMenu(indexNum + \". \" + dishName,\" $\" + dishPrice);","lastModifiedDate":"2023-10-27"},{"lineNumber":185,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":186,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":187,"author":{"gitId":"Cazh1"},"content":" public void showChefMessage() {","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.CHEF_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":194,"author":{"gitId":"Cazh1"},"content":" * Shows the total cost in the order list, formatted in the proper format","lastModifiedDate":"2023-10-27"},{"lineNumber":195,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":196,"author":{"gitId":"Cazh1"},"content":" * @param dollarCost The price of the orders","lastModifiedDate":"2023-10-27"},{"lineNumber":197,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":198,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-10-27"},{"lineNumber":199,"author":{"gitId":"NaychiMin"},"content":" showToUser(\"Total order cost: $\" + dollarCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":201,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"NaychiMin"},"content":" public void showOrderStatus(String orderStatus, String totalCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"NaychiMin"},"content":" printLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"NaychiMin"},"content":" showToUser(orderStatus);","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"NaychiMin"},"content":" showTotalCost(totalCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"NaychiMin"},"content":" printLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"NaychiMin"},"content":" showDishAvailabilityMessage();","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"NaychiMin"},"content":" public void showDishAvailabilityMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"NaychiMin"},"content":" showToUser(Messages.AVAILABLE_DISHES);","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"Cazh1"},"content":" public void showPreviousDay() {","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.PREVIOUS_DAY_COMMAND_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":216,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":217,"author":{"gitId":"Cazh1"},"content":" public void showNextDay() {","lastModifiedDate":"2023-10-30"},{"lineNumber":218,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.NEXT_DAY_COMMAND_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":219,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":220,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"NaychiMin":65,"DextheChik3n":30,"Cazh1":63,"ziyi105":44,"ShaniceTang":18}},{"path":"src/test/java/seedu/cafectrl/UiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"/**","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":" * Junit test for Ui.java","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"public class UiTest {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"DextheChik3n":1,"ShaniceTang":7}},{"path":"src/test/java/seedu/cafectrl/command/AddDishCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"class AddDishCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" void execute_oneDishAdded_expectDishInMenu() {","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" //creating a dish","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" ingredients.add(new Ingredient(\"chicken\", 100, \"g\"));","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", ingredients, (float) 1.00);","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" AddDishCommand addDishCommand \u003d new AddDishCommand(dish, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" addDishCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(1, menu.getMenuItemsList().size());","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":25,"Cazh1":3,"ShaniceTang":1}},{"path":"src/test/java/seedu/cafectrl/command/AddOrderCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"class AddOrderCommandTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public void execute_addOneOrder_expectOneOrder() {","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"chicken\", 100, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients2 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"chicken\", 200, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenRice \u003d new Dish(\"Chicken Rice\", ingredients, 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenCurry \u003d new Dish(\"Chicken Curry\", ingredients2, 4.30F);","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenRice);","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenCurry);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" assertEquals(2, menu.getSize());","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" Order orderChickenRice \u003d new Order(dishChickenRice, 2);","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d (\"Total orderList cost: $\" + dollarCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"chicken\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" OrderList orderList \u003d new OrderList();","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" Command addOrderCommand \u003d new AddOrderCommand(orderChickenRice, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" addOrderCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d Messages.CHEF_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" + \"Order is ready!\"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" + \"Total orderList cost: $5.00\"","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" + Messages.AVAILABLE_DISHES","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Rice\"","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 8\"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Curry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 4\";","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":" public void execute_addTwoOrder_expectTwoOrder() {","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"chicken\", 100, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients2 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"chicken\", 200, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenRice \u003d new Dish(\"Chicken Rice\", ingredients, 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenCurry \u003d new Dish(\"Chicken Curry\", ingredients2, 4.30F);","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenRice);","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenCurry);","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"Cazh1"},"content":" assertEquals(2, menu.getSize());","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"Cazh1"},"content":" Order orderChickenRice \u003d new Order(dishChickenRice, 2);","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":" Order orderChickenCurry \u003d new Order(dishChickenCurry, 3);","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d (\"Total orderList cost: $\" + dollarCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"chicken\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"Cazh1"},"content":" Ui uiPrintNothing \u003d new Ui() {","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"Cazh1"},"content":" OrderList orderList \u003d new OrderList();","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"Cazh1"},"content":" Command addOrderCommand \u003d new AddOrderCommand(orderChickenRice, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"Cazh1"},"content":" addOrderCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"Cazh1"},"content":" Command addOrderCommand2 \u003d new AddOrderCommand(orderChickenCurry, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"Cazh1"},"content":" addOrderCommand2.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"Cazh1"},"content":" String expectedOutputForFirstOrder \u003d Messages.CHEF_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"Cazh1"},"content":" + \"Order is ready!\"","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"Cazh1"},"content":" + \"Total orderList cost: $5.00\"","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"Cazh1"},"content":" + Messages.AVAILABLE_DISHES","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Rice\"","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 8\"","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Curry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 4\";","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":" String expectedOutputForSecondOrder \u003d Messages.CHEF_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":" + \"Order is ready!\"","lastModifiedDate":"2023-11-01"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" + \"Total orderList cost: $12.90\"","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":" + Messages.AVAILABLE_DISHES","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Rice\"","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 2\"","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Curry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 1\";","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d expectedOutputForFirstOrder + expectedOutputForSecondOrder;","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":171,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"Cazh1"},"content":" private static String convertArrayToString(String[] message, String delimiter) {","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"Cazh1"},"content":" StringBuilder sb \u003d new StringBuilder();","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"Cazh1"},"content":" for (String str : message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"Cazh1"},"content":" sb.append(str.toString()).append(delimiter);","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"Cazh1"},"content":" return sb.substring(0, sb.length() - 1);","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"Cazh1":181}},{"path":"src/test/java/seedu/cafectrl/command/BuyIngredientCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"public class BuyIngredientCommandTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" void execute_validInput_returnCorrectOutput() {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"milk\", 100, \"ml\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" ByteArrayOutputStream baos \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" PrintStream consoleStream \u003d new PrintStream(baos);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(consoleStream);","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" BuyIngredientCommand buyIngredientCommand \u003d new BuyIngredientCommand(ingredientsList, ui, pantry);","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" buyIngredientCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" String actualOutput \u003d baos.toString().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Added to stock: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: chicken\\t\\tQty: 500g\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: rice\\t\\tQty: 1000g\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: milk\\t\\tQty: 100ml\";","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" void execute_validInputWithExistingIngredient_returnCorrectOutput() {","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui, ingredientsList);","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" ByteArrayOutputStream baos \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" PrintStream consoleStream \u003d new PrintStream(baos);","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(consoleStream);","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" BuyIngredientCommand buyIngredientCommand \u003d new BuyIngredientCommand(ingredientsList, ui, pantry);","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" buyIngredientCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":" String actualOutput \u003d baos.toString().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Added to stock: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: chicken\\t\\tQty: 1000g\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":73}},{"path":"src/test/java/seedu/cafectrl/command/CommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"class CommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":5}},{"path":"src/test/java/seedu/cafectrl/command/DeleteDishCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"class DeleteDishCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" void execute_validInput() {","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Rice\", 2.50F));","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Curry\", 4.30F));","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Nasi Lemak\", 5.60F));","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" };","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" int testIndex \u003d 2;","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" DeleteDishCommand deleteDishCommand \u003d new DeleteDishCommand(testIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" deleteDishCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" int actualOutputIndex \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Okay! Chicken Curry is deleted! :)\";","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput, actualOutput.get(actualOutputIndex));","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" void execute_invalidInput_throwIndexOutOfBoundsException() {","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Rice\", 2.50F));","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Curry\", 4.30F));","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Nasi Lemak\", 5.60F));","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" int testIndex \u003d 5;","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" DeleteDishCommand deleteDishCommand \u003d new DeleteDishCommand(testIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" assertThrows(IndexOutOfBoundsException.class, () -\u003e deleteDishCommand.execute());","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":1,"Cazh1":8,"ShaniceTang":44}},{"path":"src/test/java/seedu/cafectrl/command/EditPriceCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"class EditPriceCommandTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" void execute_validInput_editPrice() {","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" int testDishIndex \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" float testNewPrice \u003d 3;","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" Command editPriceCommand \u003d new EditPriceCommand(testDishIndex, testNewPrice, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" editPriceCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" int firstLine \u003d 0;","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":" int secondLine \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":" String expectedOutputFirstLine \u003d Messages.PRICE_MODIFIED_MESSAGE;","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":" String expectedOutputSecondLine \u003d testDish.toString();","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" assertEquals(expectedOutputFirstLine, actualOutput.get(firstLine));","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":" assertEquals(expectedOutputSecondLine, actualOutput.get(secondLine));","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"Cazh1":2,"ziyi105":40}},{"path":"src/test/java/seedu/cafectrl/command/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"class HelpCommandTest {","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" void execute_validInput_editPrice() {","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutputs \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" actualOutputs.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" public void showToUserWithSpaceBetweenLines(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":" actualOutputs.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" HelpCommand helpCommand \u003d new HelpCommand(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" helpCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e expectedOutputs \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(Messages.LINE_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(Messages.LIST_OF_COMMANDS);","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(Messages.INSTRUCTION_ON_COMMAND_FORMAT);","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(AddDishCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(AddOrderCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(BuyIngredientCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(DeleteDishCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(EditPriceCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ExitCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(HelpCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ListIngredientCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ListMenuCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(NextDayCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(PreviousDayCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ViewTotalStockCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" for (int i \u003d 0; i \u003c expectedOutputs.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":" assertEquals(expectedOutputs.get(i), actualOutputs.get(i));","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"Cazh1":2,"ziyi105":55}},{"path":"src/test/java/seedu/cafectrl/command/ListIngredientCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"class ListIngredientCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":" public void execute_validIndex_printsIngredients() {","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 1, \"cup\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"NaychiMin"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" int indexToSelect \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" ListIngredientCommand listIngredientCommand \u003d new ListIngredientCommand(indexToSelect, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" listIngredientCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Chicken Rice Ingredients: \\n\"","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" + \"Rice - 1cup\\n\"","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" + \"Chicken - 100g\\n\";","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"NaychiMin"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"NaychiMin"},"content":" actualOutput.get(0).trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"NaychiMin"},"content":" public void execute_invalidIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 1, \"cup\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" int invalidIndex \u003d 3;","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e {","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" ListIngredientCommand listIngredientCommand \u003d new ListIngredientCommand(invalidIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" listIngredientCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" });","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"NaychiMin":44,"DextheChik3n":1,"Cazh1":8,"ShaniceTang":11}},{"path":"src/test/java/seedu/cafectrl/command/ListMenuCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"class ListMenuCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public void execute_addTwoDishes_expectTwoDishes() {","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" menuItems.add(new Dish(\"Chicken Rice\", 2.50F));","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" menuItems.add(new Dish(\"Chicken Curry\", 4.30F));","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" assertEquals(2, menu.getSize());","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" public void formatListMenu(String dishName, String dishPrice) {","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" String leftAlignFormat \u003d \"| %-24s | %-12s |\";","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d String.format(leftAlignFormat, dishName, dishPrice);","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" Command listMenuCommand \u003d new ListMenuCommand(menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" listMenuCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d Messages.MENU_END_CAP","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" + Messages.LIST_MENU_MESSAGE","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_CORNER","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_TITLE","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_CORNER","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" + \"| 1. Chicken Rice | $2.50 |\"","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" + \"| 2. Chicken Curry | $4.30 |\"","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_END_CAP;","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" public void execute_emptyMenu_expectEmptyMenuMessage() {","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" Command listMenuCommand \u003d new ListMenuCommand(menu, ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" listMenuCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d Messages.MENU_EMPTY_MESSAGE;","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":" private static String convertArrayToString(String[] message, String delimiter) {","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":" StringBuilder sb \u003d new StringBuilder();","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":" for (String str : message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" sb.append(str.toString()).append(delimiter);","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":" return sb.substring(0, sb.length() - 1);","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":86,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":4,"Cazh1":81,"ziyi105":1}},{"path":"src/test/java/seedu/cafectrl/command/ViewTotalStockCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"public class ViewTotalStockCommandTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" void execute_printPantryStock() {","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" pantryStock.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" pantryStock.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" ByteArrayOutputStream baos \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" PrintStream consoleStream \u003d new PrintStream(baos);","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(consoleStream);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" ViewTotalStockCommand viewTotalStockCommand \u003d new ViewTotalStockCommand(pantry, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" viewTotalStockCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" String actualOutput \u003d baos.toString().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"You have the following ingredients in pantry:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredients\\t\\tQty\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" + \"chicken\\t\\t\\t500g\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" + \"rice\\t\\t\\t1000g\";","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":43}},{"path":"src/test/java/seedu/cafectrl/data/MenuTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"//import static org.junit.jupiter.api.Assertions.*;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"class MenuTest {","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"DextheChik3n":1,"ziyi105":6}},{"path":"src/test/java/seedu/cafectrl/data/PantryTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"public class PantryTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" void addIngredientToStock_differentUnitForBuyIngredient_returnErrorMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui, ingredientsList);","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" RuntimeException exception \u003d assertThrows(RuntimeException.class, () -\u003e {","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" pantry.addIngredientToStock(\"chicken\", 500, \"ml\");","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" });","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" String expectedErrorMessage \u003d ErrorMessages.UNIT_NOT_MATCHING + \"\\nUnit used previously: g\";","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedErrorMessage, exception.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":29}},{"path":"src/test/java/seedu/cafectrl/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.AddDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.command.ListIngredientCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.IncorrectCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.DeleteDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.ViewTotalStockCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.BuyIngredientCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.parser.exception.ParserException;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" * Junit test for Parser.java","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"class ParserTest {","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_validCommand_successfulCommandParse() {","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 50, \"g\"),","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof ListIngredientCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" ListIngredientCommand listIngredientCommand \u003d (ListIngredientCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" int index \u003d listIngredientCommand.index;","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" assertEquals(1, index);","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_missingIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients\";","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_LIST_INGREDIENTS, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_invalidIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients a\";","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_LIST_INGREDIENTS, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_indexOutOfBounds_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":100,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.INVALID_DISH_INDEX, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":114,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_validDeleteCommand_successfulCommandParse() {","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"ShaniceTang"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"DextheChik3n"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 50, \"g\"),","lastModifiedDate":"2023-10-25"},{"lineNumber":119,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":120,"author":{"gitId":"ShaniceTang"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":122,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":123,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":125,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":126,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof DeleteDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":133,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":134,"author":{"gitId":"ShaniceTang"},"content":" DeleteDishCommand deleteDishCommand \u003d (DeleteDishCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":135,"author":{"gitId":"ShaniceTang"},"content":" int index \u003d deleteDishCommand.index;","lastModifiedDate":"2023-10-18"},{"lineNumber":136,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(1, index);","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":139,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":140,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_missingDeleteIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":141,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":143,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":144,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":145,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete\";","lastModifiedDate":"2023-10-18"},{"lineNumber":147,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_DELETE, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_invalidDeleteIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete a\";","lastModifiedDate":"2023-10-18"},{"lineNumber":165,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":168,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":169,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":170,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":171,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":172,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_DELETE, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":174,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":175,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":176,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_deleteIndexOutOfBounds_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":177,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":179,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":180,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":181,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":182,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":183,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":187,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":188,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":189,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":190,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.INVALID_DISH_INDEX, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":192,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":193,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":194,"author":{"gitId":"ziyi105"},"content":" void parseCommand_unrecognisedInput_unknownCommand() {","lastModifiedDate":"2023-10-18"},{"lineNumber":195,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":197,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"ziyi105"},"content":" String testUserInput \u003d \"random input\";","lastModifiedDate":"2023-10-18"},{"lineNumber":199,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":200,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":201,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":202,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":203,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":204,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":205,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":206,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":207,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":208,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":209,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":210,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":211,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":212,"author":{"gitId":"ziyi105"},"content":" Command commandReturned \u003d parserUtil.parseCommand(menu, testUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"Cazh1"},"content":" commandReturned.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":214,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.UNKNOWN_COMMAND_MESSAGE, actualOutput.get(0));","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":216,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":217,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":218,"author":{"gitId":"ziyi105"},"content":" void parseCommand_missingArgumentsForEditPrice_missingArgMsg() {","lastModifiedDate":"2023-10-18"},{"lineNumber":219,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":220,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":221,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":222,"author":{"gitId":"ziyi105"},"content":" String testUserInput \u003d \"edit_price index/1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":223,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":224,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":225,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":226,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":228,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":229,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":230,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":231,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":232,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":234,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":236,"author":{"gitId":"ziyi105"},"content":" Command commandReturned \u003d parserUtil.parseCommand(menu, testUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":237,"author":{"gitId":"Cazh1"},"content":" commandReturned.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":238,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_EDIT_PRICE, actualOutput.get(0));","lastModifiedDate":"2023-10-30"},{"lineNumber":239,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":240,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":241,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":242,"author":{"gitId":"ziyi105"},"content":" void parseCommand_invalidDishIndexForEditPrice_invalidIndexForEditPrice() {","lastModifiedDate":"2023-10-18"},{"lineNumber":243,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":244,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":245,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":246,"author":{"gitId":"ziyi105"},"content":" String testUserInput \u003d \"edit_price index/2 price/3\";","lastModifiedDate":"2023-10-18"},{"lineNumber":247,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":248,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":250,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":251,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":252,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":253,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":254,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":255,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":256,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":257,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":258,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":260,"author":{"gitId":"ziyi105"},"content":" Command commandReturned \u003d parserUtil.parseCommand(menu, testUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":261,"author":{"gitId":"Cazh1"},"content":" commandReturned.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":262,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.INVALID_DISH_INDEX, actualOutput.get(0));","lastModifiedDate":"2023-10-30"},{"lineNumber":263,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":264,"author":{"gitId":"DextheChik3n"},"content":" //@@author DextheChik3n","lastModifiedDate":"2023-10-27"},{"lineNumber":265,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":266,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_validDishInputForAddDish_dishAddedToMenu() {","lastModifiedDate":"2023-10-18"},{"lineNumber":267,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":269,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":270,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":271,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":272,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Christmas Ham price/50.00 ingredient/Ham qty/1000g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":273,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":274,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":275,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":276,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct Command type returned","lastModifiedDate":"2023-10-18"},{"lineNumber":277,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":278,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":279,"author":{"gitId":"DextheChik3n"},"content":" //Test for 1 Dish added to Menu","lastModifiedDate":"2023-10-18"},{"lineNumber":280,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":281,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(1, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":282,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":283,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct parsing of dish arguments","lastModifiedDate":"2023-10-27"},{"lineNumber":284,"author":{"gitId":"DextheChik3n"},"content":" Dish getOutputDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-27"},{"lineNumber":285,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":286,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"Christmas Ham\", getOutputDish.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":287,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 50.0, getOutputDish.getPrice());","lastModifiedDate":"2023-10-30"},{"lineNumber":288,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"[Ham - 1000g]\", getOutputDish.getIngredients().toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":289,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":290,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":291,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":292,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_dishWithThreeIngredientsForAddDish_dishContainsThreeIngredientAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":293,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":294,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":295,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":296,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":297,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":298,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/2.00 \"","lastModifiedDate":"2023-10-27"},{"lineNumber":299,"author":{"gitId":"DextheChik3n"},"content":" + \"ingredient/rice qty/100g, ingredient/chicken qty/200g, ingredient/water qty/100ml\";","lastModifiedDate":"2023-10-27"},{"lineNumber":300,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":301,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":302,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":303,"author":{"gitId":"DextheChik3n"},"content":" //Test for 3 Ingredients in the Dish added to Menu","lastModifiedDate":"2023-10-27"},{"lineNumber":304,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":305,"author":{"gitId":"DextheChik3n"},"content":" Dish actualDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-27"},{"lineNumber":306,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(3, actualDish.getIngredients().size());","lastModifiedDate":"2023-10-30"},{"lineNumber":307,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":308,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct parsing of dish arguments","lastModifiedDate":"2023-10-18"},{"lineNumber":309,"author":{"gitId":"DextheChik3n"},"content":" Dish getOutputDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-24"},{"lineNumber":310,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":311,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"Chicken Rice\", getOutputDish.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":312,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 2.0, getOutputDish.getPrice());","lastModifiedDate":"2023-10-30"},{"lineNumber":313,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"[rice - 100g, chicken - 200g, water - 100ml]\", getOutputDish.getIngredients().toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":314,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":315,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":316,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":317,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_invalidDishInputForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-18"},{"lineNumber":318,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":319,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":320,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":321,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":322,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":323,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":324,"author":{"gitId":"DextheChik3n"},"content":" //input name/ argument wrongly","lastModifiedDate":"2023-10-18"},{"lineNumber":325,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add named/Christmas Ham price/50.00 ingredient/Ham qty/1000g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":326,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":327,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":328,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":329,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-18"},{"lineNumber":330,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":331,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":332,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-18"},{"lineNumber":333,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":334,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":335,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":336,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":337,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":338,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_missingArgumentDishInputForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":339,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":340,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":341,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":342,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":343,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":344,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":345,"author":{"gitId":"DextheChik3n"},"content":" //input name/ argument wrongly","lastModifiedDate":"2023-10-18"},{"lineNumber":346,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Christmas Ham price/50.00 ingredient/Ham\";","lastModifiedDate":"2023-10-27"},{"lineNumber":347,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":348,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":349,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":350,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-18"},{"lineNumber":351,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":352,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":353,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-18"},{"lineNumber":354,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":355,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":356,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":357,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":358,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":359,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_invalidQuantityUnitForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":360,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":361,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":362,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":363,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":364,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":365,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":366,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/2.50 ingredient/rice qty/1 cup\";","lastModifiedDate":"2023-10-27"},{"lineNumber":367,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":368,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":369,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":370,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":371,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":372,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":373,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-27"},{"lineNumber":374,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":375,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":376,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":377,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":378,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":379,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_negativeDishPriceForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":380,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":381,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":382,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":383,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":384,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":385,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":386,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/-2.50 ingredient/rice qty/100g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":387,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":388,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":389,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":390,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":391,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":392,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":393,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-27"},{"lineNumber":394,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":395,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":396,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":397,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":398,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":399,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_negativeIngredientQtyForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":400,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":401,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":402,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":403,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":404,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":405,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":406,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/2.50 ingredient/rice qty/-100g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":407,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":408,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":409,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":410,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":411,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":412,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":413,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-27"},{"lineNumber":414,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":415,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":416,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":417,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":418,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":419,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_whitespaceBetweenArgumentsForAddDish_dishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":420,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":421,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":422,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":423,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":424,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":425,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/ Christmas Ham price/ 50.00 ingredient/ Ham qty/ 1000g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":426,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":427,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":428,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":429,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":430,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":431,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":432,"author":{"gitId":"DextheChik3n"},"content":" //Test for 1 Dish added to Menu","lastModifiedDate":"2023-10-27"},{"lineNumber":433,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":434,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(1, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":435,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":436,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct parsing of dish arguments","lastModifiedDate":"2023-10-27"},{"lineNumber":437,"author":{"gitId":"DextheChik3n"},"content":" Dish getOutputDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-27"},{"lineNumber":438,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":439,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"Christmas Ham\", getOutputDish.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":440,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 50.0, getOutputDish.getPrice());","lastModifiedDate":"2023-10-30"},{"lineNumber":441,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"[Ham - 1000g]\", getOutputDish.getIngredients().toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":442,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":443,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":444,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"DextheChik3n"},"content":" void parsePriceToFloat_validPriceString_exactFloatPrice() throws ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"DextheChik3n"},"content":" String inputPriceString \u003d \"3.14\";","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 3.14, Parser.parsePriceToFloat(inputPriceString));","lastModifiedDate":"2023-11-01"},{"lineNumber":449,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":452,"author":{"gitId":"DextheChik3n"},"content":" void parsePriceToFloat_largePriceString_arithmeticExceptionThrown() throws ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":453,"author":{"gitId":"DextheChik3n"},"content":" String inputPriceString \u003d \"99999999999.99\";","lastModifiedDate":"2023-11-01"},{"lineNumber":454,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":455,"author":{"gitId":"DextheChik3n"},"content":" assertThrows(ParserException.class, () -\u003e Parser.parsePriceToFloat(inputPriceString));","lastModifiedDate":"2023-11-01"},{"lineNumber":456,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":457,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":458,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":459,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_existingDishName_true() {","lastModifiedDate":"2023-11-01"},{"lineNumber":460,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":461,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":462,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":463,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":464,"author":{"gitId":"DextheChik3n"},"content":" String inputDishName \u003d \"chicken rice\";","lastModifiedDate":"2023-11-01"},{"lineNumber":465,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":466,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(Parser.isRepeatedName(inputDishName, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":467,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":468,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":469,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":470,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_nonExistingDishName_false() {","lastModifiedDate":"2023-11-01"},{"lineNumber":471,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":472,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":473,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":474,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":475,"author":{"gitId":"DextheChik3n"},"content":" String inputDishName \u003d \"chicken chop\";","lastModifiedDate":"2023-11-01"},{"lineNumber":476,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":477,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(Parser.isRepeatedName(inputDishName, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":478,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":479,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":480,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":481,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_nullString_nullPointerExceptionThrown() throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":482,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":483,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":484,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":485,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":486,"author":{"gitId":"DextheChik3n"},"content":" assertThrows(NullPointerException.class, () -\u003e Parser.isRepeatedName(null, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":487,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":488,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":489,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":490,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_emptyDishName_false() {","lastModifiedDate":"2023-11-01"},{"lineNumber":491,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":492,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":493,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":494,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":495,"author":{"gitId":"DextheChik3n"},"content":" String inputDishName \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":496,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":497,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(Parser.isRepeatedName(inputDishName, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":498,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":499,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":500,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":501,"author":{"gitId":"DextheChik3n"},"content":" void isNameLengthInvalid_moreThanMaxLengthString_true() {","lastModifiedDate":"2023-11-01"},{"lineNumber":502,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(Parser.isNameLengthInvalid(\"this string is more than 35 characters\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":503,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":504,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":505,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":506,"author":{"gitId":"DextheChik3n"},"content":" void isNameLengthInvalid_lessThanMaxLengthString_false() {","lastModifiedDate":"2023-11-01"},{"lineNumber":507,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(Parser.isNameLengthInvalid(\"this str is less than 35 chars\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":508,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":509,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":510,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":511,"author":{"gitId":"DextheChik3n"},"content":" void isNameLengthInvalid_nullString_nullPointerExceptionThrown() throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":512,"author":{"gitId":"DextheChik3n"},"content":" assertThrows(NullPointerException.class, () -\u003eParser.isNameLengthInvalid(null));","lastModifiedDate":"2023-11-01"},{"lineNumber":513,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":514,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":515,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":516,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":517,"author":{"gitId":"ShaniceTang"},"content":" void parseCommand_returnViewTotalStockCommandClass() {","lastModifiedDate":"2023-11-01"},{"lineNumber":518,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":519,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":520,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":521,"author":{"gitId":"ShaniceTang"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":522,"author":{"gitId":"ShaniceTang"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":523,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"view_stock\";","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":526,"author":{"gitId":"ShaniceTang"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-11-01"},{"lineNumber":527,"author":{"gitId":"ShaniceTang"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-11-01"},{"lineNumber":528,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":529,"author":{"gitId":"ShaniceTang"},"content":" ViewTotalStockCommand viewTotalStockCommand \u003d new ViewTotalStockCommand(pantry, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":530,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":531,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(viewTotalStockCommand.getClass(), outputCommand.getClass());","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":534,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"ShaniceTang"},"content":" void parseCommand_missingArgsForBuyIngredient_returnErrorMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"ShaniceTang"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":540,"author":{"gitId":"ShaniceTang"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"buy_ingredient\";","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"ShaniceTang"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"ShaniceTang"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":546,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-11-01"},{"lineNumber":547,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":548,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-11-01"},{"lineNumber":549,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":550,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-11-01"},{"lineNumber":551,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":552,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":553,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":554,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":555,"author":{"gitId":"ShaniceTang"},"content":" void parseCommand_invalidArgsForBuyIngredient_returnErrorMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":556,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":557,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":558,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":559,"author":{"gitId":"ShaniceTang"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":560,"author":{"gitId":"ShaniceTang"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":561,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"buy_ingredient ingredient/rice qty/5 cups\";","lastModifiedDate":"2023-11-01"},{"lineNumber":562,"author":{"gitId":"ShaniceTang"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-11-01"},{"lineNumber":563,"author":{"gitId":"ShaniceTang"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-11-01"},{"lineNumber":564,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":565,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-11-01"},{"lineNumber":566,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":567,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-11-01"},{"lineNumber":568,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":569,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(ErrorMessages.INVALID_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-11-01"},{"lineNumber":570,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":571,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":572,"author":{"gitId":"ShaniceTang"},"content":" //@@author","lastModifiedDate":"2023-11-01"},{"lineNumber":573,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"NaychiMin":49,"DextheChik3n":259,"Cazh1":47,"ziyi105":96,"ShaniceTang":122}}] +[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":" mainClass.set(\"seedu.cafectrl.CafeCtrl\")","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" archiveBaseName.set(\"cafectrl\")","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"DextheChik3n":3,"-":44}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"Display | Name | Github Profile | Portfolio ","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"--------|:--------:|:----------------------------------------:|:---------:","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Shanice | [Github](https://github.com/ShaniceTang) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Naychi | [Github](https://github.com/NaychiMin/tp) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"![](https://www.google.com/url?sa\u003di\u0026url\u003dhttps%3A%2F%2Fwww.scmp.com%2Fweek-asia%2Fpolitics%2Farticle%2F3095228%2Fmalaysia-najibs-cheesy-super-ring-jibe-comes-back-bite-him-after\u0026psig\u003dAOvVaw2ohFjBBhoZxtARfOKEnTXE\u0026ust\u003d1696586245977000\u0026source\u003dimages\u0026cd\u003dvfe\u0026opi\u003d89978449\u0026ved\u003d0CBEQjRxqFwoTCJiboLbS3oEDFQAAAAAdAAAAABAE) | Zi Yi | [Github](https://github.com/ziyi105) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Dexter Hoon | [Github](https://github.com/DextheChik3n) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Chua Zhong Heng | [Github](https://github.com/Cazh1/tp) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"NaychiMin":1,"DextheChik3n":1,"Cazh1":1,"ziyi105":1,"ShaniceTang":2,"-":3}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"* Table of Contents","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"* [Developer Guide](#developer-guide)","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" * [**Acknowledgements**](#acknowledgements)","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" * [**Setting up, getting started**](#setting-up-getting-started)","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" * [**Design**](#design)","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" * [Architecture](#architecture)","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" * [Ui Component](#ui-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" * [Parser Component](#parser-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" * [Storage Component](#storage-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" * [Data Component](#data-component)","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" * [**Feature**](#feature)","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" * [Add Dish](#add-dish)","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" * [Adding a Dish](#adding-a-dish)","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" * [List Menu](#list-menu)","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" * [Add Order](#add-order)","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" * [Next Day](#next-day)","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" * [Previous Day](#previous-day)","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" * [List Ingredients](#list-ingredients)","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" * [Delete Dish](#delete-dish)","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" * [Edit Price](#edit-price)","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" * [Help](#help)","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" * [**Product scope**](#product-scope)","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" * [Target user profile](#target-user-profile)","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" * [Value proposition](#value-proposition)","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" * [User stories](#user-stories)","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"## **Acknowledgements**","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"[addressbook-level2](https://github.com/se-edu/addressbook-level2) \u003cbr\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"[addressbook-level3](https://github.com/se-edu/addressbook-level3)","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":"## **Setting up, getting started**","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":"Refer to the guide [_UserGuide_](UserGuide.md).","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":"-------------------------------------------------------------------------------------------------------------------- ","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":"## **Design**","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"ziyi105"},"content":"### Architecture","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":"![Architecture Diagram](images/ArchitectureDiagram.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"NaychiMin"},"content":"*Figure 1: Architecture Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"ziyi105"},"content":"The ***Architecture Diagram*** given above explains the high-level design of the App.","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":"Listed below is a brief summary outlining the primary components and their interrelationships.","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":"In summary, the user interacts with the Ui components, initiating a sequence that involves:","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":"- `Parser` component for command interpretation","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":"- `Command` component for execution ","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":"- `Data` component for managing application data","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ziyi105"},"content":"The `Storage` component mainly handles interaction with external text files and main coordinates the interactions between the various Components.","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":"The bulk of the app’s work is done by the following components:","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ziyi105"},"content":"- `Ui` : The UI of the App.","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":"- `Storage` : Reads data from, and writes data to, the text files.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":"- `Data` : Consists of all the classes that are involved in execution of commands.","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":"- `Parser` : Makes sense of user input to return the appropriate command","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":"- `Command` : Executes the command requested by the user.","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":"**How the architecture components interact with each other:**","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":"The Sequence Diagram below shows how the components interact with each other for the scenario where the user issues the command `delete 1`.","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":"![Architecture Encode Data](images/sequence/Architecture_Encode_Data.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":"*Figure 2: Architecture Encode Sequence Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":"### Ui Component","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":"API: [Ui.java]({repoURL}src/main/java/seedu/cafectrl/ui/Ui.java)","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":"![Ui Class Diagram](images/class/Ui.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":"\u003cbr\u003e*Figure 3: Ui Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":"The `Ui` component is responsible for interacting with the user. Within CafeCtrl, `Ui` is instantiated by `Parser`, `Command`, `Main`, `Data`, and `Storage` components to access the print methods in `Ui.java`.","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":"In the Ui component,","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":"- `Ui.java` consists of multiple methods that received the user input and prints messages to the system console for users to see","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":"- `Messages.java` consists of multiple strings that contains greeting, command, and goodbye messages to be shown to user","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":"- `ErrorMessages.java` consists of multiple strings that contain error messages to be shown to user when an incorrect command or exception has been returned","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":"### Parser Component","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":"API: [Parser.java]({repoURL}src/main/java/seedu/cafectrl/parser/Parser.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":89,"author":{"gitId":"ziyi105"},"content":"![Parser Class Diagram](images/class/Parser.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":"*Figure 4: Parser Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":"The `Parser` component is respnsible for making sense of the user\u0027s input and return appropriate `Command` for execution. If the input is unrecognisable, `Parser` will return an `IncorrectCommand` which will display error message to the user through `Ui`.","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"ziyi105"},"content":"\u003cdiv markdown\u003d\"span\" class\u003d\"alert alert-info\"\u003e**Note:** `CafeCtrl` only have access to the interface `ParserUtil` although the run-time type object is `Parser`. With this, we are able to decrease coupling between `CafeCtrl` and `Parser`, allowing for easier maintenance. This also ensures the testability as we could provide mock or stub dependencies during testing, we could isolate the behavior of the class and focus on unit testing without external dependencies.\u003c/div\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"ziyi105"},"content":"Below is the sequence diagram of a parser which shows how `Parser` parses user input:","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"ziyi105"},"content":"![Parser Parsing User Input Sequence Diagram](images/sequence/Parser.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":"*Figure 5: Parser Parsing User Input Sequence Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":"When user input a string to `Main`, it passes the full user input to `Parser` via `parseCommand`. In `parseCommand`, it finds the matching keyword for different command from the user input, it calls the respective `prepareCommand` method within itself. `prepareCommand` then generates the corresponding command class and return it to `parseCommand`, which returns the `Command` back to `Main` for execution.","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":"### Storage Component","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"DextheChik3n"},"content":"API: [Storage.java]({repoURL}src/main/java/seedu/cafectrl/storage/Storage.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"DextheChik3n"},"content":"![Storage Class Diagram](images/class/Storage.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":"*Figure 6: Storage Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"DextheChik3n"},"content":"The `Storage` class,","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"DextheChik3n"},"content":"- loads and saves the list of dishes on the `Menu`, available ingredient stock in `Pantry` and orders for the day in `OrderList` in a text file.","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"DextheChik3n"},"content":"- depends on `Menu`, `Pantry` and `Sales` objects (which are found in the data package).","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"DextheChik3n"},"content":"- is composed of `FileManager` object as the text file needs to be located first before reading or writing.","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":"### Data Component","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":"Folder: [Data]({repoURL}src/main/java/seedu/cafectrl/data)","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"NaychiMin"},"content":"![Data Class Diagram](images/class/Data.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"NaychiMin"},"content":"*Figure 7: Data Package Class Diagram*","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"NaychiMin"},"content":"The \u0027Data\u0027 package consists of all the classes that the commands interact with to perform various functions.","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"NaychiMin"},"content":"A summary of the class diagram is as listed below:","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"NaychiMin"},"content":"- Each `Dish` within the `Menu` is constructed with a set of `Ingredient` instances, forming a one-to-many relationship with `Ingredient`.","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"NaychiMin"},"content":"- `Pantry` is instantiated with an ArrayList of `Ingredients` (`pantryStock`), forming a one-to-many relationship with `Ingredient`.","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"NaychiMin"},"content":"- The `Chef` class has a one-to-one relationship with `Pantry`, ensuring access to necessary ingredients for dish preparation.","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"NaychiMin"},"content":"- When an order is placed, the `Order` class is instantiated with an ArrayList of `Ingredient` (`ingredientList`), forming a one-to-many relationship with `Ingredient`.","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"NaychiMin"},"content":"- `OrderList` is instantiated with an ArrayList of `Order`, forming a one-to-many relationship with `Order`.","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"NaychiMin"},"content":"- `Sales` is instantiated with an ArrayList of `OrderList`, forming a one-to-many relationship with `OrderList`.","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":"- Lastly, the `CurrentDate` class keeps track of the current operating day of the cafe.","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"ziyi105"},"content":"## **Feature**","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":135,"author":{"gitId":"DextheChik3n"},"content":"### Add Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":136,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":137,"author":{"gitId":"Cazh1"},"content":"![Add Dish Execution](images/sequence/AddDishCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":"*Figure 8: Execution of add_dish command*","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":140,"author":{"gitId":"DextheChik3n"},"content":"API: [AddDishCommand.java](https://github.com/AY2324S1-CS2113-T17-2/tp/blob/master/src/main/java/seedu/cafectrl/command/AddDishCommand.java)","lastModifiedDate":"2023-10-25"},{"lineNumber":141,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":142,"author":{"gitId":"DextheChik3n"},"content":"The `add_dish` command, add a dish to the `Menu` object and prints out a formatted message to state the name, price and ingredients entered for the dish.","lastModifiedDate":"2023-10-25"},{"lineNumber":143,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":144,"author":{"gitId":"DextheChik3n"},"content":"when the `execute()` method from `AddDishCommand` is called in the main class `CafeCtrl`, the `addDish()` method is first called to add the `Dish` object to the `Menu`. It will then call the `printAddDishMessage()` method, which gets all the parameters of the `Dish` object (dishName, dishPrice, dishIngredients) and passes them to the `Ui` to then be printed out to the User.","lastModifiedDate":"2023-10-25"},{"lineNumber":145,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"DextheChik3n"},"content":"Separation of Concerns was applied to ensure the `Ui` is only responsible with only displaying messages while the `Menu` deals with the logic of adding dish to the menu. This implementation also encapsulates the details of adding a dish and displaying messages. For example, The `AddDishCommand` class doesn\u0027t need to know how the internal details of the dish adding and message printing are performed.","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":"### Adding a Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":"### List Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"Cazh1"},"content":"A `list_menu` command can be used to display all the `Dish` objects stored in `Menu`.","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of a list_menu command.","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":"![List Menu Execution](images/class/ListMenuCommandClass.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":"![List Menu Execution](images/sequence/ListMenuCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":158,"author":{"gitId":"NaychiMin"},"content":"Figure 9: Execution of list_menu command","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":"API: [ListMenuCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-10-26"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of ListMenuCommand is invoked in Main, it checks if the size of the menu by running `menu.getSize()`. ","lastModifiedDate":"2023-10-26"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":164,"author":{"gitId":"Cazh1"},"content":"1) If the menu is empty, it will call its `printEmptyMenu()` method to display to the user a `MENU_EMPTY_MESSAGE` in the Ui object and returns afterward.","lastModifiedDate":"2023-10-26"},{"lineNumber":165,"author":{"gitId":"Cazh1"},"content":"2) If the menu is not empty, it will call its `printFullMenu()` method.","lastModifiedDate":"2023-10-26"},{"lineNumber":166,"author":{"gitId":"Cazh1"},"content":"`printFullMenu()` will first print the top portion of the menu using the Ui object. ","lastModifiedDate":"2023-10-26"},{"lineNumber":167,"author":{"gitId":"Cazh1"},"content":"It then iterates through the `Dish` objects in `Menu` in a \"for\" loop, using `menu.getDishFromId()` to retrieve the Dish object.","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"Cazh1"},"content":"The `dishName` and `dishPrice` are both access from `Dish` Class using `getName()` and `getPrice()` respectively.","lastModifiedDate":"2023-10-26"},{"lineNumber":169,"author":{"gitId":"Cazh1"},"content":"The data are then packaged nicely in a `leftAlignFormat`, with (indexNum + \". \" + dishName,\" $\" + dishPrice) such that","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"Cazh1"},"content":" e.g. (1. Chicken Rice $2.50) is shown.","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"Cazh1"},"content":"### Add Order","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"Cazh1"},"content":"A add_order command can be used to add `order` to an `orderList` in `Sales`.","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of an add_order command.","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"Cazh1"},"content":"![Add_Order Execution](images/class/AddOrderCommandClass.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":"![Add_order Execution](images/sequence/AddOrderCommand_execute.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"NaychiMin"},"content":"*Figure 10: Execution of add_order command*","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"Cazh1"},"content":"API: [AddOrderCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of AddOrderCommand is invoked in Main, the parsed `order` object is added to the `orderList`.","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"Cazh1"},"content":"A `Chef` object is then created to process the order by running `cookDish()`. ","lastModifiedDate":"2023-10-31"},{"lineNumber":187,"author":{"gitId":"Cazh1"},"content":"This method first checks if the order has already been completed by running `order.getIsCompleted()`.","lastModifiedDate":"2023-10-31"},{"lineNumber":188,"author":{"gitId":"Cazh1"},"content":"If the order has not been completed, the `showDeleteMesage()` in the Ui component is triggered to display a message to show the user that the dish is being \u0027prepared\u0027.","lastModifiedDate":"2023-10-31"},{"lineNumber":189,"author":{"gitId":"Cazh1"},"content":"An ArrayList of Ingredients, ingredientList, is retrieved from the `order` object by `order.getIngredientList()`. ","lastModifiedDate":"2023-10-31"},{"lineNumber":190,"author":{"gitId":"Cazh1"},"content":"This ingredientList is passed into the `pantry` object in `pantry.decreaseIngredientsStock()` to process the ingredients used from the pantry stock.","lastModifiedDate":"2023-10-31"},{"lineNumber":191,"author":{"gitId":"Cazh1"},"content":"The order is then marked as completed by `order.setComplete()`","lastModifiedDate":"2023-10-31"},{"lineNumber":192,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":193,"author":{"gitId":"Cazh1"},"content":"Returning to the AddOrderCommand, the `order` object is checked to be completed again by running `order.getIsCompleted()`.","lastModifiedDate":"2023-10-31"},{"lineNumber":194,"author":{"gitId":"Cazh1"},"content":"This verifies that the ingredientList has been successfully retrieved and passed into `pantry.decreaseIngredientsStock()` to run without errors.","lastModifiedDate":"2023-10-31"},{"lineNumber":195,"author":{"gitId":"Cazh1"},"content":"After verifying that the order has been completed, the cost of the order is added to the total order by `orderList.addCost()`. ","lastModifiedDate":"2023-10-31"},{"lineNumber":196,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":197,"author":{"gitId":"Cazh1"},"content":"The total sum of orders in the `orderList` object is retrieved using `orderList.getTotalCost()`.","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"Cazh1"},"content":"This is then passed into Ui using `ui.showTotalCost()` to display a message to the user with the total order cost.","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"Cazh1"},"content":"### Next Day","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"Cazh1"},"content":"A `next_day` command can be used advance the current day.","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of a next_day command.","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"Cazh1"},"content":"![Next_Day Execution](images/class/NextDayCommandClass.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"Cazh1"},"content":"![Next_Day Execution](images/sequence/NextDayCommand_execute.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"NaychiMin"},"content":"*Figure 11: Execution of next_day command*","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"Cazh1"},"content":"API: [NextDayCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of NextDayCommand is invoked in Main, the day in the program is advanced by 1 day, by running `currentDate.nextDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"Cazh1"},"content":"The next day data is retrieved from the `CurrentDate` object using `currentDate.getCurrentDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"Cazh1"},"content":"This next day data is compared with the days accounted for in the `Sales` object, retrieved using `sales.getDaysAccounted()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"Cazh1"},"content":"If the next day is more than the number of days accounted in sales, this means that there is no `orderList` prepared for the coming day.","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"Cazh1"},"content":"A new `OrderList` object is created using `new OrderList()`, and added into the `Sales` object by running `sales.addOrderList()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"Cazh1"},"content":"Following this, the day has been accounted and this is updated through `sales.nextDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"Cazh1"},"content":"To end off the command, `ui.showNextDay()` is run to display a message to the user a prepared message for advancing the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"Cazh1"},"content":"The user is also shown the advanced day number.","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"Cazh1"},"content":"### Previous Day","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"Cazh1"},"content":"A `previous_day` command can be used to recede the current day.","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"Cazh1"},"content":"The following class diagram illustrates the relationship between the respective classes involved in the creation and execution of a next_day command.","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"Cazh1"},"content":"![Previous_Day Execution](images/class/PreviousDayCommandClass.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"Cazh1"},"content":"![Previous_Day Execution](images/sequence/PreviousDayCommand_execute.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"NaychiMin"},"content":"*Figure 12: Execution of previous_day command*","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"Cazh1"},"content":"API: [PreviousDayCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListMenuCommand.java)","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"Cazh1"},"content":"When the `execute()` method of PreviousDayCommand is invoked in Main, the day in the program is receded by 1 day, by running `currentDate.previousDay()`.","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"Cazh1"},"content":"To end off the command, `ui.showPreviousDay()` is run to display a message to the user a prepared message for receding the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"Cazh1"},"content":"The user is also shown the receded day number.","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"NaychiMin"},"content":"### List Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":242,"author":{"gitId":"Cazh1"},"content":"![List Ingredient Execution](images/sequence/ListIngredientCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":243,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":244,"author":{"gitId":"NaychiMin"},"content":"*Figure 13: Execution of list_ingredient command*","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":246,"author":{"gitId":"NaychiMin"},"content":"API: [ListIngredientCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/ListIngredientCommand.java)","lastModifiedDate":"2023-10-25"},{"lineNumber":247,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":248,"author":{"gitId":"NaychiMin"},"content":"| No | Step | Description |","lastModifiedDate":"2023-10-25"},{"lineNumber":249,"author":{"gitId":"NaychiMin"},"content":"|----|-------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-25"},{"lineNumber":250,"author":{"gitId":"NaychiMin"},"content":"| 1 | Initialization | The sequence begins with the `Main` class invoking the `execute` method of the `ListIngredientCommand` after parsing a user command. |","lastModifiedDate":"2023-10-25"},{"lineNumber":251,"author":{"gitId":"NaychiMin"},"content":"| 2-3 | Interaction with \u0027Menu\u0027 | The `ListIngredientCommand` communicates with the `Menu` class, invoking the `getMenuItemsList()` method to retrieve a list of menu items. The function returns an ArrayList of objects of \u0027Dish\u0027 type. |","lastModifiedDate":"2023-10-25"},{"lineNumber":252,"author":{"gitId":"NaychiMin"},"content":"| 4 | Interaction with \u0027Ui\u0027 | The `ListIngredientCommand` communicates with the `Ui` class, invoking the `printIngredients()` method to print out the list of ingredients used for the selected dish. \u003cbr/\u003e * The function returns an ArrayList of objects of \u0027Dish\u0027 type. The `get()` method is then invoked to get the dish of the specified index. However, this is ommitted to prevent unnecessary sophistication. |","lastModifiedDate":"2023-10-25"},{"lineNumber":253,"author":{"gitId":"NaychiMin"},"content":"| 5-6 | Interaction with \u0027Dish\u0027 | The `Ui` class communicates with the `Dish` class, invoking the `getIngredients()` method to obtain the list of ingredients for the selected dish. The `Dish` class responds with an ArrayList of objects of \u0027Ingredient\u0027 type to the `Ui` class. |","lastModifiedDate":"2023-10-25"},{"lineNumber":254,"author":{"gitId":"NaychiMin"},"content":"| 7-8 | Iteration through Ingredients | There is a loop that iterates through each ingredient in the list. The `Ui` class interacts with the `Ingredients` class, converting each ingredient to a string containing the ingredient and quantity needed. |","lastModifiedDate":"2023-10-25"},{"lineNumber":255,"author":{"gitId":"NaychiMin"},"content":"| 9-10 | Display to User | The `Ui` class showcases the information to the user through the `showToUser()` method. |","lastModifiedDate":"2023-10-25"},{"lineNumber":256,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":257,"author":{"gitId":"NaychiMin"},"content":"### Delete Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":258,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":259,"author":{"gitId":"Cazh1"},"content":"![Delete Dish Execution](images/sequence/DeleteDishCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":260,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"NaychiMin"},"content":"*Figure 14: Execution of delete dish command*","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":263,"author":{"gitId":"ShaniceTang"},"content":"API: [DeleteDishCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/DeleteDishCommand.java)","lastModifiedDate":"2023-10-25"},{"lineNumber":264,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":265,"author":{"gitId":"ShaniceTang"},"content":"When the `execute()` method of `DeleteDishCommand` is invoked in `Main`, it subsequently calls `getMenuItemsList().get(dishIndexToBeDeleted)` method on the `Menu` object to retrieve the `Dish` object to be deleted.","lastModifiedDate":"2023-10-25"},{"lineNumber":266,"author":{"gitId":"ShaniceTang"},"content":"Following this, the `showDeleteMesage()` method in the Ui component is triggered to display a message to show the user which dish is about to be deleted.","lastModifiedDate":"2023-10-25"},{"lineNumber":267,"author":{"gitId":"ShaniceTang"},"content":"Afterward, `DeleteDishCommand` calls `removeDish(dishIndexToBeDeleted)` of the `Menu` object to remove the selected dish at the index indicated by the user.","lastModifiedDate":"2023-10-25"},{"lineNumber":268,"author":{"gitId":"ShaniceTang"},"content":"This sequence of actions orchestrates the flow of information and operations between `Main`, `DeleteDishCommand`, `Menu`, and `Ui` components, ensuring the seamless handling of the dish deleting functionality within the application.","lastModifiedDate":"2023-10-25"},{"lineNumber":269,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":270,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":271,"author":{"gitId":"ShaniceTang"},"content":"`DeleteDishCommand` is implemented in such a way because:","lastModifiedDate":"2023-10-25"},{"lineNumber":272,"author":{"gitId":"ShaniceTang"},"content":"1. It promotes loose coupling between components. For instance, `Main` doesn\u0027t need to know the details of how the `execute()` of `DeleteDishCommand` is executed or how the message is displayed in `Ui`.","lastModifiedDate":"2023-10-25"},{"lineNumber":273,"author":{"gitId":"ShaniceTang"},"content":"2. Each component has a specific role and responsibility. `Main` is responsible for receiving user input and invoking `execute()`, `DeleteDishCommand` is responsible for encapsulating the delete operation, `Menu` is responsible for managing the menu items, and `Ui` is responsible for displaying messages to the user. This separation of concerns makes the code more maintainable and easier to understand.","lastModifiedDate":"2023-10-25"},{"lineNumber":274,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":275,"author":{"gitId":"ziyi105"},"content":"### Edit Price","lastModifiedDate":"2023-10-24"},{"lineNumber":276,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":277,"author":{"gitId":"Cazh1"},"content":"![Edit Price Execution](images/sequence/EditPriceCommand_execute.png)","lastModifiedDate":"2023-10-30"},{"lineNumber":278,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":279,"author":{"gitId":"NaychiMin"},"content":"*Figure 15: Execution of edit_price command*","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":281,"author":{"gitId":"ziyi105"},"content":"API: [EditPriceCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/EditPriceCommand.java)","lastModifiedDate":"2023-10-24"},{"lineNumber":282,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":283,"author":{"gitId":"ziyi105"},"content":"When the `execute()` method of `EditPriceCommand` is invoked in `Main`, it subsequently calls the `setPrice()` method on the `Dish` object to modify the price of the specific dish. Following this, the `showEditPriceMessages()` method in the `Ui` component is triggered to retrieve and display a message from `Messages` related to the successful execution of the price modification process. This sequence of actions orchestrates the flow of information and operations between the `Main`, `EditPriceCommand`, `Dish`, and `Ui` components, ensuring the seamless handling of the price editing functionality within the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":284,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":285,"author":{"gitId":"ziyi105"},"content":"### Help","lastModifiedDate":"2023-10-31"},{"lineNumber":286,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":287,"author":{"gitId":"ziyi105"},"content":"![Help Execution](images/sequence/HelpCommand_execute.png)","lastModifiedDate":"2023-10-31"},{"lineNumber":288,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":289,"author":{"gitId":"NaychiMin"},"content":"*Figure 16: Execution of help command*","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":291,"author":{"gitId":"ziyi105"},"content":"API: [HelpCommand.java]({repoURL}src/main/java/seedu/cafectrl/command/HelpCommand.java)","lastModifiedDate":"2023-10-31"},{"lineNumber":292,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":293,"author":{"gitId":"ziyi105"},"content":"When the `execute()` method of `HelpCommand` is invoked in `Main`, it subsequently calls the `showHelp()` method in `Ui`. In `showHelp()`, messages related to command usage will be retrieved and be printed out using by self-invoking `showToUserWithSpaceInBetweenLines(messages: String...)`.","lastModifiedDate":"2023-10-31"},{"lineNumber":294,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":295,"author":{"gitId":"ziyi105"},"content":"--------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-02"},{"lineNumber":296,"author":{"gitId":"ziyi105"},"content":"## **Product scope**","lastModifiedDate":"2023-11-02"},{"lineNumber":297,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":298,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":299,"author":{"gitId":"ziyi105"},"content":"Café proprietors who ***love*** typing on CLI and are seeking for a software solution to optimize the management of their café\u0027s operations.","lastModifiedDate":"2023-11-02"},{"lineNumber":300,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":301,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":302,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":303,"author":{"gitId":"DextheChik3n"},"content":"Our product aims to optimize managing of inventory and cash flow in a restaurant. Our CLI platform empowers users to streamline stock inventory, menu and orders. Users will also briefly be able to gain valuable insights through comprehensive sales reporting, enabling them to analyze sales trends and calculate revenue/profit margins, eliminating the need for cross-platform management.","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":305,"author":{"gitId":"ziyi105"},"content":"### User stories","lastModifiedDate":"2023-11-02"},{"lineNumber":306,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":307,"author":{"gitId":"ziyi105"},"content":"| Priority | As a …​ | I want to …​ | So that I can…​ |","lastModifiedDate":"2023-11-02"},{"lineNumber":308,"author":{"gitId":"ziyi105"},"content":"|----------|-----------------------------------------------------------|---------------------------------------------------------|-----------------------------------------------------------------------------------------|","lastModifiedDate":"2023-11-02"},{"lineNumber":309,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who is responsible for coming up with new dish | add dish to the menu | add new dish to the menu |","lastModifiedDate":"2023-11-02"},{"lineNumber":310,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe manager is responsible for managing pantry stock | track the inventory levels for ingredients and supplies | know what ingredients I need to restock |","lastModifiedDate":"2023-11-02"},{"lineNumber":311,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe manager is responsible for managing pantry stock | buy ingredients | restock low stock ingredients |","lastModifiedDate":"2023-11-02"},{"lineNumber":312,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who is also the chef | view the ingredients needed for a dish | know what ingredients to use when cooking a dish |","lastModifiedDate":"2023-11-02"},{"lineNumber":313,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who wants to maximise profit | edit the price of the dish | increase the price of the dish when there is inflation |","lastModifiedDate":"2023-11-02"},{"lineNumber":314,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who cares about the sales of the cafe | view the sales of the cafe | know whether my cafe is profiting |","lastModifiedDate":"2023-11-02"},{"lineNumber":315,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who works 7 days a week | save the menu, pantry stock and order | have access to the same menu, pantry stock and orders when I go back to work |","lastModifiedDate":"2023-11-02"},{"lineNumber":316,"author":{"gitId":"ziyi105"},"content":"| `* * *` | cafe owner who is responsible for placing order | add order | ask the chef to cook the order |","lastModifiedDate":"2023-11-02"},{"lineNumber":317,"author":{"gitId":"ziyi105"},"content":"| `* *` | cafe manager who is responsible for drafting the menu | view the menu | keep track of what dish we have |","lastModifiedDate":"2023-11-02"},{"lineNumber":318,"author":{"gitId":"ziyi105"},"content":"| `* *` | cafe owner who working 7 days a week | fast forward to the next day | close the cafe and call it a day when I am tired |","lastModifiedDate":"2023-11-02"},{"lineNumber":319,"author":{"gitId":"ziyi105"},"content":"| `* *` | clumsy cafe owner who works 7 days a week | go back to the previous day | still accept order from the previous day if I accidentally fast forward to the next day | ","lastModifiedDate":"2023-11-02"},{"lineNumber":320,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":321,"author":{"gitId":"ziyi105"},"content":"*{More to be added}*","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"NaychiMin":67,"DextheChik3n":23,"Cazh1":84,"ziyi105":98,"ShaniceTang":25,"-":24}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"# CafeCTRL","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"CafeCTRL aims to optimize managing of inventory and cash flow in a restaurant. Our CLI platform empowers Café proprietors to streamline inventory and menu management.","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"DextheChik3n":2,"-":6}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# User Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"* Table of Contents","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"* [User Guide](#user-guide)","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" * [Introduction](#introduction)","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" * [Quick Start](#quick-start)","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" * [Features](#features-)","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" * [Viewing help : `help`](#viewing-help--help)","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" * [Adding a dish : `add`](#adding-a-dish--add)","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" * [Listing all menu items : `list_menu`](#listing-all-menu-items--listmenu)","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" * [Listing ingredients needed for the selected dish : `list_ingredients`](#listing-ingredients-needed-for-the-selected-dish--listingredients)","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" * [Deleting a menu item : `delete`](#deleting-a-menu-item--delete)","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" * [Editing price of menu item : `edit_price`](#editing-price-of-menu-item--editprice)","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" * [Viewing the total stock of ingredients : `view_stock`](#viewing-the-total-stock-of-ingredients--viewstock)","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" * [Buying an ingredient : `buy_ingredient`](#buying-an-ingredient--buyingredient)","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" * [Showing all sales : `show_sales`](#showing-all-sales--showsales)","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" * [Showing sales for a chosen day : `show_sale`](#showing-sales-for-a-chosen-day--showsale)","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" * [Adding an order : `add_order`](#adding-an-order--addorder)","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" * [Returning to the previous day: `previous_day`](#returning-to-the-previous-day-previousday)","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" * [Advancing to the next day: `next_day`](#advancing-to-the-next-day-nextday)","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" * [Exiting the program : `bye`](#exiting-the-program--bye)","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" * [Known Issues](#known-issues)","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" * [Command Summary](#command-summary)","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"\u003c!-- TOC --\u003e","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"---------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"CafeCTRL aims to optimize managing of inventory and cash flow in a restaurant. Our CLI platform empowers Café proprietors to streamline inventory and menu management.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"---------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":"1. Ensure that you have Java `11` or above installed. ","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":"2. Down the latest version of `CafeCtrl` from [here](https://github.com/AY2324S1-CS2113-T17-2/tp/releases).","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":"3. Copy the file to the folder you want to use as the home folder for your Cafe Manager CLI Application.","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"4. Open a command terminal, `cd` into the folder you put the jar file in, and use the `java -jar tp.jar` command to run the application.","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":"5. If the setup is correct, you should see something like the below as the output:","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":"Hello! Welcome to CafeCTRL!","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":"\u003e ","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":"---------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":"## Features ","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":"\u003e **Notes about command format:**","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Words in `UPPER_CASE` are the arguments to be supplied by user. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" e.g. in add name/NAME, NAME is a parameter that can be used as add name/Chicken.","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Parameters need to be in the exact format as specified. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" e.g. `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY`,\u003cbr\u003e `name/` must come before `price/`.","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Items in square brackets with …​ can be used multiple times including zero times. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" e.g. `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY [, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]` \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":" can be used as \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":" `add name/Christmas Ham price/50.00 ingredient/Ham qty/1000g`\u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"DextheChik3n"},"content":" or as \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" `add name/chicken rice price/2.00 ingredient/rice qty/100g, ingredient/chicken qty/200g, ingredient/garlic qty/100g`","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":"\u003e - Extraneous parameters for commands that do not take in parameters (such as `help`, `list_menu`, `bye`) will be ignored. \u003cbr\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" e.g. if the command specifies `help 123`, it will be interpreted as `help`.","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":"### Viewing help : `help`","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":"Shows a message explaining how to use all the commands","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":62,"author":{"gitId":"DextheChik3n"},"content":"Format: `help`","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"ziyi105"},"content":"Output:","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":"These are all the commands I recognise: ","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":"(- Words in UPPER_CASE are the parameters to be supplied by the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":"e.g. in add name/NAME, NAME is a parameter that can be used as add name/Chicken.","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":"- Parameters in [] are optional.)","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":"Command Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":"add name/DISH_NAME price/DISH_PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME, qty/INGREDIENT2_QTY...]","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":"(Items in square brackets [] are optional)","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":"Example:","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":"add name/chicken rice price/3.00 ingredient/rice qty/200g, ingredient/chicken qty/100g","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"ziyi105"},"content":"list_ingredients: Lists out the ingredients needed along with the quantity for a specific dish.","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":"Parameters: INDEX","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":"Example: list_ingredients 1","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"ziyi105"},"content":"To list out all dishes on the menu: list_menu","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"ziyi105"},"content":"To delete a menu item: delete DISH_INDEX","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"ziyi105"},"content":"Example: delete 1","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":"edit_priceTo edit price of a menu item: edit_price index/DISH_INDEX price/NEW_PRICE","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":"Example: edit_price index/1 price/4.50","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"DextheChik3n"},"content":"\u003c!---@@author DextheChik3n---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"DextheChik3n"},"content":"### Adding a dish : `add`","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"DextheChik3n"},"content":"Adds a dish consisting of its ingredients to the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":93,"author":{"gitId":"DextheChik3n"},"content":"Format: `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":95,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":96,"author":{"gitId":"DextheChik3n"},"content":"* The `PRICE` must be a positive 2 decimal place number.","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"DextheChik3n"},"content":"* The `IMGREDIENT_QTY` must contain the unit ml or g specifically.","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"DextheChik3n"},"content":" * e.g. `qty/50g` or `qty/1000ml`","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":100,"author":{"gitId":"DextheChik3n"},"content":"Example:","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"DextheChik3n"},"content":"\u003e add name/chicken rice price/2.00 ingredient/rice qty/100g, ingredient/chicken qty/200g, ingredient/soup qty/50ml","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"DextheChik3n"},"content":"You have added the following dish...","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"DextheChik3n"},"content":"Dish Name: chicken rice","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"DextheChik3n"},"content":"Dish Price: $2.00","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"DextheChik3n"},"content":"chicken rice Ingredients: ","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"DextheChik3n"},"content":"rice - 100g","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"DextheChik3n"},"content":"chicken - 200g","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"DextheChik3n"},"content":"soup - 50ml","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"DextheChik3n"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":112,"author":{"gitId":"Cazh1"},"content":"\u003c!---@@author Cazh1---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"Cazh1"},"content":"### Listing all menu items : `list_menu`","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"Cazh1"},"content":"Shows a list of all dishes on the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":116,"author":{"gitId":"Cazh1"},"content":"Format: `list_menu`","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":118,"author":{"gitId":"Cazh1"},"content":"Example:","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"Cazh1"},"content":"+-----------------------------------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"Cazh1"},"content":"| Ah, behold, the grand menu of delights! |","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"Cazh1"},"content":"+--------------------------+--------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"Cazh1"},"content":"| Dish Name | Price |","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"Cazh1"},"content":"+--------------------------+--------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"Cazh1"},"content":"| 1. chicken rice | $2.50 |","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"Cazh1"},"content":"| 2. chicken curry | $4.30 |","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"Cazh1"},"content":"+-----------------------------------------+","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":"\u003c!---@@author NaychiMin---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":"### Listing ingredients needed for the selected dish : `list_ingredients`","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"NaychiMin"},"content":"Lists out the ingredients needed along with the quantity for a specific dish","lastModifiedDate":"2023-10-30"},{"lineNumber":133,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":134,"author":{"gitId":"NaychiMin"},"content":"Format: `list_ingredients DISH_INDEX`","lastModifiedDate":"2023-10-30"},{"lineNumber":135,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":136,"author":{"gitId":"NaychiMin"},"content":"Example:","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"NaychiMin"},"content":"- list followed by list_ingredients 1 lists the ingredients of the 1st dish on the menu","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"NaychiMin"},"content":"chicken salad Ingredients: ","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"NaychiMin"},"content":"pasta - 100g","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"NaychiMin"},"content":"chicken - 200g","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"NaychiMin"},"content":"lettuce - 200g","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":"tomatoes - 100g","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":"feta cheese - 20g","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"NaychiMin"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":"list followed by list_ingredients 1 lists the ingredients of the 1st dish on the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":151,"author":{"gitId":"ShaniceTang"},"content":"\u003c!---@@author ShaniceTang---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"ShaniceTang"},"content":"### Deleting a menu item : `delete`","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"ShaniceTang"},"content":"Deletes a specific dish from the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"ShaniceTang"},"content":"Format: `delete DISH_INDEX`","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"ShaniceTang"},"content":"* Deletes the dish at the specified DISH_INDEX","lastModifiedDate":"2023-10-30"},{"lineNumber":158,"author":{"gitId":"ShaniceTang"},"content":"* The index refers to the index number shown in the menu list ","lastModifiedDate":"2023-10-30"},{"lineNumber":159,"author":{"gitId":"ShaniceTang"},"content":"* The index must be a positive integer","lastModifiedDate":"2023-10-30"},{"lineNumber":160,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":161,"author":{"gitId":"ShaniceTang"},"content":"Example: `delete 1`","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"ShaniceTang"},"content":"Okay! chicken rice is deleted! :)","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":168,"author":{"gitId":"ziyi105"},"content":"\u003c!---@@author ziyi105---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"ziyi105"},"content":"### Editing price of menu item : `edit_price`","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"ziyi105"},"content":"Edits the price of an existing dish on the menu","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":172,"author":{"gitId":"ziyi105"},"content":"Format: `edit_price index/DISH_INDEX price/NEW_PRICE`","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":174,"author":{"gitId":"ziyi105"},"content":"Example: `edit_price index/1 price/4.50`","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":176,"author":{"gitId":"ziyi105"},"content":"Output: ","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"ziyi105"},"content":"Price modified for the following dish: ","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"ziyi105"},"content":"Chicken rice - $4.50","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"ziyi105"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":182,"author":{"gitId":"ShaniceTang"},"content":"\u003c!---@@author ShaniceTang---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"ShaniceTang"},"content":"### Viewing the total stock of ingredients : `view_stock`","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"ShaniceTang"},"content":"Displays the available stock of all the ingredients found in the pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"ShaniceTang"},"content":"Format: `view_stock`","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"ShaniceTang"},"content":"You have the following ingredients in pantry:","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"ShaniceTang"},"content":"Ingredients\t\tQty","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"ShaniceTang"},"content":"chicken\t\t\t500g","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"ShaniceTang"},"content":"milk\t\t\t1000ml","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":196,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":197,"author":{"gitId":"ShaniceTang"},"content":"### Buying an ingredient : `buy_ingredient`","lastModifiedDate":"2023-10-30"},{"lineNumber":198,"author":{"gitId":"ShaniceTang"},"content":"Adds one or more ingredients to the pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"ShaniceTang"},"content":"Format: `buy_ingredient ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"ShaniceTang"},"content":"Example: `buy_ingredient ingredient/chicken qty/500g, ingredient/milk qty/1000ml`","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":204,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ShaniceTang"},"content":"Added to stock:","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"ShaniceTang"},"content":"Ingredient: chicken\t\tQty: 500g","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"ShaniceTang"},"content":"Ingredient: milk\t\tQty: 1000ml","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"ShaniceTang"},"content":"### Showing all sales : `show_sales`","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"ShaniceTang"},"content":"Displays the dishes sold and total sales for each from Day 1 to the current day that ","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"ShaniceTang"},"content":"the cafe is operating on.","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"ShaniceTang"},"content":"Format: `show_sales`","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"ShaniceTang"},"content":"Example: `show_sales`","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"ShaniceTang"},"content":"- show_sales lists the dishes sold along with the total sales for every operating day of the cafe.","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"ShaniceTang"},"content":"Day 1:","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"ShaniceTang"},"content":"Dish Name Dish Qty Total Cost Price ","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"ShaniceTang"},"content":"chicken rice 4 12.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"ShaniceTang"},"content":"Total for day: $12.00","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"ShaniceTang"},"content":"Day 2:","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"ShaniceTang"},"content":"Dish Name Dish Qty Total Cost Price ","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"ShaniceTang"},"content":"chicken chop 5 21.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"ShaniceTang"},"content":"chicken rice 3 9.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"ShaniceTang"},"content":"Total for day: $30.00","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"ShaniceTang"},"content":"### Showing sales for a chosen day : `show_sale`","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"ShaniceTang"},"content":"Displays the dishes sold along with the total sales for any chosen day.","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":246,"author":{"gitId":"ShaniceTang"},"content":"Format: `show_sale day/DAY_TO_DISPLAY`","lastModifiedDate":"2023-11-01"},{"lineNumber":247,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":248,"author":{"gitId":"ShaniceTang"},"content":"Example: `show_sale day/1`","lastModifiedDate":"2023-11-01"},{"lineNumber":249,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":250,"author":{"gitId":"ShaniceTang"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":251,"author":{"gitId":"ShaniceTang"},"content":"- show_sale day/1 lists the dishes sold along with the total sales for day 1.","lastModifiedDate":"2023-11-01"},{"lineNumber":252,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":253,"author":{"gitId":"ShaniceTang"},"content":"Day 1:","lastModifiedDate":"2023-11-01"},{"lineNumber":254,"author":{"gitId":"ShaniceTang"},"content":"Dish Name Dish Qty Total Cost Price ","lastModifiedDate":"2023-11-01"},{"lineNumber":255,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":256,"author":{"gitId":"ShaniceTang"},"content":"chicken rice 4 12.0 ","lastModifiedDate":"2023-11-01"},{"lineNumber":257,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":258,"author":{"gitId":"ShaniceTang"},"content":"Total for day: $12.00","lastModifiedDate":"2023-11-01"},{"lineNumber":259,"author":{"gitId":"ShaniceTang"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":260,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"Cazh1"},"content":"\u003c!---@@author Cazh1---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"Cazh1"},"content":"### Adding an order : `add_order`","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"Cazh1"},"content":"Adds an order consisting of dishes off the menu to an order list","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"Cazh1"},"content":"Format: `add_order name/DISH_NAME qty/DISH_QTY`","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"Cazh1"},"content":"Example:","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":269,"author":{"gitId":"Cazh1"},"content":"\u003e add_order name/chicken rice qty/2","lastModifiedDate":"2023-11-01"},{"lineNumber":270,"author":{"gitId":"Cazh1"},"content":"I\u0027m busy crafting your selected dish in the virtual kitchen of your dreams. Bon appétit!","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"Cazh1"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"Cazh1"},"content":"Order is ready!","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"Cazh1"},"content":"Total order cost: $5.00","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"Cazh1"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"Cazh1"},"content":"Listed below are the availability of the dishes for the next order!","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"Cazh1"},"content":"Dish: chicken rice","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"Cazh1"},"content":"Available Dishes: 8","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"Cazh1"},"content":"-----------------------------------------------------","lastModifiedDate":"2023-11-01"},{"lineNumber":279,"author":{"gitId":"Cazh1"},"content":"Dish: chicken curry","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"Cazh1"},"content":"Available Dishes: 4","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":282,"author":{"gitId":"Cazh1"},"content":"* The `DISH_QTY` must be a positive integer number.","lastModifiedDate":"2023-11-01"},{"lineNumber":283,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":284,"author":{"gitId":"Cazh1"},"content":"Adds an order to the current business day","lastModifiedDate":"2023-11-01"},{"lineNumber":285,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":286,"author":{"gitId":"Cazh1"},"content":"Format: `add_order name/DISH_NAME qty/QUANTITY`","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"Cazh1"},"content":"Example: `add_order name/chicken rice qty/2`","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"Cazh1"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":291,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":292,"author":{"gitId":"Cazh1"},"content":"I\u0027m busy crafting your selected dish in the virtual kitchen of your dreams. Bon appétit!","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"Cazh1"},"content":"Is order completed?: true","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"Cazh1"},"content":"Total orderList cost: $4.00","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"Cazh1"},"content":"### Returning to the previous day: `previous_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":300,"author":{"gitId":"Cazh1"},"content":"Goes back to the previous business day","lastModifiedDate":"2023-11-01"},{"lineNumber":301,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":302,"author":{"gitId":"Cazh1"},"content":"Format: `previous_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":303,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"Cazh1"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":305,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":306,"author":{"gitId":"Cazh1"},"content":"Sure thing! Let\u0027s rev up the virtual DeLorean and take a spin to the previous day. Buckle up, it\u0027s time to hit that rewind button!","lastModifiedDate":"2023-11-01"},{"lineNumber":307,"author":{"gitId":"Cazh1"},"content":"Today is Day 1","lastModifiedDate":"2023-11-01"},{"lineNumber":308,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":309,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":310,"author":{"gitId":"Cazh1"},"content":"### Advancing to the next day: `next_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":311,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":312,"author":{"gitId":"Cazh1"},"content":"Proceeds to the next business day","lastModifiedDate":"2023-11-01"},{"lineNumber":313,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":314,"author":{"gitId":"Cazh1"},"content":"Format: `next_day`","lastModifiedDate":"2023-11-01"},{"lineNumber":315,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":316,"author":{"gitId":"Cazh1"},"content":"Output:","lastModifiedDate":"2023-11-01"},{"lineNumber":317,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":318,"author":{"gitId":"Cazh1"},"content":"Prepare for liftoff! We\u0027re about to fast-forward to the next day. Hold onto your hats; here we go!","lastModifiedDate":"2023-11-01"},{"lineNumber":319,"author":{"gitId":"Cazh1"},"content":"Today is Day 2","lastModifiedDate":"2023-11-01"},{"lineNumber":320,"author":{"gitId":"Cazh1"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":321,"author":{"gitId":"Cazh1"},"content":"\u003c!---@@author---\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":322,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":323,"author":{"gitId":"DextheChik3n"},"content":"### Exiting the program : `bye`","lastModifiedDate":"2023-10-30"},{"lineNumber":324,"author":{"gitId":"DextheChik3n"},"content":"Exits the program.","lastModifiedDate":"2023-10-30"},{"lineNumber":325,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":326,"author":{"gitId":"DextheChik3n"},"content":"Format: `bye`","lastModifiedDate":"2023-10-30"},{"lineNumber":327,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":328,"author":{"gitId":"ziyi105"},"content":"----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":329,"author":{"gitId":"NaychiMin"},"content":"## Known Issues","lastModifiedDate":"2023-11-01"},{"lineNumber":330,"author":{"gitId":"DextheChik3n"},"content":"- The application is unable to read the data text files if they have been edited directly in the wrong decoding format","lastModifiedDate":"2023-11-01"},{"lineNumber":331,"author":{"gitId":"DextheChik3n"},"content":"- For edit price command, special characters can be entered in the price argument","lastModifiedDate":"2023-11-01"},{"lineNumber":332,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":333,"author":{"gitId":"ziyi105"},"content":"----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-03"},{"lineNumber":334,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2023-10-30"},{"lineNumber":335,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":336,"author":{"gitId":"DextheChik3n"},"content":"| Action | Format, Examples |","lastModifiedDate":"2023-10-30"},{"lineNumber":337,"author":{"gitId":"DextheChik3n"},"content":"|---------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-30"},{"lineNumber":338,"author":{"gitId":"DextheChik3n"},"content":"| **Add** | `add name/DISH_NAME price/PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY [, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr/\u003e`add name/chicken rice price/3.00 ingredient/rice qty/50g, ingredient/chicken qty/100g` |","lastModifiedDate":"2023-10-30"},{"lineNumber":339,"author":{"gitId":"DextheChik3n"},"content":"| **List Menu** | `list_menu` |","lastModifiedDate":"2023-10-30"},{"lineNumber":340,"author":{"gitId":"ziyi105"},"content":"| **List Ingredients** | `list_ingredients DISH_INDEX`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`list_ingredients 1` |","lastModifiedDate":"2023-11-03"},{"lineNumber":341,"author":{"gitId":"ziyi105"},"content":"| **Delete** | `delete DISH_INDEX`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`delete 1` |","lastModifiedDate":"2023-11-03"},{"lineNumber":342,"author":{"gitId":"ziyi105"},"content":"| **Edit Price** | `edit_price index/DISH_INDEX price/NEW_PRICE`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`edit_price index/1 price/4.50` |","lastModifiedDate":"2023-11-03"},{"lineNumber":343,"author":{"gitId":"NaychiMin"},"content":"| **Show Sale** | `show_sales` |","lastModifiedDate":"2023-11-01"},{"lineNumber":344,"author":{"gitId":"ziyi105"},"content":"| **Show Sale by Day** | `show_sale day/DAY_TO_DISPLAY` \u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`show_sale day/ 1` |","lastModifiedDate":"2023-11-03"},{"lineNumber":345,"author":{"gitId":"ShaniceTang"},"content":"| **View Ingredient Stock** | `view_stock` |","lastModifiedDate":"2023-11-01"},{"lineNumber":346,"author":{"gitId":"ziyi105"},"content":"| **Buy Ingredients** | `buy_ingredient ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY[, ingredient/INGREDIENT2_NAME qty/INGREDIENT2_QTY, ...]`\u003cbr\u003e\u003cbr/\u003eExample\u003cbr\u003e`buy_ingredient ingredient/chicken qty/500g, ingredient/milk qty/1000ml` |","lastModifiedDate":"2023-11-03"},{"lineNumber":347,"author":{"gitId":"ziyi105"},"content":"| **Add Order** | `add_order name/DISH_NAME qty/QUANTITY`\u003cbr\u003e\u003cbr/\u003eExample:\u003cbr\u003e`add_order name/chicken rice qty/2` |","lastModifiedDate":"2023-11-03"},{"lineNumber":348,"author":{"gitId":"ShaniceTang"},"content":"| **Previous Day** | `previous_day` |","lastModifiedDate":"2023-11-01"},{"lineNumber":349,"author":{"gitId":"ShaniceTang"},"content":"| **Next Day** | `next_day` |","lastModifiedDate":"2023-11-01"},{"lineNumber":350,"author":{"gitId":"DextheChik3n"},"content":"| **Help** | `help` |","lastModifiedDate":"2023-10-30"},{"lineNumber":351,"author":{"gitId":"DextheChik3n"},"content":"| **Exit Program** | `bye` |","lastModifiedDate":"2023-10-30"},{"lineNumber":352,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"NaychiMin":23,"DextheChik3n":62,"Cazh1":79,"ziyi105":73,"ShaniceTang":99,"-":16}},{"path":"docs/diagrams/ArchitectureDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"\u0027https://plantuml.com/deployment-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"actor User","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"rectangle {","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"rectangle Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"rectangle Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"rectangle Command","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"rectangle Main","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"rectangle Data","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"rectangle Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"folder TextFiles","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"User ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"Ui --\u003e Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"Parser --\u003e Command","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"Parser ..\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"Command --\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"Command ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"Storage --\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"Storage ...\u003e TextFiles","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"Ui \u003c- Main","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"Main --\u003e Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"Main --\u003e Data","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"Main --\u003e Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":31}},{"path":"docs/diagrams/class/AddOrderCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `add_order` Command","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" UI","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- AddOrderCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" AddOrderCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"Parser ..\u003e CurrentDate","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"Parser ..\u003e Sales","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand --\u003e OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand \"1\" --\u003e \"1\" Chef","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand --\u003e Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"AddOrderCommand ..\u003e Order","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"OrderList --\u003e \"*\" Order","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"Sales --\u003e \"1...*\" OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"Chef ..\u003e Pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"class UI {","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"+ showToUser() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"+ showChefMessage() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"+ showTotalCost(dollarCost : String) : void","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"class AddOrderCommand {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"# pantry : Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"# orderList : OrderList","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"# menu : Menu","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"- order : Order","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"{static} - prepareOrder(menu : Menu, arguments : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"{static} - setOrderList(currentDate : CurrentDate, sales : Sales)","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":"class OrderList {","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"- orderList : ArrayList\u003cOrder\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"- totalOrderListCost : float","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":"+ addOrder() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":"+ addCost() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":"+ getTotalCost() : float","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"class Order {","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"- orderedDish : Dish","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":"- dishQty : int","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":"- ingredientList : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":"- isComplete : boolean","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"- totalOrderCost : float","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":"- getDishPrice() : float","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":"- setIngredientList() : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":"+ getIngredientList() : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":"+ getTotalOrderCost() : float","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"Cazh1"},"content":"+ setComplete() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"Cazh1"},"content":"+ getIsComplete() : boolean","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":"class Chef {","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":"- order : Order","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":"- pantry : Pantry","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":"+ cookDish() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"Cazh1"},"content":"class Pantry {","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"Cazh1"},"content":"- pantryStock : ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"Cazh1"},"content":"- menuItems : ArrayList\u003cDish\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"Cazh1"},"content":"+ isDishCooked( :ArrayList\u003cIngredient\u003e) : boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"Cazh1"},"content":"+ calculateDishAvailability(menu : Menu) : void","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"Cazh1"},"content":"class Sales {","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"Cazh1"},"content":"- orderLists : ArrayList\u003cOrderList\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"Cazh1"},"content":"+ getOrderList(index : int) : OrderList","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"Cazh1"},"content":"class CurrentDate {","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":"- currentDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":"+ getCurrentDay() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":104,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":105}},{"path":"docs/diagrams/class/Data.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"class Menu {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"+ getMenuItemsList(): ArrayList\u003cDish\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"+ getSize(): int","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"+ getDishFromId(menuID: int): Dish","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"+ getDishFromName(dishName: String): Dish","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"+ removeDish(menuID: int): void","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"+ addDish(dish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"+ isValidDishIndex(dishIndex: int): boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"class Dish {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"- name: String","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"- price: float","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"+ getName(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"+ getIngredients(): ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"+ getPrice(): float","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"+ setPrice(newPrice: float): void","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"class Ingredient {","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"- name: String","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"- qty: int","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"- unit: String","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"+ getName(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"+ getQty(): int","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"+ getUnit(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"+ setQty(qty:int): void","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":"class Pantry {","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"+ getPantryStock():ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":"+ addIngredientToStock(name: String, qty: int, unit: String): Ingredient","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":"+ isDishCooked(dishIngredients: ArrayList\u003cIngredient\u003e): boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":"- getIngredient(dishIngredient: Ingredient): Ingredient","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":"+ calculateDishAvailability(menu: Menu): void","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"+ calculateMaxDishes(dish: Dish, menu: Menu)","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":"- calculateMaxDishForEachIngredient(dishIngredient: Ingredient): int","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":"- handleRestock(dishIngredient: Ingredient): void","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":"+ retrieveIngredientsForDish(orderedDish: String, menu: Menu): ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":"class Chef {","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"- dollarValue: DecimalFormat","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":"+ cookDish(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":"class Order {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"- dollarValue: DecimalFormat","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":"- dishQty: int","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":"- isComplete: boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":"- totalOrderCost: float","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":"+ calculateTotalOrderCost(): float","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":"class OrderList {","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":"- dollarValue: DecimalFormat","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":"- HEADER_FORMAT: String","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":"- totalOrderListCost","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":"+ addOrder(order: Order): void","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":"+ addCost(order: Order): void","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":"+ printOrderList(menu: Menu, ui: Ui): void","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":"- aggregateOrder(order: Order, aggregatedOrder: ArrayList\u003cOrder\u003e): void","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":"- getIndexByDishName(aggregatedOrders: ArrayList\u003cOrder\u003e, dishName: String): int","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":"- calculateTotalCost(orders: ArrayList\u003cOrder\u003e): float","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":"class Sales {","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":"- HEADER_FORMAT: String","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":"- daysAccounted: int","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":"+ addOrderList(orderList: OrderList): void","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":"+ nextDay(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":"+ printSales(ui: Ui, menu Menu): void","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":"+ printSaleByDay(ui: Ui, menu: Menu, day: int): void","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":"class CurrentDate {","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":"- currentDay: int","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":"+ nextDay(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":"+ previousDay(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":"+ getCurrentDay(): int","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ShaniceTang"},"content":"class Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"ShaniceTang"},"content":"note bottom of Ui: Classes in ui package: \\nUi, Messages, and ErrorMessages","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"ShaniceTang"},"content":"Ingredient \"*\" \u003c--* \"1\" Dish : ingredients","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"ShaniceTang"},"content":"Dish \"*\" \u003c--* \"1\" Menu : menuItems","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"ShaniceTang"},"content":"Ingredient \"*\" \u003c--* \"1\" Pantry : pantryStock","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"ShaniceTang"},"content":"Dish \u003c.. Pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"ShaniceTang"},"content":"Chef \"1\" \u003c-- Pantry : pantry","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"ShaniceTang"},"content":"Pantry ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"ShaniceTang"},"content":"Chef ..\u003e Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"ShaniceTang"},"content":"Ingredient \"*\" \u003c--* \"1\" Order : ingredientList","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"ShaniceTang"},"content":"Order \"*\" \u003c--* \"1\" OrderList : orderList","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"ShaniceTang"},"content":"Order \"1\" \u003c-- Chef : order","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"ShaniceTang"},"content":"OrderList \"*\" \u003c--* \"1\" Sales : orderLists","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":104}},{"path":"docs/diagrams/class/ListMenuCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `list_menu` Command","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" UI","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- ListMenuCommand","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" ListMenuCommand","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"ListMenuCommand --\u003e Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"Menu -- \"*\" Dish","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"class UI {","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"+ showMenuTop() : void","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"+ showMenuBottom() : void","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"+ showEmptyMenu() : void","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"+ showMenuDish(indexNum : String, dishName : String, dishPrice : String) : void","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"class ListMenuCommand {","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"- menu : Menu","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"+ printEmptyMenu(ui : Ui) : void","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"+ printFullMenu(menu : Menu, ui : Ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, orderList : OrderList) : Command","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"{static} - prepareListMenu(menu : Menu, ui : Ui) : Command","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"class Menu {","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"- menuItems : ArrayList\u003cDish\u003e","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"+ getDishFromId(menuID : int) : Dish","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"class Dish {","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"- name : String","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":"- price : float","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":"+ getName() : String","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":"+ getPrice() : float","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Cazh1":60}},{"path":"docs/diagrams/class/NextDayCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `next_day` Command","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" UI","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"NextDayCommand ..\u003e OrderList : Creates \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"NextDayCommand --\u003e CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"NextDayCommand --\u003e Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"Sales --\u003e \"1...*\" OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"class UI {","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"+ showToUser() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"+ printLine() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"+ showNextDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"class NextDayCommand {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"- sales : Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"- currentDate : CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"{static} - prepareNextDay(ui : Ui, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"class OrderList {","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"- orderList : ArrayList\u003cOrder\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"class Sales {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"- orderLists : ArrayList\u003cOrderList\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"- daysAccounted : int","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":"+ getDaysAccounted() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":"+ addOrderList(orderList : OrderList)","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":"+ nextDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":"class CurrentDate {","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":"- currentDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":"+ getCurrentDay() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"+ nextDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":67}},{"path":"docs/diagrams/class/Parser.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"interface ParserUtil {","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":" +parseCommand(): Command","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"class Parser {","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" -{static}INPUT_REGEX: String","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" +parseCommand(): Command","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" -prepareXYZCommand(): Command","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" -parsePriceToFloat(priceText: String): float","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" -parseIngredient(ingredientsListString: String): ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"abstract class Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" +execute(): void","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":"class XYZCommand {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" +execute(): void","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"class Ui {","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" +showToUser(textToShow: String): void","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"CafeCtrl ..\u003e ParserUtil: use","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"XYZCommand --|\u003e Command","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"CafeCtrl ..\u003e Command: execute","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":"ParserUtil \u003c|.. Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"Parser ..\u003e XYZCommand: create","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"XYZCommand *-- data: use","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":"note left: Classes in data package: Dish, Ingredient, \\nCurrentData, Menu, Order, Pantry and Sales","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"Command *-- Ui: use","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ziyi105":34}},{"path":"docs/diagrams/class/PreviousDayCommandClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"title Class Diagram of CafeCtrl `previous_day` Command","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" Parser","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" --\u003e \"1\" CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"CafeCtrl \"1\" o-- \"*\" Command","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"Command \u003c|- PreviousDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"Parser \"1\" --\u003e \"*\" PreviousDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"PreviousDayCommand --\u003e CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"class CafeCtrl {","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"- setup()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"- run()","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":"+ main(args : String[])","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"class Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"class Ui {","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"- scanner : Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"+ receiveUserInput() : String","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":"+ showToUser() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":"+ printLine() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"+ showPreviousDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"class PreviousDayCommand {","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"- ui : Ui","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"- currentDate : CurrentDate","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"+ execute() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":"class Parser {","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"{static} + parseCommand(menu : Menu, userInput : String, ui : Ui, pantry : Pantry, sales : Sales, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"{static} - prepareNextDay(ui : Ui, currentDate : CurrentDate) : Command","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"class CurrentDate {","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"- currentDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"+ getCurrentDay() : int","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"+ previousDay() : void","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":51}},{"path":"docs/diagrams/class/Storage.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"class Storage {","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":" # fileManager: FileManager","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":" + loadMenu(): Menu","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":" - saveMenu(menu: Menu): void","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" + loadPantryStock(): Pantry","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" - savePantryStock(pantry: Pantry): void","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":" + loadOrderList(menu: menu): Sales","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" - saveOrderList(sales: Sales): void","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" + saveAll(menu: Menu, sales: Sales, pantry: Pantry): void","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":"class Data","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"note bottom of Data: Classes in data package: \\nMenu, Pantry and Sales","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"class Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"class FilePath {","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" + MENU_FILE_PATH: String","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" + PANTRY_STOCK_FILE_PATH: String","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" + ORDERS_FILE_PATH: String","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"class FileManager {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" + openTextFile(:FilePath): String","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" + readTextFile(:FilePath): ArrayList\u003cString\u003e): void","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" + overwriteFile(:FilePath, :ArrayList\u003cString\u003e): void","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":"class Decoder {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" + {static} decodeData(encodedData: ArrayList\u003cString\u003e): Data","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":" + {static} decodeSales(encodedOrderList: ArrayList\u003cString\u003e, menu: Menu): Data","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"note top of Decoder: decodeData function for\\nMenu and PantryStock data","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":"class Encoder {","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":" + {static} encodeData(data: Data): ArrayList\u003cString\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":"CafeCtrl *-- \"1\" Storage: initializes","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":"FileManager \"1\" --* Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":"Storage ..\u003e Data: stores \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":"Ui \"1\" --* FileManager : uses \u003c","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":"FileManager ..\u003e FilePath: reads from \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":"Encoder ..\u003e Data: encodes \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":"Decoder ..\u003e Data: decodes \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"DextheChik3n":53}},{"path":"docs/diagrams/class/Ui.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"class Ui {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"+ OFFSET_LIST_INDEX: int","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"- scanner: Scanner","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"+ receiveUserInput(): String","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"+ showToUser(message: String)","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"+ printAddDishMessage(dish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"+ printIngredients(selectedDish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"+ printDeleteMessage(selectedDish: Dish): void","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"+ showEditPriceMessage(menuItem: String): void","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"+ showHelp(): void","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"class Messages","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"class ErrorMessages","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"class Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"class Command","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"class Main","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"class Data","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"class Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"Messages \u003c. Ui : prints \u003c","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"Ui .\u003e ErrorMessages : prints \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"Parser ..\u003e Ui : uses \u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"*\" Command : ui","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"1\" Main : ui","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"*\" Data : ui","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"Ui \"1\" \u003c-- \"*\" Storage :ui","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":32}},{"path":"docs/diagrams/sequence/AddDishCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"autonumber","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"-\u003e AddDishCommand: execute()","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"activate AddDishCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"AddDishCommand -\u003e Menu: addDish(dish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"AddDishCommand -\u003e Ui: printAddDishMessage(dish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Dish: getName()","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":"activate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"Dish --\u003e Ui: dishNameString: String","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"deactivate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Dish: getPrice()","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"activate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"Dish --\u003e Ui: dishPrice: float","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":"deactivate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":"loop ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Ingredients: toString()","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"activate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"Ingredients --\u003e Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":"deactivate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"end loop","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":"Ui -\u003e Ui: showToUser(message: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"DextheChik3n":36}},{"path":"docs/diagrams/sequence/AddOrderCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"-\u003e \":AddOrderCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" activate \":AddOrderCommand\"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":OrderList\" : addOrder(order : Order)","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" activate \":OrderList\"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":Chef\" : new Chef(order : Order, pantry : Pantry, ui : Ui)","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" activate \":Chef\"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" return chef : Chef","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":Chef\" : cookDish()","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" activate \":Chef\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" opt !order.getIsComplete()","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Ui\" : showChefMessage()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Order\" : getIngredientList()","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" activate \":Order\"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" return :ArrayList\u003cIngredient\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Pantry\" : isDishCooked(:ArrayList\u003cIngredient\u003e)","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" activate \":Pantry\"","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" return isComplete : boolean","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Order\" : setComplete(isComplete : boolean)","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" activate \":Order\"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Ui\" : showOrderStatus(args : String)","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" \":Chef\" -\u003e \":Pantry\" : calculateDishAvailability(menu : Menu)","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" activate \":Pantry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" opt order.getIsComplete()","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" \":AddOrderCommand\" -\u003e \":OrderList\" : addCost(order : Order)","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" activate \":OrderList\"","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":49}},{"path":"docs/diagrams/sequence/Architecture_Encode_Data.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"!define COMMAND class ListIngredientCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"!define UI class Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"!define MAIN class Main","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"!define STORAGE class Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"!define DATA class Data","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"!define PARSER class Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"!define COMMAND class Command","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"autonumber","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":"Actor user","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"loop userInput !\u003d \"bye\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":"user-\u003eUi : \u0027delete 1\u0027","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":"activate Ui","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":"Ui-\u003e Main : userInput : String","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"activate Main","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"Main -\u003e Parser : parseCommand()","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"Activate Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":"Parser -\u003e Main : command: Command","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":"Deactivate Parser","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":"Main -\u003e Command : delete.execute()","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":"Activate Command","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"Command -\u003e Data : menu.remove()","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":"Activate Data","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":"user -\u003e Ui: \u0027bye\u0027","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"Ui-\u003e Main : userInput : String","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":"end loop","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":"Main-\u003eStorage : saveMenu()","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":"Activate Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"NaychiMin"},"content":"Storage -\u003e Storage: encodeMenu()","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"Activate Storage","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":"return","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"NaychiMin":40}},{"path":"docs/diagrams/sequence/DeleteDishCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"!define COMMAND class ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"!define UI class Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"!define MENU class Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"autonumber","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"-\u003e DeleteDishCommand : execute()","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"activate DeleteDishCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"DeleteDishCommand -\u003e Menu : getMenuItemsList().get(dishIndexToBeDeleted: int)","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"return (selectedDish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"DeleteDishCommand -\u003e Ui : showDeleteMessage(selectedDish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":"Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"DeleteDishCommand -\u003e Menu : removeDish(dishIndexToBeDeleted: int)","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":"return","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"ShaniceTang":26}},{"path":"docs/diagrams/sequence/EditPriceCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"autonumber","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"participant \":Main\" as Main","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"participant \":EditPriceCommand\" as EditPriceCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"participant \":Menu\" as Menu","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"participant \":Dish\" as Dish","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"participant \":Ui\" as Ui","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"participant \":Messages\" as Messages","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"Main -\u003e EditPriceCommand: execute()","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"activate EditPriceCommand","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"EditPriceCommand -\u003e Menu:getDishFromId(menuID: int)","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"activate Menu","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"Menu --\u003e EditPriceCommand: (dish: Dish)","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"deactivate Menu","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":"EditPriceCommand -\u003e Dish: setPrice(newPrice: float)","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"activate Dish","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"EditPriceCommand -\u003e Ui: showEditPriceMessages(dishString: String)","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"deactivate Dish","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"activate Messages","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"Ui -\u003e Messages: + PRICE_MODIFIED_MESSAGE: String","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"Messages --\u003e Ui: \"Price modified for the following dish: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"deactivate Messages","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"Ui -\u003e Ui: showToUser(\"Price modified for the following dish: \", dishString: String)","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":"deactivate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"deactivate EditPriceCommand","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"deactivate Dish","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ziyi105":32}},{"path":"docs/diagrams/sequence/HelpCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"autonumber","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"Main -\u003e HelpCommand: execute()","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"activate HelpCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"HelpCommand -\u003e Ui: showHelp()","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"Ui -\u003e Ui: showToUserWithSpaceBetweenLines(messages: String...)","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"activate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"deactivate Ui","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ziyi105":14}},{"path":"docs/diagrams/sequence/ListIngredientCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"!define COMMAND class ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"!define UI class Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"!define MENU class Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"!define DISH class Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"!define PARSER class Parser","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"autonumber","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" -\u003e ListIngredientCommand: execute()","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":"activate ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"ListIngredientCommand -\u003e Menu : getMenuItemsList()","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"activate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":"Menu --\u003e ListIngredientCommand: selectedDish : Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":"deactivate Menu","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"ListIngredientCommand -\u003e Ui : printIngredients(selectedDish: Dish)","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"Ui -\u003e Dish : selectedDish.getIngredients()","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":"activate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":"Dish --\u003e Ui : ingredients: Ingredient","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":"deactivate Dish","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":"loop ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"Ui -\u003e Ingredients: ingredient.toString()","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":"activate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":"Ingredients --\u003e Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"deactivate Ingredients","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":"end loop","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":"Ui -\u003e Ui: showToUser(message: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"NaychiMin"},"content":"activate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"Ui --\u003e Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":"deactivate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":"Ui --\u003e ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":"deactivate Ui","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":"deactivate ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"NaychiMin"},"content":"\u003c-- ListIngredientCommand","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"NaychiMin"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"NaychiMin":41}},{"path":"docs/diagrams/sequence/ListMenuCommandSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"hide footbox","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"activate \": CafeCtrl\"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"\": CafeCtrl\" -\u003e \"Ui\" : receiveUserInput()","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"\"Ui\" --\u003e \": CafeCtrl\" : userInput : String","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"deactivate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"\": CafeCtrl\" -\u003e \"Parser\" : Parser.parseCommand(userInput)","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"activate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"alt commandWord","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \"Parser\" -\u003e \"Parser\" : prepareListMenu(menu, ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \"Parser\" --\u003e \": CafeCtrl\" : new ListMenuCommand(menu, ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" deactivate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"else other command","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"\": CafeCtrl\" --\u003e \"ListMenuCommand\" : execute()","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" activate \"ListMenuCommand\"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" alt menu.getSize() \u003d\u003d 0","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"ListMenuCommand\" : printEmptyMenu(ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : showToUser(MENU_EMPTY_MESSAGE : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" else","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"ListMenuCommand\" : printFullMenu(menu, ui)","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : showToUser(MENU_FULL_MESSAGE : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" loop Dish : Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Menu\" : getDishFromId(id)","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" activate Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" \"Menu\" --\u003e \"ListMenuCommand\" : (selectedDish : Dish)","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" deactivate Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Dish\" : selectedDish.getName()","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" activate \"Dish\"","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" \"Dish\" --\u003e \"ListMenuCommand\" : (dishName : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Dish\" : selectedDish.getPrice()","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" \"Dish\" --\u003e \"ListMenuCommand\" : (dishPrice : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" deactivate \"Dish\"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : formatListMenu(indexNum + \". \" + dishName,\" $\" + dishPrice)","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" \"ListMenuCommand\" --\u003e \"Ui\" : showToUser(MENU_FULL_END_MESSAGE : String)","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" activate \"Ui\"","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" Ui -\u003e Ui : showToUser(message: String)","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" activate Ui","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":"\"Parser\" --\u003e \": CafeCtrl\" : command : Command","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"deactivate \"Parser\"","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":"else other command","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":"deactivate \": CafeCtrl\"","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Cazh1":72}},{"path":"docs/diagrams/sequence/ListMenuCommand_executeSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"-\u003e \":ListMenuCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" activate \":ListMenuCommand\"","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" alt menu.getSize() \u003d\u003d 0","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":ListMenuCommand\" : printEmptyMenu(ui)","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showEmptyMenu()","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" else","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":ListMenuCommand\" : printFullMenu(menu, ui)","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showMenuTop()","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" loop Dish : Menu","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Menu\" : getDishFromId(id)","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" activate \":Menu\"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" \":Menu\" --\u003e \":ListMenuCommand\" : (selectedDish : Dish)","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" deactivate \":Menu\"","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Dish\" : selectedDish.getName()","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" activate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" \":Dish\" --\u003e \":ListMenuCommand\" : (dishName : String)","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" deactivate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Dish\" : selectedDish.getPrice()","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" activate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" \":Dish\" --\u003e \":ListMenuCommand\" : (dishPrice : String)","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" deactivate \":Dish\"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showMenuDish()","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" \":ListMenuCommand\" -\u003e \":Ui\" : showMenuBottom() : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(message: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Cazh1":55}},{"path":"docs/diagrams/sequence/NextDayCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"-\u003e \":NextDayCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" activate \":NextDayCommand\"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Ui\" : printLine()","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":CurrentDate\" : nextDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" activate \":CurrentDate\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":CurrentDate\" : getCurrentDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \":CurrentDate\"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" return nextDay : int","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Sales\" : getDaysAccounted()","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" activate \":Sales\"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" return daysAccounted : int","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" opt nextDay \u003e daysAccounted","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":OrderList\" : new OrderList()","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" activate \":OrderList\"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" return newOrderList : OrderList","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Sales\" : addOrderList(newOrderList)","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" activate \":Sales\"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Sales\" : nextDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" activate \":Sales\"","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" end","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Ui\" : showNextDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" \":NextDayCommand\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":44}},{"path":"docs/diagrams/sequence/Parser.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"actor User","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"Participant \":Main\" as Main","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"Participant \":Parser\" as Parser","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"Participant \":XYZCommand\" as XYZCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"User -\u003e Main: fullUserInput: String","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"activate Main","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"Main -\u003e Parser: parseCommand(fullUserInput: String)","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"activate Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"alt XYZCOMMAND_WORD","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"Parser -\u003e Parser: prepareXYZCommand(requiredArguments)","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"activate Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"Parser -\u003e XYZCommand: XYZCommand(requiredArguments)","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":"activate XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"XYZCommand --\u003e Parser: XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"deactivate XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"deactivate Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"end alt","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":"Parser --\u003e Main: XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"deactivate Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":"Main -\u003e XYZCommand: execute()","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"activate XYZCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ziyi105":28}},{"path":"docs/diagrams/sequence/PreviousDayCommand_execute.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"@startuml","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"autonumber","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"-\u003e \":PreviousDayCommand\" : execute()","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" activate \":PreviousDayCommand\"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":Ui\" : printLine()","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":CurrentDate\" : previousDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" activate \":CurrentDate\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":Ui\" : showPreviousDay()","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" \":Ui\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" \":PreviousDayCommand\" -\u003e \":Ui\" : showToUser(args : String)","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" activate \":Ui\"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" return","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"return","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Cazh1":27}},{"path":"src/main/java/seedu/cafectrl/CafeCtrl.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.parser.Parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.parser.ParserUtil;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.storage.Storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" * CafeCtrl application\u0027s entry point.","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" * Initializes the application and starts the interaction with the user.","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"public class CafeCtrl {","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" private Menu menu;","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" private Command command;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" private Pantry pantry;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" private Sales sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" private CurrentDate currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" private Storage storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" * Private constructor for the CafeCtrl class, used for initializing the user interface and menu list.","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" private CafeCtrl() {","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d new Ui();","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" this.storage \u003d new Storage(this.ui);","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" this.sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" this.menu \u003d this.storage.loadMenu();","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" this.pantry \u003d this.storage.loadPantryStock();","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":" this.sales \u003d this.storage.loadOrderList(menu);","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" this.currentDate \u003d new CurrentDate(sales);","lastModifiedDate":"2023-11-05"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":" ","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":" * The main loop of the CafeCtrl application.","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"DextheChik3n"},"content":" * \u003cp\u003e This method consistently receives user input, parses commands, and executes the respective command","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":" * until the user enters a \"bye\" command, terminating the application.\u003c/p\u003e","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" private void run() {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" ui.showWelcome();","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" ui.printLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" do {","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" String fullUserInput \u003d ui.receiveUserInput();","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" command \u003d parserUtil.parseCommand(menu, fullUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" command.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" } finally {","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"DextheChik3n"},"content":" ui.printLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":" } while (!command.isExit());","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"ziyi105"},"content":" this.storage.saveAll(this.menu, this.sales, this.pantry);","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"DextheChik3n"},"content":" public static void main(String[] args) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" CafeCtrl cafeCtrl \u003d new CafeCtrl();","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" cafeCtrl.run();","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"NaychiMin":1,"DextheChik3n":50,"Cazh1":9,"ziyi105":10,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/command/AddDishCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"//@@author DextheChik3n","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" * Adds a menu item to the user","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"public class AddDishCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" public static final String COMMAND_WORD \u003d \"add\";","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" public static final String MESSAGE_USAGE \u003d \"To add a new dish to the menu: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" + COMMAND_WORD + \" name/DISH_NAME price/DISH_PRICE ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY\"","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" + \"[, ingredient/INGREDIENT2_NAME, qty/INGREDIENT2_QTY...]\\n\"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" + \"Example:\"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" + COMMAND_WORD + \" name/chicken rice price/3.00 ingredient/rice qty/200g, ingredient/chicken qty/100g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" private final Dish dish;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" public AddDishCommand(Dish dish, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" this.dish \u003d dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" ui.printAddDishMessage(dish);","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":31,"Cazh1":1}},{"path":"src/main/java/seedu/cafectrl/command/AddOrderCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Chef;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"public class AddOrderCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"add_order\";","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To add a new order: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \" name/DISH_NAME qty/QUANTITY\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" + \"name/chicken rice qty/2\";","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" protected OrderList orderList;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" protected Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" private final Order order;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" public AddOrderCommand(Order order, Ui ui, Pantry pantry, OrderList orderList, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" this.order \u003d order;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" this.orderList \u003d orderList;","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" orderList.addOrder(order);","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" Chef chef \u003d new Chef(order, pantry, ui, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" chef.cookDish();","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" if (order.getIsComplete()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" orderList.addCost(order);","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"NaychiMin":7,"Cazh1":32,"ziyi105":3}},{"path":"src/main/java/seedu/cafectrl/command/BuyIngredientCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"//@@author ShaniceTang","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":" * The BuyIngredientCommand class represents a command to buy ingredients and add them to the pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":" * It executes the command, adds the ingredients, and displays the results to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"public class BuyIngredientCommand extends Command {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" public static final String COMMAND_WORD \u003d \"buy_ingredient\";","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" public static final String MESSAGE_USAGE \u003d \"\\nTo buy ingredient:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" + COMMAND_WORD + \" ingredient/INGREDIENT1_NAME qty/INGREDIENT1_QTY\"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" + \"[, ingredient/INGREDIENT2_NAME, qty/INGREDIENT2_QTY...]\\n\"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" + \"Example:\"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" + COMMAND_WORD + \" ingredient/rice qty/200g, ingredient/chicken qty/100g\";","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" private ArrayList\u003cIngredient\u003e ingredients;","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" private String ingredientString \u003d \"\"; // Used to store the message about the bought ingredients","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" * Constructs a BuyIngredientCommand with the specified ingredients, user interface, and pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredients The list of ingredients to be bought and added to the pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" * @param ui The user interface to interact with the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" * @param pantry The pantry to which the ingredients will be added.","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" public BuyIngredientCommand(ArrayList\u003cIngredient\u003e ingredients, Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" this.ingredients \u003d ingredients;","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" * Executes the command to buy ingredients, adds them to the pantry, and displays the results to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" addIngredient();","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" ui.printBuyIngredientHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(ingredientString);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" } catch (RuntimeException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" * Adds the specified ingredients to the pantry.","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" * This method is called during command execution.","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" private void addIngredient() {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":" for(int i \u003d 0; i \u003c ingredients.size(); i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" Ingredient ingredient \u003d ingredients.get(i);","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":" ingredient \u003d pantry.addIngredientToStock(ingredient.getName(),","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" ingredient.getQty(),","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":" ingredient.getUnit());","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":" buildBuyIngredientMessage(ingredient, i);","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":" * Builds a message about the bought ingredient and appends it to the result message.","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredient The Ingredient object to build the message for.","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" * @param index The index of the ingredient in the list.","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":" private void buildBuyIngredientMessage(Ingredient ingredient, int index) {","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":" ingredientString +\u003d \"Ingredient: \" + ingredient.getName()","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":" + \"\\t\\tQty: \" + ingredient.getQty()","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"ShaniceTang"},"content":" + ingredient.getUnit();","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":" //append new line if current ingredient is not last","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":" if(index \u003c ingredients.size() - ui.OFFSET_LIST_INDEX) {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":" ingredientString +\u003d \"\\n\";","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ShaniceTang":85}},{"path":"src/main/java/seedu/cafectrl/command/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":" * Represents an executable command.","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"public class Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":" public int index;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" public void setIndex(int index) {","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" this.index \u003d index;","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" * check whether this command is an exit command (user input \"bye\")","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" * default returns false, this method will be overridden in ExitCommand","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" public boolean isExit() {","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" * Executes the command and returns the result.","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" throw new UnsupportedOperationException(\"This method is to be implemented by child classes\");","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"NaychiMin":1,"DextheChik3n":10,"Cazh1":17}},{"path":"src/main/java/seedu/cafectrl/command/DeleteDishCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" * Deletes a menu item identified using it\u0027s last displayed index from the menu.","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"public class DeleteDishCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" public static final String COMMAND_WORD \u003d \"delete\";","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To delete a menu item:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" + \"Parameters: INDEX\\n\"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Example: \" + COMMAND_WORD + \" 1\";","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" public DeleteDishCommand(int listIndex, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" this.index \u003d listIndex;","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" int dishIndexToBeDeleted \u003d index - Ui.OFFSET_LIST_INDEX;","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" Dish selectedDish \u003d menu.getMenuItemsList().get(dishIndexToBeDeleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" ui.printDeleteMessage(selectedDish);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" menu.removeDish(dishIndexToBeDeleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.INVALID_DISH_INDEX);","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" throw new IndexOutOfBoundsException();","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":4,"Cazh1":17,"ziyi105":6,"ShaniceTang":12}},{"path":"src/main/java/seedu/cafectrl/command/EditPriceCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" * Edit the price of a dish of a certain index","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"public class EditPriceCommand extends Command {","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" public static final String COMMAND_WORD \u003d \"edit_price\";","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To edit price of a menu item: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + \"edit_price index/DISH_INDEX price/NEW_PRICE\\n\"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \"Example: edit_price index/1 price/4.50\";","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" private final int menuID;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" private final float newPrice;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" public EditPriceCommand(int menuID, float newPrice, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" this.menuID \u003d menuID;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" this.newPrice \u003d newPrice;","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" * Set new price of the dish and show edit price message","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" Dish dish \u003d menu.getDishFromId(this.menuID - Ui.OFFSET_LIST_INDEX);","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" dish.setPrice(this.newPrice);","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":" ui.showEditPriceMessage(dish.toString());","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"ziyi105":38}},{"path":"src/main/java/seedu/cafectrl/command/ExitCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"public class ExitCommand extends Command {","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"bye\";","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To exit:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" public ExitCommand(Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" * Overrides the isExit() method which returns false","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" * @return true","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":" public boolean isExit() {","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" ui.printLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":" ui.showGoodbye();","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":16,"Cazh1":15,"ziyi105":2,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/command/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" public static final String COMMAND_WORD \u003d \"help\";","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To view all commands:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public HelpCommand(Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" ui.printLine();","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" ui.showHelp();","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"ziyi105":22}},{"path":"src/main/java/seedu/cafectrl/command/IncorrectCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":" * Represents an incorrect command. Upon execution, produces some feedback to the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"public class IncorrectCommand extends Command{","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" public IncorrectCommand(String feedbackToUser, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" ui.showToUser(feedbackToUser);","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":3,"Cazh1":18}},{"path":"src/main/java/seedu/cafectrl/command/ListIngredientCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" * Lists all ingredients used in the selected dish to the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"public class ListIngredientCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"list_ingredients\";","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To list out the ingredients needed \"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" + \"along with the quantity for a specific dish:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \"Parameters: DISH_INDEX\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Example: \" + COMMAND_WORD + \" 1\";","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" protected Menu menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" public ListIngredientCommand(int listIndex, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" this.index \u003d listIndex;","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" Dish selectedDish \u003d menu.getMenuItemsList().get(index - Ui.OFFSET_LIST_INDEX);","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" ui.printIngredients(selectedDish);","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" throw new IllegalArgumentException(ErrorMessages.INVALID_DISH_INDEX);","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"NaychiMin":10,"DextheChik3n":4,"Cazh1":17,"ziyi105":5}},{"path":"src/main/java/seedu/cafectrl/command/ListMenuCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" * Lists all dishes in the menu to the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"public class ListMenuCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"list_menu\";","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To view menu:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" private final Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" * Constructor for the ListMenuCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" * @param menu The menu object of the current session","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" public ListMenuCommand(Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" * Iterates through the menu arraylist, outputting the dish name and dish price.","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" * Calls printEmptyMenu() when (menu.getSize() \u003d\u003d 0), printFullMenu() otherwise.","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" if (menu.getSize() \u003d\u003d 0) {","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" printEmptyMenu(ui);","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" } else {","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" printFullMenu(menu, ui);","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" * Shows empty menu message to user","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" * Called only when the menu is empty","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" public void printEmptyMenu(Ui ui) {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" ui.showEmptyMenu();","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" * Prints the dishes in the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" * Called only when the menu is not empty","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" * @param menu The menu object of the current session","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" public void printFullMenu(Menu menu, Ui ui) {","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" ui.showMenuTop();","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" for (int i \u003d 0; i \u003c menu.getSize(); i++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" String indexNum \u003d String.valueOf(i + 1);","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" Dish selectedDish \u003d menu.getDishFromId(i);","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":" String dishName \u003d selectedDish.getName();","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":" String dishPrice \u003d dollarValue.format(selectedDish.getPrice());","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" ui.showMenuDish(indexNum, dishName, dishPrice);","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":" ui.showMenuBottom();","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":3,"Cazh1":68,"ziyi105":1,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/command/NextDayCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"public class NextDayCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"next_day\";","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To travel to next day:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" private final Sales sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" private final CurrentDate currentDate;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public NextDayCommand(Ui ui, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" this.sales \u003d sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" this.currentDate \u003d currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" * Changes the current day to the next day.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" * Checks if an orderList exist in Sales by comparing","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" * the intended Day vs the number of days accounted for in Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" * If orderList does not exist, new OrderList is added to Sales","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" * The days accounted for in Sales is incremented","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" ui.printLine();","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" currentDate.nextDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" int nextDay \u003d currentDate.getCurrentDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" if (nextDay \u003e sales.getDaysAccounted()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" OrderList newOrderList \u003d new OrderList();","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" sales.addOrderList(newOrderList);","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" sales.nextDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" ui.showNextDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" ui.showToUser(\"Today is Day \" + (currentDate.getCurrentDay() + 1));","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Cazh1":43,"ziyi105":2}},{"path":"src/main/java/seedu/cafectrl/command/PreviousDayCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"public class PreviousDayCommand extends Command{","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":" public static final String COMMAND_WORD \u003d \"previous_day\";","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To go back to previous day:\\n\" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" protected CurrentDate currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" public PreviousDayCommand(Ui ui, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" this.currentDate \u003d currentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" ui.printLine();","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" currentDate.previousDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" ui.showPreviousDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" ui.showToUser(\"Today is Day \" + (currentDate.getCurrentDay() + 1));","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Cazh1":24,"ziyi105":1}},{"path":"src/main/java/seedu/cafectrl/command/ShowSalesByDayCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"public class ShowSalesByDayCommand extends Command {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":" public static final String COMMAND_WORD \u003d \"show_sale\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" public static final String MESSAGE_USAGE \u003d \"To show sales for a chosen day:\\n \"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":" + \"Command Format:\" + COMMAND_WORD + \" day/DAY_TO_DISPLAY\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" + \"Example: \" + COMMAND_WORD + \" day/1\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":" private final int day;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" private final Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" private final Sales sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" private final Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" public ShowSalesByDayCommand(int day, Ui ui, Sales sales, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" this.day \u003d day;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" this.sales \u003d sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" public void execute() {","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" sales.printSaleByDay(ui, menu, day);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"NaychiMin":29}},{"path":"src/main/java/seedu/cafectrl/command/ShowSalesCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"public class ShowSalesCommand extends Command {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":" public static final String COMMAND_WORD \u003d \"show_sales\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" public static final String MESSAGE_USAGE \u003d \"To show sales for all days:\\n\" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":" private Sales sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" private Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" public ShowSalesCommand(Sales sales, Ui ui, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" this.sales \u003d sales;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" public void execute() {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" sales.printSales(ui, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"NaychiMin":24}},{"path":"src/main/java/seedu/cafectrl/command/ViewTotalStockCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"public class ViewTotalStockCommand extends Command {","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":" public static final String COMMAND_WORD \u003d \"view_stock\";","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" public static final String MESSAGE_USAGE \u003d \"To view pantry stock:\\n\" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" protected Ui ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" protected Pantry pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" private ArrayList\u003cIngredient\u003e pantryStock;","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public ViewTotalStockCommand(Pantry pantry, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" public void execute() {","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(Messages.VIEW_STOCK);","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" pantryStock \u003d pantry.getPantryStock();","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" for (Ingredient ingredient : pantryStock) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(ingredient.getName() + \"\\t\\t\\t\" + ingredient.getQty() + ingredient.getUnit());","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"Cazh1":6,"ziyi105":1,"ShaniceTang":25}},{"path":"src/main/java/seedu/cafectrl/data/Chef.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"public class Chef {","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" private final Order order;","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" private final Pantry pantry;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private Menu menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":" private final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" public Chef(Order order, Pantry pantry, Ui ui, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" this.order \u003d order;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" this.pantry \u003d pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" this.menu \u003d menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" public void cookDish() {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" try {","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" if (!order.getIsComplete()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" ui.showChefMessage();","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" boolean isComplete \u003d pantry.isDishCooked(order.getIngredientList());","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" order.setComplete(isComplete);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" String orderStatus \u003d order.getIsComplete() ? Messages.COMPLETE_ORDER : Messages.INCOMPLETE_ORDER;","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" String totalCost \u003d dollarValue.format(order.getTotalOrderCost());","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" ui.showOrderStatus(orderStatus, totalCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" pantry.calculateDishAvailability(menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"NaychiMin":16,"Cazh1":23}},{"path":"src/main/java/seedu/cafectrl/data/CurrentDate.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-05"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"public class CurrentDate {","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":" private int currentDay;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":" public CurrentDate() {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":" currentDay \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" public CurrentDate(Sales sales) {","lastModifiedDate":"2023-11-05"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":" setDate(sales);","lastModifiedDate":"2023-11-05"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-05"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public void nextDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" currentDay +\u003d 1;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public void previousDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" currentDay -\u003d 1;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" public int getCurrentDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" return currentDay;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-11-05"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" * Sets the current date to the latest date the user left off","lastModifiedDate":"2023-11-05"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-11-05"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" * @param sales Used to access the number of orderlist created","lastModifiedDate":"2023-11-05"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-11-05"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" public void setDate(Sales sales) {","lastModifiedDate":"2023-11-05"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cOrderList\u003e orderLists \u003d sales.getOrderLists();","lastModifiedDate":"2023-11-05"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" int orderListsSize \u003d orderLists.size();","lastModifiedDate":"2023-11-05"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" currentDay \u003d orderListsSize - 1;","lastModifiedDate":"2023-11-05"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-05"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Cazh1":37}},{"path":"src/main/java/seedu/cafectrl/data/Menu.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"public class Menu {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" private ArrayList\u003cDish\u003e menuItems;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" public Menu() {","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" this.menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" public Menu(ArrayList\u003cDish\u003e menuItems) {","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" this.menuItems \u003d menuItems;","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" public ArrayList\u003cDish\u003e getMenuItemsList() {","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" return menuItems;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" public int getSize() {","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" return menuItems.size();","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" public Dish getDishFromId(int menuID) {","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" return menuItems.get(menuID);","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" * Checks if the ordered dish exist in the menu and returns the menu index if exist","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" * @param dishName Name of the ordered dish","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" * @return index of the dish in menu if exists, null if not found","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" public Dish getDishFromName(String dishName) {","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" String formattedDishName \u003d dishName.toLowerCase().trim();","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" for (int i \u003d 0; i \u003c getSize(); i++) {","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" String menuDishName \u003d getDishFromId(i).getName();","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" String formattedMenuDishName \u003d menuDishName.toLowerCase().trim();","lastModifiedDate":"2023-10-24"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" if (formattedMenuDishName.equals(formattedDishName)){","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" return getDishFromId(i);","lastModifiedDate":"2023-10-24"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" return null;","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" public void removeDish(int menuID) {","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" menuItems.remove(menuID);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" public void addDish(Dish dish) {","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" menuItems.add(dish);","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" public boolean isValidDishIndex(int dishIndex) {","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":" int offSetDishIndex \u003d dishIndex - Ui.OFFSET_LIST_INDEX;","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":" return offSetDishIndex \u003e\u003d 0 \u0026\u0026 offSetDishIndex \u003c this.getSize();","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" * Retrieves an ArrayList of Order objects representing aggregated orders for each menu item.","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" * Each Order object is initialized with a dish from the menu and a quantity of 0.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" * Used in the print_sales function under Sales class.","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" * @return An ArrayList of Order objects representing aggregated orders for each menu item.","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"NaychiMin"},"content":" public ArrayList\u003cOrder\u003e getAggregatedOrders() {","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrder\u003e aggregatedOrders \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":" for (int i \u003d 0; i \u003c menuItems.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":" Order order \u003d new Order(menuItems.get(i), 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrders.add(order);","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":" return aggregatedOrders;","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"NaychiMin":22,"DextheChik3n":17,"Cazh1":19,"ziyi105":16}},{"path":"src/main/java/seedu/cafectrl/data/Order.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"public class Order {","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" private final Dish orderedDish;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private int dishQty;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" private final ArrayList\u003cIngredient\u003e ingredientList;","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" private boolean isComplete \u003d false;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" private float totalOrderCost;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" public Order(Dish orderedDish, int dishQty) {","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" this.dishQty \u003d dishQty;","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.orderedDish \u003d orderedDish;","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" this.ingredientList \u003d setIngredientList();","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" this.totalOrderCost \u003d calculateTotalOrderCost();","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":" public Order(Dish orderedDish, int dishQty, float orderCost, boolean isComplete) {","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" this.dishQty \u003d dishQty;","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" this.orderedDish \u003d orderedDish;","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" this.ingredientList \u003d setIngredientList();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" this.totalOrderCost \u003d orderCost;","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" this.isComplete \u003d isComplete;","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" return \"Order: \" + getDishName() + \" Quantity: \"+ dishQty","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" + \"\\nIngredientList: \" + ingredientList","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" + \"\\nTotal Order Cost: $\" + dollarValue.format(totalOrderCost);","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-24"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" * Calculates the total price of the order","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" * Multiplies cost per dish by number of dishes","lastModifiedDate":"2023-10-24"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" * @return Total calculated cost","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" public float calculateTotalOrderCost() {","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" float dishCost \u003d orderedDish.getPrice();","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" return dishCost * dishQty;","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" * Gets and prepares the ingredients used in the dish.","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" * Calculates the total ingredient used and stores in an Ingredient ArrayList","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" * @return Arraylist of Ingredients","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" private ArrayList\u003cIngredient\u003e setIngredientList() {","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e dishIngredient \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" for (Ingredient ingredient : orderedDish.getIngredients()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" String ingredientName \u003d ingredient.getName();","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" int ingredientQty \u003d ingredient.getQty() * dishQty;","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" String ingredientUnit \u003d ingredient.getUnit();","lastModifiedDate":"2023-10-24"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" dishIngredient.add(new Ingredient(ingredientName, ingredientQty, ingredientUnit));","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" return dishIngredient;","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":" public ArrayList\u003cIngredient\u003e getIngredientList() {","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" return ingredientList;","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" public float getTotalOrderCost() {","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":" return totalOrderCost;","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" public void setComplete(boolean isComplete) {","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" this.isComplete \u003d isComplete;","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":" public boolean getIsComplete() {","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":" return isComplete;","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" public String getDishName() {","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" return orderedDish.getName();","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" public int getQuantity() {","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" return dishQty;","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" public void setQuantity(int quantity) {","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" this.dishQty \u003d quantity;","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" public void setTotalOrderCost(float cost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" this.totalOrderCost \u003d cost;","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"NaychiMin":31,"Cazh1":66,"ShaniceTang":2}},{"path":"src/main/java/seedu/cafectrl/data/OrderList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" * The OrderList class represents a list of orders for a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":" * It manages the collection of orders and calculates the total cost for the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"public class OrderList {","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" private static final String HEADER_FORMAT \u003d \"%-20s %-10s %-20s\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" private ArrayList\u003cOrder\u003e orderList;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" private float totalOrderListCost;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" * Constructs an empty OrderList with no orders and zero total order cost.","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" public OrderList() {","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" this.orderList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.totalOrderListCost \u003d 0;","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" public ArrayList\u003cOrder\u003e getOrderList() {","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" return orderList;","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" public int getSize() {","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" return orderList.size();","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" public void addOrder(Order order) {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" orderList.add(order);","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" public void addCost(Order order) {","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" float orderCost \u003d order.getTotalOrderCost();","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" totalOrderListCost +\u003d orderCost;","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"NaychiMin"},"content":" * Prints the order list for a specific day, including dish names, quantities, and total cost prices.","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" public void printOrderList(Menu menu, Ui ui) {","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrder\u003e aggregatedOrders \u003d menu.getAggregatedOrders();","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":" if (orderList.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"No sales for this day.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" for (Order order : getOrderList()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" aggregateOrder(order, aggregatedOrders);","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" for (Order aggregatedOrder : aggregatedOrders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(String.format(HEADER_FORMAT,","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrder.getDishName(),","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrder.getQuantity(),","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrder.calculateTotalOrderCost()));","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Total for day: $\" + dollarValue.format(calculateTotalCost(aggregatedOrders)));","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":" * Aggregates orders by updating quantities and total order costs for the same dish.","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":" * @param order The Order object to be aggregated.","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" * @param aggregatedOrders The ArrayList of aggregated orders.","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"NaychiMin"},"content":" private void aggregateOrder(Order order, ArrayList\u003cOrder\u003e aggregatedOrders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" if (order.getIsComplete()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" int index \u003d getIndexByDishName(aggregatedOrders, order.getDishName());","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrders.get(index).setQuantity(aggregatedOrders.get(index).getQuantity()","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" + order.getQuantity());","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":" aggregatedOrders.get(index).setTotalOrderCost(aggregatedOrders.get(index).getTotalOrderCost()","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" + order.getTotalOrderCost());","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" * Finds the index of an order in the aggregated orders list based on the dish name.","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" * @param aggregatedOrders The ArrayList of aggregated orders.","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" * @param dishName The dish name to search for.","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" * @return The index of the order with the specified dish name, or -1 if not found.","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" private int getIndexByDishName(ArrayList\u003cOrder\u003e aggregatedOrders, String dishName) {","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" for (int i \u003d 0; i \u003c aggregatedOrders.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" Order order \u003d aggregatedOrders.get(i);","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" String orderDishName \u003d order.getDishName().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" dishName \u003d dishName.trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" if (orderDishName.equalsIgnoreCase(dishName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" return i;","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":" return -1;","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":" * Calculates the total cost of all orders for a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" * @param orders The ArrayList of orders.","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":" * @return The total cost of all orders for the day.","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" private float calculateTotalCost(ArrayList\u003cOrder\u003e orders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":" float totalCost \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" for (Order order : orders) {","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"NaychiMin"},"content":" totalCost +\u003d order.getTotalOrderCost();","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"NaychiMin"},"content":" return totalCost;","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"NaychiMin":87,"Cazh1":30}},{"path":"src/main/java/seedu/cafectrl/data/Pantry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"NaychiMin"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"public class Pantry {","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":" private ArrayList\u003cIngredient\u003e pantryStock;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private Ui ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":" public Pantry(Ui ui, ArrayList\u003cIngredient\u003e pantryStock) {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":" this.pantryStock \u003d pantryStock;","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" public Pantry(Ui ui) {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" this.pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" * Retrieves the current pantry stock from storage, which may include reading from a file (pantry.txt).","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" * @return An ArrayList of Ingredient objects representing the current pantry stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" public ArrayList\u003cIngredient\u003e getPantryStock() {","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" return pantryStock;","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" * Adds or updates an ingredient in the pantry stock based on its name and quantity.","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" * @param name The name of the ingredient to add or update.","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" * @param qty The quantity of the ingredient (e.g., \"100g\").","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" * @param unit The unit of measurement for the quantity.","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" * @return The Ingredient object that was added or updated in the pantry stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" public Ingredient addIngredientToStock (String name, int qty, String unit) {","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" pantryStock \u003d getPantryStock(); //get latest pantry stock from pantry.txt","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" int ingredientIndex \u003d getIndexOfIngredient(name);","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" //if ingredient exists in pantry, add quantity of that ingredient","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" if (ingredientIndex !\u003d -1) {","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" return addIngredientQuantity(qty, ingredientIndex, unit);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" //else, add new ingredient to pantry","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" Ingredient ingredient \u003d new Ingredient(name, qty, unit);","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" pantryStock.add(ingredient);","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" return ingredient;","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":" * Updates an ingredient\u0027s quantity in the pantry stock or adds a new ingredient if it doesn\u0027t exist.","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":" * @param qty The quantity of the ingredient (e.g., \"100g\").","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredientIndex The index of the ingredient in the pantry stock (-1 if not found).","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":" * @return The Ingredient object that was added or updated in the pantry stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":" private Ingredient addIngredientQuantity(int qty, int ingredientIndex, String unit) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":" Ingredient ingredient \u003d pantryStock.get(ingredientIndex);","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":" if (!unit.equalsIgnoreCase(ingredient.getUnit())) {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":" throw new RuntimeException(ErrorMessages.UNIT_NOT_MATCHING","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":" + \"\\nUnit used previously: \" + ingredient.getUnit());","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":" qty +\u003d ingredient.getQty(); //adds new qty to current qty","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" ingredient.setQty(qty);","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":" return ingredient;","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"ShaniceTang"},"content":" * Gets the index of an ingredient in the pantry stock based on its name (case-insensitive comparison).","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":" * @param name The name of the ingredient to search for.","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":" * @return The index of the ingredient in the pantry stock or -1 if not found.","lastModifiedDate":"2023-10-22"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":" private int getIndexOfIngredient(String name) {","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":" for (int i \u003d 0; i \u003c pantryStock.size(); i++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":" String ingredientName \u003d pantryStock.get(i).getName().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":" if (name.equalsIgnoreCase(ingredientName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ShaniceTang"},"content":" return i;","lastModifiedDate":"2023-10-22"},{"lineNumber":87,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":88,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":89,"author":{"gitId":"ShaniceTang"},"content":" return -1;","lastModifiedDate":"2023-10-22"},{"lineNumber":90,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":91,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" * Decreases the stock of ingredients based on the given dish order.","lastModifiedDate":"2023-10-22"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredients Array of ingredients used to make the dish order.","lastModifiedDate":"2023-10-24"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" public boolean isDishCooked(ArrayList\u003cIngredient\u003e dishIngredients) {","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" //for each ingredient that is used in the dish, update the stock of ingredient left.","lastModifiedDate":"2023-10-22"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" for (Ingredient dishIngredient : dishIngredients) {","lastModifiedDate":"2023-10-22"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":" Ingredient usedIngredientFromStock \u003d getIngredient(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":102,"author":{"gitId":"NaychiMin"},"content":" if (usedIngredientFromStock \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":" int stockQuantity \u003d usedIngredientFromStock.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":" int usedQuantity \u003d dishIngredient.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" int finalQuantity \u003d stockQuantity - usedQuantity;","lastModifiedDate":"2023-10-24"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":" if (finalQuantity \u003c 0) {","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":" usedIngredientFromStock.setQty(finalQuantity);","lastModifiedDate":"2023-10-24"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":113,"author":{"gitId":"NaychiMin"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":115,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":116,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":" * Retrieves the ingredient used in the ordered dish from pantryStock.","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":119,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredient The ingredient used in the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"NaychiMin"},"content":" * @return The corresponding ingredient in pantryStock.","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":122,"author":{"gitId":"NaychiMin"},"content":" private Ingredient getIngredient(Ingredient dishIngredient) {","lastModifiedDate":"2023-10-22"},{"lineNumber":123,"author":{"gitId":"NaychiMin"},"content":" return pantryStock.stream()","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"NaychiMin"},"content":" .filter(ingredient -\u003e ingredient.getName().equals(dishIngredient.getName()))","lastModifiedDate":"2023-10-22"},{"lineNumber":125,"author":{"gitId":"NaychiMin"},"content":" .findFirst()","lastModifiedDate":"2023-10-22"},{"lineNumber":126,"author":{"gitId":"NaychiMin"},"content":" .orElse(null);","lastModifiedDate":"2023-10-22"},{"lineNumber":127,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":128,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":" * Checks the availability of dishes based on ingredient stock.","lastModifiedDate":"2023-10-22"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":132,"author":{"gitId":"NaychiMin"},"content":" public void calculateDishAvailability(Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"NaychiMin"},"content":" int menuSize \u003d menu.getSize();","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"NaychiMin"},"content":" for (int i \u003d 0; i \u003c menuSize; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"NaychiMin"},"content":" Dish dish \u003d menu.getDishFromId(i);","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Dish: \" + dish.getName());","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"NaychiMin"},"content":" int numberOfDishes \u003d calculateMaxDishes(dish, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":" ui.showDishAvailability(numberOfDishes);","lastModifiedDate":"2023-10-24"},{"lineNumber":139,"author":{"gitId":"NaychiMin"},"content":" if (i !\u003d menuSize - 1) {","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"NaychiMin"},"content":" ui.printLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":" //@@author","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":146,"author":{"gitId":"NaychiMin"},"content":" * Calculates the number of dishes that can be prepared with the available ingredients.","lastModifiedDate":"2023-10-24"},{"lineNumber":147,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":" * @param dish The dish being ordered.","lastModifiedDate":"2023-10-22"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":" public int calculateMaxDishes(Dish dish, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"NaychiMin"},"content":" int maxNumofDish \u003d Integer.MAX_VALUE;","lastModifiedDate":"2023-10-22"},{"lineNumber":152,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cIngredient\u003e dishIngredients \u003d retrieveIngredientsForDish(dish.getName(), menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"NaychiMin"},"content":" for (Ingredient dishIngredient : dishIngredients) {","lastModifiedDate":"2023-10-22"},{"lineNumber":155,"author":{"gitId":"NaychiMin"},"content":" int numOfDish \u003d calculateMaxDishForEachIngredient(dishIngredient);","lastModifiedDate":"2023-10-24"},{"lineNumber":156,"author":{"gitId":"NaychiMin"},"content":" maxNumofDish \u003d Math.min(numOfDish, maxNumofDish);","lastModifiedDate":"2023-10-22"},{"lineNumber":157,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":158,"author":{"gitId":"NaychiMin"},"content":" if (numOfDish \u003d\u003d 0) {","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"NaychiMin"},"content":" handleRestock(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":160,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":161,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":162,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":163,"author":{"gitId":"NaychiMin"},"content":" return maxNumofDish;","lastModifiedDate":"2023-10-22"},{"lineNumber":164,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":165,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":166,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":167,"author":{"gitId":"NaychiMin"},"content":" * Calculates the number of dishes that can be prepared with the provided ingredients.","lastModifiedDate":"2023-10-24"},{"lineNumber":168,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":169,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredient The ingredient used in the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":170,"author":{"gitId":"NaychiMin"},"content":" * @return The number of dishes that can be prepared.","lastModifiedDate":"2023-10-22"},{"lineNumber":171,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":172,"author":{"gitId":"NaychiMin"},"content":" private int calculateMaxDishForEachIngredient(Ingredient dishIngredient) {","lastModifiedDate":"2023-10-24"},{"lineNumber":173,"author":{"gitId":"NaychiMin"},"content":" Ingredient usedIngredientFromStock \u003d getIngredient(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":174,"author":{"gitId":"NaychiMin"},"content":" if (usedIngredientFromStock \u003d\u003d null) {","lastModifiedDate":"2023-10-22"},{"lineNumber":175,"author":{"gitId":"NaychiMin"},"content":" return 0;","lastModifiedDate":"2023-10-22"},{"lineNumber":176,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":177,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"NaychiMin"},"content":" int currentQuantity \u003d usedIngredientFromStock.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":179,"author":{"gitId":"NaychiMin"},"content":" int usedQuantity \u003d dishIngredient.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":180,"author":{"gitId":"NaychiMin"},"content":" return currentQuantity / usedQuantity;","lastModifiedDate":"2023-10-22"},{"lineNumber":181,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":182,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":183,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":184,"author":{"gitId":"NaychiMin"},"content":" * Handles the case when restocking is required for a specific ingredient.","lastModifiedDate":"2023-10-22"},{"lineNumber":185,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":186,"author":{"gitId":"NaychiMin"},"content":" * @param dishIngredient The ingredient for which restocking is needed.","lastModifiedDate":"2023-10-22"},{"lineNumber":187,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":188,"author":{"gitId":"NaychiMin"},"content":" private void handleRestock(Ingredient dishIngredient) {","lastModifiedDate":"2023-10-22"},{"lineNumber":189,"author":{"gitId":"NaychiMin"},"content":" String dishIngredientName \u003d dishIngredient.getName();","lastModifiedDate":"2023-10-22"},{"lineNumber":190,"author":{"gitId":"NaychiMin"},"content":" Ingredient stockIngredient \u003d getIngredient(dishIngredient);","lastModifiedDate":"2023-10-22"},{"lineNumber":191,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":192,"author":{"gitId":"NaychiMin"},"content":" int currentQuantity \u003d (stockIngredient \u003d\u003d null) ? 0 : stockIngredient.getQty();","lastModifiedDate":"2023-10-24"},{"lineNumber":193,"author":{"gitId":"NaychiMin"},"content":" String unit \u003d dishIngredient.getUnit();","lastModifiedDate":"2023-10-24"},{"lineNumber":194,"author":{"gitId":"NaychiMin"},"content":" String neededIngredient \u003d dishIngredient.toString();","lastModifiedDate":"2023-10-24"},{"lineNumber":195,"author":{"gitId":"NaychiMin"},"content":" ui.showNeededRestock(dishIngredientName, currentQuantity, unit, neededIngredient);","lastModifiedDate":"2023-10-24"},{"lineNumber":196,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":197,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":198,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":199,"author":{"gitId":"NaychiMin"},"content":" * Retrieves the ingredients for a specific ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":200,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":201,"author":{"gitId":"NaychiMin"},"content":" * @param orderedDish The name of the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":202,"author":{"gitId":"NaychiMin"},"content":" * @return The list of ingredients for the ordered dish.","lastModifiedDate":"2023-10-22"},{"lineNumber":203,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":204,"author":{"gitId":"NaychiMin"},"content":" public ArrayList\u003cIngredient\u003e retrieveIngredientsForDish(String orderedDish, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cIngredient\u003e dishIngredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":206,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":207,"author":{"gitId":"NaychiMin"},"content":" //retrieving the ingredients for orderedDish","lastModifiedDate":"2023-10-22"},{"lineNumber":208,"author":{"gitId":"NaychiMin"},"content":" for (Dish dish : menu.getMenuItemsList()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"NaychiMin"},"content":" if (dish.getName().equals(orderedDish)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":210,"author":{"gitId":"NaychiMin"},"content":" dishIngredients.addAll(dish.getIngredients());","lastModifiedDate":"2023-10-22"},{"lineNumber":211,"author":{"gitId":"NaychiMin"},"content":" break;","lastModifiedDate":"2023-10-22"},{"lineNumber":212,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":213,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":214,"author":{"gitId":"NaychiMin"},"content":" return dishIngredients;","lastModifiedDate":"2023-10-22"},{"lineNumber":215,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":216,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-22"},{"lineNumber":217,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":218,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"NaychiMin":145,"ShaniceTang":73}},{"path":"src/main/java/seedu/cafectrl/data/Sales.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":" * The Sales class represents sales data over a period of time, maintaining a collection of order lists.","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"public class Sales {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":" private static final DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":" private static final String HEADER_FORMAT \u003d \"%-20s %-10s %-20s\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":" private static ArrayList\u003cOrderList\u003e orderLists;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" private int daysAccounted;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" public Sales() {","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" this.orderLists \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" orderLists.add(new OrderList());","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" public Sales(ArrayList\u003cOrderList\u003e orderLists) {","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" this.orderLists \u003d orderLists;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" //TODO: @Zhong Heng, Remove this method if not used","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" public Sales(OrderList orderList) {","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" this.orderLists \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" orderLists.add(orderList);","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" public void addOrderList(OrderList orderList) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" orderLists.add(orderList);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"NaychiMin"},"content":" //TODO: @Zhong Heng, Remove this method if not used","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" public void removeOrderList(int orderListId) {","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" orderLists.remove(orderListId);","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" public void nextDay() {","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" this.daysAccounted +\u003d 1;","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" public int getDaysAccounted() {","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" return daysAccounted;","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" public ArrayList\u003cOrderList\u003e getOrderLists() {","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" return orderLists;","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" public OrderList getOrderList(int index) {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" return orderLists.get(index);","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" * Prints all sales data, organized by day, including dish names, quantities, and total cost prices.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"NaychiMin"},"content":" public void printSales(Ui ui, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" if (orderLists.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"No orders for the day!\");","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"NaychiMin"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"NaychiMin"},"content":" for (int day \u003d 0; day \u003c orderLists.size(); day++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" OrderList orderList \u003d orderLists.get(day);","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Day \" + (day + 1) + \":\");","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(String.format(HEADER_FORMAT, \"Dish Name\", \"Dish Qty\", \"Total Cost Price\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" orderList.printOrderList(menu, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" * Prints sales data for a specific day, including dish names, quantities, and total cost prices.","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" * @param day The day for which sales data is to be printed.","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" public void printSaleByDay(Ui ui, Menu menu, int day) {","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" int orderListIndex \u003d day - 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" OrderList orderList \u003d orderLists.get(orderListIndex);","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"Day \" + (day) + \":\");","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(String.format(HEADER_FORMAT, \"Dish Name\", \"Dish Qty\", \"Total Cost Price\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" orderList.printOrderList(menu, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(\"An error occurred while printing sales for the specified day.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" //@@author","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"NaychiMin":51,"Cazh1":50}},{"path":"src/main/java/seedu/cafectrl/data/dish/Dish.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data.dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"public class Dish {","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" private String name;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" private ArrayList\u003cIngredient\u003e ingredients;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" private float price;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" public Dish(String name, ArrayList\u003cIngredient\u003e ingredients, float price) {","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" this.ingredients \u003d ingredients;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" this.price \u003d price;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public Dish(String name, float price) {","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" this.ingredients \u003d null;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" this.price \u003d price;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" public String getName() {","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" return name;","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":" public ArrayList\u003cIngredient\u003e getIngredients() {","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" return ingredients;","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" public float getPrice() {","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" return price;","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" public void setPrice(float newPrice) {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" this.price \u003d newPrice;","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":" public String toString() {","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" return this.name + \" $\" + this.price;","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"DextheChik3n":13,"Cazh1":5,"ziyi105":22,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/data/dish/Ingredient.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data.dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"public class Ingredient {","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":" private String name;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":" private int qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":" private String unit;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":" public Ingredient(String name) {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":" this.qty \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":" this.unit \u003d null;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":" public Ingredient(String name, int qty, String unit) {","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" this.qty \u003d qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" this.unit \u003d unit;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" public String getName() {","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" return name;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" public int getQty() {","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" return qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" public String getUnit() {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" return unit;","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" public void setQty(int qty) {","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" this.qty \u003d qty;","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":" public String toString() {","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" return name + \" - \" + qty + unit;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"NaychiMin":7,"DextheChik3n":14,"ziyi105":7,"ShaniceTang":13}},{"path":"src/main/java/seedu/cafectrl/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.AddDishCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.AddOrderCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.BuyIngredientCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.DeleteDishCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.EditPriceCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ExitCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.HelpCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.IncorrectCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListIngredientCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListMenuCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.NextDayCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.command.PreviousDayCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.command.ShowSalesCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.command.ShowSalesByDayCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.ViewTotalStockCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.parser.exception.ParserException;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"import java.text.ParseException;","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":" * Parse everything received from the users on terminal","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":" * into a format that can be interpreted by other core classes","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"ziyi105"},"content":"public class Parser implements ParserUtil {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"ziyi105"},"content":" private static final String COMMAND_ARGUMENT_REGEX \u003d \"(?\u003ccommandWord\u003e[a-z_]+)\\\\s*(?\u003carguments\u003e.*)\";","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" //@@author DextheChik3n","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" /** Add Dish Command Handler Patterns*/","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" private static final String ADD_ARGUMENT_STRING \u003d \"name/(?\u003cdishName\u003e[A-Za-z0-9\\\\s]+) \"","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" + \"price/\\\\s*(?\u003cdishPrice\u003e[0-9]*\\\\.[0-9]{0,2}|[0-9]+)\\\\s+\"","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":" + \"(?\u003cingredients\u003eingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+\"","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":" + \"(?:,\\\\s*ingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+)*)\";","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"DextheChik3n"},"content":" private static final String DISH_NAME_MATCHER_GROUP_LABEL \u003d \"dishName\";","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" private static final String PRICE_MATCHER_GROUP_LABEL \u003d \"dishPrice\";","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENTS_MATCHER_GROUP_LABEL \u003d \"ingredients\";","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_ARGUMENT_STRING \u003d \"\\\\s*ingredient/(?\u003cingredientName\u003e[A-Za-z0-9\\\\s]+) \"","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"DextheChik3n"},"content":" + \"qty/\\\\s*(?\u003cingredientQty\u003e[0-9]+)\\\\s*(?\u003cingredientUnit\u003eg|ml)\\\\s*\";","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_NAME_REGEX_GROUP_LABEL \u003d \"ingredientName\";","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_QTY_REGEX_GROUP_LABEL \u003d \"ingredientQty\";","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_UNIT_REGEX_GROUP_LABEL \u003d \"ingredientUnit\";","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"DextheChik3n"},"content":" private static final String INGREDIENT_DIVIDER_REGEX \u003d \",\";","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"DextheChik3n"},"content":" /** Add Order Command Handler Patterns*/","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"DextheChik3n"},"content":" private static final int DISH_NAME_MATCHER_GROUP_NUM \u003d 1;","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" private static final int ORDER_QTY_MATCHER_GROUP_NUM \u003d 2;","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" private static final String ADD_ORDER_ARGUMENT_STRING \u003d \"name/([A-Za-z0-9\\\\s]+) \"","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" + \"qty/([A-Za-z0-9\\\\s]+)\";","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":" /** The rest of Command Handler Patterns*/","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":" private static final String LIST_INGREDIENTS_ARGUMENT_STRING \u003d \"(\\\\d+)\";","lastModifiedDate":"2023-10-17"},{"lineNumber":72,"author":{"gitId":"DextheChik3n"},"content":" private static final String DELETE_ARGUMENT_STRING \u003d \"(\\\\d+)\";","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"DextheChik3n"},"content":" private static final String EDIT_PRICE_ARGUMENT_STRING \u003d \"index/(\\\\d+) price/(\\\\d+(\\\\.\\\\d+)?)\";","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"DextheChik3n"},"content":" private static final String BUY_INGREDIENT_ARGUMENT_STRING \u003d \"(ingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+\"","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"DextheChik3n"},"content":" + \"(?:, ingredient/[A-Za-z0-9\\\\s]+ qty/[A-Za-z0-9\\\\s]+)*)\";","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"DextheChik3n"},"content":" private static final String SHOW_SALE_BY_DAY_ARGUMENT_STRING \u003d \"day/(\\\\d+)\";","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":" * Parse userInput and group it under commandWord and arguments","lastModifiedDate":"2023-10-17"},{"lineNumber":81,"author":{"gitId":"ziyi105"},"content":" * use commandWord to find the matching command and prepare the command","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"ziyi105"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"ziyi105"},"content":" * @param menu The arraylist object created that stores current tasks","lastModifiedDate":"2023-10-17"},{"lineNumber":84,"author":{"gitId":"ziyi105"},"content":" * @param userInput The full user input String","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"ziyi105"},"content":" * @param ui The ui object created that handles I/O with the user","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":" * @param pantry The arraylist object created that stores current ingredients in stock","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":" * @return command requested by the user","lastModifiedDate":"2023-10-17"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":89,"author":{"gitId":"ziyi105"},"content":" public Command parseCommand(Menu menu, String userInput, Ui ui,","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"ziyi105"},"content":" Pantry pantry, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"ziyi105"},"content":" Pattern userInputPattern \u003d Pattern.compile(COMMAND_ARGUMENT_REGEX);","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"ziyi105"},"content":" final Matcher matcher \u003d userInputPattern.matcher(userInput.trim());","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":94,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(\"Incorrect command format!\", ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":95,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":96,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":97,"author":{"gitId":"ziyi105"},"content":" final String commandWord \u003d matcher.group(\"commandWord\");","lastModifiedDate":"2023-10-17"},{"lineNumber":98,"author":{"gitId":"ziyi105"},"content":" final String arguments \u003d matcher.group(\"arguments\");","lastModifiedDate":"2023-10-17"},{"lineNumber":99,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":100,"author":{"gitId":"ziyi105"},"content":" switch (commandWord) {","lastModifiedDate":"2023-10-17"},{"lineNumber":101,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":" case AddDishCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":" return prepareAdd(arguments, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" case DeleteDishCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":106,"author":{"gitId":"ziyi105"},"content":" return prepareDelete(menu, arguments, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":108,"author":{"gitId":"ziyi105"},"content":" case ListIngredientCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":109,"author":{"gitId":"ziyi105"},"content":" return prepareListIngredient(menu, arguments, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":110,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":111,"author":{"gitId":"ziyi105"},"content":" case ListMenuCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":112,"author":{"gitId":"ziyi105"},"content":" return prepareListMenu(menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":114,"author":{"gitId":"ziyi105"},"content":" case EditPriceCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":115,"author":{"gitId":"ziyi105"},"content":" return prepareEditPriceCommand(menu, arguments, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":117,"author":{"gitId":"ziyi105"},"content":" case ViewTotalStockCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":" return prepareViewTotalStock(ui, pantry);","lastModifiedDate":"2023-10-25"},{"lineNumber":119,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"ziyi105"},"content":" case BuyIngredientCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"ziyi105"},"content":" return prepareBuyIngredient(arguments, ui, pantry);","lastModifiedDate":"2023-10-24"},{"lineNumber":122,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":123,"author":{"gitId":"ziyi105"},"content":" case HelpCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"ziyi105"},"content":" return prepareHelpCommand(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":125,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":126,"author":{"gitId":"ziyi105"},"content":" case ExitCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":127,"author":{"gitId":"ziyi105"},"content":" return new ExitCommand(ui, pantry);","lastModifiedDate":"2023-10-24"},{"lineNumber":128,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":129,"author":{"gitId":"ziyi105"},"content":" case AddOrderCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":130,"author":{"gitId":"ziyi105"},"content":" return prepareOrder(menu, arguments, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":131,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":132,"author":{"gitId":"ziyi105"},"content":" case NextDayCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-29"},{"lineNumber":133,"author":{"gitId":"ziyi105"},"content":" return prepareNextDay(ui, sales, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":134,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"ziyi105"},"content":" case PreviousDayCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-29"},{"lineNumber":136,"author":{"gitId":"ziyi105"},"content":" return preparePreviousDay(ui, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"ziyi105"},"content":" case ShowSalesCommand.COMMAND_WORD:","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"ziyi105"},"content":" return prepareShowSales(sales, menu, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"ziyi105"},"content":" case ShowSalesByDayCommand.COMMAND_WORD:","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"ziyi105"},"content":" return prepareShowSalesByDay(arguments, ui, sales, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":144,"author":{"gitId":"ziyi105"},"content":" default:","lastModifiedDate":"2023-10-17"},{"lineNumber":145,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.UNKNOWN_COMMAND_MESSAGE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":147,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":148,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":149,"author":{"gitId":"ziyi105"},"content":" //All prepareCommand Classes","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-10-28"},{"lineNumber":151,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"Cazh1"},"content":" * Prepares the ListMenuCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":" * @param ui ui of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":" * @return new ListMenuCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":158,"author":{"gitId":"Cazh1"},"content":" private static Command prepareListMenu(Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":" return new ListMenuCommand(menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":162,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-28"},{"lineNumber":163,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":164,"author":{"gitId":"ziyi105"},"content":" * Parse argument in the context of edit price command","lastModifiedDate":"2023-10-17"},{"lineNumber":165,"author":{"gitId":"ziyi105"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-18"},{"lineNumber":166,"author":{"gitId":"ziyi105"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-17"},{"lineNumber":167,"author":{"gitId":"ziyi105"},"content":" * @return new EditDishCommand","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"ziyi105"},"content":" private static Command prepareEditPriceCommand(Menu menu, String arguments, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":170,"author":{"gitId":"ziyi105"},"content":" Pattern editDishArgumentsPattern \u003d Pattern.compile(EDIT_PRICE_ARGUMENT_STRING);","lastModifiedDate":"2023-10-17"},{"lineNumber":171,"author":{"gitId":"ziyi105"},"content":" Matcher matcher \u003d editDishArgumentsPattern.matcher(arguments);","lastModifiedDate":"2023-10-17"},{"lineNumber":172,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":173,"author":{"gitId":"ziyi105"},"content":" // Checks whether the overall pattern of edit price arguments is correct","lastModifiedDate":"2023-10-17"},{"lineNumber":174,"author":{"gitId":"ziyi105"},"content":" if (!matcher.find()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":175,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_EDIT_PRICE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":176,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":177,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":178,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":179,"author":{"gitId":"ziyi105"},"content":" int dishIndexGroup \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":180,"author":{"gitId":"ziyi105"},"content":" int newPriceGroup \u003d 2;","lastModifiedDate":"2023-10-18"},{"lineNumber":181,"author":{"gitId":"ziyi105"},"content":" int dishIndex \u003d Integer.parseInt(matcher.group(dishIndexGroup));","lastModifiedDate":"2023-10-18"},{"lineNumber":182,"author":{"gitId":"ziyi105"},"content":" float newPrice \u003d parsePriceToFloat(matcher.group(newPriceGroup));","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":184,"author":{"gitId":"ziyi105"},"content":" // Check whether the dish index is valid","lastModifiedDate":"2023-10-18"},{"lineNumber":185,"author":{"gitId":"ziyi105"},"content":" if (!menu.isValidDishIndex(dishIndex)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DISH_INDEX, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":188,"author":{"gitId":"ziyi105"},"content":" return new EditPriceCommand(dishIndex, newPrice, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":189,"author":{"gitId":"ziyi105"},"content":" } catch (ParserException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"ziyi105"},"content":" return new IncorrectCommand(ErrorMessages.WRONG_ARGUMENT_TYPE_FOR_EDIT_PRICE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":192,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":193,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"DextheChik3n"},"content":" //@@author DextheChik3n","lastModifiedDate":"2023-10-27"},{"lineNumber":195,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":196,"author":{"gitId":"DextheChik3n"},"content":" * Parses the user input text into ingredients to form a \u003ccode\u003eDish\u003c/code\u003e that is added to the \u003ccode\u003eMenu\u003c/code\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":197,"author":{"gitId":"DextheChik3n"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"DextheChik3n"},"content":" * @return new AddDishCommand","lastModifiedDate":"2023-10-23"},{"lineNumber":199,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":200,"author":{"gitId":"DextheChik3n"},"content":" private static Command prepareAdd(String arguments, Menu menu, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":201,"author":{"gitId":"DextheChik3n"},"content":" final Pattern addArgumentPatter \u003d Pattern.compile(ADD_ARGUMENT_STRING);","lastModifiedDate":"2023-10-17"},{"lineNumber":202,"author":{"gitId":"DextheChik3n"},"content":" Matcher matcher \u003d addArgumentPatter.matcher(arguments);","lastModifiedDate":"2023-10-17"},{"lineNumber":203,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":204,"author":{"gitId":"DextheChik3n"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":205,"author":{"gitId":"DextheChik3n"},"content":" // Checks whether the overall pattern of add arguments is correct","lastModifiedDate":"2023-10-17"},{"lineNumber":206,"author":{"gitId":"DextheChik3n"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":207,"author":{"gitId":"DextheChik3n"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ADD_DISH_FORMAT_MESSAGE","lastModifiedDate":"2023-10-30"},{"lineNumber":208,"author":{"gitId":"DextheChik3n"},"content":" + AddDishCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":209,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":210,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":211,"author":{"gitId":"DextheChik3n"},"content":" // To retrieve specific arguments from arguments","lastModifiedDate":"2023-10-17"},{"lineNumber":212,"author":{"gitId":"DextheChik3n"},"content":" String dishName \u003d matcher.group(DISH_NAME_MATCHER_GROUP_LABEL).trim();","lastModifiedDate":"2023-10-27"},{"lineNumber":213,"author":{"gitId":"DextheChik3n"},"content":" float price \u003d parsePriceToFloat(matcher.group(PRICE_MATCHER_GROUP_LABEL));","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"DextheChik3n"},"content":" String ingredientsListString \u003d matcher.group(INGREDIENTS_MATCHER_GROUP_LABEL);","lastModifiedDate":"2023-10-24"},{"lineNumber":215,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":216,"author":{"gitId":"DextheChik3n"},"content":" if (isNameLengthInvalid(dishName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_DISH_NAME_LENGTH_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"DextheChik3n"},"content":" if (isRepeatedName(dishName, menu)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(Messages.REPEATED_DISH_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":223,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d parseIngredients(ingredientsListString);","lastModifiedDate":"2023-10-31"},{"lineNumber":225,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":226,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(dishName, ingredients, price);","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":228,"author":{"gitId":"DextheChik3n"},"content":" return new AddDishCommand(dish, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":229,"author":{"gitId":"DextheChik3n"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":230,"author":{"gitId":"DextheChik3n"},"content":" return new IncorrectCommand(ErrorMessages.NULL_NAME_DETECTED_MESSAGE, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"DextheChik3n"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"DextheChik3n"},"content":" return new IncorrectCommand(e.getMessage(), ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":234,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":236,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":237,"author":{"gitId":"DextheChik3n"},"content":" * Parses the user\u0027s input text ingredients.","lastModifiedDate":"2023-10-25"},{"lineNumber":238,"author":{"gitId":"DextheChik3n"},"content":" * @param ingredientsListString user\u0027s input string of ingredients, multiple ingredients seperated by \u0027,\u0027 is allowed","lastModifiedDate":"2023-10-25"},{"lineNumber":239,"author":{"gitId":"DextheChik3n"},"content":" * @return Ingredient objects that consists of the dish","lastModifiedDate":"2023-10-23"},{"lineNumber":240,"author":{"gitId":"DextheChik3n"},"content":" * @throws IllegalArgumentException if the input string of ingredients is in an incorrect format.","lastModifiedDate":"2023-10-23"},{"lineNumber":241,"author":{"gitId":"DextheChik3n"},"content":" * @throws ParserException if the input string does not match the constraints","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":243,"author":{"gitId":"DextheChik3n"},"content":" private static ArrayList\u003cIngredient\u003e parseIngredients(String ingredientsListString)","lastModifiedDate":"2023-10-31"},{"lineNumber":244,"author":{"gitId":"DextheChik3n"},"content":" throws IllegalArgumentException, ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"DextheChik3n"},"content":" String[] inputIngredientList \u003d {ingredientsListString};","lastModifiedDate":"2023-10-27"},{"lineNumber":246,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":247,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":248,"author":{"gitId":"DextheChik3n"},"content":" //check if there is more than 1 ingredient","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"DextheChik3n"},"content":" if (ingredientsListString.contains(INGREDIENT_DIVIDER_REGEX)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":250,"author":{"gitId":"DextheChik3n"},"content":" //split the whole string of ingredients into separate individual ingredients","lastModifiedDate":"2023-10-23"},{"lineNumber":251,"author":{"gitId":"DextheChik3n"},"content":" inputIngredientList \u003d ingredientsListString.split(INGREDIENT_DIVIDER_REGEX);","lastModifiedDate":"2023-10-27"},{"lineNumber":252,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":253,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":254,"author":{"gitId":"DextheChik3n"},"content":" //Parsing each ingredient","lastModifiedDate":"2023-10-23"},{"lineNumber":255,"author":{"gitId":"DextheChik3n"},"content":" for (String inputIngredient: inputIngredientList) {","lastModifiedDate":"2023-10-27"},{"lineNumber":256,"author":{"gitId":"DextheChik3n"},"content":" final Pattern ingredientPattern \u003d Pattern.compile(INGREDIENT_ARGUMENT_STRING);","lastModifiedDate":"2023-10-18"},{"lineNumber":257,"author":{"gitId":"DextheChik3n"},"content":" Matcher ingredientMatcher \u003d ingredientPattern.matcher(inputIngredient);","lastModifiedDate":"2023-10-27"},{"lineNumber":258,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"DextheChik3n"},"content":" if (!ingredientMatcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":260,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_ADD_DISH_FORMAT_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"DextheChik3n"},"content":" + AddDishCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":263,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":264,"author":{"gitId":"DextheChik3n"},"content":" String ingredientName \u003d ingredientMatcher.group(INGREDIENT_NAME_REGEX_GROUP_LABEL).trim();","lastModifiedDate":"2023-10-27"},{"lineNumber":265,"author":{"gitId":"DextheChik3n"},"content":" String ingredientQtyString \u003d ingredientMatcher.group(INGREDIENT_QTY_REGEX_GROUP_LABEL);","lastModifiedDate":"2023-10-27"},{"lineNumber":266,"author":{"gitId":"DextheChik3n"},"content":" String ingredientUnit \u003d ingredientMatcher.group(INGREDIENT_UNIT_REGEX_GROUP_LABEL);","lastModifiedDate":"2023-10-25"},{"lineNumber":267,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"DextheChik3n"},"content":" int ingredientQty \u003d Integer.parseInt(ingredientQtyString);","lastModifiedDate":"2023-10-27"},{"lineNumber":269,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":270,"author":{"gitId":"DextheChik3n"},"content":" if (isNameLengthInvalid(ingredientName)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_INGREDIENT_NAME_LENGTH_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"DextheChik3n"},"content":" if (isRepeatedName(ingredientName, ingredients)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"DextheChik3n"},"content":" continue;","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"DextheChik3n"},"content":" Ingredient ingredient \u003d new Ingredient(ingredientName, ingredientQty, ingredientUnit);","lastModifiedDate":"2023-10-27"},{"lineNumber":279,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":280,"author":{"gitId":"DextheChik3n"},"content":" ingredients.add(ingredient);","lastModifiedDate":"2023-10-18"},{"lineNumber":281,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":282,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":283,"author":{"gitId":"DextheChik3n"},"content":" return ingredients;","lastModifiedDate":"2023-10-23"},{"lineNumber":284,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":285,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":286,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"DextheChik3n"},"content":" * Converts text of price to float while also checking if the price input is within reasonable range","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"DextheChik3n"},"content":" * @param priceText text input for price argument","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"DextheChik3n"},"content":" * @return price in float format","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"DextheChik3n"},"content":" * @throws ArithmeticException if price \u003e 10000000000.00","lastModifiedDate":"2023-11-01"},{"lineNumber":291,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":292,"author":{"gitId":"DextheChik3n"},"content":" static float parsePriceToFloat(String priceText) throws ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"DextheChik3n"},"content":" float price \u003d Float.parseFloat(priceText);","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"DextheChik3n"},"content":" float maxPriceValue \u003d (float) 10000000000.00;","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"DextheChik3n"},"content":" if (price \u003e maxPriceValue) {","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"DextheChik3n"},"content":" throw new ParserException(ErrorMessages.INVALID_PRICE_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":300,"author":{"gitId":"DextheChik3n"},"content":" return price;","lastModifiedDate":"2023-11-01"},{"lineNumber":301,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":302,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":303,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"DextheChik3n"},"content":" * Checks in the menu if the dish name already exists in the menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":305,"author":{"gitId":"DextheChik3n"},"content":" * @param inputDishName dish name entered by the user","lastModifiedDate":"2023-11-01"},{"lineNumber":306,"author":{"gitId":"DextheChik3n"},"content":" * @param menu contains all the existing Dishes","lastModifiedDate":"2023-11-01"},{"lineNumber":307,"author":{"gitId":"DextheChik3n"},"content":" * @return true if dish name already exists in menu, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":308,"author":{"gitId":"DextheChik3n"},"content":" * @throws NullPointerException if the input string is null","lastModifiedDate":"2023-11-01"},{"lineNumber":309,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":310,"author":{"gitId":"DextheChik3n"},"content":" static boolean isRepeatedName(String inputDishName, Menu menu) throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":311,"author":{"gitId":"DextheChik3n"},"content":" if (inputDishName \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":312,"author":{"gitId":"DextheChik3n"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-01"},{"lineNumber":313,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":314,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":315,"author":{"gitId":"DextheChik3n"},"content":" for (Dish dish: menu.getMenuItemsList()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":316,"author":{"gitId":"DextheChik3n"},"content":" String menuDishNameLowerCase \u003d dish.getName().toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":317,"author":{"gitId":"DextheChik3n"},"content":" String inputDishNameLowerCase \u003d inputDishName.toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":318,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":319,"author":{"gitId":"DextheChik3n"},"content":" if (menuDishNameLowerCase.equals(inputDishNameLowerCase)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":320,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":321,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":322,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":323,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":324,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":325,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":326,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":327,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":328,"author":{"gitId":"DextheChik3n"},"content":" * Checks in the menu if the dish name already exists in the menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":329,"author":{"gitId":"DextheChik3n"},"content":" * @param inputName dish name entered by the user","lastModifiedDate":"2023-11-01"},{"lineNumber":330,"author":{"gitId":"DextheChik3n"},"content":" * @param ingredients contains all the existing Ingredients","lastModifiedDate":"2023-11-01"},{"lineNumber":331,"author":{"gitId":"DextheChik3n"},"content":" * @return true if ingredient name already exists in menu, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":332,"author":{"gitId":"DextheChik3n"},"content":" * @throws NullPointerException if the input string is null","lastModifiedDate":"2023-11-01"},{"lineNumber":333,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":334,"author":{"gitId":"DextheChik3n"},"content":" static boolean isRepeatedName(String inputName, ArrayList\u003cIngredient\u003e ingredients) throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":335,"author":{"gitId":"DextheChik3n"},"content":" if (inputName \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":336,"author":{"gitId":"DextheChik3n"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-01"},{"lineNumber":337,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":338,"author":{"gitId":"DextheChik3n"},"content":" for (Ingredient ingredient: ingredients) {","lastModifiedDate":"2023-11-01"},{"lineNumber":339,"author":{"gitId":"DextheChik3n"},"content":" String ingredientNameLowerCase \u003d ingredient.getName().toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":340,"author":{"gitId":"DextheChik3n"},"content":" String inputIngredientNameLowerCase \u003d inputName.toLowerCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":341,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":342,"author":{"gitId":"DextheChik3n"},"content":" if (ingredientNameLowerCase.equals(inputIngredientNameLowerCase)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":343,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":344,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":345,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":346,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":347,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":348,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":349,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":350,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":351,"author":{"gitId":"DextheChik3n"},"content":" * Checks the length of the name is too long","lastModifiedDate":"2023-11-01"},{"lineNumber":352,"author":{"gitId":"DextheChik3n"},"content":" * @param inputName name","lastModifiedDate":"2023-11-01"},{"lineNumber":353,"author":{"gitId":"DextheChik3n"},"content":" * @return true if the name is more than max character limit set, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":354,"author":{"gitId":"DextheChik3n"},"content":" * @throws NullPointerException if the input string is null","lastModifiedDate":"2023-11-01"},{"lineNumber":355,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":356,"author":{"gitId":"DextheChik3n"},"content":" static boolean isNameLengthInvalid(String inputName) throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":357,"author":{"gitId":"DextheChik3n"},"content":" int maxNameLength \u003d 35;","lastModifiedDate":"2023-11-01"},{"lineNumber":358,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":359,"author":{"gitId":"DextheChik3n"},"content":" if (inputName \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":360,"author":{"gitId":"DextheChik3n"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-01"},{"lineNumber":361,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":362,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":363,"author":{"gitId":"DextheChik3n"},"content":" if (inputName.length() \u003e maxNameLength) {","lastModifiedDate":"2023-11-01"},{"lineNumber":364,"author":{"gitId":"DextheChik3n"},"content":" return true;","lastModifiedDate":"2023-11-01"},{"lineNumber":365,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":366,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":367,"author":{"gitId":"DextheChik3n"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":368,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":369,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":370,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-10-27"},{"lineNumber":371,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":372,"author":{"gitId":"NaychiMin"},"content":" * Parses arguments in the context of the ListIngredient command.","lastModifiedDate":"2023-10-17"},{"lineNumber":373,"author":{"gitId":"NaychiMin"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-18"},{"lineNumber":374,"author":{"gitId":"NaychiMin"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-18"},{"lineNumber":375,"author":{"gitId":"NaychiMin"},"content":" * @return the prepared command","lastModifiedDate":"2023-10-17"},{"lineNumber":376,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":377,"author":{"gitId":"NaychiMin"},"content":" private static Command prepareListIngredient(Menu menu, String arguments, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":378,"author":{"gitId":"NaychiMin"},"content":" final Pattern prepareListPattern \u003d Pattern.compile(LIST_INGREDIENTS_ARGUMENT_STRING);","lastModifiedDate":"2023-10-18"},{"lineNumber":379,"author":{"gitId":"NaychiMin"},"content":" Matcher matcher \u003d prepareListPattern.matcher(arguments.trim());","lastModifiedDate":"2023-10-18"},{"lineNumber":380,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":381,"author":{"gitId":"NaychiMin"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":382,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_LIST_INGREDIENTS, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":383,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":384,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":385,"author":{"gitId":"NaychiMin"},"content":" int dishIndex \u003d Integer.parseInt(matcher.group(1));","lastModifiedDate":"2023-10-18"},{"lineNumber":386,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":387,"author":{"gitId":"NaychiMin"},"content":" if (!menu.isValidDishIndex(dishIndex)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":388,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DISH_INDEX, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":389,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":390,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":391,"author":{"gitId":"NaychiMin"},"content":" return new ListIngredientCommand(dishIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":392,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":393,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":394,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-10-28"},{"lineNumber":395,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":396,"author":{"gitId":"ShaniceTang"},"content":" * Parses arguments in the context of the Delete command.","lastModifiedDate":"2023-10-17"},{"lineNumber":397,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":398,"author":{"gitId":"ShaniceTang"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-18"},{"lineNumber":399,"author":{"gitId":"ShaniceTang"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-18"},{"lineNumber":400,"author":{"gitId":"ShaniceTang"},"content":" * @return DeleteDishCommand if command is valid, IncorrectCommand otherwise","lastModifiedDate":"2023-10-18"},{"lineNumber":401,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":402,"author":{"gitId":"ShaniceTang"},"content":" private static Command prepareDelete(Menu menu, String arguments, Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":403,"author":{"gitId":"ShaniceTang"},"content":" Pattern deleteDishArgumentsPattern \u003d Pattern.compile(DELETE_ARGUMENT_STRING);","lastModifiedDate":"2023-10-18"},{"lineNumber":404,"author":{"gitId":"ShaniceTang"},"content":" Matcher matcher \u003d deleteDishArgumentsPattern.matcher(arguments.trim());","lastModifiedDate":"2023-10-18"},{"lineNumber":405,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":406,"author":{"gitId":"ShaniceTang"},"content":" // Checks whether the overall pattern of delete price arguments is correct","lastModifiedDate":"2023-10-18"},{"lineNumber":407,"author":{"gitId":"ShaniceTang"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":408,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_DELETE, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":409,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":410,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":411,"author":{"gitId":"ShaniceTang"},"content":" int listIndexArgGroup \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":412,"author":{"gitId":"ShaniceTang"},"content":" int dishIndex \u003d Integer.parseInt(matcher.group(listIndexArgGroup));","lastModifiedDate":"2023-10-18"},{"lineNumber":413,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":414,"author":{"gitId":"ShaniceTang"},"content":" if (!menu.isValidDishIndex(dishIndex)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":415,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DISH_INDEX, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":416,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":417,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":418,"author":{"gitId":"ShaniceTang"},"content":" return new DeleteDishCommand(dishIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":419,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":420,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":421,"author":{"gitId":"ShaniceTang"},"content":" private static Command prepareViewTotalStock(Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-25"},{"lineNumber":422,"author":{"gitId":"ShaniceTang"},"content":" return new ViewTotalStockCommand(pantry, ui);","lastModifiedDate":"2023-10-25"},{"lineNumber":423,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":424,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":425,"author":{"gitId":"ShaniceTang"},"content":" private static Command prepareBuyIngredient(String arguments, Ui ui, Pantry pantry) {","lastModifiedDate":"2023-10-24"},{"lineNumber":426,"author":{"gitId":"ShaniceTang"},"content":" Pattern buyIngredientArgumentsPattern \u003d Pattern.compile(BUY_INGREDIENT_ARGUMENT_STRING);","lastModifiedDate":"2023-10-25"},{"lineNumber":427,"author":{"gitId":"ShaniceTang"},"content":" Matcher matcher \u003d buyIngredientArgumentsPattern.matcher(arguments.trim());","lastModifiedDate":"2023-10-22"},{"lineNumber":428,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":429,"author":{"gitId":"ShaniceTang"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":430,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":431,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.MISSING_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-10-31"},{"lineNumber":432,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-31"},{"lineNumber":433,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":434,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":435,"author":{"gitId":"ShaniceTang"},"content":" String ingredientsListString \u003d matcher.group(0);","lastModifiedDate":"2023-10-25"},{"lineNumber":436,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":437,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":438,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d parseIngredients(ingredientsListString);","lastModifiedDate":"2023-11-01"},{"lineNumber":439,"author":{"gitId":"ShaniceTang"},"content":" return new BuyIngredientCommand(ingredients, ui, pantry);","lastModifiedDate":"2023-10-25"},{"lineNumber":440,"author":{"gitId":"ShaniceTang"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-22"},{"lineNumber":441,"author":{"gitId":"ShaniceTang"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-10-31"},{"lineNumber":442,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-31"},{"lineNumber":443,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":444,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":445,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":446,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-28"},{"lineNumber":447,"author":{"gitId":"ziyi105"},"content":" private static Command prepareHelpCommand(Ui ui) {","lastModifiedDate":"2023-10-24"},{"lineNumber":448,"author":{"gitId":"ziyi105"},"content":" return new HelpCommand(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":449,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":450,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":451,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-11-01"},{"lineNumber":452,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":453,"author":{"gitId":"Cazh1"},"content":" * Parses arguments in the context of the AddOrder command.","lastModifiedDate":"2023-10-30"},{"lineNumber":454,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":455,"author":{"gitId":"Cazh1"},"content":" * @param menu menu of the current session","lastModifiedDate":"2023-10-23"},{"lineNumber":456,"author":{"gitId":"Cazh1"},"content":" * @param arguments string that matches group arguments","lastModifiedDate":"2023-10-23"},{"lineNumber":457,"author":{"gitId":"Cazh1"},"content":" * @param ui","lastModifiedDate":"2023-10-30"},{"lineNumber":458,"author":{"gitId":"Cazh1"},"content":" * @return AddOrderCommand if command is valid, IncorrectCommand otherwise","lastModifiedDate":"2023-10-23"},{"lineNumber":459,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":460,"author":{"gitId":"Cazh1"},"content":" private static Command prepareOrder(Menu menu, String arguments, Ui ui,","lastModifiedDate":"2023-10-30"},{"lineNumber":461,"author":{"gitId":"Cazh1"},"content":" Pantry pantry, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":462,"author":{"gitId":"Cazh1"},"content":" final Pattern addOrderArgumentPatter \u003d Pattern.compile(ADD_ORDER_ARGUMENT_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":463,"author":{"gitId":"Cazh1"},"content":" Matcher matcher \u003d addOrderArgumentPatter.matcher(arguments);","lastModifiedDate":"2023-10-23"},{"lineNumber":464,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":465,"author":{"gitId":"Cazh1"},"content":" // Checks whether the overall pattern of add order arguments is correct","lastModifiedDate":"2023-10-23"},{"lineNumber":466,"author":{"gitId":"Cazh1"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":467,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ADD_ORDER_FORMAT_MESSAGE","lastModifiedDate":"2023-10-30"},{"lineNumber":468,"author":{"gitId":"Cazh1"},"content":" + AddOrderCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":469,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":470,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":471,"author":{"gitId":"Cazh1"},"content":" OrderList orderList \u003d setOrderList(currentDate, sales);","lastModifiedDate":"2023-10-30"},{"lineNumber":472,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":473,"author":{"gitId":"Cazh1"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":474,"author":{"gitId":"Cazh1"},"content":" // To retrieve specific arguments from arguments","lastModifiedDate":"2023-10-23"},{"lineNumber":475,"author":{"gitId":"Cazh1"},"content":" String dishName \u003d matcher.group(DISH_NAME_MATCHER_GROUP_NUM);","lastModifiedDate":"2023-10-23"},{"lineNumber":476,"author":{"gitId":"Cazh1"},"content":" int dishQty \u003d Integer.parseInt(matcher.group(ORDER_QTY_MATCHER_GROUP_NUM));","lastModifiedDate":"2023-10-23"},{"lineNumber":477,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":478,"author":{"gitId":"Cazh1"},"content":" Dish orderedDish \u003d menu.getDishFromName(dishName);","lastModifiedDate":"2023-10-24"},{"lineNumber":479,"author":{"gitId":"Cazh1"},"content":" if (orderedDish \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":480,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(ErrorMessages.DISH_NOT_FOUND, ui);","lastModifiedDate":"2023-10-30"},{"lineNumber":481,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":482,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":483,"author":{"gitId":"Cazh1"},"content":" Order order \u003d new Order(orderedDish, dishQty);","lastModifiedDate":"2023-10-24"},{"lineNumber":484,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":485,"author":{"gitId":"Cazh1"},"content":" return new AddOrderCommand(order, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":486,"author":{"gitId":"Cazh1"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":487,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_ADD_ORDER_FORMAT_MESSAGE","lastModifiedDate":"2023-10-30"},{"lineNumber":488,"author":{"gitId":"Cazh1"},"content":" + AddOrderCommand.MESSAGE_USAGE + e.getMessage(), ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":489,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":490,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":491,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":492,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":493,"author":{"gitId":"Cazh1"},"content":" * Prepares PreviousDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":494,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":495,"author":{"gitId":"Cazh1"},"content":" * @param ui ui object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":496,"author":{"gitId":"Cazh1"},"content":" * @param currentDate currentDate object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":497,"author":{"gitId":"Cazh1"},"content":" * @return PreviousDayCommand if after day 1, IncorrectCommand if before","lastModifiedDate":"2023-10-30"},{"lineNumber":498,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":499,"author":{"gitId":"Cazh1"},"content":" private static Command preparePreviousDay(Ui ui, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":500,"author":{"gitId":"Cazh1"},"content":" int currentDay \u003d currentDate.getCurrentDay();","lastModifiedDate":"2023-10-29"},{"lineNumber":501,"author":{"gitId":"Cazh1"},"content":" if (currentDay \u003d\u003d 0) {","lastModifiedDate":"2023-10-29"},{"lineNumber":502,"author":{"gitId":"Cazh1"},"content":" return new IncorrectCommand(Messages.PREVIOUS_DAY_TIME_TRAVEL, ui);","lastModifiedDate":"2023-10-29"},{"lineNumber":503,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":504,"author":{"gitId":"Cazh1"},"content":" return new PreviousDayCommand(ui, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":505,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":506,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":507,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":508,"author":{"gitId":"Cazh1"},"content":" * Prepares NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":509,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":510,"author":{"gitId":"Cazh1"},"content":" * @param ui ui object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":511,"author":{"gitId":"Cazh1"},"content":" * @param sales sales object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":512,"author":{"gitId":"Cazh1"},"content":" * @param currentDate currentDate object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":513,"author":{"gitId":"Cazh1"},"content":" * @return NextDayCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":514,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":515,"author":{"gitId":"Cazh1"},"content":" private static Command prepareNextDay(Ui ui, Sales sales, CurrentDate currentDate) {","lastModifiedDate":"2023-10-30"},{"lineNumber":516,"author":{"gitId":"Cazh1"},"content":" return new NextDayCommand(ui, sales, currentDate);","lastModifiedDate":"2023-10-30"},{"lineNumber":517,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":518,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":519,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":520,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":521,"author":{"gitId":"NaychiMin"},"content":" * Prepares a command to display all sales items.","lastModifiedDate":"2023-11-01"},{"lineNumber":522,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":523,"author":{"gitId":"NaychiMin"},"content":" * @param sale The Sales object containing sales data.","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":526,"author":{"gitId":"NaychiMin"},"content":" * @return A ShowSalesCommand instance for viewing all sales items.","lastModifiedDate":"2023-11-01"},{"lineNumber":527,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":528,"author":{"gitId":"NaychiMin"},"content":" private static Command prepareShowSales(Sales sale, Menu menu, Ui ui) {","lastModifiedDate":"2023-11-01"},{"lineNumber":529,"author":{"gitId":"NaychiMin"},"content":" return new ShowSalesCommand(sale, ui, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":530,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":531,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"NaychiMin"},"content":" * Prepares a command to display sales items for a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":534,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"NaychiMin"},"content":" * @param arguments The arguments containing the day for which sales are to be displayed.","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"NaychiMin"},"content":" * @param ui The Ui object for user interface interactions.","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"NaychiMin"},"content":" * @param sales The Sales object containing sales data.","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"NaychiMin"},"content":" * @param menu The Menu object representing the cafe\u0027s menu.","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"NaychiMin"},"content":" * @return A ShowSalesByDayCommand instance for viewing sales items on a specific day.","lastModifiedDate":"2023-11-01"},{"lineNumber":540,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"NaychiMin"},"content":" private static Command prepareShowSalesByDay(String arguments, Ui ui, Sales sales, Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"NaychiMin"},"content":" final Pattern showSaleByDayPattern \u003d Pattern.compile(SHOW_SALE_BY_DAY_ARGUMENT_STRING);","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"NaychiMin"},"content":" Matcher matcher \u003d showSaleByDayPattern.matcher(arguments.trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"NaychiMin"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":546,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_SHOW_SALE_DAY_FORMAT_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":547,"author":{"gitId":"NaychiMin"},"content":" + ShowSalesByDayCommand.MESSAGE_USAGE, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":548,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":549,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":550,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":551,"author":{"gitId":"NaychiMin"},"content":" int day \u003d Integer.parseInt(matcher.group(1));","lastModifiedDate":"2023-11-01"},{"lineNumber":552,"author":{"gitId":"NaychiMin"},"content":" return new ShowSalesByDayCommand(day, ui, sales, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":553,"author":{"gitId":"NaychiMin"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":554,"author":{"gitId":"NaychiMin"},"content":" return new IncorrectCommand(ErrorMessages.INVALID_DAY_FORMAT, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":555,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":556,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":557,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":558,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-11-01"},{"lineNumber":559,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":560,"author":{"gitId":"Cazh1"},"content":" * Sets the orderList according to the Day","lastModifiedDate":"2023-10-30"},{"lineNumber":561,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":562,"author":{"gitId":"Cazh1"},"content":" * @param currentDate currentDate object of the current session","lastModifiedDate":"2023-10-30"},{"lineNumber":563,"author":{"gitId":"Cazh1"},"content":" * @param sales sales object of the current session, contains the orderLists","lastModifiedDate":"2023-10-30"},{"lineNumber":564,"author":{"gitId":"Cazh1"},"content":" * @return The respective orderList","lastModifiedDate":"2023-10-30"},{"lineNumber":565,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":566,"author":{"gitId":"Cazh1"},"content":" private static OrderList setOrderList(CurrentDate currentDate, Sales sales) {","lastModifiedDate":"2023-10-30"},{"lineNumber":567,"author":{"gitId":"Cazh1"},"content":" int currentDay \u003d currentDate.getCurrentDay();","lastModifiedDate":"2023-10-30"},{"lineNumber":568,"author":{"gitId":"Cazh1"},"content":" return sales.getOrderList(currentDay);","lastModifiedDate":"2023-10-30"},{"lineNumber":569,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":570,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":571,"author":{"gitId":"Cazh1"},"content":" //@@author Cazh1","lastModifiedDate":"2023-11-01"},{"lineNumber":572,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":573,"author":{"gitId":"Cazh1"},"content":" * Parses the given arguments string to identify task index number.","lastModifiedDate":"2023-10-17"},{"lineNumber":574,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":575,"author":{"gitId":"Cazh1"},"content":" * @param userInput arguments string to parse as index number","lastModifiedDate":"2023-10-17"},{"lineNumber":576,"author":{"gitId":"Cazh1"},"content":" * @param command expected String name of the command called","lastModifiedDate":"2023-10-17"},{"lineNumber":577,"author":{"gitId":"Cazh1"},"content":" * @return the parsed index number","lastModifiedDate":"2023-10-17"},{"lineNumber":578,"author":{"gitId":"Cazh1"},"content":" * @throws ParseException if no region of the args string could be found for the index","lastModifiedDate":"2023-10-17"},{"lineNumber":579,"author":{"gitId":"Cazh1"},"content":" * @throws NumberFormatException the args string region is not a valid number","lastModifiedDate":"2023-10-17"},{"lineNumber":580,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":581,"author":{"gitId":"Cazh1"},"content":" private static int parseArgsAsDisplayedIndex(String userInput, String command)","lastModifiedDate":"2023-10-17"},{"lineNumber":582,"author":{"gitId":"Cazh1"},"content":" throws ParseException, NumberFormatException {","lastModifiedDate":"2023-10-17"},{"lineNumber":583,"author":{"gitId":"Cazh1"},"content":" String formattedString \u003d userInput.replace(command, \"\").trim();","lastModifiedDate":"2023-10-17"},{"lineNumber":584,"author":{"gitId":"Cazh1"},"content":" return Integer.parseInt(formattedString);","lastModifiedDate":"2023-10-17"},{"lineNumber":585,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":586,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":587,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":588,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":589,"author":{"gitId":"ShaniceTang"},"content":" * Extracts the quantity (numeric part) from a given string containing both quantity and unit.","lastModifiedDate":"2023-10-23"},{"lineNumber":590,"author":{"gitId":"ShaniceTang"},"content":" * @param qty A string containing both quantity and unit (e.g., \"100g\").","lastModifiedDate":"2023-10-23"},{"lineNumber":591,"author":{"gitId":"ShaniceTang"},"content":" * @return An integer representing the extracted quantity.","lastModifiedDate":"2023-10-23"},{"lineNumber":592,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":593,"author":{"gitId":"ShaniceTang"},"content":" public static int extractQty(String qty) {","lastModifiedDate":"2023-10-23"},{"lineNumber":594,"author":{"gitId":"ShaniceTang"},"content":" return Integer.parseInt(qty.replaceAll(\"[^0-9]\", \"\"));","lastModifiedDate":"2023-10-23"},{"lineNumber":595,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":596,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":597,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":598,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":599,"author":{"gitId":"ShaniceTang"},"content":" * Extracts the unit (non-numeric part) from a given string containing both quantity and unit.","lastModifiedDate":"2023-10-23"},{"lineNumber":600,"author":{"gitId":"ShaniceTang"},"content":" * @param qty A string containing both quantity and unit (e.g., \"100g\").","lastModifiedDate":"2023-10-23"},{"lineNumber":601,"author":{"gitId":"ShaniceTang"},"content":" * @return A string representing the extracted unit.","lastModifiedDate":"2023-10-23"},{"lineNumber":602,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":603,"author":{"gitId":"ShaniceTang"},"content":" public static String extractUnit(String qty) {","lastModifiedDate":"2023-10-23"},{"lineNumber":604,"author":{"gitId":"ShaniceTang"},"content":" return qty.replaceAll(\"[0-9]\", \"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":605,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":606,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"NaychiMin":67,"DextheChik3n":212,"Cazh1":119,"ziyi105":135,"ShaniceTang":73}},{"path":"src/main/java/seedu/cafectrl/parser/ParserUtil.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" * Parser interface for external class to use Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"public interface ParserUtil {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" Command parseCommand(Menu menu, String userInput, Ui ui,","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" Pantry pantry, Sales sales, CurrentDate currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ziyi105":16}},{"path":"src/main/java/seedu/cafectrl/parser/exception/ParserException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.parser.exception;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":" * Represents a parse error encountered by parser.","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"public class ParserException extends Exception {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":" * @param errorMessage contains relevant information on failed constraint(s)","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" public ParserException(String errorMessage) {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":" super(errorMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"DextheChik3n":12}},{"path":"src/main/java/seedu/cafectrl/storage/Decoder.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"NaychiMin"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" * The Decoder class offers methods to interpret string representations from text files,","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" * decoding them into appropriate data structures. It includes methods to decode a Menu,","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":" * Pantry stock, and OrderList, allowing retrieval of data stored in a file.","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"public class Decoder {","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" private static final String DIVIDER \u003d \"\\\\| \";","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" private static final Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" * Decodes an ArrayList of string lines into a Menu object, reconstructing its content.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" * @param textLines An ArrayList of strings representing the encoded Menu data.","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" * @return A Menu object containing the decoded Menu data.","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" public static Menu decodeMenuData(ArrayList\u003cString\u003e textLines) {","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cDish\u003e menuDishList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" for(String dishString : textLines) {","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" String[] dishStringArray \u003d dishString.split(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" String dishName \u003d dishStringArray[0].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" float dishPrice \u003d Float.parseFloat(dishStringArray[1]);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" String[] ingredientStringArray \u003d Arrays.copyOfRange(dishStringArray, 2, dishStringArray.length);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d decodeIngredientData(ingredientStringArray);","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" menuDishList.add(new Dish(dishName, ingredientsList, dishPrice));","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" return new Menu(menuDishList);","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" * Decodes an array of strings representing ingredient data into a list of Ingredient objects.","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredientsStringArray An array of strings containing encoded ingredient data.","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" * @return An ArrayList of Ingredient objects containing the decoded ingredient information.","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" private static ArrayList\u003cIngredient\u003e decodeIngredientData(String[] ingredientsStringArray) {","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" for(String ingredientString : ingredientsStringArray) {","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" String[] array \u003d ingredientString.split(\" \");","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":" String name \u003d array[0].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" int qty \u003d Integer.parseInt(array[1]);","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":" String unit \u003d array[2].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" ingredientList.add(new Ingredient(name, qty, unit));","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" return ingredientList;","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":" * Decodes raw string from pantry stock data file and create ingredient object from the data","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" * @param encodedPantryStock raw string from pantry stock data file","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" * @return a new pantry object with data from the pantry stock data file","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":" public static Pantry decodePantryStockData(ArrayList\u003cString\u003e encodedPantryStock) {","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":" if (encodedPantryStock.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":" return new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"ziyi105"},"content":" for (String encodedData : encodedPantryStock) {","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":" String[] decodedData \u003d encodedData.split(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":" if (!isValidPantryStockFormat(decodedData)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.ERROR_IN_PANTRY_STOCK_DATA);","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"ziyi105"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"ziyi105"},"content":" Ingredient ingredient \u003d new Ingredient(decodedData[0],","lastModifiedDate":"2023-10-28"},{"lineNumber":83,"author":{"gitId":"ziyi105"},"content":" Integer.parseInt(decodedData[1].trim()), decodedData[2]);","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ziyi105"},"content":" pantryStock.add(ingredient);","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":" return new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"ziyi105"},"content":" * Checks whether the pantry stock is in the format of ingredient name | quantity (int) | unit","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"ziyi105"},"content":" * @param decodedPantryStock string array of the raw data string from pantry stock data file","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":" * split with \"|\"","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"ziyi105"},"content":" * @return true if the format is correct, false otherwise","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"ziyi105"},"content":" private static boolean isValidPantryStockFormat(String[] decodedPantryStock) {","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"ziyi105"},"content":" if (decodedPantryStock.length !\u003d 3) {","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.ERROR_IN_PANTRY_STOCK_DATA);","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"ziyi105"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"ziyi105"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-10-28"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":" Integer.parseInt(decodedPantryStock[1].trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.ERROR_IN_PANTRY_STOCK_DATA);","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" return false;","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"ziyi105"},"content":" return true;","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":110,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"NaychiMin"},"content":" * Decodes a list of order data and constructs a Sales object using an array of OrderList objects.","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"NaychiMin"},"content":" * @param textLines List of order strings in the format \"dishName|quantity|totalOrderCost\".","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"NaychiMin"},"content":" * @param menu Menu instance to retrieve Dish objects based on dishName.","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"NaychiMin"},"content":" * @return Sales object containing OrderList objects decoded from the provided strings.","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"NaychiMin"},"content":" public static Sales decodeSales(ArrayList\u003cString\u003e textLines, Menu menu) {","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrderList\u003e orderLists \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"NaychiMin"},"content":" if(textLines.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"NaychiMin"},"content":" return new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"NaychiMin"},"content":" //for each \u0027order\u0027 in text file","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"NaychiMin"},"content":" for (String line : textLines) {","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"NaychiMin"},"content":" String[] orderData \u003d line.split(DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"NaychiMin"},"content":" int day \u003d Integer.parseInt(orderData[0].trim()) - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"NaychiMin"},"content":" String dishName \u003d orderData[1].trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"NaychiMin"},"content":" int quantity \u003d Integer.parseInt(orderData[2].trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"NaychiMin"},"content":" float totalOrderCost \u003d Float.parseFloat(orderData[3].trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"NaychiMin"},"content":" boolean isComplete \u003d \"true\".equals(orderData[4].trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"NaychiMin"},"content":" Order orderedDish \u003d new Order(menu.getDishFromName(dishName), quantity, totalOrderCost, isComplete);","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"NaychiMin"},"content":" //increase size of orderLists if needed","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"NaychiMin"},"content":" //this can be used in the event that the text file\u0027s first order is not day 0","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"NaychiMin"},"content":" while (orderLists.size() \u003c\u003d day) {","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"NaychiMin"},"content":" orderLists.add(new OrderList());","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":140,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"NaychiMin"},"content":" orderLists.get(day).addOrder(orderedDish);","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":" return new Sales(orderLists);","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"NaychiMin":50,"ziyi105":56,"ShaniceTang":39}},{"path":"src/main/java/seedu/cafectrl/storage/Encoder.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":" * The Encoder class provides methods to encode various data structures into string representations to","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" * be written into their respective text files.","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" * It includes methods to encode a Menu, Pantry stock, and OrderList,","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" * making the data suitable for saving to a file.","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"public class Encoder {","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":" private static final String DIVIDER \u003d \" | \";","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" * Encodes a Menu object into a list of strings representing its contents, suitable for saving to a file.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" * @param menu The Menu object to encode into a string representation.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" * @return An ArrayList of strings, where each string represents a Dish in the Menu.","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" public static ArrayList\u003cString\u003e encodeMenu(Menu menu) {","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cString\u003e menuStringList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cDish\u003e menuDishList \u003d menu.getMenuItemsList();","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" for(Dish dish : menuDishList) {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" StringBuilder dishString \u003d new StringBuilder();","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(dish.getName() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(dish.getPrice() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(encodeIngredientList(dish.getIngredients()));","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" dishString.append(System.lineSeparator());","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" menuStringList.add(String.valueOf(dishString));","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" return menuStringList;","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" * Encodes a list of ingredients into a StringBuilder for inclusion in the menu encoding.","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" * @param ingredientList The list of Ingredient objects to encode.","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" * @return A StringBuilder containing the encoded representation of the ingredient list.","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" private static StringBuilder encodeIngredientList(ArrayList\u003cIngredient\u003e ingredientList) {","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" StringBuilder ingredientListString \u003d new StringBuilder();","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" for(Ingredient ingredient : ingredientList) {","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" ingredientListString.append(ingredient.getName() + \" \");","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" ingredientListString.append(ingredient.getQty() + \" \");","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" ingredientListString.append(ingredient.getUnit() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" return ingredientListString;","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ziyi105"},"content":" * Encodes the pantry stock into format ingredient name | quantity | unit","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ziyi105"},"content":" * @param pantry the pantry from current session","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ziyi105"},"content":" * @return an arrayList of string of ecoded pantry stock","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":" public static ArrayList\u003cString\u003e encodePantryStock(Pantry pantry) {","lastModifiedDate":"2023-10-28"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":" // Convert pantry stock to a list of String","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e pantryStockInString \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d pantry.getPantryStock();","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" for (Ingredient ingredient : pantryStock) {","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" StringBuilder encodedIngredient \u003d new StringBuilder();","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(ingredient.getName());","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(ingredient.getQty());","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(ingredient.getUnit());","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":" encodedIngredient.append(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ziyi105"},"content":" pantryStockInString.add(encodedIngredient.toString());","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"ziyi105"},"content":" return pantryStockInString;","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":80,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" * Encodes a Sales object into a list of strings for storage.","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" * Each string represents an order, including day, dish name, quantity, and total cost.","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" * @param sales The Sales object to be encoded.","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" * @return An ArrayList of strings representing the encoded sales data.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" public static ArrayList\u003cString\u003e encodeSales(Sales sales) {","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cString\u003e encodedList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cOrderList\u003e orderLists \u003d sales.getOrderLists();","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" for (int day \u003d 0; day \u003c orderLists.size(); day++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" //get orderList for each day from list of sales","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" OrderList orderList \u003d sales.getOrderList(day);","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" //get order from each orderList obtained","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" for (Order order : orderList.getOrderList()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" StringBuilder orderString \u003d new StringBuilder();","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" //day of each orderList is index + 1","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" orderString.append((day + 1) + DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.getDishName() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.getQuantity() + DIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.calculateTotalOrderCost() + DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"NaychiMin"},"content":" orderString.append(order.getIsComplete());","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"NaychiMin"},"content":" orderString.append(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":" encodedList.add(String.valueOf(orderString));","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" return encodedList;","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"NaychiMin":35,"ziyi105":31,"ShaniceTang":45}},{"path":"src/main/java/seedu/cafectrl/storage/FileManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import java.io.File;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import java.nio.file.Files;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import java.nio.file.Path;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import java.nio.file.Paths;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":"//@@author DextheChik3n","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":" * Manage everything related to file such as writing, reading, opening and creating file","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"public class FileManager {","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"DextheChik3n"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" public FileManager(Ui ui) {","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" * Reads the text file from the specified file path and stores each line in an ArrayList.","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":" * @return ArrayList that consists of every text line in each element","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"DextheChik3n"},"content":" * @throws FileNotFoundException if text file at the specified file path does not exist","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"DextheChik3n"},"content":" public ArrayList\u003cString\u003e readTextFile(String filePath) throws FileNotFoundException {","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" String userWorkingDirectory \u003d System.getProperty(\"user.dir\");","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":" Path dataFilePath \u003d Paths.get(userWorkingDirectory, filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" File textFile \u003d new File(String.valueOf(dataFilePath));","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cString\u003e textLines \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" Scanner s \u003d new Scanner(textFile);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"DextheChik3n"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"DextheChik3n"},"content":" textLines.add(s.nextLine());","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"DextheChik3n"},"content":" s.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"DextheChik3n"},"content":" return textLines;","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":49,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":50,"author":{"gitId":"DextheChik3n"},"content":" * Checks if the text file and folder exists in the user\u0027s system and creates them (if needed)","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath the specified path location of the file","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":53,"author":{"gitId":"DextheChik3n"},"content":" public void checkFileExists(String filePath) throws IOException {","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"DextheChik3n"},"content":" String userWorkingDirectory \u003d System.getProperty(\"user.dir\");","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"DextheChik3n"},"content":" Path dataFilePath \u003d Paths.get(userWorkingDirectory, filePath);","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"DextheChik3n"},"content":" Path dataFolderPath \u003d dataFilePath.getParent();","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"DextheChik3n"},"content":" File textFile \u003d new File(String.valueOf(dataFilePath));","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"DextheChik3n"},"content":" File folder \u003d new File(String.valueOf(dataFolderPath));","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"DextheChik3n"},"content":" //Check if data folder exists","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"DextheChik3n"},"content":" if (!Files.exists(dataFolderPath)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":62,"author":{"gitId":"DextheChik3n"},"content":" folder.mkdir();","lastModifiedDate":"2023-10-28"},{"lineNumber":63,"author":{"gitId":"DextheChik3n"},"content":" ui.showToUser(ErrorMessages.DATA_FOLDER_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":65,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" //Check if the file at the specified file path exists","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" if (!Files.exists(dataFilePath)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" textFile.createNewFile();","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":72,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":73,"author":{"gitId":"DextheChik3n"},"content":" * Writes a list of texts to the text file at the specified file path.","lastModifiedDate":"2023-10-28"},{"lineNumber":74,"author":{"gitId":"DextheChik3n"},"content":" * Will overwrite all text in text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":75,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":76,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath file path of the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":77,"author":{"gitId":"DextheChik3n"},"content":" * @param listOfTextToAdd text to be written to the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"DextheChik3n"},"content":" * @throws IOException If I/O operations are interrupted.","lastModifiedDate":"2023-10-28"},{"lineNumber":79,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":80,"author":{"gitId":"DextheChik3n"},"content":" public void overwriteFile(String filePath, ArrayList\u003cString\u003e listOfTextToAdd) throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"DextheChik3n"},"content":" checkFileExists(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"DextheChik3n"},"content":" FileWriter fw \u003d new FileWriter(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"DextheChik3n"},"content":" for (String line : listOfTextToAdd) {","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"DextheChik3n"},"content":" fw.write(line);","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"DextheChik3n"},"content":" fw.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"DextheChik3n"},"content":" * Writes text to the text file at the specified file path.","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"DextheChik3n"},"content":" * Will overwrite all text in text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath file path of the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"DextheChik3n"},"content":" * @param textToAdd text to be written to the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"DextheChik3n"},"content":" * @throws IOException If I/O operations are interrupted.","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":97,"author":{"gitId":"DextheChik3n"},"content":" public void overwriteFile(String filePath, String textToAdd) throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"DextheChik3n"},"content":" checkFileExists(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"DextheChik3n"},"content":" FileWriter fw \u003d new FileWriter(filePath);","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"DextheChik3n"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-28"},{"lineNumber":101,"author":{"gitId":"DextheChik3n"},"content":" fw.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":102,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":103,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":105,"author":{"gitId":"DextheChik3n"},"content":" * Appends text to the text file at the specified file path.","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"DextheChik3n"},"content":" * Will add text to text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":107,"author":{"gitId":"DextheChik3n"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"DextheChik3n"},"content":" * @param filePath file path of the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"DextheChik3n"},"content":" * @param textToAdd text to be added to the text file.","lastModifiedDate":"2023-10-28"},{"lineNumber":110,"author":{"gitId":"DextheChik3n"},"content":" * @throws IOException If I/O operations are interrupted.","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":112,"author":{"gitId":"DextheChik3n"},"content":" public void appendToFile(String filePath, String textToAdd) throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":113,"author":{"gitId":"DextheChik3n"},"content":" checkFileExists(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"DextheChik3n"},"content":" FileWriter fw \u003d new FileWriter(filePath, true);","lastModifiedDate":"2023-10-28"},{"lineNumber":115,"author":{"gitId":"DextheChik3n"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-28"},{"lineNumber":116,"author":{"gitId":"DextheChik3n"},"content":" fw.close();","lastModifiedDate":"2023-10-28"},{"lineNumber":117,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":118,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"DextheChik3n":104,"ziyi105":12,"ShaniceTang":2}},{"path":"src/main/java/seedu/cafectrl/storage/FilePath.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"public class FilePath {","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" public static final String MENU_FILE_PATH \u003d \"data/menu.txt\";","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" public static final String PANTRY_STOCK_FILE_PATH \u003d \"data/pantry_stock.txt\";","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" public static final String ORDERS_FILE_PATH \u003d \"data/orders.txt\";","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ziyi105":8}},{"path":"src/main/java/seedu/cafectrl/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.storage;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"//@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" * Handles loading and saving data for menu, orderList, pantryStock","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"public class Storage {","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" protected FileManager fileManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" protected Ui ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" public Storage (Ui ui) {","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" this.fileManager \u003d new FileManager(ui);","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" * Loads menu data from a text file, decodes it, and returns it as a Menu object.","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" * @return A Menu object containing data from the file.","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" public Menu loadMenu() {","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cString\u003e encodedMenu \u003d fileManager.readTextFile(FilePath.MENU_FILE_PATH);","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" return Decoder.decodeMenuData(encodedMenu);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" ui.showToUser(ErrorMessages.MENU_FILE_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" return new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" * Encodes the provided menu data and writes it to a text file.","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" * @param menu The Menu object to be saved to the file.","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":" * @throws IOException if the file is not found in the specified file path.","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" private void saveMenu(Menu menu) throws IOException {","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" fileManager.overwriteFile(FilePath.MENU_FILE_PATH, Encoder.encodeMenu(menu));","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":" * Read and decode pantryStock data from text file and pass it to the menu","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":" * @return pantryStock with data from the file","lastModifiedDate":"2023-10-28"},{"lineNumber":56,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"ziyi105"},"content":" public Pantry loadPantryStock() {","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e encodedPantryStock \u003d this.fileManager.readTextFile(FilePath.PANTRY_STOCK_FILE_PATH);","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"ziyi105"},"content":" return Decoder.decodePantryStockData(encodedPantryStock);","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"ziyi105"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(ErrorMessages.PANTRY_FILE_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ziyi105"},"content":" return new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" * Encode and write the data from PantryStock to the text file","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" * @param pantry pantry from current session","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"ziyi105"},"content":" * @throws IOException if the file is not found in the specified file path","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":" private void savePantryStock(Pantry pantry) throws IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ziyi105"},"content":" this.fileManager.overwriteFile(FilePath.PANTRY_STOCK_FILE_PATH, Encoder.encodePantryStock(pantry));","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" //@@author NaychiMin","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" * Loads order lists from a text file, decodes it, and returns it as a Sales object.","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":" * @return An OrderList object containing data from the file.","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":82,"author":{"gitId":"NaychiMin"},"content":" public Sales loadOrderList(Menu menu) {","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"NaychiMin"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cString\u003e encodedOrderList \u003d fileManager.readTextFile(FilePath.ORDERS_FILE_PATH);","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" return Decoder.decodeSales(encodedOrderList, menu);","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"NaychiMin"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"NaychiMin"},"content":" ui.showToUser(ErrorMessages.ORDER_LIST_FILE_NOT_FOUND_MESSAGE, System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":" return new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"NaychiMin"},"content":" * Encodes the provided OrderList data from Sales object and writes it to a text file","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":" * @param sales The Sales object containing the order to be saved to the file.","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" * @throws IOException if the file is not found in the specified file path.","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" private void saveOrderList(Sales sales) throws IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"NaychiMin"},"content":" this.fileManager.overwriteFile(FilePath.ORDERS_FILE_PATH, Encoder.encodeSales(sales));","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"ziyi105"},"content":" //@@author ziyi105","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":" * Encode and write the data from menu, orderList and pantry to the respective text files","lastModifiedDate":"2023-10-28"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" * @param menu menu from current session","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"ziyi105"},"content":" * @param sales sale object from current session","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":" * @param pantry pantry from current session","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"ziyi105"},"content":" public void saveAll(Menu menu, Sales sales, Pantry pantry) {","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"ziyi105"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"ziyi105"},"content":" saveMenu(menu);","lastModifiedDate":"2023-10-28"},{"lineNumber":112,"author":{"gitId":"ziyi105"},"content":" saveOrderList(sales);","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":" saveMenu(menu);","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"ziyi105"},"content":" savePantryStock(pantry);","lastModifiedDate":"2023-10-28"},{"lineNumber":115,"author":{"gitId":"ziyi105"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"ziyi105"},"content":" ui.showToUser(e.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":119,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":120,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"NaychiMin":26,"DextheChik3n":8,"ziyi105":59,"ShaniceTang":27}},{"path":"src/main/java/seedu/cafectrl/ui/ErrorMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.ui;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"public class ErrorMessages {","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":" /** Error messages */","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_ADD_DISH_FORMAT_MESSAGE \u003d \"Error: Incorrect format for the add command.\\n\";","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":" public static final String NULL_NAME_DETECTED_MESSAGE \u003d \"Error: Null dish name detected\";","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_PRICE_MESSAGE \u003d \"Error: Price value entered is too big!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":" public static final String INVALID_DISH_NAME_LENGTH_MESSAGE \u003d \"Error: Your dish name length is too long!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":" public static final String INVALID_INGREDIENT_NAME_LENGTH_MESSAGE \u003d \"Error: Your dish name length is too long!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_EDIT_PRICE \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" + \"for edit price command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_LIST_INGREDIENTS \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":" + \"for list ingredients command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_DELETE \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" + \"for delete command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" public static final String MISSING_ARGUMENT_FOR_BUY_INGREDIENT \u003d \"Error: Missing arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" + \"for buy ingredient command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" public static final String WRONG_ARGUMENT_TYPE_FOR_EDIT_PRICE \u003d \"Error: Invalid dish index. \\n \"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" + \"Make sure dish index is \"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" + \"of type int and price is of type float!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" public static final String UNKNOWN_COMMAND_MESSAGE \u003d \"Error: Unknown command. \"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" + \"Type \u0027help\u0027 to view the accepted list of commands\";","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_DISH_INDEX \u003d \"Error: Invalid dish index.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_ARGUMENT_FOR_BUY_INGREDIENT \u003d \"Error: Invalid arguments \"","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" + \"for buy ingredient command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" public static final String INVALID_ADD_ORDER_FORMAT_MESSAGE \u003d \"Error: Incorrect format for the add order command.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" public static final String DATA_FOLDER_NOT_FOUND_MESSAGE \u003d \"Data Folder was not found!\\nIt\u0027s ok... \"","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":" + \"a new data folder has been created.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":" public static final String DISH_NOT_FOUND \u003d \"I\u0027m sorry, but it appears that dish is so exclusive \"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" + \"it hasn\u0027t even made it to our menu yet!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" public static final String ERROR_IN_PANTRY_STOCK_DATA \u003d \"Error in pantry stock data file! Skipping this \"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" + \"particular ingredient!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" public static final String UNIT_NOT_MATCHING \u003d \"Sorry, you have used a different unit for this ingredient!\";","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DextheChik3n"},"content":" public static final String MENU_FILE_NOT_FOUND_MESSAGE \u003d \"Menu data was not found!\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" + \"No worries, new menu has been created\";","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":" public static final String PANTRY_FILE_NOT_FOUND_MESSAGE \u003d \"Pantry stock data was not found!\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"DextheChik3n"},"content":" + \"No worries, new pantry has been created\";","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" public static final String ORDER_LIST_FILE_NOT_FOUND_MESSAGE \u003d \"Order list data was not found!\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"DextheChik3n"},"content":" + \"No worries, new order list has been created\";","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":" public static final String INVALID_SHOW_SALE_DAY_FORMAT_MESSAGE \u003d \"Error: Incorrect format for the show_sale \"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"NaychiMin"},"content":" + \"command.\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":" public static final String INVALID_DAY_FORMAT \u003d \"Sorry, please enter a valid integer for the \u0027day\u0027 field!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"NaychiMin":5,"DextheChik3n":9,"ziyi105":28,"ShaniceTang":1}},{"path":"src/main/java/seedu/cafectrl/ui/Messages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"public class Messages {","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":" /** Greeting messages */","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":" public static final String LINE_STRING \u003d \"-----------------------------------------------------\";","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":" public static final String WELCOME_MESSAGE \u003d \"Hello! Welcome to CafeCTRL!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":" public static final String GOODBYE_MESSAGE \u003d \"Goodbye \u003c3 Have a great day ahead!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":" /** Messages for edit price command */","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":" public static final String PRICE_MODIFIED_MESSAGE \u003d \"Price modified for the following dish: \";","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":" /** Messages for list menu command */","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" public static final String LIST_MENU_MESSAGE \u003d \"| Ah, behold, the grand menu of delights! |\";","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_EMPTY_MESSAGE \u003d \"It seems our menu is currently taking a break. \"","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" + \"Let\u0027s give it a wake-up call and fill \u0027er up with delectable delights, shall we?\";","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_END_CAP \u003d \"+-------------------------------------------------------+\";","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_CORNER \u003d \"+----------------------------------------+--------------+\";","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public static final String MENU_TITLE \u003d \"| Dish Name | Price |\";","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" /** Messages for add dish command */","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" public static final String ADD_DISH_MESSAGE \u003d \"You have added the following dish...\";","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" public static final String REPEATED_DISH_MESSAGE \u003d \"Sorry, this dish name already exists.\";","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" /** Messages for view stock command */","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" public static final String VIEW_STOCK \u003d \"You have the following ingredients in pantry:\"","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" + \"\\nIngredients\\t\\tQty\";","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" /** Messages for help command */","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" public static final String LIST_OF_COMMANDS \u003d \"These are all the commands I recognise: \";","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" public static final String INSTRUCTION_ON_COMMAND_FORMAT \u003d \"- Words in UPPER_CASE are \"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" + \"the parameters to be supplied by the user.\\n\"","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":" + \" e.g. in add name/NAME, NAME is a parameter that can be used as add name/Chicken.\\n\"","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" + \"- Parameters in [] are optional.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" /** Messages for order command */","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" public static final String CHEF_MESSAGE \u003d \"I\u0027m busy crafting your selected dish \"","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" + \"in the virtual kitchen of your dreams. Bon appétit!\";","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":" public static final String PREVIOUS_DAY_TIME_TRAVEL \u003d \"Whoa there, time traveler! \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" \"Unfortunately, the DeLorean can\u0027t take us back to the previous day because it\u0027s already Day 1, \" +","lastModifiedDate":"2023-11-05"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" \"and there\u0027s no rewind button in this space-time continuum!\";","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" public static final String PREVIOUS_DAY_COMMAND_MESSAGE \u003d \"Sure thing! \"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" + \"Let\u0027s rev up the virtual DeLorean and take a spin to the previous day. \"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" + \"Buckle up, it\u0027s time to hit that rewind button!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" public static final String NEXT_DAY_COMMAND_MESSAGE \u003d \"Prepare for liftoff! \"","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" + \"We\u0027re about to fast-forward to the next day. \"","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" + \"Hold onto your hats; here we go!\";","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DextheChik3n"},"content":" public static final String INITIALISE_STORAGE_MESSAGE \u003d \"...Downloading data...\";","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":" public static final String AVAILABLE_DISHES \u003d \"Listed below are the availability of the dishes for the next order!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":" public static final String COMPLETE_ORDER \u003d \"Order is ready!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" public static final String INCOMPLETE_ORDER \u003d \"Please restock ingredients before preparing the order :) \";","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"NaychiMin":3,"DextheChik3n":5,"Cazh1":17,"ziyi105":13,"ShaniceTang":15}},{"path":"src/main/java/seedu/cafectrl/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.AddDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.AddOrderCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.BuyIngredientCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.DeleteDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.EditPriceCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ExitCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.HelpCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListIngredientCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ListMenuCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.NextDayCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.PreviousDayCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.command.ViewTotalStockCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":"import java.text.DecimalFormat;","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"NaychiMin"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":"public class Ui {","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"DextheChik3n"},"content":" public static final int OFFSET_LIST_INDEX \u003d 1;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"NaychiMin"},"content":" private final Scanner scanner;","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" * Constructs a UI instance with a Scanner for user input.","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" public Ui() {","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"DextheChik3n"},"content":" public void printLine() {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":" showToUser(Messages.LINE_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":" public String receiveUserInput() {","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" System.out.print(\"\u003e \");","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"NaychiMin"},"content":" return scanner.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":" public void showWelcome() {","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" showToUser(Messages.WELCOME_MESSAGE);","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"NaychiMin"},"content":" public void showGoodbye() {","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" showToUser(Messages.GOODBYE_MESSAGE);","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"NaychiMin"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"NaychiMin"},"content":" * Prints out the quantity of each ingredient needed for the","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" * dish that the user selects.","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"NaychiMin"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"NaychiMin"},"content":" * @param selectedDish Dish for ingredients to be listed out.","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" public void printIngredients(Dish selectedDish) {","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" String ingredientsString \u003d selectedDish.getName() + \" Ingredients: \\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" for (Ingredient ingredient : selectedDish.getIngredients()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" ingredientsString +\u003d ingredient.toString() + \"\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" showToUser(ingredientsString.trim());","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"DextheChik3n"},"content":" public void printAddDishMessage(Dish dish) {","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"DextheChik3n"},"content":" String dishNameString \u003d \"Dish Name: \" + dish.getName();","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"DextheChik3n"},"content":" DecimalFormat dollarValue \u003d new DecimalFormat(\"0.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"DextheChik3n"},"content":" float dishPrice \u003d dish.getPrice();","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"DextheChik3n"},"content":" String dishPriceString \u003d \"Dish Price: $\" + dollarValue.format(dishPrice);","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" showToUser(Messages.ADD_DISH_MESSAGE,","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"DextheChik3n"},"content":" dishNameString,","lastModifiedDate":"2023-10-17"},{"lineNumber":74,"author":{"gitId":"DextheChik3n"},"content":" dishPriceString);","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"DextheChik3n"},"content":" printIngredients(dish);","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"ShaniceTang"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"ShaniceTang"},"content":" * Shows delete message to user","lastModifiedDate":"2023-10-17"},{"lineNumber":81,"author":{"gitId":"ShaniceTang"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"ShaniceTang"},"content":" * @param selectedDish Dish to be deleted","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":84,"author":{"gitId":"ShaniceTang"},"content":" public void printDeleteMessage(Dish selectedDish) {","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ShaniceTang"},"content":" showToUser(\"Okay! \" + selectedDish.getName() + \" is deleted! :)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":86,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":88,"author":{"gitId":"ShaniceTang"},"content":" public void printBuyIngredientHeader() {","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"ShaniceTang"},"content":" showToUser(\"Added to stock:\");","lastModifiedDate":"2023-10-25"},{"lineNumber":90,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"DextheChik3n"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":93,"author":{"gitId":"DextheChik3n"},"content":" * Shows messages(s) to the user","lastModifiedDate":"2023-10-17"},{"lineNumber":94,"author":{"gitId":"DextheChik3n"},"content":" * @param message string(s) of messages to print","lastModifiedDate":"2023-10-17"},{"lineNumber":95,"author":{"gitId":"DextheChik3n"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":96,"author":{"gitId":"DextheChik3n"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"DextheChik3n"},"content":" for (String m: message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"DextheChik3n"},"content":" System.out.println(m);","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"Cazh1"},"content":" * Shows menu to user is table format","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"Cazh1"},"content":" * @param dishName","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"Cazh1"},"content":" * @param dishPrice","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"ziyi105"},"content":" public void formatListMenu(String dishName, String dishPrice) {","lastModifiedDate":"2023-10-22"},{"lineNumber":108,"author":{"gitId":"Cazh1"},"content":" String leftAlignFormat \u003d \"| %-38s | %-12s |%n\";","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"Cazh1"},"content":" System.out.format(leftAlignFormat, dishName, dishPrice);","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"Cazh1"},"content":" //+-----------------+------+","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":114,"author":{"gitId":"ziyi105"},"content":" * show edit price message to user","lastModifiedDate":"2023-10-17"},{"lineNumber":115,"author":{"gitId":"ziyi105"},"content":" * @param menuItem menuItem that has been modified","lastModifiedDate":"2023-10-17"},{"lineNumber":116,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":117,"author":{"gitId":"ziyi105"},"content":" public void showEditPriceMessage(String menuItem) {","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"ziyi105"},"content":" this.showToUser(Messages.PRICE_MODIFIED_MESSAGE, menuItem);","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":120,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"ziyi105"},"content":" public void showHelp() {","lastModifiedDate":"2023-10-22"},{"lineNumber":122,"author":{"gitId":"ShaniceTang"},"content":" showToUserWithSpaceBetweenLines(Messages.LIST_OF_COMMANDS,","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"ShaniceTang"},"content":" Messages.INSTRUCTION_ON_COMMAND_FORMAT,","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"ziyi105"},"content":" AddDishCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"ziyi105"},"content":" AddOrderCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"ziyi105"},"content":" BuyIngredientCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"ziyi105"},"content":" DeleteDishCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"ziyi105"},"content":" EditPriceCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"ziyi105"},"content":" ExitCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"ziyi105"},"content":" HelpCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"ziyi105"},"content":" ListIngredientCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ziyi105"},"content":" ListMenuCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"ziyi105"},"content":" NextDayCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"ziyi105"},"content":" PreviousDayCommand.MESSAGE_USAGE,","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"ziyi105"},"content":" ViewTotalStockCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":138,"author":{"gitId":"ziyi105"},"content":" public void showToUserWithSpaceBetweenLines(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":139,"author":{"gitId":"ziyi105"},"content":" for (String m: message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":140,"author":{"gitId":"ziyi105"},"content":" System.out.println(m + \"\\n\");","lastModifiedDate":"2023-10-22"},{"lineNumber":141,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":143,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":144,"author":{"gitId":"NaychiMin"},"content":" public void showDishAvailability(int numberOfDishes){","lastModifiedDate":"2023-10-24"},{"lineNumber":145,"author":{"gitId":"NaychiMin"},"content":" showToUser(\"Available Dishes: \" + numberOfDishes);","lastModifiedDate":"2023-10-24"},{"lineNumber":146,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":147,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":148,"author":{"gitId":"NaychiMin"},"content":" public void showNeededRestock(String ingredientName, int currentQuantity, String unit, String neededIngredient){","lastModifiedDate":"2023-10-24"},{"lineNumber":149,"author":{"gitId":"NaychiMin"},"content":" showToUser(\"Please Restock: \" + ingredientName","lastModifiedDate":"2023-10-24"},{"lineNumber":150,"author":{"gitId":"NaychiMin"},"content":" , \"Current \" + ingredientName + \": \" + currentQuantity + unit","lastModifiedDate":"2023-10-24"},{"lineNumber":151,"author":{"gitId":"NaychiMin"},"content":" , \"Needed \" + ingredientName + \": \" + neededIngredient);","lastModifiedDate":"2023-10-24"},{"lineNumber":152,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":" * Shows the top portion of the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":" public void showMenuTop() {","lastModifiedDate":"2023-10-27"},{"lineNumber":158,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.MENU_END_CAP, Messages.LIST_MENU_MESSAGE,","lastModifiedDate":"2023-10-27"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":" Messages.MENU_CORNER, Messages.MENU_TITLE, Messages.MENU_CORNER);","lastModifiedDate":"2023-10-27"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":" * Shows the bottom portion of the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":164,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":165,"author":{"gitId":"Cazh1"},"content":" public void showMenuBottom() {","lastModifiedDate":"2023-10-27"},{"lineNumber":166,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.MENU_END_CAP);","lastModifiedDate":"2023-10-27"},{"lineNumber":167,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":168,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":169,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":170,"author":{"gitId":"Cazh1"},"content":" * Shows the message for empty menu","lastModifiedDate":"2023-10-27"},{"lineNumber":171,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":172,"author":{"gitId":"Cazh1"},"content":" public void showEmptyMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":173,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.MENU_EMPTY_MESSAGE);","lastModifiedDate":"2023-10-27"},{"lineNumber":174,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":175,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":176,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":177,"author":{"gitId":"Cazh1"},"content":" * Shows the dishes in the menu, formatted in the proper format","lastModifiedDate":"2023-10-27"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":179,"author":{"gitId":"Cazh1"},"content":" * @param indexNum The index number of the dish in the menu print","lastModifiedDate":"2023-10-27"},{"lineNumber":180,"author":{"gitId":"Cazh1"},"content":" * @param dishName The name of the dish in the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":181,"author":{"gitId":"Cazh1"},"content":" * @param dishPrice The price of the dish in the menu","lastModifiedDate":"2023-10-27"},{"lineNumber":182,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":183,"author":{"gitId":"Cazh1"},"content":" public void showMenuDish(String indexNum, String dishName, String dishPrice) {","lastModifiedDate":"2023-10-27"},{"lineNumber":184,"author":{"gitId":"Cazh1"},"content":" formatListMenu(indexNum + \". \" + dishName,\" $\" + dishPrice);","lastModifiedDate":"2023-10-27"},{"lineNumber":185,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":186,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":187,"author":{"gitId":"Cazh1"},"content":" public void showChefMessage() {","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.CHEF_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"Cazh1"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":194,"author":{"gitId":"Cazh1"},"content":" * Shows the total cost in the order list, formatted in the proper format","lastModifiedDate":"2023-10-27"},{"lineNumber":195,"author":{"gitId":"Cazh1"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":196,"author":{"gitId":"Cazh1"},"content":" * @param dollarCost The price of the orders","lastModifiedDate":"2023-10-27"},{"lineNumber":197,"author":{"gitId":"Cazh1"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":198,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-10-27"},{"lineNumber":199,"author":{"gitId":"NaychiMin"},"content":" showToUser(\"Total order cost: $\" + dollarCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":201,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"NaychiMin"},"content":" public void showOrderStatus(String orderStatus, String totalCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"NaychiMin"},"content":" printLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"NaychiMin"},"content":" showToUser(orderStatus);","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"NaychiMin"},"content":" showTotalCost(totalCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"NaychiMin"},"content":" printLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"NaychiMin"},"content":" showDishAvailabilityMessage();","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"NaychiMin"},"content":" public void showDishAvailabilityMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"NaychiMin"},"content":" showToUser(Messages.AVAILABLE_DISHES);","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"Cazh1"},"content":" public void showPreviousDay() {","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.PREVIOUS_DAY_COMMAND_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":216,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":217,"author":{"gitId":"Cazh1"},"content":" public void showNextDay() {","lastModifiedDate":"2023-10-30"},{"lineNumber":218,"author":{"gitId":"Cazh1"},"content":" showToUser(Messages.NEXT_DAY_COMMAND_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":219,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":220,"author":{"gitId":"NaychiMin"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"NaychiMin":65,"DextheChik3n":30,"Cazh1":63,"ziyi105":44,"ShaniceTang":18}},{"path":"src/test/java/seedu/cafectrl/UiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"/**","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":" * Junit test for Ui.java","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"public class UiTest {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"DextheChik3n":1,"ShaniceTang":7}},{"path":"src/test/java/seedu/cafectrl/command/AddDishCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"DextheChik3n"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"DextheChik3n"},"content":"class AddDishCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"DextheChik3n"},"content":" void execute_oneDishAdded_expectDishInMenu() {","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"DextheChik3n"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"DextheChik3n"},"content":" //creating a dish","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" ingredients.add(new Ingredient(\"chicken\", 100, \"g\"));","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", ingredients, (float) 1.00);","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" AddDishCommand addDishCommand \u003d new AddDishCommand(dish, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" addDishCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(1, menu.getMenuItemsList().size());","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":25,"Cazh1":3,"ShaniceTang":1}},{"path":"src/test/java/seedu/cafectrl/command/AddOrderCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Cazh1"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Order;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.OrderList;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":"class AddOrderCommandTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" public void execute_addOneOrder_expectOneOrder() {","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"chicken\", 100, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients2 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"chicken\", 200, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenRice \u003d new Dish(\"Chicken Rice\", ingredients, 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenCurry \u003d new Dish(\"Chicken Curry\", ingredients2, 4.30F);","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenRice);","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenCurry);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" assertEquals(2, menu.getSize());","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" Order orderChickenRice \u003d new Order(dishChickenRice, 2);","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d (\"Total orderList cost: $\" + dollarCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"chicken\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" OrderList orderList \u003d new OrderList();","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" Command addOrderCommand \u003d new AddOrderCommand(orderChickenRice, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" addOrderCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d Messages.CHEF_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" + \"Order is ready!\"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" + \"Total orderList cost: $5.00\"","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" + Messages.AVAILABLE_DISHES","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Rice\"","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 8\"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Curry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 4\";","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":" public void execute_addTwoOrder_expectTwoOrder() {","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"chicken\", 100, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"Cazh1"},"content":" ingredients.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e ingredients2 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"chicken\", 200, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"Cazh1"},"content":" ingredients2.add(new Ingredient(\"rice\", 50, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenRice \u003d new Dish(\"Chicken Rice\", ingredients, 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"Cazh1"},"content":" Dish dishChickenCurry \u003d new Dish(\"Chicken Curry\", ingredients2, 4.30F);","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenRice);","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"Cazh1"},"content":" menuItems.add(dishChickenCurry);","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"Cazh1"},"content":" assertEquals(2, menu.getSize());","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"Cazh1"},"content":" Order orderChickenRice \u003d new Order(dishChickenRice, 2);","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":" Order orderChickenCurry \u003d new Order(dishChickenCurry, 3);","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d (\"Total orderList cost: $\" + dollarCost);","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"chicken\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"Cazh1"},"content":" pantryStock.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"Cazh1"},"content":" Ui uiPrintNothing \u003d new Ui() {","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"Cazh1"},"content":" public void showTotalCost(String dollarCost) {","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"Cazh1"},"content":" OrderList orderList \u003d new OrderList();","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"Cazh1"},"content":" Command addOrderCommand \u003d new AddOrderCommand(orderChickenRice, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"Cazh1"},"content":" addOrderCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"Cazh1"},"content":" Command addOrderCommand2 \u003d new AddOrderCommand(orderChickenCurry, ui, pantry, orderList, menu);","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"Cazh1"},"content":" addOrderCommand2.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"Cazh1"},"content":" String expectedOutputForFirstOrder \u003d Messages.CHEF_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"Cazh1"},"content":" + \"Order is ready!\"","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"Cazh1"},"content":" + \"Total orderList cost: $5.00\"","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"Cazh1"},"content":" + Messages.AVAILABLE_DISHES","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Rice\"","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 8\"","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Curry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 4\";","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"Cazh1"},"content":" String expectedOutputForSecondOrder \u003d Messages.CHEF_MESSAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"Cazh1"},"content":" + \"Order is ready!\"","lastModifiedDate":"2023-11-01"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" + \"Total orderList cost: $12.90\"","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":" + Messages.AVAILABLE_DISHES","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Rice\"","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 2\"","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"Cazh1"},"content":" + Messages.LINE_STRING","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"Cazh1"},"content":" + \"Dish: Chicken Curry\"","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"Cazh1"},"content":" + \"Available Dishes: 1\";","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d expectedOutputForFirstOrder + expectedOutputForSecondOrder;","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":171,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"Cazh1"},"content":" private static String convertArrayToString(String[] message, String delimiter) {","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"Cazh1"},"content":" StringBuilder sb \u003d new StringBuilder();","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"Cazh1"},"content":" for (String str : message) {","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"Cazh1"},"content":" sb.append(str.toString()).append(delimiter);","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"Cazh1"},"content":" return sb.substring(0, sb.length() - 1);","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"Cazh1":181}},{"path":"src/test/java/seedu/cafectrl/command/BuyIngredientCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"public class BuyIngredientCommandTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" void execute_validInput_returnCorrectOutput() {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"milk\", 100, \"ml\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" ByteArrayOutputStream baos \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" PrintStream consoleStream \u003d new PrintStream(baos);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(consoleStream);","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" BuyIngredientCommand buyIngredientCommand \u003d new BuyIngredientCommand(ingredientsList, ui, pantry);","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" buyIngredientCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" String actualOutput \u003d baos.toString().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Added to stock: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: chicken\\t\\tQty: 500g\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: rice\\t\\tQty: 1000g\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: milk\\t\\tQty: 100ml\";","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" void execute_validInputWithExistingIngredient_returnCorrectOutput() {","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui, ingredientsList);","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"ShaniceTang"},"content":" ByteArrayOutputStream baos \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"ShaniceTang"},"content":" PrintStream consoleStream \u003d new PrintStream(baos);","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ShaniceTang"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(consoleStream);","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ShaniceTang"},"content":" BuyIngredientCommand buyIngredientCommand \u003d new BuyIngredientCommand(ingredientsList, ui, pantry);","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ShaniceTang"},"content":" buyIngredientCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"ShaniceTang"},"content":" String actualOutput \u003d baos.toString().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Added to stock: \\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredient: chicken\\t\\tQty: 1000g\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":73}},{"path":"src/test/java/seedu/cafectrl/command/CommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DextheChik3n"},"content":"class CommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"DextheChik3n":5}},{"path":"src/test/java/seedu/cafectrl/command/DeleteDishCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":"class DeleteDishCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" void execute_validInput() {","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Rice\", 2.50F));","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Curry\", 4.30F));","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Nasi Lemak\", 5.60F));","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" };","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":" int testIndex \u003d 2;","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" DeleteDishCommand deleteDishCommand \u003d new DeleteDishCommand(testIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" deleteDishCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" int actualOutputIndex \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Okay! Chicken Curry is deleted! :)\";","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput, actualOutput.get(actualOutputIndex));","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" void execute_invalidInput_throwIndexOutOfBoundsException() {","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Rice\", 2.50F));","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Chicken Curry\", 4.30F));","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"ShaniceTang"},"content":" menu.addDish(new Dish(\"Nasi Lemak\", 5.60F));","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"ShaniceTang"},"content":" int testIndex \u003d 5;","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" DeleteDishCommand deleteDishCommand \u003d new DeleteDishCommand(testIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" assertThrows(IndexOutOfBoundsException.class, () -\u003e deleteDishCommand.execute());","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":1,"Cazh1":8,"ShaniceTang":44}},{"path":"src/test/java/seedu/cafectrl/command/EditPriceCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"class EditPriceCommandTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":" void execute_validInput_editPrice() {","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" int testDishIndex \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" float testNewPrice \u003d 3;","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" Command editPriceCommand \u003d new EditPriceCommand(testDishIndex, testNewPrice, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" editPriceCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" int firstLine \u003d 0;","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":" int secondLine \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":" String expectedOutputFirstLine \u003d Messages.PRICE_MODIFIED_MESSAGE;","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":" String expectedOutputSecondLine \u003d testDish.toString();","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" assertEquals(expectedOutputFirstLine, actualOutput.get(firstLine));","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":" assertEquals(expectedOutputSecondLine, actualOutput.get(secondLine));","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"Cazh1":2,"ziyi105":40}},{"path":"src/test/java/seedu/cafectrl/command/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ziyi105"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"ziyi105"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"ziyi105"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ziyi105"},"content":"class HelpCommandTest {","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":" void execute_validInput_editPrice() {","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutputs \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":" actualOutputs.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":25,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ziyi105"},"content":" public void showToUserWithSpaceBetweenLines(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"ziyi105"},"content":" actualOutputs.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" HelpCommand helpCommand \u003d new HelpCommand(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" helpCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e expectedOutputs \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(Messages.LINE_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(Messages.LIST_OF_COMMANDS);","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(Messages.INSTRUCTION_ON_COMMAND_FORMAT);","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(AddDishCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(AddOrderCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(BuyIngredientCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(DeleteDishCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(EditPriceCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ExitCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(HelpCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ListIngredientCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ListMenuCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(NextDayCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(PreviousDayCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ziyi105"},"content":" expectedOutputs.add(ViewTotalStockCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ziyi105"},"content":" for (int i \u003d 0; i \u003c expectedOutputs.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ziyi105"},"content":" assertEquals(expectedOutputs.get(i), actualOutputs.get(i));","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"Cazh1":2,"ziyi105":55}},{"path":"src/test/java/seedu/cafectrl/command/ListIngredientCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"NaychiMin"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"NaychiMin"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"NaychiMin"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"NaychiMin"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"NaychiMin"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"class ListIngredientCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":" public void execute_validIndex_printsIngredients() {","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 1, \"cup\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"NaychiMin"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"NaychiMin"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"NaychiMin"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"NaychiMin"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" int indexToSelect \u003d 1;","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":" ListIngredientCommand listIngredientCommand \u003d new ListIngredientCommand(indexToSelect, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" listIngredientCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"Chicken Rice Ingredients: \\n\"","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" + \"Rice - 1cup\\n\"","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" + \"Chicken - 100g\\n\";","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"NaychiMin"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"NaychiMin"},"content":" actualOutput.get(0).trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"NaychiMin"},"content":" public void execute_invalidIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 1, \"cup\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" int invalidIndex \u003d 3;","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e {","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":" ListIngredientCommand listIngredientCommand \u003d new ListIngredientCommand(invalidIndex, menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" listIngredientCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" });","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"NaychiMin":44,"DextheChik3n":1,"Cazh1":8,"ShaniceTang":11}},{"path":"src/test/java/seedu/cafectrl/command/ListMenuCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"Cazh1"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.ui.Messages;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"Cazh1"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"Cazh1"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"Cazh1"},"content":"class ListMenuCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":" public void execute_addTwoDishes_expectTwoDishes() {","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"Cazh1"},"content":" menuItems.add(new Dish(\"Chicken Rice\", 2.50F));","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Cazh1"},"content":" menuItems.add(new Dish(\"Chicken Curry\", 4.30F));","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"Cazh1"},"content":" assertEquals(2, menu.getSize());","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":" public void formatListMenu(String dishName, String dishPrice) {","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"Cazh1"},"content":" String leftAlignFormat \u003d \"| %-24s | %-12s |\";","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d String.format(leftAlignFormat, dishName, dishPrice);","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"Cazh1"},"content":" Command listMenuCommand \u003d new ListMenuCommand(menu, ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"Cazh1"},"content":" listMenuCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d Messages.MENU_END_CAP","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"Cazh1"},"content":" + Messages.LIST_MENU_MESSAGE","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_CORNER","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_TITLE","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_CORNER","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" + \"| 1. Chicken Rice | $2.50 |\"","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"Cazh1"},"content":" + \"| 2. Chicken Curry | $4.30 |\"","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"Cazh1"},"content":" + Messages.MENU_END_CAP;","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"Cazh1"},"content":" public void execute_emptyMenu_expectEmptyMenuMessage() {","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"Cazh1"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"Cazh1"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"Cazh1"},"content":" ArrayList\u003cString\u003e commandOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"Cazh1"},"content":" @Override","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" String parseString \u003d convertArrayToString(message, \",\");","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" commandOutput.add(parseString);","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"Cazh1"},"content":" };","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"Cazh1"},"content":" Command listMenuCommand \u003d new ListMenuCommand(menu, ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"Cazh1"},"content":" listMenuCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"Cazh1"},"content":" String actualOutput \u003d String.join(\",\", commandOutput);","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"Cazh1"},"content":" String expectedOutput \u003d Messages.MENU_EMPTY_MESSAGE;","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"Cazh1"},"content":" assert (expectedOutput.trim().replaceAll(\",\", \"\").equals(actualOutput.trim().replaceAll(\",\", \"\")));","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"Cazh1"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"Cazh1"},"content":" private static String convertArrayToString(String[] message, String delimiter) {","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"Cazh1"},"content":" StringBuilder sb \u003d new StringBuilder();","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":" for (String str : message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" sb.append(str.toString()).append(delimiter);","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":" return sb.substring(0, sb.length() - 1);","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"Cazh1"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":86,"author":{"gitId":"Cazh1"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"DextheChik3n":4,"Cazh1":81,"ziyi105":1}},{"path":"src/test/java/seedu/cafectrl/command/ViewTotalStockCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.command;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"public class ViewTotalStockCommandTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" void execute_printPantryStock() {","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e pantryStock \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":" pantryStock.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" pantryStock.add(new Ingredient(\"rice\", 1000, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui, pantryStock);","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" ByteArrayOutputStream baos \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" PrintStream consoleStream \u003d new PrintStream(baos);","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(consoleStream);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":" ViewTotalStockCommand viewTotalStockCommand \u003d new ViewTotalStockCommand(pantry, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ShaniceTang"},"content":" viewTotalStockCommand.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"ShaniceTang"},"content":" String actualOutput \u003d baos.toString().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"ShaniceTang"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"ShaniceTang"},"content":" String expectedOutput \u003d \"You have the following ingredients in pantry:\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"ShaniceTang"},"content":" + \"Ingredients\\t\\tQty\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ShaniceTang"},"content":" + \"chicken\\t\\t\\t500g\\n\"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"ShaniceTang"},"content":" + \"rice\\t\\t\\t1000g\";","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedOutput.trim().replaceAll(\"\\\\s+\", \" \"),","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" actualOutput.trim().replaceAll(\"\\\\s+\", \" \"));","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":43}},{"path":"src/test/java/seedu/cafectrl/data/MenuTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ziyi105"},"content":"//import static org.junit.jupiter.api.Assertions.*;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"ziyi105"},"content":"class MenuTest {","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"DextheChik3n":1,"ziyi105":6}},{"path":"src/test/java/seedu/cafectrl/data/PantryTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ShaniceTang"},"content":"package seedu.cafectrl.data;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"public class PantryTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"ShaniceTang"},"content":" void addIngredientToStock_differentUnitForBuyIngredient_returnErrorMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cIngredient\u003e ingredientsList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"ShaniceTang"},"content":" ingredientsList.add(new Ingredient(\"chicken\", 500, \"g\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui, ingredientsList);","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"ShaniceTang"},"content":" RuntimeException exception \u003d assertThrows(RuntimeException.class, () -\u003e {","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"ShaniceTang"},"content":" pantry.addIngredientToStock(\"chicken\", 500, \"ml\");","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":" });","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"ShaniceTang"},"content":" String expectedErrorMessage \u003d ErrorMessages.UNIT_NOT_MATCHING + \"\\nUnit used previously: g\";","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(expectedErrorMessage, exception.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"ShaniceTang"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ShaniceTang":29}},{"path":"src/test/java/seedu/cafectrl/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DextheChik3n"},"content":"package seedu.cafectrl.parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"ShaniceTang"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.Command;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.AddDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.command.ListIngredientCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.IncorrectCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.DeleteDishCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.ViewTotalStockCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.command.BuyIngredientCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.CurrentDate;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Menu;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"ShaniceTang"},"content":"import seedu.cafectrl.data.Pantry;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"Cazh1"},"content":"import seedu.cafectrl.data.Sales;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.data.dish.Dish;","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"NaychiMin"},"content":"import seedu.cafectrl.data.dish.Ingredient;","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"DextheChik3n"},"content":"import seedu.cafectrl.parser.exception.ParserException;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.ErrorMessages;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"ziyi105"},"content":"import seedu.cafectrl.ui.Ui;","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"ziyi105"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"ziyi105"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"DextheChik3n"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"ziyi105"},"content":"/**","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"ziyi105"},"content":" * Junit test for Parser.java","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"ziyi105"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"ziyi105"},"content":"class ParserTest {","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"Cazh1"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_validCommand_successfulCommandParse() {","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"NaychiMin"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"DextheChik3n"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 50, \"g\"),","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"NaychiMin"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof ListIngredientCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"NaychiMin"},"content":" ListIngredientCommand listIngredientCommand \u003d (ListIngredientCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"NaychiMin"},"content":" int index \u003d listIngredientCommand.index;","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"NaychiMin"},"content":" assertEquals(1, index);","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_missingIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients\";","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":73,"author":{"gitId":"NaychiMin"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"NaychiMin"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_LIST_INGREDIENTS, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_invalidIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":82,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":83,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients a\";","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"NaychiMin"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"NaychiMin"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_LIST_INGREDIENTS, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"NaychiMin"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"NaychiMin"},"content":" public void parseCommand_indexOutOfBounds_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"NaychiMin"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":100,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":101,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"NaychiMin"},"content":" String userInput \u003d \"list_ingredients 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"NaychiMin"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"NaychiMin"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"NaychiMin"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"NaychiMin"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.INVALID_DISH_INDEX, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"NaychiMin"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":114,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_validDeleteCommand_successfulCommandParse() {","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"ShaniceTang"},"content":" ArrayList\u003cDish\u003e menuItems \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"ShaniceTang"},"content":" menuItems.add(new Dish(\"Chicken Rice\",","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"DextheChik3n"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Rice\", 50, \"g\"),","lastModifiedDate":"2023-10-25"},{"lineNumber":119,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 100, \"g\"))), 8.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":120,"author":{"gitId":"ShaniceTang"},"content":" menuItems.add(new Dish(\"Chicken Sandwich\",","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"ShaniceTang"},"content":" new ArrayList\u003c\u003e(Arrays.asList(new Ingredient(\"Lettuce\", 100, \"g\"),","lastModifiedDate":"2023-10-23"},{"lineNumber":122,"author":{"gitId":"ShaniceTang"},"content":" new Ingredient(\"Chicken\", 50, \"g\"))), 5.0F));","lastModifiedDate":"2023-10-23"},{"lineNumber":123,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu(menuItems);","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":125,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":126,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof DeleteDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":133,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":134,"author":{"gitId":"ShaniceTang"},"content":" DeleteDishCommand deleteDishCommand \u003d (DeleteDishCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":135,"author":{"gitId":"ShaniceTang"},"content":" int index \u003d deleteDishCommand.index;","lastModifiedDate":"2023-10-18"},{"lineNumber":136,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(1, index);","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":139,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":140,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_missingDeleteIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":141,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":143,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":144,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":145,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete\";","lastModifiedDate":"2023-10-18"},{"lineNumber":147,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_DELETE, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_invalidDeleteIndex_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":161,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":162,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete a\";","lastModifiedDate":"2023-10-18"},{"lineNumber":165,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":168,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":169,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":170,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":171,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":172,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_DELETE, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":174,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":175,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":176,"author":{"gitId":"ShaniceTang"},"content":" public void parseCommand_deleteIndexOutOfBounds_returnsErrorMessage() {","lastModifiedDate":"2023-10-18"},{"lineNumber":177,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":178,"author":{"gitId":"Cazh1"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-24"},{"lineNumber":179,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":180,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":181,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":182,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"delete 1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":183,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"ziyi105"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":187,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":188,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-10-18"},{"lineNumber":189,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-10-18"},{"lineNumber":190,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.INVALID_DISH_INDEX, feedbackToUser);","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":192,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":193,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":194,"author":{"gitId":"ziyi105"},"content":" void parseCommand_unrecognisedInput_unknownCommand() {","lastModifiedDate":"2023-10-18"},{"lineNumber":195,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":197,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"ziyi105"},"content":" String testUserInput \u003d \"random input\";","lastModifiedDate":"2023-10-18"},{"lineNumber":199,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":200,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":201,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":202,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":203,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":204,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":205,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":206,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":207,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":208,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":209,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":210,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":211,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":212,"author":{"gitId":"ziyi105"},"content":" Command commandReturned \u003d parserUtil.parseCommand(menu, testUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"Cazh1"},"content":" commandReturned.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":214,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.UNKNOWN_COMMAND_MESSAGE, actualOutput.get(0));","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":216,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":217,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":218,"author":{"gitId":"ziyi105"},"content":" void parseCommand_missingArgumentsForEditPrice_missingArgMsg() {","lastModifiedDate":"2023-10-18"},{"lineNumber":219,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":220,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":221,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":222,"author":{"gitId":"ziyi105"},"content":" String testUserInput \u003d \"edit_price index/1\";","lastModifiedDate":"2023-10-18"},{"lineNumber":223,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":224,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":225,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":226,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":228,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":229,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":230,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":231,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":232,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":234,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":236,"author":{"gitId":"ziyi105"},"content":" Command commandReturned \u003d parserUtil.parseCommand(menu, testUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":237,"author":{"gitId":"Cazh1"},"content":" commandReturned.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":238,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_EDIT_PRICE, actualOutput.get(0));","lastModifiedDate":"2023-10-30"},{"lineNumber":239,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":240,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":241,"author":{"gitId":"ziyi105"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":242,"author":{"gitId":"ziyi105"},"content":" void parseCommand_invalidDishIndexForEditPrice_invalidIndexForEditPrice() {","lastModifiedDate":"2023-10-18"},{"lineNumber":243,"author":{"gitId":"ziyi105"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":244,"author":{"gitId":"ziyi105"},"content":" Dish testDish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-10-18"},{"lineNumber":245,"author":{"gitId":"ziyi105"},"content":" menu.addDish(testDish);","lastModifiedDate":"2023-10-18"},{"lineNumber":246,"author":{"gitId":"ziyi105"},"content":" String testUserInput \u003d \"edit_price index/2 price/3\";","lastModifiedDate":"2023-10-18"},{"lineNumber":247,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":248,"author":{"gitId":"ziyi105"},"content":" ArrayList\u003cString\u003e actualOutput \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"ziyi105"},"content":" Ui ui \u003d new Ui() {","lastModifiedDate":"2023-10-18"},{"lineNumber":250,"author":{"gitId":"ziyi105"},"content":" @Override","lastModifiedDate":"2023-10-18"},{"lineNumber":251,"author":{"gitId":"ziyi105"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":252,"author":{"gitId":"ziyi105"},"content":" actualOutput.addAll(Arrays.asList(message));","lastModifiedDate":"2023-10-18"},{"lineNumber":253,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":254,"author":{"gitId":"ziyi105"},"content":" };","lastModifiedDate":"2023-10-18"},{"lineNumber":255,"author":{"gitId":"Cazh1"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":256,"author":{"gitId":"Cazh1"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":257,"author":{"gitId":"Cazh1"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":258,"author":{"gitId":"ziyi105"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"ziyi105"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":260,"author":{"gitId":"ziyi105"},"content":" Command commandReturned \u003d parserUtil.parseCommand(menu, testUserInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":261,"author":{"gitId":"Cazh1"},"content":" commandReturned.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":262,"author":{"gitId":"ziyi105"},"content":" assertEquals(ErrorMessages.INVALID_DISH_INDEX, actualOutput.get(0));","lastModifiedDate":"2023-10-30"},{"lineNumber":263,"author":{"gitId":"ziyi105"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":264,"author":{"gitId":"DextheChik3n"},"content":" //@@author DextheChik3n","lastModifiedDate":"2023-10-27"},{"lineNumber":265,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":266,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_validDishInputForAddDish_dishAddedToMenu() {","lastModifiedDate":"2023-10-18"},{"lineNumber":267,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":269,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":270,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":271,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":272,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Christmas Ham price/50.00 ingredient/Ham qty/1000g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":273,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":274,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":275,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":276,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct Command type returned","lastModifiedDate":"2023-10-18"},{"lineNumber":277,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":278,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":279,"author":{"gitId":"DextheChik3n"},"content":" //Test for 1 Dish added to Menu","lastModifiedDate":"2023-10-18"},{"lineNumber":280,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":281,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(1, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":282,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":283,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct parsing of dish arguments","lastModifiedDate":"2023-10-27"},{"lineNumber":284,"author":{"gitId":"DextheChik3n"},"content":" Dish getOutputDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-27"},{"lineNumber":285,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":286,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"Christmas Ham\", getOutputDish.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":287,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 50.0, getOutputDish.getPrice());","lastModifiedDate":"2023-10-30"},{"lineNumber":288,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"[Ham - 1000g]\", getOutputDish.getIngredients().toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":289,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":290,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":291,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":292,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_dishWithThreeIngredientsForAddDish_dishContainsThreeIngredientAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":293,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":294,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":295,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":296,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":297,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":298,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/2.00 \"","lastModifiedDate":"2023-10-27"},{"lineNumber":299,"author":{"gitId":"DextheChik3n"},"content":" + \"ingredient/rice qty/100g, ingredient/chicken qty/200g, ingredient/water qty/100ml\";","lastModifiedDate":"2023-10-27"},{"lineNumber":300,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":301,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":302,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":303,"author":{"gitId":"DextheChik3n"},"content":" //Test for 3 Ingredients in the Dish added to Menu","lastModifiedDate":"2023-10-27"},{"lineNumber":304,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":305,"author":{"gitId":"DextheChik3n"},"content":" Dish actualDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-27"},{"lineNumber":306,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(3, actualDish.getIngredients().size());","lastModifiedDate":"2023-10-30"},{"lineNumber":307,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":308,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct parsing of dish arguments","lastModifiedDate":"2023-10-18"},{"lineNumber":309,"author":{"gitId":"DextheChik3n"},"content":" Dish getOutputDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-24"},{"lineNumber":310,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":311,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"Chicken Rice\", getOutputDish.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":312,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 2.0, getOutputDish.getPrice());","lastModifiedDate":"2023-10-30"},{"lineNumber":313,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"[rice - 100g, chicken - 200g, water - 100ml]\", getOutputDish.getIngredients().toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":314,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":315,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":316,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":317,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_invalidDishInputForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-18"},{"lineNumber":318,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-18"},{"lineNumber":319,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-18"},{"lineNumber":320,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-24"},{"lineNumber":321,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":322,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":323,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":324,"author":{"gitId":"DextheChik3n"},"content":" //input name/ argument wrongly","lastModifiedDate":"2023-10-18"},{"lineNumber":325,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add named/Christmas Ham price/50.00 ingredient/Ham qty/1000g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":326,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":327,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":328,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":329,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-18"},{"lineNumber":330,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":331,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":332,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-18"},{"lineNumber":333,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":334,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":335,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":336,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":337,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":338,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_missingArgumentDishInputForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":339,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":340,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":341,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":342,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":343,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":344,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":345,"author":{"gitId":"DextheChik3n"},"content":" //input name/ argument wrongly","lastModifiedDate":"2023-10-18"},{"lineNumber":346,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Christmas Ham price/50.00 ingredient/Ham\";","lastModifiedDate":"2023-10-27"},{"lineNumber":347,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":348,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":349,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":350,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-18"},{"lineNumber":351,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-18"},{"lineNumber":352,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":353,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-18"},{"lineNumber":354,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":355,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":356,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":357,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":358,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":359,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_invalidQuantityUnitForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":360,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":361,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":362,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":363,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":364,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":365,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":366,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/2.50 ingredient/rice qty/1 cup\";","lastModifiedDate":"2023-10-27"},{"lineNumber":367,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":368,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":369,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":370,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":371,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":372,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":373,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-27"},{"lineNumber":374,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":375,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":376,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":377,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":378,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":379,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_negativeDishPriceForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":380,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":381,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":382,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":383,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":384,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":385,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":386,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/-2.50 ingredient/rice qty/100g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":387,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":388,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":389,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":390,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":391,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":392,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":393,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-27"},{"lineNumber":394,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":395,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":396,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":397,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":398,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":399,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_negativeIngredientQtyForAddDish_noDishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":400,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":401,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":402,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":403,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":404,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":405,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":406,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/Chicken Rice price/2.50 ingredient/rice qty/-100g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":407,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":408,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":409,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":410,"author":{"gitId":"DextheChik3n"},"content":" //Test for incorrect Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":411,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":412,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":413,"author":{"gitId":"DextheChik3n"},"content":" //Test for no dish added in menu","lastModifiedDate":"2023-10-27"},{"lineNumber":414,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":415,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(0, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":416,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":417,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":418,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-10-27"},{"lineNumber":419,"author":{"gitId":"DextheChik3n"},"content":" void parseCommand_whitespaceBetweenArgumentsForAddDish_dishAddedToMenu() {","lastModifiedDate":"2023-10-27"},{"lineNumber":420,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-10-27"},{"lineNumber":421,"author":{"gitId":"DextheChik3n"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-27"},{"lineNumber":422,"author":{"gitId":"DextheChik3n"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-10-27"},{"lineNumber":423,"author":{"gitId":"DextheChik3n"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-10-30"},{"lineNumber":424,"author":{"gitId":"DextheChik3n"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-10-30"},{"lineNumber":425,"author":{"gitId":"DextheChik3n"},"content":" String addDishTestInput \u003d \"add name/ Christmas Ham price/ 50.00 ingredient/ Ham qty/ 1000g\";","lastModifiedDate":"2023-10-27"},{"lineNumber":426,"author":{"gitId":"DextheChik3n"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":427,"author":{"gitId":"DextheChik3n"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, addDishTestInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":428,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":429,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct Command type returned","lastModifiedDate":"2023-10-27"},{"lineNumber":430,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(outputCommand instanceof AddDishCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":431,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":432,"author":{"gitId":"DextheChik3n"},"content":" //Test for 1 Dish added to Menu","lastModifiedDate":"2023-10-27"},{"lineNumber":433,"author":{"gitId":"DextheChik3n"},"content":" outputCommand.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":434,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(1, menu.getSize());","lastModifiedDate":"2023-10-30"},{"lineNumber":435,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":436,"author":{"gitId":"DextheChik3n"},"content":" //Test for correct parsing of dish arguments","lastModifiedDate":"2023-10-27"},{"lineNumber":437,"author":{"gitId":"DextheChik3n"},"content":" Dish getOutputDish \u003d menu.getDishFromId(0);","lastModifiedDate":"2023-10-27"},{"lineNumber":438,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":439,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"Christmas Ham\", getOutputDish.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":440,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 50.0, getOutputDish.getPrice());","lastModifiedDate":"2023-10-30"},{"lineNumber":441,"author":{"gitId":"DextheChik3n"},"content":" assertEquals(\"[Ham - 1000g]\", getOutputDish.getIngredients().toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":442,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":443,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":444,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"DextheChik3n"},"content":" void parsePriceToFloat_validPriceString_exactFloatPrice() throws ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"DextheChik3n"},"content":" String inputPriceString \u003d \"3.14\";","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"DextheChik3n"},"content":" assertEquals((float) 3.14, Parser.parsePriceToFloat(inputPriceString));","lastModifiedDate":"2023-11-01"},{"lineNumber":449,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":452,"author":{"gitId":"DextheChik3n"},"content":" void parsePriceToFloat_largePriceString_arithmeticExceptionThrown() throws ParserException {","lastModifiedDate":"2023-11-01"},{"lineNumber":453,"author":{"gitId":"DextheChik3n"},"content":" String inputPriceString \u003d \"99999999999.99\";","lastModifiedDate":"2023-11-01"},{"lineNumber":454,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":455,"author":{"gitId":"DextheChik3n"},"content":" assertThrows(ParserException.class, () -\u003e Parser.parsePriceToFloat(inputPriceString));","lastModifiedDate":"2023-11-01"},{"lineNumber":456,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":457,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":458,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":459,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_existingDishName_true() {","lastModifiedDate":"2023-11-01"},{"lineNumber":460,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":461,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":462,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":463,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":464,"author":{"gitId":"DextheChik3n"},"content":" String inputDishName \u003d \"chicken rice\";","lastModifiedDate":"2023-11-01"},{"lineNumber":465,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":466,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(Parser.isRepeatedName(inputDishName, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":467,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":468,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":469,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":470,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_nonExistingDishName_false() {","lastModifiedDate":"2023-11-01"},{"lineNumber":471,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":472,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":473,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":474,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":475,"author":{"gitId":"DextheChik3n"},"content":" String inputDishName \u003d \"chicken chop\";","lastModifiedDate":"2023-11-01"},{"lineNumber":476,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":477,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(Parser.isRepeatedName(inputDishName, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":478,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":479,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":480,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":481,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_nullString_nullPointerExceptionThrown() throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":482,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":483,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":484,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":485,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":486,"author":{"gitId":"DextheChik3n"},"content":" assertThrows(NullPointerException.class, () -\u003e Parser.isRepeatedName(null, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":487,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":488,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":489,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":490,"author":{"gitId":"DextheChik3n"},"content":" void isRepeatedDishName_emptyDishName_false() {","lastModifiedDate":"2023-11-01"},{"lineNumber":491,"author":{"gitId":"DextheChik3n"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":492,"author":{"gitId":"DextheChik3n"},"content":" Dish dish \u003d new Dish(\"Chicken Rice\", 2.50F);","lastModifiedDate":"2023-11-01"},{"lineNumber":493,"author":{"gitId":"DextheChik3n"},"content":" menu.addDish(dish);","lastModifiedDate":"2023-11-01"},{"lineNumber":494,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":495,"author":{"gitId":"DextheChik3n"},"content":" String inputDishName \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":496,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":497,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(Parser.isRepeatedName(inputDishName, menu));","lastModifiedDate":"2023-11-01"},{"lineNumber":498,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":499,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":500,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":501,"author":{"gitId":"DextheChik3n"},"content":" void isNameLengthInvalid_moreThanMaxLengthString_true() {","lastModifiedDate":"2023-11-01"},{"lineNumber":502,"author":{"gitId":"DextheChik3n"},"content":" assertTrue(Parser.isNameLengthInvalid(\"this string is more than 35 characters\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":503,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":504,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":505,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":506,"author":{"gitId":"DextheChik3n"},"content":" void isNameLengthInvalid_lessThanMaxLengthString_false() {","lastModifiedDate":"2023-11-01"},{"lineNumber":507,"author":{"gitId":"DextheChik3n"},"content":" assertFalse(Parser.isNameLengthInvalid(\"this str is less than 35 chars\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":508,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":509,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":510,"author":{"gitId":"DextheChik3n"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":511,"author":{"gitId":"DextheChik3n"},"content":" void isNameLengthInvalid_nullString_nullPointerExceptionThrown() throws NullPointerException {","lastModifiedDate":"2023-11-01"},{"lineNumber":512,"author":{"gitId":"DextheChik3n"},"content":" assertThrows(NullPointerException.class, () -\u003eParser.isNameLengthInvalid(null));","lastModifiedDate":"2023-11-01"},{"lineNumber":513,"author":{"gitId":"DextheChik3n"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":514,"author":{"gitId":"DextheChik3n"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":515,"author":{"gitId":"ShaniceTang"},"content":" //@@author ShaniceTang","lastModifiedDate":"2023-11-01"},{"lineNumber":516,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":517,"author":{"gitId":"ShaniceTang"},"content":" void parseCommand_returnViewTotalStockCommandClass() {","lastModifiedDate":"2023-11-01"},{"lineNumber":518,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":519,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":520,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":521,"author":{"gitId":"ShaniceTang"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":522,"author":{"gitId":"ShaniceTang"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":523,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"view_stock\";","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":526,"author":{"gitId":"ShaniceTang"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-11-01"},{"lineNumber":527,"author":{"gitId":"ShaniceTang"},"content":" Command outputCommand \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-11-01"},{"lineNumber":528,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":529,"author":{"gitId":"ShaniceTang"},"content":" ViewTotalStockCommand viewTotalStockCommand \u003d new ViewTotalStockCommand(pantry, ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":530,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":531,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(viewTotalStockCommand.getClass(), outputCommand.getClass());","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":534,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"ShaniceTang"},"content":" void parseCommand_missingArgsForBuyIngredient_returnErrorMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"ShaniceTang"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":540,"author":{"gitId":"ShaniceTang"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"buy_ingredient\";","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"ShaniceTang"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"ShaniceTang"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":546,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-11-01"},{"lineNumber":547,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":548,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-11-01"},{"lineNumber":549,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":550,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(ErrorMessages.MISSING_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-11-01"},{"lineNumber":551,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":552,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":553,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":554,"author":{"gitId":"ShaniceTang"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":555,"author":{"gitId":"ShaniceTang"},"content":" void parseCommand_invalidArgsForBuyIngredient_returnErrorMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":556,"author":{"gitId":"ShaniceTang"},"content":" Menu menu \u003d new Menu();","lastModifiedDate":"2023-11-01"},{"lineNumber":557,"author":{"gitId":"ShaniceTang"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-11-01"},{"lineNumber":558,"author":{"gitId":"ShaniceTang"},"content":" Pantry pantry \u003d new Pantry(ui);","lastModifiedDate":"2023-11-01"},{"lineNumber":559,"author":{"gitId":"ShaniceTang"},"content":" Sales sales \u003d new Sales();","lastModifiedDate":"2023-11-01"},{"lineNumber":560,"author":{"gitId":"ShaniceTang"},"content":" CurrentDate currentDate \u003d new CurrentDate();","lastModifiedDate":"2023-11-01"},{"lineNumber":561,"author":{"gitId":"ShaniceTang"},"content":" String userInput \u003d \"buy_ingredient ingredient/rice qty/5 cups\";","lastModifiedDate":"2023-11-01"},{"lineNumber":562,"author":{"gitId":"ShaniceTang"},"content":" ParserUtil parserUtil \u003d new Parser();","lastModifiedDate":"2023-11-01"},{"lineNumber":563,"author":{"gitId":"ShaniceTang"},"content":" Command result \u003d parserUtil.parseCommand(menu, userInput, ui, pantry, sales, currentDate);","lastModifiedDate":"2023-11-01"},{"lineNumber":564,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":565,"author":{"gitId":"ShaniceTang"},"content":" assertTrue(result instanceof IncorrectCommand);","lastModifiedDate":"2023-11-01"},{"lineNumber":566,"author":{"gitId":"ShaniceTang"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":567,"author":{"gitId":"ShaniceTang"},"content":" IncorrectCommand incorrectCommand \u003d (IncorrectCommand) result;","lastModifiedDate":"2023-11-01"},{"lineNumber":568,"author":{"gitId":"ShaniceTang"},"content":" String feedbackToUser \u003d incorrectCommand.feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":569,"author":{"gitId":"ShaniceTang"},"content":" assertEquals(ErrorMessages.INVALID_ARGUMENT_FOR_BUY_INGREDIENT","lastModifiedDate":"2023-11-01"},{"lineNumber":570,"author":{"gitId":"ShaniceTang"},"content":" + BuyIngredientCommand.MESSAGE_USAGE, feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":571,"author":{"gitId":"ShaniceTang"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":572,"author":{"gitId":"ShaniceTang"},"content":" //@@author","lastModifiedDate":"2023-11-01"},{"lineNumber":573,"author":{"gitId":"ziyi105"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"NaychiMin":49,"DextheChik3n":259,"Cazh1":47,"ziyi105":96,"ShaniceTang":122}}] diff --git a/AY2324S1-CS2113-T17-2_tp_master/commits.json b/AY2324S1-CS2113-T17-2_tp_master/commits.json index fed5acb..716614c 100644 --- a/AY2324S1-CS2113-T17-2_tp_master/commits.json +++ b/AY2324S1-CS2113-T17-2_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"NaychiMin":[{"date":"2023-10-05","commitResults":[{"hash":"094363dc81635ad0658ac71e4eb02ca05a61c993","isMergeCommit":false,"messageTitle":"Edit about us with updated information.","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"568bed8b462e7fa328b1459b8cb2430513f0186c","isMergeCommit":true,"messageTitle":"Merge pull request #1 from NaychiMin/master","messageBody":"Edit about us with updated information.","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"78321f89bd358320aec6190b2e1f57bceec9b61b","isMergeCommit":false,"messageTitle":"Add Ui class for user input handling and UserOutput enum for user messages. Fixes #9","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":0}}},{"hash":"47e208e3c20a79c10f0f4c9fe082b7db52170725","isMergeCommit":false,"messageTitle":"Remove showError() function from Ui class.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":15}}}]},{"date":"2023-10-17","commitResults":[{"hash":"b1c8b3917bf5d9a2969b2dfcc85a77ed902bb5ab","isMergeCommit":false,"messageTitle":"Add list ingredient command.","messageBody":"#Fixes 20\n","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":1}}},{"hash":"3208c1e12e18a4730c187ef788f95e8c69b477f5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 20-UI-to-list-ingredients-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/data/Menu.java\n#\tsrc/main/java/seedu/duke/data/dish/Dish.java\n#\tsrc/main/java/seedu/duke/ui/Ui.java\n\n#Fixes 20\n","fileTypesAndContributionMap":{}},{"hash":"9f31ada3ba8e663dce87e230896db30dc424a8c9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 20-UI-to-list-ingredients-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2c367e72327872d4a83ee33f677e2e977129ad7a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 20-UI-to-list-ingredients-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"517bdf262e8a206ffde596e42f4ce95e17ea3d1f","isMergeCommit":false,"messageTitle":"Implement parsing for listing ingredients and necessary error handling.","messageBody":"Fixes #23\n","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":29}}},{"hash":"06da5aa5369ab28d0ad2880c2f68094700fb5cbe","isMergeCommit":false,"messageTitle":"Remove unused imports from Ui class and ListIngredientCommand class.","messageBody":"Fixes #23\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"ea5dbbd520baf2c7ae4b0e34f21a81b974e40961","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #23\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"d23e91b4260bd6d3677ece51eb74663a1655b266","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 23-parser-for-list-ingredients-v1.0","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"2fb7143c3608035bd2598e54e161afa8f31bac17","isMergeCommit":false,"messageTitle":"Add Junit test for list ingredient command.","messageBody":"Fixes #56\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":6},"test-code":{"insertions":51,"deletions":0}}},{"hash":"06cc5ab4bd4bc12cd600dff0a5e02fb9342cec43","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 56-Junit-test-for-list-ingredient.v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7a6a61058cc79064a530c3f47ddd22ce55efd919","isMergeCommit":false,"messageTitle":"Rename imported packages in ListIngredientCommandTest.java into the new refactored format.","messageBody":"Fixes #56\n","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3},"test-code":{"insertions":4,"deletions":4}}},{"hash":"421167b78f8a3be9664ab6d40146164793398dc6","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #56\n","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":7}}},{"hash":"37824dd4fbe3a1a7651fa68e34755eedfb2d726d","isMergeCommit":false,"messageTitle":"Update parsing of List Ingredients command.","messageBody":"Fixes #15\n","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":12}}},{"hash":"f3cc35239cedc9d46cb877ebe130fd7b47d1627d","isMergeCommit":false,"messageTitle":"Implement JUnit test for parsing list ingredients command.","messageBody":"Fixes #15\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5},"test-code":{"insertions":74,"deletions":0}}},{"hash":"6e09c0cac22f46b9e55ad711e96d793d38302f99","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 23-parser-for-list-ingredients-v1.0","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"5b7fa6298201506cb8947488d2bcfd94d02210a6","isMergeCommit":false,"messageTitle":"Improve coding standard using line wrapping.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-22","commitResults":[{"hash":"df0be27f0abb658365f85c686e483b4b7af8d9d9","isMergeCommit":false,"messageTitle":"Implement stock checking of ingredients in Pantry class","messageBody":"-Include decreasing of stock ingredients after processing each other\n-Include checking of low stock ingredients\n\nFixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":210,"deletions":1}}}]},{"date":"2023-10-23","commitResults":[{"hash":"213b1b2b789cc2f00849b4b688d15f10b472c10d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into implement-low-stock","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0ff4fad54b828cc704c117102d1cdb11485e5480","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into implement-low-stock","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"88235e7b9833aeaf0080fb2678cb6b8bb3e925f8","isMergeCommit":false,"messageTitle":"Refactor code to abstract print functions to UI class.","messageBody":"Fixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":42}}},{"hash":"b4d466fdd3ba96e2124e5e5c3bcaca1d675002a4","isMergeCommit":false,"messageTitle":"Improve code quality by refactoring methods.","messageBody":"Fixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":9}}},{"hash":"8df78067116251bb7f174b3d18dec6c8d841f187","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into implement-low-stock","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/data/Pantry.java\n#\tsrc/main/java/seedu/cafectrl/data/dish/Ingredient.java\n\nFixes #92, Fixes #93\n","fileTypesAndContributionMap":{}},{"hash":"21b07cd22ff5826632905428a7efd3b451deac44","isMergeCommit":false,"messageTitle":"Edit existing constructor parameter of Pantry class.","messageBody":"Fixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":14,"deletions":13}}}]},{"date":"2023-10-25","commitResults":[{"hash":"e35f79c510e4b5dafb173826092913cee9b6a317","isMergeCommit":false,"messageTitle":"Refactor the folder structure of \u0027docs\u0027 to include \u0027umldiagrams\u0027 and \u0027umlimages\u0027","messageBody":"Fixes #115\n","fileTypesAndContributionMap":{"docs":{"insertions":39,"deletions":39}}},{"hash":"c2620fa2f944bf5b72b246298470574441ed4e89","isMergeCommit":false,"messageTitle":"Create a .puml file capturing the sequence diagram for the List Ingredient Command.","messageBody":"Fixes #115\n","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":0}}},{"hash":"1544ec1119cac3beacacea949d8a734073c1c499","isMergeCommit":false,"messageTitle":"Edit developer guide to include the list ingredient command function.","messageBody":"Fixes #115\n","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":4}}}]},{"date":"2023-10-30","commitResults":[{"hash":"4b20991f4fe788632d2623df48a2c8fa899df332","isMergeCommit":false,"messageTitle":"Implement encoding for OrderList to store the OrderList object to a text file.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":60}}},{"hash":"2b2aa6a744f569bd3a21c90949f40cfa094b5a52","isMergeCommit":false,"messageTitle":"Implement decoding for OrderList to convert data from text file into OrderList object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":29}}},{"hash":"e76c983732bffec4749166ed604970507d0db3c6","isMergeCommit":false,"messageTitle":"Add in necessary methods that are used in coding and encoding of the OrderList object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":10}}},{"hash":"8f324edf329f966761335bd99397d6a375d6240b","isMergeCommit":false,"messageTitle":"Add in javadoc for \u0027Decoder\u0027 class.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"ea1cd27ff9ef8be316c69a98c2ba06d4f632d61c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 148_encoding_decoding_orders_v2.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/CafeCtrl.java\n#\tsrc/main/java/seedu/cafectrl/data/Order.java\n#\tsrc/main/java/seedu/cafectrl/data/OrderList.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"a9c0289354c3aaaa821fbded7151d44a534d6d9c","isMergeCommit":false,"messageTitle":"Improve encoding of orderList object to be able to encode an array of orderLists from the provided Sales object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":35}}},{"hash":"a49071fb4393f04d93849455df7a6ad88ea5e31b","isMergeCommit":false,"messageTitle":"Improve decoding of text file containing Orders to decode the text file from the provided Sales object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":18}}},{"hash":"554f33d026e5deb8649b0fcb265a927ec885511d","isMergeCommit":false,"messageTitle":"Create sales object and pass it into the function that saves it to storage.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"ce5b9008597ab4e623de3db5ac834ff56e40c541","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 148_encoding_decoding_orders_v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"65ff347261e28cd87f7307ac10b84c4af1c018bc","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":13}}},{"hash":"3137e0b64647d16fcceab8e90a9fa8ee747b6989","isMergeCommit":false,"messageTitle":"Add javadoc for encoder and author tags where necessary.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}},{"hash":"2b98bd6074559185f884def44f3ae76b449f4bc7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 148_encoding_decoding_orders_v2.0","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"4bed50e6f94cc0977e28b55142a247ca153a8a32","isMergeCommit":false,"messageTitle":"Implement the function to show total sales for each day since the cafe has operated.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":123,"deletions":17}}},{"hash":"bedd22130cdb1c6399cda1920dcd41dfaae987d7","isMergeCommit":false,"messageTitle":"Implement function to print sale by selected day.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":1}}},{"hash":"f6e1fe96cc2f4085a2b032edf9e6d852952af7d1","isMergeCommit":false,"messageTitle":"Implement parsing for commands to show total sales and show sales by day.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":16}}},{"hash":"7ab78b8caa3152372260a6fef318061c9e69f9da","isMergeCommit":false,"messageTitle":"Create ShowSalesByDayCommand class.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":1}}},{"hash":"9dece87746f697fb91b7dfdfc5d0f49b8e2e6e05","isMergeCommit":false,"messageTitle":"Create ShowSalesCommand class.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":1}}},{"hash":"59f7580b8ce3cb6a673f94d96e426e1602895529","isMergeCommit":false,"messageTitle":"Edit storage function for sales to accommodate showing sales functions.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":13}}},{"hash":"80c9f917e6a4e51d9435405b9f9dd386e2ccb1ee","isMergeCommit":false,"messageTitle":"Add in needed constant to improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"9350a6b66b658490974fbd9de287a59b1abe9542","isMergeCommit":false,"messageTitle":"Refactor necessary classes and functions to accommodate the function to show sales.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":23}}},{"hash":"c343e87d41d4bd36ed197a4b058d7096a75725b2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into print_orderlist","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/data/Pantry.java\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}},{"hash":"b1591c3d4bd40dd08ebc8d9c8601f65a67944e82","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":82,"deletions":52}}},{"hash":"ab0c385e800661e61323a75b3485381cc097000b","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":19}}},{"hash":"af5606aac98ecfc2f9dbd726f368ac3af247f43e","isMergeCommit":false,"messageTitle":"Refactor functions to improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":19}}},{"hash":"cb36d44f553b9202934ba28b8180075681304edb","isMergeCommit":false,"messageTitle":"Edit author tag.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"075888de34ce8beae269362261cafea028b85954","isMergeCommit":false,"messageTitle":"Edit author tag.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"cf5d5950d94764e1fd249ac91e9ac5c0b00e9a2f","isMergeCommit":false,"messageTitle":"Edit Java Doc in Sales class.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":46}}},{"hash":"dca5363b842a7049c8660c620742a462b97fb0e4","isMergeCommit":false,"messageTitle":"Improve code standard.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":22}}},{"hash":"437264eddf17a792b0f6524479cbfb198eb0c0a8","isMergeCommit":false,"messageTitle":"Minor bug fixes in Pantry.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":7}}},{"hash":"35af0d12234048f0234db4ea8895e972015036b6","isMergeCommit":false,"messageTitle":"Improve coding standard and coding quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":39},"test-code":{"insertions":149,"deletions":149}}},{"hash":"e7b450815da8ae9a2184a88c0f2cef95d5c228e1","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":5}}},{"hash":"7877f1ee665968bfe7db478e0dd69dd7b84225f1","isMergeCommit":false,"messageTitle":"Improve coding quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"59aeae46d450dba0990fa8134a7eb0f5a20e662a","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"5b57bae37b6ffceff70a8e5c3c1ee184e52d9462","isMergeCommit":false,"messageTitle":"Add line to resolve error when reading an empty file.","messageBody":"Fixes #198\n","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2},"test-code":{"insertions":10,"deletions":14}}},{"hash":"7ef0e64c59b4d892f6dc8550e76331d75ba89f0d","isMergeCommit":false,"messageTitle":"Remove unused junit test files.","messageBody":"Fixes #198\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":0,"deletions":8}}},{"hash":"996ba04cb7eb9f1f7180581b27e77827c5a59578","isMergeCommit":false,"messageTitle":"Remove unused junit test file.","messageBody":"Fixes #198\n","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}},{"hash":"37cd82653edc793879ae6e275f165da13c191106","isMergeCommit":false,"messageTitle":"Fixed minor bugs and add in clearer error messages.","messageBody":"Fixes #94\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":6}}},{"hash":"8186e9f6918c090a680d4c35c25b1b537f74b675","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #94\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":9}}},{"hash":"fadf1244e23eb269d17783421253d9f26448fb02","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #94\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"27cca2a065dcd86839125bc3bcfb2bc4c2333fd2","isMergeCommit":false,"messageTitle":"Update DG with description of data class diagram and architecture diagram.","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":2}}},{"hash":"80ffff5fb1bab92fa02078302dfea781d758c768","isMergeCommit":false,"messageTitle":"Update user guide with necessary commands.","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":62,"deletions":4}}},{"hash":"40c6b2b8a5b8bef17d78a14d094c41d980dd3e67","isMergeCommit":false,"messageTitle":"Add sequence diagram for Architecture diagram.","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":0}}},{"hash":"d88fd83e4c49661446006f922bf48b01804f39b1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 94-user-story-dish-availability-v2.0","messageBody":"# Conflicts:\n#\tdocs/DeveloperGuide.md\n#\tdocs/UserGuide.md\n","fileTypesAndContributionMap":{}},{"hash":"923b4d15a65588972afa86b75f599e50071dacbb","isMergeCommit":false,"messageTitle":"Finalise architecture diagram of DG.","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":68,"deletions":49}}},{"hash":"2210a7420ddbc5184a01326240b3eb0e64910b24","isMergeCommit":false,"messageTitle":"Finalise UG","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":16}}}]}],"DextheChik3n":[{"date":"2023-10-05","commitResults":[{"hash":"21a60988c0892050292fffd82c8fb54d749500d8","isMergeCommit":false,"messageTitle":"Add information in AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"b5fd7b2190cecf65805f1bbb30e667ef2c1292b2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d76839232f9c1431f4caf8f5cfb25e385855dfa3","isMergeCommit":true,"messageTitle":"Merge pull request #3 from DextheChik3n/master","messageBody":"Add information in AboutUs.md","fileTypesAndContributionMap":{}},{"hash":"dbf0d943a9c8571848d9a7b298faf23652a8c899","isMergeCommit":true,"messageTitle":"Merge pull request #5 from Cazh1/master","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"ff19f057cf581945a4cd59e390d9be62bfc7fcc2","isMergeCommit":true,"messageTitle":"Merge pull request #34 from ziyi105/31-create-common-classes-v0.1","messageBody":"Task 31 Create Menu.java, Dish.java, Ingredient.java","fileTypesAndContributionMap":{}},{"hash":"d89e31068e0e0da1879bc5598aeb4ead9e960ab6","isMergeCommit":true,"messageTitle":"Merge pull request #32 from ziyi105/8-12-create-parser-class-v0.1","messageBody":"Task 8, 12 Create parser class and parser test class","fileTypesAndContributionMap":{}},{"hash":"04bdcc795e4402fb53826282d1623dad29c321d5","isMergeCommit":true,"messageTitle":"Merge pull request #35 from ziyi105/8-12-create-parser-class-v0.1","messageBody":"PR Review: add javadoc to the ParserTest class","fileTypesAndContributionMap":{}},{"hash":"2d1e435914a8d7a18891a5e9562d272c5b202d53","isMergeCommit":true,"messageTitle":"Merge pull request #37 from ShaniceTang/27-create-UiTest-class-v0.1","messageBody":"Issue #27, Add JUnit Test for UI class","fileTypesAndContributionMap":{}},{"hash":"3ca63034d0c9587550244e0ca3ac1fce710fbf7a","isMergeCommit":true,"messageTitle":"Merge pull request #36 from NaychiMin/9-create-UI-class-v0.1","messageBody":"Task 9, Create Ui class and UserOutput enum.","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"19e37bdc77938ff179bc7bcc3ddd59592394dc2e","isMergeCommit":true,"messageTitle":"Merge pull request #39 from Cazh1/master","messageBody":"10-create-command-class-v0.1 ","fileTypesAndContributionMap":{}},{"hash":"8e4fb479ae61dfc19385dee50a5acffe9072dd7d","isMergeCommit":false,"messageTitle":"Add commonly used methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":0}}},{"hash":"f97b53934e0c8778b06897e07499db1182d9365f","isMergeCommit":false,"messageTitle":"Add getters for Ingredient class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}}]},{"date":"2023-10-17","commitResults":[{"hash":"0d23d416e38c44e837ef3925d0862cca5e201e3e","isMergeCommit":true,"messageTitle":"Merge pull request #45 from ShaniceTang/21-implement-delete-ui","messageBody":"Issue 21, Implement Ui message for deleting a menu item","fileTypesAndContributionMap":{}},{"hash":"74f4f4d8f197fab8035bc1e7a855ccbd426dfc11","isMergeCommit":false,"messageTitle":"Implement add dish feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":7}}},{"hash":"f5824da1df3a9f3402190010e915feb380ebdbd0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 43-add-items-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"13d502c1c6a51e25c60748c110433973e7e72f6e","isMergeCommit":true,"messageTitle":"Merge pull request #47 from NaychiMin/20-UI-to-list-ingredients-v1.0","messageBody":"20 UI to list ingredients v1.0","fileTypesAndContributionMap":{}},{"hash":"69b789b05598d52130d17ad17ceeec896c42ef5e","isMergeCommit":false,"messageTitle":"Add testing for add dish command","messageBody":"Fixes #48\n","fileTypesAndContributionMap":{"test-code":{"insertions":24,"deletions":0}}},{"hash":"ca9212eada5e9bc6b5c18f161cb2a8983ccc3a35","isMergeCommit":false,"messageTitle":"Edit comment","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"eed8da07c304064b6e444c35e284ab8e0c393455","isMergeCommit":false,"messageTitle":"Update code based on gradle coding standard","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"0667ad8410478761765952e3186d0c5e5cc33356","isMergeCommit":true,"messageTitle":"Merge pull request #49 from Cazh1/#16-View-Menu-Items","messageBody":"#16 view menu items","fileTypesAndContributionMap":{}},{"hash":"c5043aaeea97d5ad78353eaf80389098f3e1f210","isMergeCommit":true,"messageTitle":"Merge pull request #50 from Cazh1/#19-Implement-Parser-Support","messageBody":"#19 implement parser support","fileTypesAndContributionMap":{}},{"hash":"eb16e2ca4bf8e39022a0ec75a64f2e3beab45774","isMergeCommit":true,"messageTitle":"Merge pull request #53 from ShaniceTang/22-implement-delete-feature","messageBody":"Task 22, Implement parser support for deleting a dish","fileTypesAndContributionMap":{}},{"hash":"a60c6f8075c9bac64b07d31815539843eb994d77","isMergeCommit":true,"messageTitle":"Merge pull request #54 from NaychiMin/23-parser-for-list-ingredients-v1.0","messageBody":"Task 23, Implement parsing support for listing ingredients .","fileTypesAndContributionMap":{}},{"hash":"2df1928e48276841f508f61e5cd0349ca6fe6df3","isMergeCommit":true,"messageTitle":"Merge pull request #51 from ziyi105/use-pattern-and-matcher-in-parser","messageBody":"Use pattern and matcher in parser","fileTypesAndContributionMap":{}},{"hash":"59eef0cdf11d0ea66d95fb251b957f33a24b201f","isMergeCommit":false,"messageTitle":"Renamed main class to CafeCtrl","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":19},"other":{"insertions":64,"deletions":56},"test-code":{"insertions":10,"deletions":10}}},{"hash":"08b6d3757647c4100510c3f57df4a3423980a755","isMergeCommit":false,"messageTitle":"Edit main function to start CafeCtrl application","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":7}}},{"hash":"557ea9cc49cdf6bce167d8bba7f828c9bb35dfea","isMergeCommit":false,"messageTitle":"Add JavaDoc to appropriate methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":1}}},{"hash":"a84615c4ad6c93f020b83e1cb92e6717d84e77ae","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 38-edit-main-class-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"87ceea9d298f8b648ed7219c550f363a2685ec60","isMergeCommit":false,"messageTitle":"Edit code to change displayed text","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"d96a43c56516085e4f47d119e887509154d76318","isMergeCommit":false,"messageTitle":"Remove unused import statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"ef8dd90e355a925a8d75c9a7ef0fd3e55e4efa46","isMergeCommit":false,"messageTitle":"Edit accessibility, add Javadoc and edit to resolve coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":3}}},{"hash":"6da928e074d832fb7ec5d798d84fe03a2dfd4b3c","isMergeCommit":false,"messageTitle":"Edit code for exiting loop logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":1}}},{"hash":"597bd744aa3a8af3f037200da66ec4124e067311","isMergeCommit":false,"messageTitle":"Edit code to follow coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-18","commitResults":[{"hash":"5cbc5ff9fbc6f1cd8e2f45f9254dad5522fe73b6","isMergeCommit":true,"messageTitle":"Merge pull request #61 from ziyi105/master","messageBody":"Sync my master ","fileTypesAndContributionMap":{}},{"hash":"c5cd369348c670f00cee3d1057e691e82af5d924","isMergeCommit":true,"messageTitle":"Merge pull request #64 from ziyi105/ziyi105-11-feature-edit-price-v1.0","messageBody":"11 feature edit price v1.0","fileTypesAndContributionMap":{}},{"hash":"cd65ca12b9a4aa2d948b592690f25f2f23c10502","isMergeCommit":false,"messageTitle":"Create parsing logic for add command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":26}}},{"hash":"662573be694dfbb3b724a75cb1523a54ed7d65be","isMergeCommit":false,"messageTitle":"Refactor prepareAdd method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":24}}},{"hash":"1efc60f9586f0d30b7825876730b0b655c88eeb7","isMergeCommit":false,"messageTitle":"Edit error messages for add dish parsing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":3}}},{"hash":"a91ce9760719dd42f2a4f04b5945d19194e15e02","isMergeCommit":false,"messageTitle":"Remove magic numbers in prepareAdd method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"b288c8a7fe69918fc91bbaeaeacb7b0e4a3d3e22","isMergeCommit":false,"messageTitle":"Edit printAddDishMessage method to display price in 2 decimal place","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":2}}},{"hash":"46d545187e45a75040194e17f555938a00c0531a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 24-parser-add-dish-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"bafeabf2525e5166b1ab60cb4f14a6fc7566bf58","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":9}}},{"hash":"dc474694da89328e8858e7a6d0dbd9e3acecd725","isMergeCommit":false,"messageTitle":"Fix regex for checking command format","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"b2cdb4b7ed5c7a53f4c94a59976d9cb9b210fa5f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 48-add-junit-add-dish-command-class-v1.0","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/duke/command/AddDishCommandTest.java\n","fileTypesAndContributionMap":{}},{"hash":"fa8ef0342b58f18674f264f4ccf62ba1c191089e","isMergeCommit":true,"messageTitle":"Merge pull request #68 from ziyi105/65-junit-test-edit_price","messageBody":"65 junit test edit price","fileTypesAndContributionMap":{}},{"hash":"4d15f13e7ddfa5613ca9aeead0a522e7ca345d7d","isMergeCommit":false,"messageTitle":"Migrate code to the proper file to account for refactoring","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":25,"deletions":31}}},{"hash":"21f12ca05d6c12e1ebf594b645ee414aa463f867","isMergeCommit":false,"messageTitle":"Rename assertion test class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"39a749dfb863c53632cfc7fe43940e78ffcbaa36","isMergeCommit":true,"messageTitle":"Merge pull request #71 from NaychiMin/23-parser-for-list-ingredients-v1.0","messageBody":"Task 15 Fulfill user story: As a cafe owner, I want to list the ingredients needed for each dish on the menu","fileTypesAndContributionMap":{}},{"hash":"edf80a2a80eecbec3210162b4005895920dc697f","isMergeCommit":true,"messageTitle":"Merge pull request #70 from Cazh1/master","messageBody":"Update ListMenuCommand JUnit assertion use","fileTypesAndContributionMap":{}},{"hash":"293c66243dde702314e4b2f53db72f638f5a773b","isMergeCommit":false,"messageTitle":"Added JUnit Tests for add dish command parsing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":35,"deletions":0}}},{"hash":"a1c50f66393dc01a4e45c75e9ef33fb975305ec7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 67-junit-test-for-add-dish-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"41cb964a10164e5c327493bac64d1bb053d05657","isMergeCommit":false,"messageTitle":"Update ParserTest.java to resolve checkstyle bug","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"1b21699f299353403aff2b6e37e077e604e675cf","isMergeCommit":true,"messageTitle":"Merge pull request #75 from ShaniceTang/22-implement-delete-feature","messageBody":"Task 17, Implement delete feature","fileTypesAndContributionMap":{}},{"hash":"c694c066583b13ef900278baa32b1df645b43fd6","isMergeCommit":false,"messageTitle":"Edit add dish parsing code to prevent negative price input","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":0}}},{"hash":"d1fa8a2f18fd567e65f8e22359f333e35cda5099","isMergeCommit":false,"messageTitle":"Edit code to solve checkstyle issues","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":6}}}]},{"date":"2023-10-22","commitResults":[{"hash":"bf777c46f6b1718b5e939b83e6b6d710b37ff8ff","isMergeCommit":false,"messageTitle":"build.gradle: Enable assertions","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-23","commitResults":[{"hash":"dd09c3f9be85aa42430c94212437518ea9d53ebe","isMergeCommit":true,"messageTitle":"Merge pull request #98 from ziyi105/73-implement-help-command","messageBody":"73 implement help command","fileTypesAndContributionMap":{}},{"hash":"d4e717104a76ff44bd25aa1ead7a97fb824f026c","isMergeCommit":false,"messageTitle":"Change exception handling for prepareAdd logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":25}}},{"hash":"baf4a1b83f4c0c988a4cd37d3c8feece84a3e541","isMergeCommit":false,"messageTitle":"Change error messages and minor change to AddDishCommand class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":7}}},{"hash":"c0666d970edad17702f9fdaa56d9297c274b0c67","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 102-add-dish-exception-handling-v1.1","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d2c657d8b35474fa8ab79ecdaca5159baf2c2aac","isMergeCommit":false,"messageTitle":"Change ingredientParsing function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"49f5b540ecf1e3ef0ee405221278dc12bbf19b74","isMergeCommit":false,"messageTitle":"Add Javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":1}}}]},{"date":"2023-10-24","commitResults":[{"hash":"50624791c21f56e1f453f446afce153456266da2","isMergeCommit":false,"messageTitle":"Change parsing logic to read ml or g units for ingredient qty","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":15}}},{"hash":"f6a34539b291986a3439ae429844b5a016c7b88a","isMergeCommit":true,"messageTitle":"Merge pull request #108 from Cazh1/#107-Change-Command-Class-execute-method","messageBody":"#107 change command class execute method","fileTypesAndContributionMap":{}},{"hash":"f4dbba3497804b4ceec6a5b68c8fe324ec9e249f","isMergeCommit":false,"messageTitle":"Revert \"#107 change command class execute method\"","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":85,"deletions":334},"test-code":{"insertions":42,"deletions":56}}},{"hash":"bc4b74ad8633b1d37f27b508c78e99918be6a35f","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e66b7355da6b48050d48947d30973317235d1891","isMergeCommit":true,"messageTitle":"Merge pull request #109 from AY2324S1-CS2113-T17-2/revert-108-#107-Change-Command-Class-execute-method","messageBody":"Revert \"#107 change command class execute method\"","fileTypesAndContributionMap":{}},{"hash":"763688f9316bb15ceebec3e5fe7c9747055d46ce","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fcebfff0e3f01ae40591acf89499f89160cec509","isMergeCommit":true,"messageTitle":"Merge pull request #105 from Cazh1/#84-Implement-UI-support-for-Order-class","messageBody":"#84 implement UI support for order class","fileTypesAndContributionMap":{}},{"hash":"463b45b58762eb58809172419a4d88849bc163c7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"868d299a491cff787a4543c64d3d95fc51d85716","isMergeCommit":false,"messageTitle":"Edit parsing logic to divide ingredient qty into name and unit","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3}}},{"hash":"06d4c57a5100fa38963ba199a057f693adb61f69","isMergeCommit":false,"messageTitle":"Rename variables and regex for clarity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":10}}},{"hash":"c726c8364e1b7d52b5f508d0519eb117b1d48a23","isMergeCommit":false,"messageTitle":"Fix BuyIngredient parsing logic to use updated regex","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":6}}},{"hash":"3c40f6dcb8cb7f2ffbb1a5b6195eb0455f63d575","isMergeCommit":false,"messageTitle":"Edit the AddDish parsing error handling and JavaDoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":10}}},{"hash":"5fe0bb191e6c4fb60de7be71cd53d223fa0000e5","isMergeCommit":false,"messageTitle":"Change all definition statements to private","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":16}}},{"hash":"4955e587557a0acf43b478b0c020f21a22ece253","isMergeCommit":false,"messageTitle":"Update test cases for addDish command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":4}}},{"hash":"2eaf137b2222ceb165ec7b2bfd4eb37da13f9ba4","isMergeCommit":true,"messageTitle":"Merge pull request #110 from Cazh1/#107-Change-Command-Class-execute-method","messageBody":"#107 Change Command class execute method","fileTypesAndContributionMap":{}},{"hash":"3c0a0355135e6759f50ef5084bebd5b24cb20f53","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7c914b24d70c3ee96323c1c59993858be531c15d","isMergeCommit":true,"messageTitle":"Merge pull request #114 from DextheChik3n/100-format-read-ingredient-unit-v1.2","messageBody":"100 format read ingredient unit v1.2","fileTypesAndContributionMap":{}},{"hash":"18c5dc331f026ecb2eab6c20363b82479c68cf4e","isMergeCommit":false,"messageTitle":"Create sequence diagram for AddDish command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":28,"deletions":0}}},{"hash":"2d7ab89f7011b388dbb57e217907d7a4b94de9a2","isMergeCommit":true,"messageTitle":"Merge pull request #119 from ShaniceTang/118-improve-buyIngredient","messageBody":"Task 118, Improve buyIngredient command to accept multiple ingredients","fileTypesAndContributionMap":{}},{"hash":"f279fd2394c61d0c4d1f7691fd30a874786c4795","isMergeCommit":false,"messageTitle":"Refactor printAddDishMessage method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":13}}},{"hash":"8d41e0641a730c2a758054408f4ca018c6c2924e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 123-refactor-add-dish-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4948df6bbc47975cf084a3d5bd6b17b248b196ef","isMergeCommit":false,"messageTitle":"Fix addDishCommand parsing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"63d0a366759628ad0a96443a3f9c6f02e367df11","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 117-DG-add-dish","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0fbeaaf0766307cf02d5a53018a33d366879f89a","isMergeCommit":false,"messageTitle":"Create sequence diagram for addDish command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":5}}},{"hash":"2095e06b8466275844050c3ec1069e49ebc29159","isMergeCommit":false,"messageTitle":"Update developer guide to explain the implementation of addDish command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":1}}},{"hash":"c1f95056eb4c57270099003ecdc7a8cc69d27b31","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 117-DG-add-dish","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"da87ea78a13f050c5faeb6b76910706d2d1cac45","isMergeCommit":true,"messageTitle":"Merge pull request #126 from ShaniceTang/120-create-deleteDish-uml","messageBody":"Task 120, Update DG for delete dish command","fileTypesAndContributionMap":{}},{"hash":"0549edae1c207ee9cc03b766e7f63fa271494fd2","isMergeCommit":true,"messageTitle":"Merge pull request #127 from NaychiMin/115_DG_for_list_ingredients","messageBody":"Task 115, Edit developer guide for List Ingredient command.","fileTypesAndContributionMap":{}},{"hash":"200d0c4f4cc2132f8d9ded86cdc48f99b9b43da5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 117-DG-add-dish","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"702daf244d44f64fc0b9eeecf2da38c4d93d1904","isMergeCommit":true,"messageTitle":"Merge pull request #129 from Cazh1/128-Update-DG-for-list_menu-feature","messageBody":"Update DG for list_menu feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"4aaf45365970c0b45c780d93e1e264be6efd9244","isMergeCommit":false,"messageTitle":"Create Storage parent class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":0}}},{"hash":"af3570530ca7557025e99fae83b08db3e7b11a62","isMergeCommit":false,"messageTitle":"Create error handling for file and folder saving","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":3}}},{"hash":"e0b1c99d944481e3a58b5b1f4207fcbba3b59c84","isMergeCommit":false,"messageTitle":"Create menu storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":69,"deletions":0}}},{"hash":"2f6306dd6846b8b2807c885bf87befa86b392904","isMergeCommit":false,"messageTitle":"Edit main to do foundational text storage functionality for Menu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":4}}},{"hash":"d7d1074b7d442c5d7dbaea6dd44467fcd185b8ba","isMergeCommit":false,"messageTitle":"Edit messages for storage feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"81762ce619200d8623de91be574608098c69839f","isMergeCommit":false,"messageTitle":"Change messages for opening text file logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"4c8803d8490b01f1ff9b333ac4823702002d556b","isMergeCommit":false,"messageTitle":"Edit add dish parsing logic to accept whitespaces","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":19}}},{"hash":"857b9a8c177620f73a4a81fe8bba331c1acbb1f4","isMergeCommit":false,"messageTitle":"Refactor AddDish command logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":12}}},{"hash":"cdf7ad077e707a50c7bdd6cacf43dfb8456c7b7a","isMergeCommit":false,"messageTitle":"Add more JUnit Tests with respect to bug fix","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":153,"deletions":9}}},{"hash":"e48aecff8ac3a85fc076d7637d6e3127e79b18e1","isMergeCommit":false,"messageTitle":"Add author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2},"test-code":{"insertions":2,"deletions":1}}},{"hash":"7eb0cbed400121c284dd9b92a7f766fa77d46615","isMergeCommit":false,"messageTitle":"Refactor to satisfy coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-28","commitResults":[{"hash":"a5919cc3adf1c086294058972a795b8b9a565829","isMergeCommit":false,"messageTitle":"Edit user input command regex","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"8146494321ad74edd59983b438548e9badf2db06","isMergeCommit":false,"messageTitle":"Add author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":6}}},{"hash":"07c0d58b8b3e124407c1d012f819b4dee545708a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 138-fix-add-dish-command-bugs-v2.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Ui.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"4dff4aacbf5069ed1e685c680112e0fdb2f2f466","isMergeCommit":true,"messageTitle":"Merge pull request #143 from ziyi105/140-more-oop-storage","messageBody":"#140 Refactor Storage System to be more OOP","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"0cc8fe97f31a4acfe4b8375330157da132720ed5","isMergeCommit":false,"messageTitle":"Add error handling for price input overflow","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":2}}},{"hash":"303361945e22679cf8855171c0780ed2c5f5b5ff","isMergeCommit":false,"messageTitle":"Add JUnit tests for priceParseToFloat function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":0}}},{"hash":"0c646fc5dd8dd5b88a45fb363aa0bd214d242881","isMergeCommit":false,"messageTitle":"Edit JUnit tests for AddDish commands","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":17,"deletions":35}}},{"hash":"a961283ef6cb23315121adc83a5b80885069ad6d","isMergeCommit":false,"messageTitle":"Edit classes to standardise spacing for consistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":10}}},{"hash":"5d65c3c89bbfed88ae1fa6e9f567bf7dd904df1e","isMergeCommit":false,"messageTitle":"Update User Guide for v1.0 commands","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":100,"deletions":21}}},{"hash":"c25809b3524b1129f95adcbbe4f20d43e8440696","isMergeCommit":false,"messageTitle":"Edit command summary table","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":8}}}]},{"date":"2023-10-31","commitResults":[{"hash":"30594403954ddec545efb5cad5c7e2bc450d1b10","isMergeCommit":true,"messageTitle":"Merge pull request #156 from ziyi105/147-encode-decode-pantry-stock","messageBody":"147 encode decode pantry stock","fileTypesAndContributionMap":{}},{"hash":"6c0e5578d76a8db5acc29bdd256c802226b1b1a9","isMergeCommit":true,"messageTitle":"Merge pull request #160 from Cazh1/#158-Update-DG-with-Add-Order-feature","messageBody":"#158 update dg with add order feature","fileTypesAndContributionMap":{}},{"hash":"fe1a5cb8ff37cb1980a6eecbe9eaf990a2055e6c","isMergeCommit":true,"messageTitle":"Merge pull request #165 from ziyi105/DG-parser-class","messageBody":"Update DG: parser class and help command","fileTypesAndContributionMap":{}},{"hash":"0de5fe72357608e4d467c589c7fa64d1f0bbf273","isMergeCommit":false,"messageTitle":"Add error handling for repeated dish name in add dish command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":1}}},{"hash":"8592f76712fa8afb25647d0c2bd1549c8f67880d","isMergeCommit":false,"messageTitle":"Add JUnit tests for isRepeatedDishName function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":0}}},{"hash":"4e4c4af31e91166a22a0d154c523650d22ff5fb6","isMergeCommit":false,"messageTitle":"Add error handling for null dish name","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"e4169e6f6b4985aec867b9508be92944f8698774","isMergeCommit":false,"messageTitle":"Add Ui messages for existing dish name detected","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"af9cdf9da0f34acdd84e170ee3741c53bef63782","isMergeCommit":false,"messageTitle":"Refactor function name","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"51787b1c73182e64d245bbe19a612c5e5158255d","isMergeCommit":false,"messageTitle":"Make small changes to comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"d0a459125e57bda70df4a024d4775fea92e09382","isMergeCommit":false,"messageTitle":"Remove error handling from main and redundant code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":12}}},{"hash":"dfb08cba67b8ae335249c1a2ee4a3e88d2860617","isMergeCommit":false,"messageTitle":"Create UML structure for Storage class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":49,"deletions":0}}},{"hash":"f5a82858fcd4b5857ef48fe811f773d63b0b39ab","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 169-dg-order-class-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a1f97402167777e4794df19e01f7f2474f3df372","isMergeCommit":true,"messageTitle":"Merge pull request #161 from ShaniceTang/146-encoding-decoding-menu","messageBody":"Task 146, Create encoding and decoding to text file in menu storage","fileTypesAndContributionMap":{}},{"hash":"e92acc2b430109d31961be2b8ecb2efa5c534c82","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 169-dg-order-class-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8d83eb98f570d76f2d2205e99c29e527c8f38998","isMergeCommit":false,"messageTitle":"Refactor Storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":17}}}]},{"date":"2023-11-01","commitResults":[{"hash":"e5db639676dc93980d77e67e28a96ae4faf71fc1","isMergeCommit":false,"messageTitle":"Create Storage class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":28,"deletions":19}}},{"hash":"af0deb9e8153d900782dbaefa723f505fca29424","isMergeCommit":false,"messageTitle":"Update DG for Storage class","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":1}}},{"hash":"2268167952af4b0da3aba82622b9e2a95e9b7b21","isMergeCommit":false,"messageTitle":"Clean up small error in documentation","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":6}}},{"hash":"893a34c9c61d77bbc175ee77fe790ca4e54a74ad","isMergeCommit":true,"messageTitle":"Merge pull request #177 from ziyi105/176-UG-help-edit-price","messageBody":"176 UG help edit price","fileTypesAndContributionMap":{}},{"hash":"7e6d0d442540090670485a3b261773ad063c264d","isMergeCommit":true,"messageTitle":"Merge pull request #181 from DextheChik3n/169-dg-storage-class-v2.0","messageBody":"169 dg storage class v2.0","fileTypesAndContributionMap":{}},{"hash":"309cd9c8c918cfe102df02fb5e35d7025719a130","isMergeCommit":true,"messageTitle":"Merge pull request #183 from ziyi105/182-standardise-help-command","messageBody":"182 standardise help command","fileTypesAndContributionMap":{}},{"hash":"fd88ff4ca16bdd7d8baee87ea2288806af83a932","isMergeCommit":false,"messageTitle":"Add error handling for name input exceed max characters","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":4}}},{"hash":"ac197685e05b776ba5e9a7094b1e894f4dbf2be0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 178-limit-name-input-char-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ee9fd0770887a9356f3297f46954009a13edef0b","isMergeCommit":false,"messageTitle":"Refactor utility functions to ParserUtil class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":72,"deletions":71},"test-code":{"insertions":6,"deletions":6}}},{"hash":"dd83de059ce69a23d88a057d96db2bae0a1acd5c","isMergeCommit":false,"messageTitle":"Refactor error handling and utility functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":16},"test-code":{"insertions":68,"deletions":56}}},{"hash":"0eb8ef573c7794f5291bab7a85cd3e2f817c8deb","isMergeCommit":false,"messageTitle":"Add JUnit tests for name length checker function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":0}}},{"hash":"fa4345bd4079771ae4d9b1caf90c1a65977f9760","isMergeCommit":false,"messageTitle":"Resolve JUnit test from refactoring error handling","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"fd5187d59068c49a2e39f7e27d78060659c5d0a7","isMergeCommit":false,"messageTitle":"Edit JUnit test code to satisfy coding standards","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"b4b623164b3667549d776a77b7be64f3d1ab01b8","isMergeCommit":true,"messageTitle":"Merge pull request #191 from ShaniceTang/173-buyIngredient-junit-test","messageBody":"Task 173, Implement JUnit Test for buyIngredient function","fileTypesAndContributionMap":{}},{"hash":"d72c1cd30a36518a6b359e955b544260c7f1d412","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 178-limit-name-input-char-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bb362bceaf19daeb4b35af8f5f178f64d6564838","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 142-storage-error-handling-v2.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/CafeCtrl.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}},{"hash":"a176f7b6371d6e446fa5da0cedeb36d2123714f7","isMergeCommit":true,"messageTitle":"Merge pull request #190 from NaychiMin/189_print_orderlist","messageBody":"Task 189, implement function to show total sales for all days and sales by specific days.","fileTypesAndContributionMap":{}},{"hash":"758eac51eaaeb2252725849874f9b16cf9b46c91","isMergeCommit":true,"messageTitle":"Merge pull request #193 from ShaniceTang/188-viewTotalStock-junit-test","messageBody":"Task 188, Add JUnit test for viewTotalStock command","fileTypesAndContributionMap":{}},{"hash":"a08dae0532beb124f16824cda6096e61e17c5103","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 178-limit-name-input-char-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"818b1b37a5cea3e6777053c10a64ac0871dce6d0","isMergeCommit":false,"messageTitle":"Edit error handling in main CafeCtrl class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}},{"hash":"983089ccde232737a16e28d57d5635e9b971dfa9","isMergeCommit":false,"messageTitle":"Resolve errors in ParserTest class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":57}}},{"hash":"4f7cfe1cf5f25608e5ef3ce380cf1a957a3eafb6","isMergeCommit":false,"messageTitle":"Edit error handling for file storage functionality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":71,"deletions":76},"test-code":{"insertions":0,"deletions":12}}},{"hash":"5115b8b25034bdf64ca9dfe329bb5befc1e7090f","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":6}}},{"hash":"7bff627dc74a9fcadc78530f73dbb9da42c59d14","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 142-storage-error-handling-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e66637376701afa4e1e8f018fee7238a73290457","isMergeCommit":true,"messageTitle":"Merge pull request #199 from NaychiMin/198-fix-main-v2.0","messageBody":"Task 198, fix main v2.0","fileTypesAndContributionMap":{}},{"hash":"df8de17fe11838dae6673191f217b201ea55cab4","isMergeCommit":false,"messageTitle":"Resolve issues found when pulling code from local repo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"9dda2b9aa06cb68b2fb5c427bf678edea362f53b","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 142-storage-error-handling-v2.0","messageBody":"# Conflicts:\n#\tdata/orders.txt\n","fileTypesAndContributionMap":{}},{"hash":"1d15b6ca5e88a9b962fd5b7b3bdef331f7ee4f71","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"79ee69fd33aded144ae636d8add17c3f23f4e6f2","isMergeCommit":false,"messageTitle":"Refactor code based on reviewer feedback","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":64},"test-code":{"insertions":74,"deletions":73}}},{"hash":"9bb972ffc4661a279a30be4a67213ad45b9b09e2","isMergeCommit":false,"messageTitle":"Make minor changes for to revert ParserUtil class changes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3},"test-code":{"insertions":0,"deletions":15}}},{"hash":"587d98518f7597da4985bdf3cdca1f0a031ae893","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3},"test-code":{"insertions":3,"deletions":1}}},{"hash":"f78c56ac089977184c63e95f58215d968bbb56a1","isMergeCommit":true,"messageTitle":"Merge pull request #192 from DextheChik3n/178-limit-name-input-char-v2.0","messageBody":"178 limit number of characters for dish name and ingredient name input v2.0","fileTypesAndContributionMap":{}},{"hash":"8b92dcedd233d555dc8407a31abd99e9d258a44c","isMergeCommit":true,"messageTitle":"Merge pull request #201 from Cazh1/#200-Bug-Fix-for-AddOrderCommandTest","messageBody":"Fix bug for AddOrderCommandTest","fileTypesAndContributionMap":{}},{"hash":"f58f1e5028775bc0e8bc075b9ad51e49cd900ab0","isMergeCommit":true,"messageTitle":"Merge pull request #202 from NaychiMin/94-user-story-dish-availability-v2.0","messageBody":"Task 94, Fixed minor bugs and add in clearer error messages.","fileTypesAndContributionMap":{}},{"hash":"770508adba038ade4fb3b840d6c0712db05d0ce5","isMergeCommit":true,"messageTitle":"Merge pull request #203 from ziyi105/184-encode-pantrt-stock-with-regex","messageBody":"184 encode pantrt stock with regex","fileTypesAndContributionMap":{}},{"hash":"ff6892e6031e0e1e738f832ef89c1d567e10de5e","isMergeCommit":true,"messageTitle":"Merge pull request #186 from Cazh1/#159-Update-DG-with-Multi-day-Order-feature","messageBody":"#159 Update DG with Multi-day Order feature","fileTypesAndContributionMap":{}},{"hash":"4ac72d1a7644050d559a42213488e4bfc68f6ddf","isMergeCommit":false,"messageTitle":"Add fix to prevent multiple ingredients with same name","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":2},"test-code":{"insertions":4,"deletions":4}}},{"hash":"9bf0d888fcf148d3d6c0b5962d53ef0e22a396a2","isMergeCommit":false,"messageTitle":"Edit Javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"782fa3b95ebea39a45afa2d8e2e5fce93e80df24","isMergeCommit":true,"messageTitle":"Merge pull request #204 from ShaniceTang/185-data-dg","messageBody":"Task 185, Add class diagram for Data component","fileTypesAndContributionMap":{}},{"hash":"ee5db7a1f4bb5514574f7f4e843bc25b30a9c862","isMergeCommit":true,"messageTitle":"Merge pull request #212 from Cazh1/#211-Bug--1-index-Error-when-showing-sales","messageBody":"Fix bug","fileTypesAndContributionMap":{}},{"hash":"8a30636776caef556d6d91cfba7ed3410365cd5e","isMergeCommit":true,"messageTitle":"Merge pull request #207 from Cazh1/Update-UG-for-Add-Order","messageBody":"Update UG for Add Order","fileTypesAndContributionMap":{}},{"hash":"e1074283e30fa07e2459c8fc44a8a8bc30c14577","isMergeCommit":true,"messageTitle":"Merge pull request #208 from ShaniceTang/187-architecture-diagram","messageBody":"Task 187, Add architecture diagram","fileTypesAndContributionMap":{}},{"hash":"75ad7059636a75aec6e778134c8c0bb3233be63d","isMergeCommit":true,"messageTitle":"Merge pull request #213 from ShaniceTang/174-ui-classDiagram","messageBody":"Task 174, Add UI Component to DG","fileTypesAndContributionMap":{}},{"hash":"d80103eb96593deaf5c24784c0e5a5fe48337173","isMergeCommit":true,"messageTitle":"Merge pull request #214 from ziyi105/184-encode-pantrt-stock-with-regex","messageBody":"Debug encoding pantry stock cannot add more than one ingredient","fileTypesAndContributionMap":{}},{"hash":"21edf2f45490a5adf7b88a6c05a0ebaa4036e84a","isMergeCommit":false,"messageTitle":"Remove unused code for printing ingredients in add dish command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":12}}},{"hash":"c339beff59100ce960eb76ec8f333673b535010d","isMergeCommit":false,"messageTitle":"Fix bug for adding same dish name after reloading application","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"3cfc15076bfc67baf39105dec434079cbdc92018","isMergeCommit":false,"messageTitle":"Add author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"43fa69375beab01cc6ad094824d793c2d16a88a3","isMergeCommit":false,"messageTitle":"Update UG and DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":20}}},{"hash":"20a8d133d32a4fff81d4acd4b0fff144c8b6467c","isMergeCommit":true,"messageTitle":"Merge pull request #217 from Cazh1/master","messageBody":"Update Code Quality","fileTypesAndContributionMap":{}},{"hash":"5fd22a1694d408b36976066d6f08043071dc7766","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 94-user-story-dish-availability-v2.0","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"b353ffa86847f49a3b5b765ffe19afc9b75babd6","isMergeCommit":true,"messageTitle":"Merge pull request #215 from NaychiMin/94-user-story-dish-availability-v2.0","messageBody":"Task 94, user story dish availability v2.0","tags":["A-Release-v2.0"],"fileTypesAndContributionMap":{}}]}],"Cazh1":[{"date":"2023-10-05","commitResults":[{"hash":"070155ed53e9e987a79208ac10c5a7942c4cf353","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"723d6d3ec5d4432d2631550b9b22baf980699341","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"7c37a72bf95a8e73203623e2f7bba0d31d980da2","isMergeCommit":false,"messageTitle":"Add Command class","messageBody":"Fixes #10\n","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":0},"test-code":{"insertions":28,"deletions":0}}},{"hash":"41a9cdcf458fc3a5c3263d6a38a86dcd2df4bf24","isMergeCommit":false,"messageTitle":"Update DeleteCommand.java documentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"d97572fd5728f2ca25a88738e0051ea5e7eb8ad0","isMergeCommit":false,"messageTitle":"Update class names to be more specific","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":11},"other":{"insertions":2,"deletions":2},"test-code":{"insertions":20,"deletions":23}}},{"hash":"eb08e382fa90c0fb9bdf8e71b309f20284cd98ad","isMergeCommit":false,"messageTitle":"Add newline at end of test files","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":5}}},{"hash":"3c06e5aa4557a25d90dda38e1a41ae36ca9e6e10","isMergeCommit":false,"messageTitle":"Update execute method in Command class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":6}}},{"hash":"07a56ed80238819e5d1923bc0495342718d6cc60","isMergeCommit":false,"messageTitle":"Update Command class to include index attribute","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":1}}},{"hash":"0571dea28a7a323f5ea3157b5b11efc77a16ad9d","isMergeCommit":false,"messageTitle":"Update ListMenuCommand.java for spacing issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"67f65e2b750751127920b80b45d162c28849b99f","isMergeCommit":false,"messageTitle":"Update Menu.java methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":1}}},{"hash":"dd7c6f2d40a3ed811a03e75cc2af2322965eb214","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027 into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"43905d03b1a0e1e6f237519feb227e5c606d0e3d","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027 into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"188ec8e7c0cd4b376b7ab20baa1b24b4b3a9fce0","isMergeCommit":false,"messageTitle":"Update ListMenuCommand.java function","messageBody":"Fixes #16\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":4}}},{"hash":"960269b67e4aa999773ea1f4dbc28795c369f061","isMergeCommit":false,"messageTitle":"Implement UI support for ListMenu","messageBody":"Fixes #18\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"ad6b223efae6bf4be468bf1ad7cbeb772c58d774","isMergeCommit":false,"messageTitle":"Implement Junit for ListCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0},"test-code":{"insertions":16,"deletions":0}}},{"hash":"ac4e57130e2e050f03f1ccd7411de2e88ee69082","isMergeCommit":false,"messageTitle":"Update ListMenuCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":0}}},{"hash":"00a910fc686c6c00e94650e0d5916547bc5e5ad9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f6297af60c900eefedcceacecce2d08c15276341","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"2856c5f60c980e91be95c745fedd8c9e8ddd6e31","isMergeCommit":false,"messageTitle":"Implement Parser Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":136,"deletions":10}}},{"hash":"0d2d717f903269c31c1ca662023c8ce76f91caa6","isMergeCommit":true,"messageTitle":"Merge branch \u0027#16-View-Menu-Items\u0027 of https://github.com/Cazh1/tp into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b561971875675cd6dbafb42d37fd06e4bf2c8ddf","isMergeCommit":false,"messageTitle":"Implement Parser Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"9ce30642e1d1acc79672f3dcf830307d7482cf42","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"d9714d689f822fffe73a376d3954546775ceaa7d","isMergeCommit":false,"messageTitle":"Update code in reference to Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":20}}},{"hash":"71629404bad7b6184f37a4cff09948061ab74dda","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"ec3ad41cac129fdce30e4415477e1dded5257571","isMergeCommit":false,"messageTitle":"Update Duke.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":29}}},{"hash":"108544c2ee7ab0add14e4add818cec3bd9833423","isMergeCommit":false,"messageTitle":"Update code with regards to Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":47},"test-code":{"insertions":3,"deletions":3}}},{"hash":"dcb4058fbb404099fe3a75a755d95dccb55511a5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #19-Implement-Parser-Support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5f5820c74f52b67d4286d5eb18c96c705fb71c52","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"017b36204c1a5a2dfcec158d84a28b4c8f9bfd0d","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"31be1a09cca6f201e27ca77b56b7b58c660e54fb","isMergeCommit":false,"messageTitle":"Update JUnit to include assertion","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":1}}},{"hash":"0bfb9deb1c64b443917db9cf43fd1941db44c731","isMergeCommit":false,"messageTitle":"Update Parser to support ListMenuCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"2374d2890158c0441811d369ecfb121d1c23bc25","isMergeCommit":false,"messageTitle":"Update JUnit test case name to comply with standards","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-18","commitResults":[{"hash":"aa96baada7a5530ba329e33200dc264f6b09434e","isMergeCommit":false,"messageTitle":"Update code to remove use of Magic String","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":6}}},{"hash":"4d0cc8da2c44626b3abdc3baaac5f28f183e57bc","isMergeCommit":false,"messageTitle":"Update JUnit assertion use","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":27,"deletions":1}}},{"hash":"0956546fb4a59b7037ad7a3e659dc894f97ef3dc","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":4}}},{"hash":"e43dffdab7af41343dd985321360c9d9547d0ff3","isMergeCommit":false,"messageTitle":"Update MenuList appearance","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":2},"test-code":{"insertions":4,"deletions":4}}}]},{"date":"2023-10-19","commitResults":[{"hash":"b18deabd054b19780e3d5cc6eac3fe1e541643d1","isMergeCommit":false,"messageTitle":"Update code to comply Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-22","commitResults":[{"hash":"b1aac1c4b0473c620dcb918ceb878ab12757384a","isMergeCommit":false,"messageTitle":"Add method for empty menu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":2}}},{"hash":"69168a3d641267d405a4019bcbade582689e8d5f","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"927b64d77278cb15a7b0f986d7719a29bb655771","isMergeCommit":false,"messageTitle":"Update JUnit for ListMenu","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":18,"deletions":8}}},{"hash":"c2c3c5c523442a2120fd42ec4c0403a3c32892d5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Edit-List_Menu-appearance","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fffd1c462fa1ec1f8c4f210824670563c458d26e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Edit-List_Menu-appearance","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"65510e0cc0896dd9dbb314673257289143d76e40","isMergeCommit":false,"messageTitle":"Update ListMenu to use Messages.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":1}}},{"hash":"bf9bd2b8a6eb33b17431bede88dc2a51f58c49c1","isMergeCommit":false,"messageTitle":"Add Order Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":0}}}]},{"date":"2023-10-23","commitResults":[{"hash":"6d2ba2ce36b19daf8b6baf44842569ee9ec923a8","isMergeCommit":false,"messageTitle":"Add parser support for Order","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":140,"deletions":0}}},{"hash":"999da2ca70324fe354af44f98cc2ae9e7ced7169","isMergeCommit":false,"messageTitle":"Add toString() in Order.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"28b5c10ffbd796984f446a32ede19d8e69f7f173","isMergeCommit":true,"messageTitle":"Merge branch \u0027#82-Create-Order-Class\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ce93be786fd23cac0983576e9654e2976dca38e8","isMergeCommit":false,"messageTitle":"Update Messages with UI support for Order","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"277d6b480ea0d5ac28fd0572edfbdec3194bf2d6","isMergeCommit":true,"messageTitle":"Merge branch \u0027#84-Implement-UI-support-for-Order-class\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cabad889ab555b6563a97a75e0075e5911d512ea","isMergeCommit":false,"messageTitle":"Create OrderList.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":0}}},{"hash":"9741101389b74a91575214cfd166abff8b62a3a3","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"c184350348434e9d36140d1010ef592d6f98e4d2","isMergeCommit":false,"messageTitle":"Add JavaDoc for Order in Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":44}}},{"hash":"5032b6d32f31a70c2ffd8d85f6c01c4e9f7ea5a1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"974c5c0d82e8a75ac4fe1e985f5eb03bc49923d1","isMergeCommit":false,"messageTitle":"Update ListMenu Code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-24","commitResults":[{"hash":"5d2c79ac86b449d58c9ee372a58864601722bcb3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bfa0891e46c52dcfb3c301d159915bc0d5fcfaf7","isMergeCommit":false,"messageTitle":"Create Chef class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":0}}},{"hash":"a35e40f8136d9c95a5ec2e100a5e930cfc86c5a5","isMergeCommit":false,"messageTitle":"Update AddOrderCommand to use Chef","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":11}}},{"hash":"b22019ca7fff561c382049fc14d97e3174b353a0","isMergeCommit":false,"messageTitle":"Update Order class code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":15}}},{"hash":"affdce44fc86bf9850ec750265f3c3a5e337c750","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"a32a17b831d014945885eacea84b3b14e41c587a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #84-Implement-UI-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"05a92d6223524f43e6e233ea103bd4c4742442dc","isMergeCommit":false,"messageTitle":"Update code to comply with gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"70f16480d5975e0778f245142b7b2819e97a9849","isMergeCommit":false,"messageTitle":"Update Chef class to use Ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4}}},{"hash":"29da53f5b545c4b0ce50154ee2b0dd676b8e8b13","isMergeCommit":false,"messageTitle":"Update code to alter execute method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":127,"deletions":94},"test-code":{"insertions":56,"deletions":42}}},{"hash":"9977e9dbef1cb6980d68e58c14a5fd40a843a711","isMergeCommit":false,"messageTitle":"Update Chef.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":3}}},{"hash":"4e383c745f760820f608f5509bff260a73a88718","isMergeCommit":false,"messageTitle":"Update code with regards to review","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":64,"deletions":66},"test-code":{"insertions":1,"deletions":1}}},{"hash":"768f13442c347a6f40bd991777a4e0c2bdd06976","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"22eb421484549850d736ee67ec13c8c1a0de2688","isMergeCommit":false,"messageTitle":"Update Parser to resolve merge conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":2}}},{"hash":"15c038f646a5c0fcec0477ea8cb18b0114c0adfb","isMergeCommit":false,"messageTitle":"Update code to resolve merge conlfict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":6}}},{"hash":"9312315cae7e2625181586376372c22a480bb2b7","isMergeCommit":false,"messageTitle":"Update OrderList.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"ceff204fb713b24ead6620309da5c78f723c3a84","isMergeCommit":false,"messageTitle":"Add Parser support for OrderList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":6},"test-code":{"insertions":27,"deletions":13}}},{"hash":"3e8c796c16b4712623dafe9873a59df8de4ba070","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #107-Change-Command-Class-execute-method","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"42cb0cbf4ee8df6366b64d35e2543834a136bc21","isMergeCommit":false,"messageTitle":"Update code to resolve conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":114,"deletions":90},"test-code":{"insertions":20,"deletions":29}}},{"hash":"f6a67ab891e824d91f90bed8ff5c232c6ad3a451","isMergeCommit":false,"messageTitle":"Update Ui support for Order","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"9f28786d5e63b99b79138746e32c8356b59d4c77","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"d9e8b98a6aa48f3c4d8ff72e80cae61a7f2f6b10","isMergeCommit":false,"messageTitle":"Update Ui support for Chef","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}}]},{"date":"2023-10-26","commitResults":[{"hash":"c3f3597d326961fb2052c775c154fb67f8155481","isMergeCommit":false,"messageTitle":"Update DG for list_menu feature","messageBody":"Fixes #128\n","fileTypesAndContributionMap":{"docs":{"insertions":207,"deletions":0}}}]},{"date":"2023-10-27","commitResults":[{"hash":"79b51513fb2c6566b320cfc034f9d8652f5b30bd","isMergeCommit":false,"messageTitle":"Refactor ListMenu Command process","messageBody":"Fixes #130\n","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":11}}},{"hash":"88340a9be72cd5c73c3c74676d60b742de979b9c","isMergeCommit":false,"messageTitle":"Update DG after refactor","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":37,"deletions":38}}},{"hash":"6b4144af4e10585f41be34b845ccacd39a1aa90c","isMergeCommit":false,"messageTitle":"Refactor Order Class","messageBody":"Fixes #132\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":7}}},{"hash":"abae31307b2929a857db60da6ec5ebac18ffab15","isMergeCommit":false,"messageTitle":"Update ListMenuCommand to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"4844849403ba995597fe64295b0ffd26474d6d07","isMergeCommit":false,"messageTitle":"Update JUnit for ListMenuCommand","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":25,"deletions":0}}},{"hash":"5b66a0bdb9d519577cf7a5ace93d9af934d4ceec","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest to comply Gradle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"029346035f6cdc1e41be5898afcea6452d0e1df2","isMergeCommit":false,"messageTitle":"Update DG after refactor","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":3}}},{"hash":"56566297c9b81e559daf5b81b9fd07198109801b","isMergeCommit":false,"messageTitle":"Implement JUnit for AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":1},"test-code":{"insertions":136,"deletions":0}}},{"hash":"d745b59046f0a41bbf4f55a27a6f6078d6c13c40","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":8,"deletions":7}}},{"hash":"287d3f7f2d589db16f9b3026cd28661587e53b81","isMergeCommit":false,"messageTitle":"Update AddOrderCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":3}}},{"hash":"c5a094acfe56c03ef4a9962ffb0b88ae9359a3ba","isMergeCommit":false,"messageTitle":"Update AddOrderCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":13,"deletions":1}}},{"hash":"32025f87af667fe81815c327984f6b4ce357822c","isMergeCommit":false,"messageTitle":"Update Pantry.java for AddOrderCommand JUnit","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"eb38d96a39f2153008a6a0a0e3247fe794451924","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/#132-Refactor-Order-Class\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e7a9e42d83b1befbaadd915c827d487fa6bddbc0","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest with regards to review","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":8}}},{"hash":"a72b6f9dd133c9cead596c517d45b027129f7798","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"f0bc3aa9956d207f2b05dec0f9fbc9ce8ffd3a4f","isMergeCommit":false,"messageTitle":"Implement MultiDay support","messageBody":"Ability to store orders across days\n","fileTypesAndContributionMap":{"functional-code":{"insertions":339,"deletions":50},"other":{"insertions":4,"deletions":4},"test-code":{"insertions":8,"deletions":9}}},{"hash":"34f14811368ad1853189a555302dbc432fe432ae","isMergeCommit":false,"messageTitle":"Refactor CurrentDate and Sales","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":9},"other":{"insertions":2,"deletions":2}}},{"hash":"5a03a113a3dc747c0fbe57a842bb62f4a1a749b5","isMergeCommit":false,"messageTitle":"Add totalSale in the Sales","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":2}}},{"hash":"70a30d4fcf7aeafd185cd8999301c92aad6bb81f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"45ef83c9737a9ab4cb95c4e15cf8c7ae06b68f14","isMergeCommit":false,"messageTitle":"Update code to resolve merge conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":6},"test-code":{"insertions":2,"deletions":0}}}]},{"date":"2023-10-30","commitResults":[{"hash":"c832dba849812c868cbcdaf162ba21de8bbbb6f6","isMergeCommit":false,"messageTitle":"Refactor Sales to be inside Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":152}}},{"hash":"34149e8ff935871f2ae039b60c34905f222ac9ab","isMergeCommit":false,"messageTitle":"Add JavaDoc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":0}}},{"hash":"5788286a3a57962099261c8009fb1d6edd8805e3","isMergeCommit":false,"messageTitle":"Update ParserTest after changes to Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":60,"deletions":42}}},{"hash":"b03e4895a0945479851eb7582843c5ee9e96c677","isMergeCommit":false,"messageTitle":"Update AddOrderCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":2}}},{"hash":"20dca7e9e3d0e02bdb4847ca7ace65e71cc93b5d","isMergeCommit":false,"messageTitle":"Update CafeCtrl.java to remove unused import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"91d87a0c1068d996643d6ba82e46dd621e383a8a","isMergeCommit":false,"messageTitle":"Update CafeCtrl.java to remove unused import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"c6c139f4a50660a2c9212623a2d2930262ac948f","isMergeCommit":false,"messageTitle":"Remove extra empty line","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"e4657bd5e9bf1799dddc317a739adadd32d88759","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b71c0700f0f6ef866810a2d1f7ecb7dec8474f3c","isMergeCommit":false,"messageTitle":"Refactor folder for UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":108,"deletions":56}}},{"hash":"a66509ed92b81a12ffd29d754d72c7b8b3a0a9f5","isMergeCommit":false,"messageTitle":"Update code to be more OOP","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":28}}},{"hash":"0ed5896c725fd7e30876675ea72d1cd1be95d5e5","isMergeCommit":false,"messageTitle":"Add Class Diagram for Add Order","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":89,"deletions":0}}},{"hash":"3afca99679fa53c4f386dc81f7da70627aecd5c1","isMergeCommit":false,"messageTitle":"Update UG for NextDayCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4},"docs":{"insertions":109,"deletions":0}}},{"hash":"d57f47ad43d874d8cc133cb53a8a3aa38f527fd5","isMergeCommit":false,"messageTitle":"Update UG for PreviousDayCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":76,"deletions":0}}},{"hash":"88792021c4fde7340348727adf0f22fe01092080","isMergeCommit":false,"messageTitle":"Update UG of AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":1}}}]},{"date":"2023-10-31","commitResults":[{"hash":"99d0527aec4844a0a74d2cdb765e0e9e9d775722","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8ad5d02aef54b2386bf8d53ef5d8364c023c4fc3","isMergeCommit":false,"messageTitle":"Update DG for AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":4}}}]},{"date":"2023-11-01","commitResults":[{"hash":"d1f8b555054498d46b567383bf43a5dc784de808","isMergeCommit":false,"messageTitle":"Update DG for AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"docs":{"insertions":12,"deletions":6}}},{"hash":"d8664afaeac13bb2dbb8efea97d47686a4eab695","isMergeCommit":false,"messageTitle":"Update DG for PreviousDayCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":3}}},{"hash":"a7a538774768d43233ab200e650d0ae79f0d376d","isMergeCommit":false,"messageTitle":"Update DG for NextDayCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"0702ccebdb16f751dbe6df6f7542d27cd8e76372","isMergeCommit":false,"messageTitle":"Update DG for ListMenuCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"docs":{"insertions":4,"deletions":4}}},{"hash":"0c67b9bb96636bb1da3821ce6885d40cf402b941","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":42,"deletions":1}}},{"hash":"2a9eceb42d56a25f7198e208010e046a2055fda1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f907eeb625402a37f40a34bbcc913301ceaf5f25","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0a0fb00388a52824d84c2266eded180e62f9b68c","isMergeCommit":false,"messageTitle":"Fix bug for AddOrderCommandTest","messageBody":"Fixes #200\n","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":6},"test-code":{"insertions":181,"deletions":149}}},{"hash":"9c7f19cc801aa35c7a02127bf9c0df49f0f3a17c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0c3c380b9690720c963ab432ab353a7ac9d4b4b8","isMergeCommit":false,"messageTitle":"Update DG with regards to Code changes","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":16}}},{"hash":"66a5a7e1e441a1708cb1ff60cb91b9dd72c9c06b","isMergeCommit":false,"messageTitle":"Update UG for Add Order","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":31,"deletions":1}}},{"hash":"475695469d6d0f6ea45a1e3d0964cfa91331783e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Update-UG-for-Add-Order","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b1478c142f31ed934d6ab101f9425ce6d8e44b76","isMergeCommit":false,"messageTitle":"Bug Fix","messageBody":"Fixes #211\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"7a4e3f3d1c1172a05f3bed4f9cac12422c03700d","isMergeCommit":false,"messageTitle":"Update Code Quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3},"docs":{"insertions":2,"deletions":2}}}]}],"ziyi105":[{"date":"2023-10-05","commitResults":[{"hash":"ce55b55eeedfddf78b8dcd41a589ab3097fc943f","isMergeCommit":false,"messageTitle":"Update AboutUs.md with Ziyi\u0027s name and github","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"0a4dab6d434c8f1fce06a3b938c558a2f24cba82","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9ac70fde66fd83d921866a9b4555dd6d59d78e7c","isMergeCommit":true,"messageTitle":"Merge pull request #4 from ziyi105/master","messageBody":"Update AboutUs.md with Ziyi\u0027s name and github","fileTypesAndContributionMap":{}},{"hash":"db3be0d4dbc95092f2a772ee485cf24139f4a960","isMergeCommit":false,"messageTitle":"Update Ziyi\u0027s photo on AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"4c760d59203dc1a28a8eb86763ea3e80f6a71ff2","isMergeCommit":true,"messageTitle":"Merge pull request #6 from ziyi105/master","messageBody":"Update Ziyi\u0027s photo on AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"a58bed14f14de4d92994e46cc136783aba7fd4c3","isMergeCommit":false,"messageTitle":"Add Parser.java","messageBody":"fixes #8\n","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}},{"hash":"5ddffe229dba287cf4773bad97938c3b6659e9ef","isMergeCommit":false,"messageTitle":"Parser.java: move from package Parser to seedu.duke.parser","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"b806594dfa85c2c71007f457c46139694b196274","isMergeCommit":false,"messageTitle":"Add ParserTest.java","messageBody":"fixes #12\n","fileTypesAndContributionMap":{"test-code":{"insertions":7,"deletions":0}}},{"hash":"74d345ea8d7fd35e7906b35ae7c5dea5124d0f2f","isMergeCommit":false,"messageTitle":"ParserTest.java: remove wild card import","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}}]},{"date":"2023-10-15","commitResults":[{"hash":"72f47e36ee6fc50c291c3ba56995c48ca4d7adec","isMergeCommit":false,"messageTitle":"ParserTest.java: add a new line at the end of the file","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"ce21b499b97b8604e902d81c2ffc5d2e5e3dbda1","isMergeCommit":false,"messageTitle":"Add Menu.java, Dish.java, Ingredient.java and their test classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0},"test-code":{"insertions":21,"deletions":0}}},{"hash":"6cd980d30ffc7269100b0e144deb704624108ba4","isMergeCommit":false,"messageTitle":"Add Menu.java","messageBody":"fixes 31\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":13}}},{"hash":"9de4ee60d69353f1d1e32b5a60b5b27991d8219c","isMergeCommit":false,"messageTitle":"Revert \"Add Menu.java\"","messageBody":"This reverts commit 6cd980d30ffc7269100b0e144deb704624108ba4.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":0}}},{"hash":"79afe5da305b841bf11d7be35b464cbfc2ad8134","isMergeCommit":false,"messageTitle":"Dish.java: change price type double to float","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e5534107d88a9f49f4eaa864f24622948c9dc773","isMergeCommit":false,"messageTitle":"ParserTest.java: add javadoc to the class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":0}}}]},{"date":"2023-10-16","commitResults":[{"hash":"2600dcb46108a997b4c7366401b3fd7bcb2b8e44","isMergeCommit":true,"messageTitle":"Merge pull request #42 from Cazh1/master","messageBody":"Update attributes and methods in Command class","fileTypesAndContributionMap":{}},{"hash":"bf1325d50b3a48da0fd72c5ab665f452d4d4f919","isMergeCommit":true,"messageTitle":"Merge pull request #44 from DextheChik3n/edit-classes-v1.0","messageBody":"Edit classes v1.0","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"f079f9950ec7a31a8ce26b0cf50c5a7507d3dd6f","isMergeCommit":false,"messageTitle":"Implement parseCommand() method according to AddressbookLevel2","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0}}},{"hash":"0852e29a9ee8563ff84a34e75b5b0efd5b342e09","isMergeCommit":false,"messageTitle":"Implement ui support for edit price feature","messageBody":"fixes #14\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"0dcf6106d09cef97c0c807f356e3a62be9043b33","isMergeCommit":false,"messageTitle":"Dish.java: add setter for price","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"b67df48ceadf6e7b7d4972f4ab094428396d9293","isMergeCommit":false,"messageTitle":"Create EditPriceCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":0}}},{"hash":"db9131da26048c68ee531e9cf035c0a3045ffa72","isMergeCommit":true,"messageTitle":"Merge pull request #46 from DextheChik3n/43-add-items-v1.0","messageBody":"Implement add dish feature","fileTypesAndContributionMap":{}},{"hash":"c88d9091f99c7c1c13c815b1a926dec91d729117","isMergeCommit":false,"messageTitle":"Parser.java: add parserCommand() method and incomplete prepareEditPriceCommand()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":0}}},{"hash":"38e05b78ff2369a7299c9de1a6c53cfa8560537d","isMergeCommit":false,"messageTitle":"Add constant COMMAND_WORD in executable command classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}},{"hash":"2743a171159dc3e00cc9bf9134802df91516a91c","isMergeCommit":false,"messageTitle":"Declare COMMAND_ARGUMENT_STRING for compiling patterns","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":7}}},{"hash":"fc0ae7663b7c245853f11061b2d7d0531b378f6c","isMergeCommit":false,"messageTitle":"Implement parseCommand with pattern and matcher","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":2}}},{"hash":"87643e1fff76ea1ff58a72c59069501ea1ad8d5d","isMergeCommit":false,"messageTitle":"Parser.java: design the overall structure of different prepareCommands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":10}}},{"hash":"687f3a97f09b7b76fdc37f1647fe310d852dbcaa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into use-pattern-and-matcher-in-parser","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a4588d6428a667606b73729fc4d7b171b814bc0e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into use-pattern-and-matcher-in-parser","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"76f879d8556fefdcdd8426b7ce96f08e9661dcf8","isMergeCommit":false,"messageTitle":"Parser.java: remove argument when creating DeleteDishCommand and ListIngredientCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"3166afc463ac1cf0c36a3c0f02025286408336a9","isMergeCommit":false,"messageTitle":"Parser.java: pass arguments to prepareListIngredient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"4e07571336b93f76098b442a3b7818cc3de7638f","isMergeCommit":false,"messageTitle":"Update ListIngredientCommand.java with constructor that takes in listIndex","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"972c84e4f91f7e6184b2071370f7ce136e27da80","isMergeCommit":false,"messageTitle":"Update Parser.java with correct coding standard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"17930caaedda6b70d54027eabb2b45b299f3429f","isMergeCommit":false,"messageTitle":"Parser.java: split ADD_COMMAND_ARGUMENTS correctly","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"2f877b3b7908caaa0fa8feec1de4bf94936aa508","isMergeCommit":false,"messageTitle":"Parser.java: update ADD_PATTERN to ADD_ARGUMENT_PATTERN","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"fe4ae667b55c28acbef1156b7576731def556694","isMergeCommit":false,"messageTitle":"Parser.java: correct indentation at line 129","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"306797c8dc6fbccf4d7d8ffd573f27301af152d7","isMergeCommit":true,"messageTitle":"Merge branch \u002711-feature-edit-price-v1.0\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"f9822a12af4e06828b3f5dcd72ba6019bfa22186","isMergeCommit":true,"messageTitle":"Merge pull request #57 from DextheChik3n/38-edit-main-class-v1.0","messageBody":"38 edit main class v1.0","fileTypesAndContributionMap":{}},{"hash":"3b01a433e7853ceea15ec017094e14628381c8f6","isMergeCommit":false,"messageTitle":"EditPriceCommand.java: update edit price to edit_price","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"20abc84278a6421e5be06493cdb0619b4103f6f4","isMergeCommit":false,"messageTitle":"Implement parser support for edit_price feature","messageBody":"fixes #13\n","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":6}}},{"hash":"b7b6c987b205a69bc9bfda9bf6b6bb62604a065e","isMergeCommit":false,"messageTitle":"Dish.java: add toString method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"e4a58f40bd283404e96d922aee5bbf1b9c0c7f1b","isMergeCommit":false,"messageTitle":"Ui.java: make showToUser and showEditPriceMessage static","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"d87ddca7b459be077d396635d101e07b267a5036","isMergeCommit":false,"messageTitle":"EditPriceCommand.java: show message after execute","messageBody":"Fixes #14\n","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":1}}},{"hash":"31aec2fa86642f1dc57bcb132c4afd5b60260c6f","isMergeCommit":false,"messageTitle":"Ui.java: add javadoc for showEditPriceMessage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":1}}},{"hash":"a1926699bd7da67ea47b9daa1148860d14cbb2ab","isMergeCommit":false,"messageTitle":"Parser.java: rename ADD_ARGUMENT_STRING and EDIT_DISH_ARGUMENT to camelCase","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":6}}}]},{"date":"2023-10-18","commitResults":[{"hash":"569e182e90d0a3efd3d9e2b08b848914b93e03d0","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/master\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/command/EditPriceCommand.java\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"e991c9db72a04d04051bbd6fef381a324a2f7b05","isMergeCommit":false,"messageTitle":"Parser.java: remove wildcard import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":1}}},{"hash":"d3f5e998de9b97220a2fb1c5de9e42ed1565e310","isMergeCommit":false,"messageTitle":"Parser.java: remove duplicated import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"e7bb131f1de78bf89df8036169b194cca157557d","isMergeCommit":true,"messageTitle":"Merge pull request #60 from Cazh1/master","messageBody":"Update code quality","fileTypesAndContributionMap":{}},{"hash":"4aef10a1aaade726ea889271653dc5f2a7fe17f2","isMergeCommit":true,"messageTitle":"Merge pull request #58 from ShaniceTang/55-deletecommand-junit-test","messageBody":"Task 55, Add JUnit test for Delete Command","fileTypesAndContributionMap":{}},{"hash":"4075a3361550a84ae8b24e23fec324f9db30502c","isMergeCommit":false,"messageTitle":"Menu.java: add isValidDishIndex method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"721151f928162dceba3584c0bd568cef7596a74d","isMergeCommit":false,"messageTitle":"Parser.java: remove catch block for IndexOutOfBoundsException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":11}}},{"hash":"cf6e6994cea30240729079377b6b68476dcfe433","isMergeCommit":true,"messageTitle":"Merge pull request #62 from NaychiMin/56-Junit-test-for-list-ingredient.v1.0","messageBody":"Task 56, Add junit test for List Ingredient command.","fileTypesAndContributionMap":{}},{"hash":"6e6f539c96aa5844eb403591beb81a723bf06059","isMergeCommit":true,"messageTitle":"Merge branch \u002711-feature-edit-price-v1.0\u0027 into ziyi105-11-feature-edit-price-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/command/EditPriceCommand.java\n#\tsrc/main/java/seedu/cafectrl/data/Menu.java\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"d8fd274670ac311f83fcb2090492a94c62379017","isMergeCommit":false,"messageTitle":"Ui.java: remove static from showToUser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"edf108043148d24277cf8430c989201972ec2c45","isMergeCommit":false,"messageTitle":"Improve code quality with gradlew","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"d128fc7c9682256fea60137e194f239e52521613","isMergeCommit":false,"messageTitle":"Messages.java: update position of plus operator for strings","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":6}}},{"hash":"bd4181f11168d9c3e1b34bf16a0f7efa37f68418","isMergeCommit":false,"messageTitle":"Parser.java: update position of plus operator","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"defbb3e75f20842edf6faa71e54688a3367ed1d6","isMergeCommit":false,"messageTitle":"Messages.java: Update position of plus operator for MISSING_ARGUMENT_FOR_EDIT_PRICE","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"e7ca9e70c6a75d581ac6d8fa41cf173be97da596","isMergeCommit":false,"messageTitle":"Parser.java: replace matcher.matches() with matcher.find() in line 96","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"54e6c789b799b86d458d6a74ee4d57e8362a1fa2","isMergeCommit":false,"messageTitle":"EditPriceCommand.java: minus offset for menuID","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"908e1da4fe7c6f257b299d05d81fc277440ff8cc","isMergeCommit":false,"messageTitle":"EditPriceCommandTest.ava: add JUnit test for valid input","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2},"test-code":{"insertions":42,"deletions":0}}},{"hash":"7f6ae576969e353434ae08a9b55ead58169bb6f0","isMergeCommit":false,"messageTitle":"ParserTest.java: add JUnit test for parseCommand_unrecognisedInput_unknownCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":2},"test-code":{"insertions":32,"deletions":0}}},{"hash":"b4ae9501b1c0bad09222f0d0d90da681de3da7a0","isMergeCommit":true,"messageTitle":"Merge pull request #66 from DextheChik3n/24-parser-add-dish-v1.0","messageBody":"24 parser add dish v1.0","fileTypesAndContributionMap":{}},{"hash":"a20cbd574d66169d6c7098cc9edeffbadefbf04d","isMergeCommit":false,"messageTitle":"ParserTest.java: add JUnit test for possible user inputs for edit_price command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":2}}},{"hash":"9f593575dd7db9e268f6508508d3a7bb12de40e3","isMergeCommit":true,"messageTitle":"Merge pull request #69 from DextheChik3n/48-add-junit-add-dish-command-class-v1.0","messageBody":"48 add junit add dish command class v1.0","fileTypesAndContributionMap":{}},{"hash":"b47e636e131f0a3984ee2cbd5fb2d149ff029dab","isMergeCommit":true,"messageTitle":"Merge pull request #72 from DextheChik3n/67-junit-test-for-add-dish-v1.0","messageBody":"Added JUnit Tests for add dish command parsing","fileTypesAndContributionMap":{}},{"hash":"e677079202361a2f65f201103b146ae13c1a143b","isMergeCommit":true,"messageTitle":"Merge pull request #76 from DextheChik3n/74-resolve-negative-price-input-v1.0","messageBody":"Edit add dish parsing code to prevent negative price input","tags":["A-Release-v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-22","commitResults":[{"hash":"96882eb9101008776de82b957a9ae270e0af3bff","isMergeCommit":true,"messageTitle":"Merge pull request #80 from ShaniceTang/78-combine-messages","messageBody":"Task 78, Add UserOutput enumeration messages to Message class","fileTypesAndContributionMap":{}},{"hash":"06fb6a449152d4bbcb83c66a33ea8e1f5fce6457","isMergeCommit":true,"messageTitle":"Merge pull request #81 from Cazh1/Edit-List_Menu-appearance","messageBody":"Edit list menu appearance","fileTypesAndContributionMap":{}},{"hash":"793446992cc666d6865910f66025374082ad37d9","isMergeCommit":false,"messageTitle":"Ui.java: rename showToUerFormat to formatListMenu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"cec3c524bbd1d3ef76e0e833435fef721827d145","isMergeCommit":false,"messageTitle":"Implement help command","messageBody":"fixes #73\n","fileTypesAndContributionMap":{"functional-code":{"insertions":70,"deletions":31},"test-code":{"insertions":1,"deletions":1}}},{"hash":"cfe46d6d3284681a80fa99ef46fbc4f4c0c2963c","isMergeCommit":false,"messageTitle":"Complete messages for help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":5}}},{"hash":"494813d67cce020f13b6bf14eaa9268b838fbbde","isMergeCommit":false,"messageTitle":"Ui.java: add method showToUserWithSpaceBetweenLines for showHelp()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":2}}},{"hash":"56fbe7c76d7c928a696fb1a31922f88a13947a25","isMergeCommit":false,"messageTitle":"Add JUnit test for HelpCommand (incomplete)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":37,"deletions":0}}},{"hash":"b6f15b18161b307a88ec6e2cb43f496e908bfcba","isMergeCommit":false,"messageTitle":"HelpCommandtest.java: improve code quality","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":4}}},{"hash":"318b4e7f859ad0a4f8b4fff81731e5472fad9a08","isMergeCommit":true,"messageTitle":"Merge pull request #97 from DextheChik3n/77-enable-assertions-v1.1","messageBody":"77 enable assertions v1.1","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"37a70ddcb2b047143d26d65a8cb7dfb94cf64716","isMergeCommit":false,"messageTitle":"Move LINE_STRING from Ui.java to Messages.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"756e97ebc15c91ca89be53688609d5a60b6ec466","isMergeCommit":false,"messageTitle":"Complete helpCommandTest for execute","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":21,"deletions":4}}},{"hash":"44b84aacf3a7c12558a9a63902a1e97604c0c0d7","isMergeCommit":false,"messageTitle":"ListMenuCommand.java: add space around operator","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"efdc7cab49f6c35295221cee69a79ca1e4ef76e1","isMergeCommit":false,"messageTitle":"Parser.java: update formatting of single line comment","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"2cd77bfba70bf778f72bcde41df599c94a610cc2","isMergeCommit":false,"messageTitle":"Messages.java: update string spliting indentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"0ecc4dec59a6571cb3dfea65183a6d88157d5a39","isMergeCommit":true,"messageTitle":"Merge pull request #103 from DextheChik3n/102-add-dish-exception-handling-v1.1","messageBody":"102 AddDish Command exception handling v1.1","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"f131f3098fc876525832b3fcbd5bcd962f506755","isMergeCommit":true,"messageTitle":"Merge pull request #95 from ShaniceTang/90-91-implement-pantry-class","messageBody":"Task 90 and Task 91 Implement View Total Stock and Buy Ingredients","fileTypesAndContributionMap":{}},{"hash":"f0a24cc9c932148cdae5eeac35c617b2553594c9","isMergeCommit":true,"messageTitle":"Merge pull request #96 from NaychiMin/implement-low-stock","messageBody":"Task 92, Task 93 Implement stock checking of ingredients in Pantry class","fileTypesAndContributionMap":{}},{"hash":"0ef8819a85677bad5ef007538da629f078230bb6","isMergeCommit":true,"messageTitle":"Merge pull request #106 from Cazh1/#86-Implement-Parser-support","messageBody":"#86 Implement parser support for addOrder command","fileTypesAndContributionMap":{}},{"hash":"0e41f3d102afc76c03d8897e5bf4785aa1cb3990","isMergeCommit":false,"messageTitle":"Add DG for how parser parse command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":1}}},{"hash":"2a56a3509b1546802275085a1e58cfd8678ee2ad","isMergeCommit":false,"messageTitle":"Edit formatting of DeveloperGuide.md for Parser","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":9}}},{"hash":"f3efe12eb9d02b02b41179c689888b6aa472ab77","isMergeCommit":false,"messageTitle":"Add UML for EditPriceCommand execute method","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":0}}},{"hash":"04ac7375b6e5e7bcd5e7736ee1b9e93449547986","isMergeCommit":false,"messageTitle":"Add DG for edit price feature","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":0}}},{"hash":"8e8d9daf3c5849ce51268e256a71da41d61614b1","isMergeCommit":false,"messageTitle":"Add description for edit_price feature in DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":2}}}]},{"date":"2023-10-25","commitResults":[{"hash":"c876030a1267e79016085c1705e9dbfefdac002e","isMergeCommit":false,"messageTitle":"EditPriceCommand_execute.puml: include parameter type","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"f901af8c281e088afc7adfed87e3c657151f8267","isMergeCommit":false,"messageTitle":"Update Parser.puml with parameter type","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"147db2d52616ab5e56d8a9ffc06f822bd13b6f8c","isMergeCommit":false,"messageTitle":"Update Parser and editPriceCommand_execute UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"55a5805dd6df74abbb2bb7c254a638c7958c481c","isMergeCommit":true,"messageTitle":"Merge branch \u0027111-DG-parser\u0027 into DG-merge-conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"57e73e5992156ef76ddbbd15084af051e2c8bb39","isMergeCommit":true,"messageTitle":"Merge pull request #113 from ziyi105/111-DG-parser","messageBody":"Update DG for Parser and edit_price","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"dd5c5d6ea7099cc2514e52438a6de53d6d615e6e","isMergeCommit":true,"messageTitle":"Merge pull request #125 from DextheChik3n/117-DG-add-dish","messageBody":"117 developer guide: add dish","fileTypesAndContributionMap":{}},{"hash":"b651a3fdc315a636a7be69985c33880c66073b88","isMergeCommit":true,"messageTitle":"Merge pull request #124 from DextheChik3n/123-refactor-add-dish-v1.2","messageBody":"123 refactor add dish v1.2","fileTypesAndContributionMap":{}},{"hash":"9790239580356a28e53a7b1132c78dab9a8d6bd2","isMergeCommit":true,"messageTitle":"Merge pull request #133 from Cazh1/#132-Refactor-Order-Class","messageBody":"132 Refactor Order Class","fileTypesAndContributionMap":{}},{"hash":"a3bfd53e20c8482a1dede926ce3511b05dd5f231","isMergeCommit":true,"messageTitle":"Merge pull request #134 from Cazh1/#83-Add-JUnit-Test-for-Order-class","messageBody":"#83 add JUnit test for order class","fileTypesAndContributionMap":{}},{"hash":"f9925f2bf0351a95ec21b48789c4c6868319f745","isMergeCommit":true,"messageTitle":"Merge pull request #137 from Cazh1/130-Refactor-ListMenu-Command-process","messageBody":"Update ListMenuCommandTest with regards to review","fileTypesAndContributionMap":{}},{"hash":"a993819f1789b67348c69074dcfd2093fa32550c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 135-create-storage-parent-class-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ad5fa6ce9dde0555128323479745530ba8980c47","isMergeCommit":true,"messageTitle":"Merge pull request #136 from DextheChik3n/135-create-storage-parent-class-v2.0","messageBody":"135 create storage parent class v2.0","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"a05446d86bafd9f552939ea0cb92ab49eedb20d9","isMergeCommit":true,"messageTitle":"Merge pull request #141 from DextheChik3n/138-fix-add-dish-command-bugs-v2.0","messageBody":"138 fix add dish command bugs v2.0","fileTypesAndContributionMap":{}},{"hash":"59850307c55d41d9b21c28fa95dd377c7a095c45","isMergeCommit":false,"messageTitle":"Add Decoder.java and Encoder.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":103,"deletions":0}}},{"hash":"be88ba168065a14b68ad07c595d96889faa7be8f","isMergeCommit":false,"messageTitle":"Add FileManager.java and move relevant methods from Storage to there","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":154,"deletions":165}}},{"hash":"6e22e140757e7c85c0bb69d744c3bcc4d975d638","isMergeCommit":false,"messageTitle":"Pantry.java: remove unused methods related to storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":19}}},{"hash":"4ee74bb5029bde5542a27876363d51958ff05b66","isMergeCommit":false,"messageTitle":"Refactor CafeCtrl to use the new storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":26}}},{"hash":"52b8d168fb68bba71af3237dfb06931f12468c7f","isMergeCommit":false,"messageTitle":"Move pantry.writeToPantry storage from ExitCommand.java to run() in CafeCtrl","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"fd122345e20957b8be59dd498b82a94072c811b9","isMergeCommit":false,"messageTitle":"Pantry.java: create a constructor with ui as param","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"bede707287c62189fc34f96108917d752da2611d","isMergeCommit":false,"messageTitle":"Add author and update code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":9}}},{"hash":"a267e8a023f8a988fbca090bc35f0112fcf101cb","isMergeCommit":false,"messageTitle":"Modify expected io test file and related classes to ignore error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"e917e241833c49959daf67a6c0dab67e864a4845","isMergeCommit":false,"messageTitle":"Storage.java: remove unused import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"b96e7f50f9e3542024be8542c6ac5b6da503e642","isMergeCommit":false,"messageTitle":"Storage.java: add author","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"ceaf0dd8aed2f375b3c587fe1f25ed42f8aef6f7","isMergeCommit":false,"messageTitle":"Add Javadoc comments in FileManager and Storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":5}}}]},{"date":"2023-10-29","commitResults":[{"hash":"0633d5e927d22d0618c6427aca12cabf5316411f","isMergeCommit":false,"messageTitle":"Encoder.java: add encodePantryStock method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":1}}}]},{"date":"2023-10-30","commitResults":[{"hash":"979613151ef041f0a5f8177e83c6ba7c0d429601","isMergeCommit":false,"messageTitle":"Encoder.java: modify the encodePantryStock method to encode the ingredient with space in between attributes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"9de19f24186d2236113c837193dab90fe42bd921","isMergeCommit":false,"messageTitle":"Move all error messages to one class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":58,"deletions":52},"test-code":{"insertions":10,"deletions":10}}},{"hash":"855ca78a90af72f7bb1142eb031b36ee25a0a0de","isMergeCommit":false,"messageTitle":"Add line between methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"b14ef3a2eec5d2b5204244fa70fe4535a8d53dff","isMergeCommit":false,"messageTitle":"Decoder.java: modify isValidQuantityFormat toisValidPantryStockFormat","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":6}}},{"hash":"e3b6b17a80a742c17725b7eeaa0ce0917a06fade","isMergeCommit":false,"messageTitle":"Add dummy try-catch in readTextFile to avoid error throwing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":12}}},{"hash":"fbcf11472ca6c030735fe89448e36fa65497ed9e","isMergeCommit":true,"messageTitle":"Merge pull request #150 from DextheChik3n/149-price-float-overflow-v2.0","messageBody":"149 price float overflow v2.0","fileTypesAndContributionMap":{}},{"hash":"31f5684de60c59be21a1f9ad7e5e9073632795e5","isMergeCommit":false,"messageTitle":"DecodePantryStockData: return new empty pantry if the data file is empty","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"12dc5a4508ab9c43778ca9832107287152d560df","isMergeCommit":false,"messageTitle":"Uncomment lines related to pantry storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":11}}},{"hash":"f210efecc30ea09310c3c13a9814f2a1d7eda853","isMergeCommit":false,"messageTitle":"Format line that is too long","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"0ca8c232030d80d94838a40fbae8eb1e923918e8","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 147-encode-decode-pantry-stock","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"621b6d503771130c4b9beeb39d245e07217c8f7c","isMergeCommit":false,"messageTitle":"Move error messages to ErrorMessages.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":4}}},{"hash":"18c5809253755e10dbc742b300345262086a7a19","isMergeCommit":false,"messageTitle":"FileManager.overwriteFile(): call openTextFile() before writing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"7a4512f101d1bc24ff31caa542b90a23541a16bd","isMergeCommit":true,"messageTitle":"Merge pull request #153 from Cazh1/#85-Implement-Multiple-day-support-for-Order-class","messageBody":"#85 implement multiple day support for order class","fileTypesAndContributionMap":{}},{"hash":"af7bcfe27b39c6f366f729c322b8c473f13949f8","isMergeCommit":false,"messageTitle":"FileManger.openTextFile(): remove extra lines","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":5}}},{"hash":"7e6e178f1bf1e4405f0ac44e7ad00a68ecaad655","isMergeCommit":false,"messageTitle":"Add import in Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"73f1188f059760fa22547319f481356a92af954f","isMergeCommit":true,"messageTitle":"Merge branch \u0027147-encode-decode-pantry-stock\u0027 into merge-conflicts-pr-255","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ff49fe4a800cc5417830abfc4822a499b1f5c411","isMergeCommit":true,"messageTitle":"Merge pull request #155 from DextheChik3n/152-edit-UG-v2.0","messageBody":"152 edit UG for v2.0","fileTypesAndContributionMap":{}},{"hash":"be43b8ab6fc16b26e938d6cff3dc58331013438e","isMergeCommit":false,"messageTitle":"Change OrderList to Sales","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":7}}},{"hash":"74db276cf7be8bfcf8c432b665fa608b4f30a498","isMergeCommit":false,"messageTitle":"Add author tag","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":9}}},{"hash":"d90fdbd457dfb81106f5546bb50dc44a373085ac","isMergeCommit":false,"messageTitle":"Use MESSAGE_USESAGE from command class for help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}},{"hash":"516b914db4f68faee0d5ba21c433b0d0073f22ec","isMergeCommit":false,"messageTitle":"Update HelpCommandTest expected output to use MESSAGE.USAGE","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3},"test-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-31","commitResults":[{"hash":"90040b3bba40c2dbb837ac1026d0814d9d33bf5c","isMergeCommit":false,"messageTitle":"Add Parser class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":34,"deletions":0}}},{"hash":"f65b8c7397f2bd3b2bb4f42b9568641ae3ed3efa","isMergeCommit":false,"messageTitle":"Add more details to Parser sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":10}}},{"hash":"6432dada325f4e09e24eeb277700b7959fec24c8","isMergeCommit":false,"messageTitle":"Add more details to EditPriceCommand_execute sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":3}}},{"hash":"dc6b47809e0a4b1cce58c2d9fffd2d5de7dd766c","isMergeCommit":false,"messageTitle":"Deactivate Parser in Parser sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"18dd8d023d63c47b9080ea51e908e1b66af840ac","isMergeCommit":false,"messageTitle":"Update DG parser class and sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":4}}},{"hash":"26c2c129fdd9655468314efc5b18b8d67df818c9","isMergeCommit":false,"messageTitle":"Add sequence diagram for HelpCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":0}}},{"hash":"f2f70860af4f62008bdbd3e6f2ab03a533b18d04","isMergeCommit":false,"messageTitle":"Update DG for HelpCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":0}}},{"hash":"b76a27ac45ab37dfc98d6d621b1c149b788c6101","isMergeCommit":true,"messageTitle":"Merge pull request #168 from DextheChik3n/151-same-dish-name-bug-v2.0","messageBody":"151 same dish name bug v2.0","fileTypesAndContributionMap":{}},{"hash":"f23ad963a59d4582af953707581c8421250f13bd","isMergeCommit":false,"messageTitle":"Create ParserUtil.java interface","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0}}},{"hash":"5835531232082192f75c0428c22a31e4ed4d94eb","isMergeCommit":false,"messageTitle":"Refactor classes that use Parser to use ParserUtil instead","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4},"test-code":{"insertions":39,"deletions":21}}},{"hash":"b14e681521aa81fa54c695862477148462b84065","isMergeCommit":true,"messageTitle":"Merge branch \u0027171-ParserUtil-interface\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"132908e11ab5307b408e396e9d20e5584996a364","isMergeCommit":true,"messageTitle":"Merge pull request #170 from NaychiMin/148_encoding_decoding_orders_v2.0","messageBody":"Task 148, Encoding and Decoding of Sales object v2.0","fileTypesAndContributionMap":{}},{"hash":"2d0a09c584797365dbe5668cd07a1b4fa5847963","isMergeCommit":false,"messageTitle":"Update UG: help command and edit_price command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":33,"deletions":2}}},{"hash":"31bdccaf67723a7f29eef1f43ffd66cc31f7597c","isMergeCommit":true,"messageTitle":"Merge pull request #175 from ShaniceTang/89-implement-buy-ingredient","messageBody":"Task 89, Implement buy ingredient to fulfill user story","fileTypesAndContributionMap":{}},{"hash":"a75ffcb86cadbc86a9e8f8d9691353fd55dadda9","isMergeCommit":false,"messageTitle":"Update ParserUtil.java with correct indentation","messageBody":"Co-authored-by: Dexter \u003c35828587+DextheChik3n@users.noreply.github.com\u003e","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"379dd270740cc009553a17b2815614407d0dacd6","isMergeCommit":false,"messageTitle":"Update Parser.java with correct indentation","messageBody":"Co-authored-by: Dexter \u003c35828587+DextheChik3n@users.noreply.github.com\u003e","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}}]},{"date":"2023-11-01","commitResults":[{"hash":"815114c29fdcda2bdf9e3081baf806b0d197b7b6","isMergeCommit":false,"messageTitle":"Correct typo in Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"f84fb017afda95cae5cb58b5583a173067193e28","isMergeCommit":true,"messageTitle":"Merge pull request #172 from ziyi105/171-ParserUtil-interface","messageBody":"171 ParserUtil interface","fileTypesAndContributionMap":{}},{"hash":"39176035be5332dc9be26b0877c34ebc8f37f061","isMergeCommit":true,"messageTitle":"Merge pull request #167 from Cazh1/#159-Update-DG-with-Multi-day-Order-feature","messageBody":"#159 Update DG with Multi-day Order feature","fileTypesAndContributionMap":{}},{"hash":"219c6e5433d6c027853c144cc3f357e0855f9fe4","isMergeCommit":false,"messageTitle":"Move MESSAGE_USAGE to command classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":37}}},{"hash":"e7b6978f6bdb0fbdbb8ecaeca7c93da8041f8a47","isMergeCommit":false,"messageTitle":"Update HelpCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":14,"deletions":8}}},{"hash":"b5060fbfce81f007679561e25684f33b82633011","isMergeCommit":false,"messageTitle":"Ui.java: remove wildcard import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":1}}},{"hash":"2fb89d49b8ebd1e722827d1f74b2b6153610dbd4","isMergeCommit":false,"messageTitle":"Ui.java: correct typo in import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":12}}},{"hash":"4702e0e142728a6011156f8be933b6c00db5e5c3","isMergeCommit":true,"messageTitle":"Merge pull request #197 from DextheChik3n/142-storage-error-handling-v2.0","messageBody":"142 storage error handling v2.0","fileTypesAndContributionMap":{}},{"hash":"273572b9c7fb1bdc8e11681ddcf37cdff1460add","isMergeCommit":false,"messageTitle":"Use divider for decoding and encoding of pantry stock Fixes #184","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"95c58ee1734a71b074043b32dd2f5533cdfa89ca","isMergeCommit":false,"messageTitle":"Add javadoc for encoding and decoding pantry stock","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":0}}},{"hash":"d88d1df37b0b6ed12b94a172be937e4339d622f5","isMergeCommit":false,"messageTitle":"Add author tag","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"13ffe6114d7e010d2ad5b3e652fb8f9448dee456","isMergeCommit":false,"messageTitle":"Use string builder for encoding pantryStock and add a new line after every ingredient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":3}}},{"hash":"290857cf6c34a1dfe2f50a891f7fb512a7ff23d9","isMergeCommit":false,"messageTitle":"Standardise formating of help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"2b6b642a324b69b20185fb492c9ae8a47e3c4497","isMergeCommit":false,"messageTitle":"Decoding of pantryStock: trim the quantity before parseInt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"17d681a19cd66cc227cd60a0f6b0c24653b562cf","isMergeCommit":true,"messageTitle":"Merge pull request #206 from DextheChik3n/205-bug-same-name-ingredients-v2.0","messageBody":"205 bug same name ingredients v2.0","fileTypesAndContributionMap":{}},{"hash":"7f2fe276408207a30640b3217302e9ad8c8e36fc","isMergeCommit":true,"messageTitle":"Merge pull request #218 from DextheChik3n/216-repeat-dish-name-bug-v2.0","messageBody":"216 repeat dish name bug v2.0","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"47e16eb6b43a922697358f9c63e02fe1008beba7","isMergeCommit":false,"messageTitle":"EditPriceCommand_execute.puml: add semicolon before class name","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":0}}},{"hash":"5d51e868872984081e196078539d8f7af466300a","isMergeCommit":false,"messageTitle":"Parser.puml: add semicolon before class name","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"51d051c3b91e97b0db505b780e5a87a0e3777b40","isMergeCommit":false,"messageTitle":"DG: add theme Time Machine","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"c213917a876476a6d34e84b01a674b11d14e31ea","isMergeCommit":false,"messageTitle":"DeveloperGuide: change theme","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"d6a8f4160a03633d8cd0e01a9afb31baf05704b6","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"8fc06cedbf86155647063f2bed787bcd52a0a23d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"eef5c8d65ac7b47b036f195121e6f65b8d890d46","isMergeCommit":false,"messageTitle":"DG: add table of contents","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":29,"deletions":0}}},{"hash":"cf750643d7b6581fd6347ca6fcb7971efd5b34e5","isMergeCommit":false,"messageTitle":"DG: add hyperlink to data folder","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"119b662088b026d34f667ca3a1f6d7621a071beb","isMergeCommit":false,"messageTitle":"DG: Add user stories","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":0}}},{"hash":"41cadabac1ccb35a14e70c78149b050d96b59ffe","isMergeCommit":false,"messageTitle":"DG: format the title and subtitle","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":29,"deletions":21}}},{"hash":"ad66f75b8fec0f95db3d53901bc9a034a5ea7dba","isMergeCommit":false,"messageTitle":"DG: correct typo","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b5074aaab342b7c8f8b5aba583e0b84ed1c6d642","isMergeCommit":false,"messageTitle":"DG: hyperlink to user guide for setting up","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6b9a52b698b0a282babbee55accd445ac676c440","isMergeCommit":false,"messageTitle":"DG: add new line at the end of the file","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"b3440c42db5086516b8ec0b694505f62a724425a","isMergeCommit":false,"messageTitle":"DG: add acknowledgement","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"d99f51dfbebab2ba344da96bbf769a3b8522bbe4","isMergeCommit":false,"messageTitle":"UG: remove extra |","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-03","commitResults":[{"hash":"aba15d03ddaa9b6d8ed398c75f8dfadb5d9660a7","isMergeCommit":false,"messageTitle":"UG: add table of content","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":29,"deletions":3}}},{"hash":"b565e25467d52010b666dcbc8ce944cf1410c03a","isMergeCommit":false,"messageTitle":"Add author tag","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"7662bcf8345ee6c295227dfbf08e6347001ca4a3","isMergeCommit":true,"messageTitle":"Merge pull request #221 from ziyi105/220-standardise-UG-DG","messageBody":"220 Standardise DG","fileTypesAndContributionMap":{}},{"hash":"ec6e7689f4e61bd8272c8cb04225383d150ace92","isMergeCommit":false,"messageTitle":"UG: edit command summary table","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":6}}},{"hash":"99d7542fdc5d67f01e19d57b9fa9e781611eb4c5","isMergeCommit":true,"messageTitle":"Merge pull request #222 from ziyi105/220-standardise-UG-DG","messageBody":"UG: edit command summary table","fileTypesAndContributionMap":{}}]}],"ShaniceTang":[{"date":"2023-10-05","commitResults":[{"hash":"88288a4ee312a4a3906c0c7f8ecad9003abaf8fa","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"cea95da46d699ef3d7182ed840e860be204a6270","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"6b3c432ddb95359f5c4f9dee044cba3b53dc4b62","isMergeCommit":true,"messageTitle":"Merge pull request #2 from ShaniceTang/master","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"dadae0261aa4778ac64d68cbc66ec345da97f599","isMergeCommit":false,"messageTitle":"Fixes #27","messageBody":"Create UiTest JUnit Class\n","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":0}}},{"hash":"ba46ad20ecedd9d0cb49290bd75ba7df3e989b11","isMergeCommit":false,"messageTitle":"Add javadoc to UiTest class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":0}}}]},{"date":"2023-10-17","commitResults":[{"hash":"c4e118ce054a0eed4b0d076aadeaf5059f04853a","isMergeCommit":false,"messageTitle":"Add delete message to Ui class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"93ca9601f61702c86011451a21e6c3a097ff8f11","isMergeCommit":false,"messageTitle":"Fixes #21","messageBody":"Add javadoc to delete message method\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"812654327335924346f337a4102942a40b05df4e","isMergeCommit":false,"messageTitle":"Edit delete message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"ddd3d5049a361d1bc8b66e1fc77f7b4ea24ed638","isMergeCommit":false,"messageTitle":"Update delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":1}}},{"hash":"2a3d1fdcc0f08aba6e15f425fd490c8ffa5eb1b7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5e69f2317cb5536d4b0bbad556082b7c831439a8","isMergeCommit":false,"messageTitle":"Rename remove to removeDish method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"0ea6f655d06d20f1b3ff16724412856b42269ca4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/command/DeleteDishCommand.java\n","fileTypesAndContributionMap":{}},{"hash":"be50d359eeb512d129d052773bddfd07c2982b9f","isMergeCommit":false,"messageTitle":"Handle invalid index error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":5}}},{"hash":"411253bc7049f64567ed3785d19fc9e8d93c4dbb","isMergeCommit":false,"messageTitle":"Reformat printed string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"2e861f26e20a182639268add85bec7b82792038c","isMergeCommit":false,"messageTitle":"Fixes #22","messageBody":"Implement parser support for deleting a dish\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":12}}},{"hash":"e94d49fcda0fa69ee9d80bab03b075c94b7c80e5","isMergeCommit":false,"messageTitle":"Improve code standard","messageBody":"Fixes #22\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3}}},{"hash":"1c1742d4902012be02dfe7409ac94eb0e17f45e9","isMergeCommit":false,"messageTitle":"Handle out of bounds input index","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":5}}},{"hash":"39edc4758bf49b45c071bbe3f2bb0612d87381b3","isMergeCommit":false,"messageTitle":"Add JUnit test for Delete Command valid and invalid input","messageBody":"Fixes #55\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":59,"deletions":0}}},{"hash":"d2dfdeed55d7eb2b519262ccd86d50d2dcb86e3f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 55-deletecommand-junit-test","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1bd674a5beecdb86bfec754b7b106c70180ce148","isMergeCommit":false,"messageTitle":"Update import path","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":3}}}]},{"date":"2023-10-18","commitResults":[{"hash":"02f561afd0972856a346bb73cfd099c3414c1fd7","isMergeCommit":false,"messageTitle":"Add try-catch error handler","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3}}},{"hash":"40341fbba23130d1bb37d570eabbe1422bcf451b","isMergeCommit":false,"messageTitle":"Throw Index Out Of Bounds Exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"aca573016cb7a28d67fb0cb705e45fe9f562d15f","isMergeCommit":false,"messageTitle":"Update prepareDelete to match other methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":5}}},{"hash":"eed4152ad902aee18c1690be1c2b8e5d1264823a","isMergeCommit":false,"messageTitle":"Assert exception instead of equal string","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":7,"deletions":18}}},{"hash":"7f02a0de9aac1ed99944fc0c4beebc648b1d7d60","isMergeCommit":false,"messageTitle":"Create JUnit test for prepareDelete in Parser class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":17,"deletions":0}}},{"hash":"19a2ba9679b87ce118bc75987aed02a6207c6236","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"4881d95845ceae0c637849d3fa0142af1402db66","isMergeCommit":false,"messageTitle":"Use message string from Messages class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"695a304ae83f3e437f8ad2ed792591a1a624f2f6","isMergeCommit":false,"messageTitle":"Update prepareDelete method to standardize","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":10}}},{"hash":"cdea65514d1e4bc676cec5623e13bc10b96da8b3","isMergeCommit":false,"messageTitle":"Add JUnit test for delete command for parseCommand method","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":4}}},{"hash":"b366ac5c0f59c71cbe7964111908f0f4e3cbb2d5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"72da852206244ef87bcd8f2f765de519177317d0","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"Fixes #17\n","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"d2c8fd89be220ad3d1ddf9ce4f4e2a0f734dc9c0","isMergeCommit":false,"messageTitle":"Remove duplicate import statement","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}}]},{"date":"2023-10-22","commitResults":[{"hash":"8e589d37d341acdb4abcb34da25475bdc8a04e33","isMergeCommit":false,"messageTitle":"Move all messages in to Message class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":26},"test-code":{"insertions":1,"deletions":2}}},{"hash":"12bc39306efa8ba725bcbe10c93079d745569e03","isMergeCommit":false,"messageTitle":"Update unknown command message","messageBody":"Fixes #78\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"82d0bd4a04fc3ed9706de6e21369c75a97131511","isMergeCommit":false,"messageTitle":"Implement view total stock in pantry feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":0}}},{"hash":"bb4541ec67ee47679cd5f9b0d8b14da1c57841b9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into implement-pantry-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"851cba3e9f44f4e438b57a904820b0cf3cd7c870","isMergeCommit":false,"messageTitle":"Implement Pantry class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":119,"deletions":0}}},{"hash":"8a23bd2fcd39cb9e460fd15fa31884e5e6513ad8","isMergeCommit":false,"messageTitle":"Add view total stock command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":2}}},{"hash":"c421353e71a17d12dedffd0c40d9f3a0026b2522","isMergeCommit":false,"messageTitle":"Add buy ingredient command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":0}}},{"hash":"19276cf1582acf1ef53f0733417a6af8a3422933","isMergeCommit":false,"messageTitle":"Add Ui support for viewTotalStock and buyIngredients","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0}}},{"hash":"a3094cde4ebc7ec9c301bf89bff04137ba67dd69","isMergeCommit":false,"messageTitle":"Add parser support for viewTotalStock and buyIngredient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":2}}},{"hash":"9e878bd8f5dc5c24e8af6fba9b466b96b86af67b","isMergeCommit":false,"messageTitle":"Add setter for quantity varibale","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":1}}},{"hash":"0b2987ab90909285001d2ae7dfbc04a414b527fc","isMergeCommit":false,"messageTitle":"Add messages to display when error occurs","messageBody":"Fixes #90, Fixes #91\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":2}}}]},{"date":"2023-10-23","commitResults":[{"hash":"c50dc144cba53b1a2bd193f84223cff096a6eb31","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 90-91-implement-pantry-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5c073191d93908f8c98a6a0c812ff0c16f62def3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 90-91-implement-pantry-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"108c001310e4783c66ebda734490b70c5ec923d4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 90-91-implement-pantry-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"2d8533c6fff09e6ba664424cf1eefec4b897c76a","isMergeCommit":true,"messageTitle":"Merge branch \u002790-91-implement-pantry-class\u0027 of https://github.com/ShaniceTang/tp into 90-91-implement-pantry-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"2dae7a2dfb59ee73d09ed981ea3c94faf6345f85","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"Fixes #90, Fixes #91\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2},"test-code":{"insertions":1,"deletions":1}}},{"hash":"f9a255fb362187b5b41de91f2f9dea4d3985c04c","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":8}}},{"hash":"f61f1d549bd4af23fa2aa533b60b6c10dd0d39c2","isMergeCommit":false,"messageTitle":"Add method to write pantry list to storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":4}}},{"hash":"57eb8502badae1d6fdaaec17f5c8bddc07e337f9","isMergeCommit":false,"messageTitle":"Improve coding quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":2}}},{"hash":"c94591a0a0b63758478a837cdc66bbca828db743","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":4}}},{"hash":"5c0fb17c294a54c982dfcc760a0f860c6617dfbd","isMergeCommit":false,"messageTitle":"Instantiate pantry object at main and add pantry parameter to execute methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":14}}},{"hash":"7f63281f8d0d6607f26211dd1d6913febd008b32","isMergeCommit":false,"messageTitle":"Update parameters of execute method in JUnit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":20,"deletions":14}}}]},{"date":"2023-10-25","commitResults":[{"hash":"82231b9c3b4516bd26def3be6505aff3a90a7255","isMergeCommit":false,"messageTitle":"Improve buyIngredient command to accept multiple ingredients","messageBody":"Fixes #118\n","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":28}}},{"hash":"b173c22fb1b2fc6ba116fa45ff8bf85c1e3cb369","isMergeCommit":false,"messageTitle":"Add sequence diagram for deleteDishCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":28,"deletions":0}}},{"hash":"282fef71ed9d6aadf2d575b1c109a7fd443dd885","isMergeCommit":false,"messageTitle":"Update according comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"325d1c9f813429bcde54284dccb3aac13ed19772","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 118-improve-buyIngredient","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5594273db85e94c376db067fa0386baacf5c4446","isMergeCommit":false,"messageTitle":"Fix AddDish command test cases","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"fba840c4e6b3e86319d03cd1b04ab24bdee42a32","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 118-improve-buyIngredient","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"54f3a0994268f20c1a901553c569d313b349848c","isMergeCommit":true,"messageTitle":"Merge branch \u0027118-improve-buyIngredient\u0027 of https://github.com/ShaniceTang/tp into 118-improve-buyIngredient","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"14255c37af68c2974097b50e39241bc7253387cb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 120-create-deleteDish-uml","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"586400675d2601337b0b797dda8e8d7fd0d37ff1","isMergeCommit":false,"messageTitle":"Update sequence diagram for deleteDishCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":0}}},{"hash":"3dc567ebb9594123d8904c61d3f9854750964ac7","isMergeCommit":false,"messageTitle":"Update DG for delete dish command","messageBody":"Fixes #120\n","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":13}}},{"hash":"8b437c243edf3e5b013fea057b55d44b11d6ef74","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 120-create-deleteDish-uml","messageBody":"# Conflicts:\n#\tdocs/DeveloperGuide.md\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"64ea82e107bd47eb8edce8f92fcedc3451cf8eae","isMergeCommit":false,"messageTitle":"Handle all file related exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"53b6ce1ec8ce6edab618b891219ad458b14125c2","isMergeCommit":false,"messageTitle":"Include appropriate author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"39f9a51bcfa20e7c10ab0214cf2f5ae0c7a13172","isMergeCommit":false,"messageTitle":"Remove unecessary code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":32}}},{"hash":"eb4fe9c2be104ced8c51c20b6fabed88a32034c1","isMergeCommit":false,"messageTitle":"Implement decoder for Menu to parse text file as ArrayList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":20}}},{"hash":"4daafb7e583578324146488811440027fc38b50d","isMergeCommit":false,"messageTitle":"Implement encoder for Menu to parse ArrayList as text file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":26}}},{"hash":"b927d22f26bc291ebec9e2594537ae8c10f64e21","isMergeCommit":false,"messageTitle":"Import class java.nio.file.Path and java.nio.file.Paths","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4}}},{"hash":"e9578fb16e68469deeabaf0e806de3da3be24840","isMergeCommit":false,"messageTitle":"Implement loadMenu and saveMenu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":16}}},{"hash":"8613f8c8880e5a3bd0250a5652fa675fe3117732","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n\nFixes #146\n","fileTypesAndContributionMap":{}},{"hash":"bb021f4078b7821de7f78b0172991d0cbd1039a9","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"Fixes #146\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"05920cbd9f15e15f41f3ecc35822ee5739b8774a","isMergeCommit":false,"messageTitle":"Remove unused imports","messageBody":"Fixes #146\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}}]},{"date":"2023-10-31","commitResults":[{"hash":"e3c10021bd8821e821d38c9614bbce9017abc013","isMergeCommit":false,"messageTitle":"Handle case when quantity units are different","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":12}}},{"hash":"a96a45859608ba3f76d362be47f59e9d642ab9be","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/FileManager.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n#\ttext-ui-test/EXPECTED.TXT\n","fileTypesAndContributionMap":{}},{"hash":"05ad0ba200029d311504649786e6baeb08365c56","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 89-implement-buy-ingredient","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n#\ttext-ui-test/EXPECTED.TXT\n","fileTypesAndContributionMap":{}},{"hash":"d4fadf57a3a9fee6210f7a484bd34ef7bba92e85","isMergeCommit":false,"messageTitle":"Add message usage in list menu to standardize all command related messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"72198af146fde796143753c7d7c4443b388c155a","isMergeCommit":false,"messageTitle":"Remove unused messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":11}}},{"hash":"1f41243b552b2facf6a7a00b4e68bd49b32750b8","isMergeCommit":false,"messageTitle":"Improve code quality to standard all command guides to be from command classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":3},"test-code":{"insertions":2,"deletions":2}}},{"hash":"8c69b653a65eeb141148fba96f152eab96454a0e","isMergeCommit":false,"messageTitle":"Standarize origin of messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":13}}},{"hash":"2f2bd1478a3c4ba9df83939fedd0ace006067ea6","isMergeCommit":false,"messageTitle":"Update buyIngredientCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":5}}},{"hash":"343528dc20565797f0ce17553ac6ee5d031c6757","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c73a2ce648424056ff8221661c98681453941a92","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 89-implement-buy-ingredient","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3d247c2480d9f08bbe47a989ed63a8f840eeb7c6","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"811ad4bd8331ab410d1094af1c36db4f5f225532","isMergeCommit":false,"messageTitle":"Update expectedOutput in helpCommand JUnit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":5}}},{"hash":"222782638243434ac402101d5da7d3655e3a118c","isMergeCommit":false,"messageTitle":"Improve coding quality and standard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"89dc29ea6111c1d9943a21e01c23b745d666908d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 146-encoding-decoding-menu","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"652a7078d8ca4df46a3b0def78d06fa53126c415","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}},{"hash":"6f96737021fbe784f4cfa2f1cbd7d02c93b133a1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\t.gitignore\n","fileTypesAndContributionMap":{}},{"hash":"998fd8b9d7f5f3a3d27bc646626737d350e5592d","isMergeCommit":true,"messageTitle":"Merge branch \u0027146-encoding-decoding-menu\u0027 of https://github.com/ShaniceTang/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"5382fc052080ed435b935b65d0394537f7d081e2","isMergeCommit":false,"messageTitle":"Implement JUnit test for buyIngredient command parsing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":23,"deletions":2}}},{"hash":"dca0f60b741dedef767c909c1f68ffa45e0e576a","isMergeCommit":false,"messageTitle":"Implement JUnit test for buyIngredient execute command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":73,"deletions":0}}},{"hash":"6f01021fa34f2e7b2253de60e3491c6ce8ddee4a","isMergeCommit":false,"messageTitle":"Implement JUnit test for addIngredientToStock method","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":29,"deletions":0}}},{"hash":"ae5054f3ae5a4f371673c8cf49a33c996b045c79","isMergeCommit":false,"messageTitle":"Add new line in message usage string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"6913515ec669be5a7908d0a3261b755b1a2a466b","isMergeCommit":false,"messageTitle":"Handle error for invalid units for buyIngredient command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"32d49b7a3148c963a41168801514fa38c1a4398f","isMergeCommit":false,"messageTitle":"Implement JUnit test for invalid arguments for buyIngredient command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":19,"deletions":0}}},{"hash":"29253e2e1018d614f6dcf618e11a90ab3f978a74","isMergeCommit":false,"messageTitle":"Implement JUnit test for parseCommand to ensure viewTotalStockCommand is returned","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":22,"deletions":3}}},{"hash":"ec613ebbb2c1bae995517c2afcb1ed10f53fce3f","isMergeCommit":false,"messageTitle":"Implement JUnit test for ViewTotalStock execute command","messageBody":"Fixes #188\n","fileTypesAndContributionMap":{"test-code":{"insertions":43,"deletions":0}}},{"hash":"baa8b22c14a551c665738672d918561fe2984cd0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 188-viewTotalStock-junit-test","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n\nFixes #188\n","fileTypesAndContributionMap":{}},{"hash":"278b1516a87a76176f891778437a395ea6f31623","isMergeCommit":false,"messageTitle":"Update UG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":74,"deletions":6}}},{"hash":"1d02a9fbf49a0cbabaf8f437d95d3cbd159b1f94","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"c5a2b0ef9936b401c32364503e4730f27696190c","isMergeCommit":false,"messageTitle":"Add @@author tags","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":1}}},{"hash":"9c0e45dd659c80bb166e6ee9c4b7b9cd66e0b49e","isMergeCommit":false,"messageTitle":"Add author tags to UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":6}}},{"hash":"1dc83dd05a3ce5f80975ff3353e4be286e599576","isMergeCommit":false,"messageTitle":"Draw class diagram for UI package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"docs":{"insertions":56,"deletions":0}}},{"hash":"77e1e6dea5f60607f544c3c2b1a8350e63ff90e6","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into update-ug-dg","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cb3e1975b8d54b510471b5d675477cf69d5b3f73","isMergeCommit":false,"messageTitle":"Draw the class diagram for data component","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":7},"docs":{"insertions":54,"deletions":6}}},{"hash":"4a1c2b32d283a346266d32be6e483ace441ee794","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into update-ug-dg","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b4fc894fac1d20e5e6de7069f0a79322a27f846c","isMergeCommit":false,"messageTitle":"Remove unused variables and methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":10}}},{"hash":"48741b829bf3fa47f52d6e56dd73bb62eb70865d","isMergeCommit":false,"messageTitle":"Remove unused imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"f6dfe9524b88ea4c0b95aa885f6dcafd28ed4ee0","isMergeCommit":false,"messageTitle":"Add architecture diagram for overall CafeCtrl","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":31,"deletions":0}}},{"hash":"ca14decf88ec93ec1c98b465b35d0bf91cff01a1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 187-architecture-diagram","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8ef15951ac271f3295237fdd82bb5ea0703d2691","isMergeCommit":false,"messageTitle":"Add Ui component to DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":15,"deletions":0}}},{"hash":"db150a3cd0039f7b40b98ca945a7dd8084e92416","isMergeCommit":false,"messageTitle":"Remove unused method and standardise methid names","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":16}}},{"hash":"631d9ed7945b05139b984b91a87c27e9183ed523","isMergeCommit":false,"messageTitle":"Add Ui class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":0}}}]}]},"authorFileTypeContributionMap":{"NaychiMin":{"docs":172,"functional-code":682,"test-code":93},"DextheChik3n":{"docs":177,"functional-code":546,"test-code":297,"other":3},"Cazh1":{"docs":694,"functional-code":679,"test-code":332},"ziyi105":{"docs":280,"functional-code":538,"test-code":198},"ShaniceTang":{"docs":319,"functional-code":434,"test-code":330}},"authorContributionVariance":{"NaychiMin":52212.836,"DextheChik3n":41511.27,"Cazh1":50548.605,"ziyi105":13806.047,"ShaniceTang":11396.316},"authorDisplayNameMap":{"NaychiMin":"CS2113-T17-2 SAUN.. MIN","DextheChik3n":"CS2113-T17-2 DEXT..G EN","Cazh1":"CS2113-T17-2 CHUA..HENG","ziyi105":"CS2113-T17-2 NG Z..I YI","ShaniceTang":"CS2113-T17-2 TANG..NICE"}} +{"authorDailyContributionsMap":{"NaychiMin":[{"date":"2023-10-05","commitResults":[{"hash":"094363dc81635ad0658ac71e4eb02ca05a61c993","isMergeCommit":false,"messageTitle":"Edit about us with updated information.","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"568bed8b462e7fa328b1459b8cb2430513f0186c","isMergeCommit":true,"messageTitle":"Merge pull request #1 from NaychiMin/master","messageBody":"Edit about us with updated information.","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"78321f89bd358320aec6190b2e1f57bceec9b61b","isMergeCommit":false,"messageTitle":"Add Ui class for user input handling and UserOutput enum for user messages. Fixes #9","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":0}}},{"hash":"47e208e3c20a79c10f0f4c9fe082b7db52170725","isMergeCommit":false,"messageTitle":"Remove showError() function from Ui class.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":15}}}]},{"date":"2023-10-17","commitResults":[{"hash":"b1c8b3917bf5d9a2969b2dfcc85a77ed902bb5ab","isMergeCommit":false,"messageTitle":"Add list ingredient command.","messageBody":"#Fixes 20\n","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":1}}},{"hash":"3208c1e12e18a4730c187ef788f95e8c69b477f5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 20-UI-to-list-ingredients-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/data/Menu.java\n#\tsrc/main/java/seedu/duke/data/dish/Dish.java\n#\tsrc/main/java/seedu/duke/ui/Ui.java\n\n#Fixes 20\n","fileTypesAndContributionMap":{}},{"hash":"9f31ada3ba8e663dce87e230896db30dc424a8c9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 20-UI-to-list-ingredients-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2c367e72327872d4a83ee33f677e2e977129ad7a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 20-UI-to-list-ingredients-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"517bdf262e8a206ffde596e42f4ce95e17ea3d1f","isMergeCommit":false,"messageTitle":"Implement parsing for listing ingredients and necessary error handling.","messageBody":"Fixes #23\n","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":29}}},{"hash":"06da5aa5369ab28d0ad2880c2f68094700fb5cbe","isMergeCommit":false,"messageTitle":"Remove unused imports from Ui class and ListIngredientCommand class.","messageBody":"Fixes #23\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"ea5dbbd520baf2c7ae4b0e34f21a81b974e40961","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #23\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"d23e91b4260bd6d3677ece51eb74663a1655b266","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 23-parser-for-list-ingredients-v1.0","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"2fb7143c3608035bd2598e54e161afa8f31bac17","isMergeCommit":false,"messageTitle":"Add Junit test for list ingredient command.","messageBody":"Fixes #56\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":6},"test-code":{"insertions":51,"deletions":0}}},{"hash":"06cc5ab4bd4bc12cd600dff0a5e02fb9342cec43","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 56-Junit-test-for-list-ingredient.v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7a6a61058cc79064a530c3f47ddd22ce55efd919","isMergeCommit":false,"messageTitle":"Rename imported packages in ListIngredientCommandTest.java into the new refactored format.","messageBody":"Fixes #56\n","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3},"test-code":{"insertions":4,"deletions":4}}},{"hash":"421167b78f8a3be9664ab6d40146164793398dc6","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #56\n","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":7}}},{"hash":"37824dd4fbe3a1a7651fa68e34755eedfb2d726d","isMergeCommit":false,"messageTitle":"Update parsing of List Ingredients command.","messageBody":"Fixes #15\n","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":12}}},{"hash":"f3cc35239cedc9d46cb877ebe130fd7b47d1627d","isMergeCommit":false,"messageTitle":"Implement JUnit test for parsing list ingredients command.","messageBody":"Fixes #15\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5},"test-code":{"insertions":74,"deletions":0}}},{"hash":"6e09c0cac22f46b9e55ad711e96d793d38302f99","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 23-parser-for-list-ingredients-v1.0","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"5b7fa6298201506cb8947488d2bcfd94d02210a6","isMergeCommit":false,"messageTitle":"Improve coding standard using line wrapping.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-22","commitResults":[{"hash":"df0be27f0abb658365f85c686e483b4b7af8d9d9","isMergeCommit":false,"messageTitle":"Implement stock checking of ingredients in Pantry class","messageBody":"-Include decreasing of stock ingredients after processing each other\n-Include checking of low stock ingredients\n\nFixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":210,"deletions":1}}}]},{"date":"2023-10-23","commitResults":[{"hash":"213b1b2b789cc2f00849b4b688d15f10b472c10d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into implement-low-stock","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0ff4fad54b828cc704c117102d1cdb11485e5480","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into implement-low-stock","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"88235e7b9833aeaf0080fb2678cb6b8bb3e925f8","isMergeCommit":false,"messageTitle":"Refactor code to abstract print functions to UI class.","messageBody":"Fixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":42}}},{"hash":"b4d466fdd3ba96e2124e5e5c3bcaca1d675002a4","isMergeCommit":false,"messageTitle":"Improve code quality by refactoring methods.","messageBody":"Fixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":9}}},{"hash":"8df78067116251bb7f174b3d18dec6c8d841f187","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into implement-low-stock","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/data/Pantry.java\n#\tsrc/main/java/seedu/cafectrl/data/dish/Ingredient.java\n\nFixes #92, Fixes #93\n","fileTypesAndContributionMap":{}},{"hash":"21b07cd22ff5826632905428a7efd3b451deac44","isMergeCommit":false,"messageTitle":"Edit existing constructor parameter of Pantry class.","messageBody":"Fixes #92, Fixes #93\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":14,"deletions":13}}}]},{"date":"2023-10-25","commitResults":[{"hash":"e35f79c510e4b5dafb173826092913cee9b6a317","isMergeCommit":false,"messageTitle":"Refactor the folder structure of \u0027docs\u0027 to include \u0027umldiagrams\u0027 and \u0027umlimages\u0027","messageBody":"Fixes #115\n","fileTypesAndContributionMap":{"docs":{"insertions":39,"deletions":39}}},{"hash":"c2620fa2f944bf5b72b246298470574441ed4e89","isMergeCommit":false,"messageTitle":"Create a .puml file capturing the sequence diagram for the List Ingredient Command.","messageBody":"Fixes #115\n","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":0}}},{"hash":"1544ec1119cac3beacacea949d8a734073c1c499","isMergeCommit":false,"messageTitle":"Edit developer guide to include the list ingredient command function.","messageBody":"Fixes #115\n","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":4}}}]},{"date":"2023-10-30","commitResults":[{"hash":"4b20991f4fe788632d2623df48a2c8fa899df332","isMergeCommit":false,"messageTitle":"Implement encoding for OrderList to store the OrderList object to a text file.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":60}}},{"hash":"2b2aa6a744f569bd3a21c90949f40cfa094b5a52","isMergeCommit":false,"messageTitle":"Implement decoding for OrderList to convert data from text file into OrderList object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":29}}},{"hash":"e76c983732bffec4749166ed604970507d0db3c6","isMergeCommit":false,"messageTitle":"Add in necessary methods that are used in coding and encoding of the OrderList object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":10}}},{"hash":"8f324edf329f966761335bd99397d6a375d6240b","isMergeCommit":false,"messageTitle":"Add in javadoc for \u0027Decoder\u0027 class.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"ea1cd27ff9ef8be316c69a98c2ba06d4f632d61c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 148_encoding_decoding_orders_v2.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/CafeCtrl.java\n#\tsrc/main/java/seedu/cafectrl/data/Order.java\n#\tsrc/main/java/seedu/cafectrl/data/OrderList.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"a9c0289354c3aaaa821fbded7151d44a534d6d9c","isMergeCommit":false,"messageTitle":"Improve encoding of orderList object to be able to encode an array of orderLists from the provided Sales object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":35}}},{"hash":"a49071fb4393f04d93849455df7a6ad88ea5e31b","isMergeCommit":false,"messageTitle":"Improve decoding of text file containing Orders to decode the text file from the provided Sales object.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":18}}},{"hash":"554f33d026e5deb8649b0fcb265a927ec885511d","isMergeCommit":false,"messageTitle":"Create sales object and pass it into the function that saves it to storage.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"ce5b9008597ab4e623de3db5ac834ff56e40c541","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 148_encoding_decoding_orders_v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"65ff347261e28cd87f7307ac10b84c4af1c018bc","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":13}}},{"hash":"3137e0b64647d16fcceab8e90a9fa8ee747b6989","isMergeCommit":false,"messageTitle":"Add javadoc for encoder and author tags where necessary.","messageBody":"Fixes #148\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}},{"hash":"2b98bd6074559185f884def44f3ae76b449f4bc7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 148_encoding_decoding_orders_v2.0","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"4bed50e6f94cc0977e28b55142a247ca153a8a32","isMergeCommit":false,"messageTitle":"Implement the function to show total sales for each day since the cafe has operated.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":123,"deletions":17}}},{"hash":"bedd22130cdb1c6399cda1920dcd41dfaae987d7","isMergeCommit":false,"messageTitle":"Implement function to print sale by selected day.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":1}}},{"hash":"f6e1fe96cc2f4085a2b032edf9e6d852952af7d1","isMergeCommit":false,"messageTitle":"Implement parsing for commands to show total sales and show sales by day.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":16}}},{"hash":"7ab78b8caa3152372260a6fef318061c9e69f9da","isMergeCommit":false,"messageTitle":"Create ShowSalesByDayCommand class.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":1}}},{"hash":"9dece87746f697fb91b7dfdfc5d0f49b8e2e6e05","isMergeCommit":false,"messageTitle":"Create ShowSalesCommand class.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":1}}},{"hash":"59f7580b8ce3cb6a673f94d96e426e1602895529","isMergeCommit":false,"messageTitle":"Edit storage function for sales to accommodate showing sales functions.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":13}}},{"hash":"80c9f917e6a4e51d9435405b9f9dd386e2ccb1ee","isMergeCommit":false,"messageTitle":"Add in needed constant to improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"9350a6b66b658490974fbd9de287a59b1abe9542","isMergeCommit":false,"messageTitle":"Refactor necessary classes and functions to accommodate the function to show sales.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":23}}},{"hash":"c343e87d41d4bd36ed197a4b058d7096a75725b2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into print_orderlist","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/data/Pantry.java\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}},{"hash":"b1591c3d4bd40dd08ebc8d9c8601f65a67944e82","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":82,"deletions":52}}},{"hash":"ab0c385e800661e61323a75b3485381cc097000b","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":19}}},{"hash":"af5606aac98ecfc2f9dbd726f368ac3af247f43e","isMergeCommit":false,"messageTitle":"Refactor functions to improve code quality.","messageBody":"Fixes #189\n","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":19}}},{"hash":"cb36d44f553b9202934ba28b8180075681304edb","isMergeCommit":false,"messageTitle":"Edit author tag.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"075888de34ce8beae269362261cafea028b85954","isMergeCommit":false,"messageTitle":"Edit author tag.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"cf5d5950d94764e1fd249ac91e9ac5c0b00e9a2f","isMergeCommit":false,"messageTitle":"Edit Java Doc in Sales class.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":46}}},{"hash":"dca5363b842a7049c8660c620742a462b97fb0e4","isMergeCommit":false,"messageTitle":"Improve code standard.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":22}}},{"hash":"437264eddf17a792b0f6524479cbfb198eb0c0a8","isMergeCommit":false,"messageTitle":"Minor bug fixes in Pantry.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":7}}},{"hash":"35af0d12234048f0234db4ea8895e972015036b6","isMergeCommit":false,"messageTitle":"Improve coding standard and coding quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":39},"test-code":{"insertions":149,"deletions":149}}},{"hash":"e7b450815da8ae9a2184a88c0f2cef95d5c228e1","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":5}}},{"hash":"7877f1ee665968bfe7db478e0dd69dd7b84225f1","isMergeCommit":false,"messageTitle":"Improve coding quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"59aeae46d450dba0990fa8134a7eb0f5a20e662a","isMergeCommit":false,"messageTitle":"Improve code quality.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"5b57bae37b6ffceff70a8e5c3c1ee184e52d9462","isMergeCommit":false,"messageTitle":"Add line to resolve error when reading an empty file.","messageBody":"Fixes #198\n","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2},"test-code":{"insertions":10,"deletions":14}}},{"hash":"7ef0e64c59b4d892f6dc8550e76331d75ba89f0d","isMergeCommit":false,"messageTitle":"Remove unused junit test files.","messageBody":"Fixes #198\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":0,"deletions":8}}},{"hash":"996ba04cb7eb9f1f7180581b27e77827c5a59578","isMergeCommit":false,"messageTitle":"Remove unused junit test file.","messageBody":"Fixes #198\n","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}},{"hash":"37cd82653edc793879ae6e275f165da13c191106","isMergeCommit":false,"messageTitle":"Fixed minor bugs and add in clearer error messages.","messageBody":"Fixes #94\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":6}}},{"hash":"8186e9f6918c090a680d4c35c25b1b537f74b675","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #94\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":9}}},{"hash":"fadf1244e23eb269d17783421253d9f26448fb02","isMergeCommit":false,"messageTitle":"Improve coding standard.","messageBody":"Fixes #94\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"27cca2a065dcd86839125bc3bcfb2bc4c2333fd2","isMergeCommit":false,"messageTitle":"Update DG with description of data class diagram and architecture diagram.","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":2}}},{"hash":"80ffff5fb1bab92fa02078302dfea781d758c768","isMergeCommit":false,"messageTitle":"Update user guide with necessary commands.","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":62,"deletions":4}}},{"hash":"40c6b2b8a5b8bef17d78a14d094c41d980dd3e67","isMergeCommit":false,"messageTitle":"Add sequence diagram for Architecture diagram.","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":0}}},{"hash":"d88fd83e4c49661446006f922bf48b01804f39b1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 94-user-story-dish-availability-v2.0","messageBody":"# Conflicts:\n#\tdocs/DeveloperGuide.md\n#\tdocs/UserGuide.md\n","fileTypesAndContributionMap":{}},{"hash":"923b4d15a65588972afa86b75f599e50071dacbb","isMergeCommit":false,"messageTitle":"Finalise architecture diagram of DG.","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":68,"deletions":49}}},{"hash":"2210a7420ddbc5184a01326240b3eb0e64910b24","isMergeCommit":false,"messageTitle":"Finalise UG","messageBody":"Fixes #152\n","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":16}}}]}],"DextheChik3n":[{"date":"2023-10-05","commitResults":[{"hash":"21a60988c0892050292fffd82c8fb54d749500d8","isMergeCommit":false,"messageTitle":"Add information in AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"b5fd7b2190cecf65805f1bbb30e667ef2c1292b2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d76839232f9c1431f4caf8f5cfb25e385855dfa3","isMergeCommit":true,"messageTitle":"Merge pull request #3 from DextheChik3n/master","messageBody":"Add information in AboutUs.md","fileTypesAndContributionMap":{}},{"hash":"dbf0d943a9c8571848d9a7b298faf23652a8c899","isMergeCommit":true,"messageTitle":"Merge pull request #5 from Cazh1/master","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"ff19f057cf581945a4cd59e390d9be62bfc7fcc2","isMergeCommit":true,"messageTitle":"Merge pull request #34 from ziyi105/31-create-common-classes-v0.1","messageBody":"Task 31 Create Menu.java, Dish.java, Ingredient.java","fileTypesAndContributionMap":{}},{"hash":"d89e31068e0e0da1879bc5598aeb4ead9e960ab6","isMergeCommit":true,"messageTitle":"Merge pull request #32 from ziyi105/8-12-create-parser-class-v0.1","messageBody":"Task 8, 12 Create parser class and parser test class","fileTypesAndContributionMap":{}},{"hash":"04bdcc795e4402fb53826282d1623dad29c321d5","isMergeCommit":true,"messageTitle":"Merge pull request #35 from ziyi105/8-12-create-parser-class-v0.1","messageBody":"PR Review: add javadoc to the ParserTest class","fileTypesAndContributionMap":{}},{"hash":"2d1e435914a8d7a18891a5e9562d272c5b202d53","isMergeCommit":true,"messageTitle":"Merge pull request #37 from ShaniceTang/27-create-UiTest-class-v0.1","messageBody":"Issue #27, Add JUnit Test for UI class","fileTypesAndContributionMap":{}},{"hash":"3ca63034d0c9587550244e0ca3ac1fce710fbf7a","isMergeCommit":true,"messageTitle":"Merge pull request #36 from NaychiMin/9-create-UI-class-v0.1","messageBody":"Task 9, Create Ui class and UserOutput enum.","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"19e37bdc77938ff179bc7bcc3ddd59592394dc2e","isMergeCommit":true,"messageTitle":"Merge pull request #39 from Cazh1/master","messageBody":"10-create-command-class-v0.1 ","fileTypesAndContributionMap":{}},{"hash":"8e4fb479ae61dfc19385dee50a5acffe9072dd7d","isMergeCommit":false,"messageTitle":"Add commonly used methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":0}}},{"hash":"f97b53934e0c8778b06897e07499db1182d9365f","isMergeCommit":false,"messageTitle":"Add getters for Ingredient class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}}]},{"date":"2023-10-17","commitResults":[{"hash":"0d23d416e38c44e837ef3925d0862cca5e201e3e","isMergeCommit":true,"messageTitle":"Merge pull request #45 from ShaniceTang/21-implement-delete-ui","messageBody":"Issue 21, Implement Ui message for deleting a menu item","fileTypesAndContributionMap":{}},{"hash":"74f4f4d8f197fab8035bc1e7a855ccbd426dfc11","isMergeCommit":false,"messageTitle":"Implement add dish feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":7}}},{"hash":"f5824da1df3a9f3402190010e915feb380ebdbd0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 43-add-items-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"13d502c1c6a51e25c60748c110433973e7e72f6e","isMergeCommit":true,"messageTitle":"Merge pull request #47 from NaychiMin/20-UI-to-list-ingredients-v1.0","messageBody":"20 UI to list ingredients v1.0","fileTypesAndContributionMap":{}},{"hash":"69b789b05598d52130d17ad17ceeec896c42ef5e","isMergeCommit":false,"messageTitle":"Add testing for add dish command","messageBody":"Fixes #48\n","fileTypesAndContributionMap":{"test-code":{"insertions":24,"deletions":0}}},{"hash":"ca9212eada5e9bc6b5c18f161cb2a8983ccc3a35","isMergeCommit":false,"messageTitle":"Edit comment","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"eed8da07c304064b6e444c35e284ab8e0c393455","isMergeCommit":false,"messageTitle":"Update code based on gradle coding standard","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"0667ad8410478761765952e3186d0c5e5cc33356","isMergeCommit":true,"messageTitle":"Merge pull request #49 from Cazh1/#16-View-Menu-Items","messageBody":"#16 view menu items","fileTypesAndContributionMap":{}},{"hash":"c5043aaeea97d5ad78353eaf80389098f3e1f210","isMergeCommit":true,"messageTitle":"Merge pull request #50 from Cazh1/#19-Implement-Parser-Support","messageBody":"#19 implement parser support","fileTypesAndContributionMap":{}},{"hash":"eb16e2ca4bf8e39022a0ec75a64f2e3beab45774","isMergeCommit":true,"messageTitle":"Merge pull request #53 from ShaniceTang/22-implement-delete-feature","messageBody":"Task 22, Implement parser support for deleting a dish","fileTypesAndContributionMap":{}},{"hash":"a60c6f8075c9bac64b07d31815539843eb994d77","isMergeCommit":true,"messageTitle":"Merge pull request #54 from NaychiMin/23-parser-for-list-ingredients-v1.0","messageBody":"Task 23, Implement parsing support for listing ingredients .","fileTypesAndContributionMap":{}},{"hash":"2df1928e48276841f508f61e5cd0349ca6fe6df3","isMergeCommit":true,"messageTitle":"Merge pull request #51 from ziyi105/use-pattern-and-matcher-in-parser","messageBody":"Use pattern and matcher in parser","fileTypesAndContributionMap":{}},{"hash":"59eef0cdf11d0ea66d95fb251b957f33a24b201f","isMergeCommit":false,"messageTitle":"Renamed main class to CafeCtrl","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":19},"other":{"insertions":64,"deletions":56},"test-code":{"insertions":10,"deletions":10}}},{"hash":"08b6d3757647c4100510c3f57df4a3423980a755","isMergeCommit":false,"messageTitle":"Edit main function to start CafeCtrl application","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":7}}},{"hash":"557ea9cc49cdf6bce167d8bba7f828c9bb35dfea","isMergeCommit":false,"messageTitle":"Add JavaDoc to appropriate methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":1}}},{"hash":"a84615c4ad6c93f020b83e1cb92e6717d84e77ae","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 38-edit-main-class-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"87ceea9d298f8b648ed7219c550f363a2685ec60","isMergeCommit":false,"messageTitle":"Edit code to change displayed text","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"d96a43c56516085e4f47d119e887509154d76318","isMergeCommit":false,"messageTitle":"Remove unused import statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"ef8dd90e355a925a8d75c9a7ef0fd3e55e4efa46","isMergeCommit":false,"messageTitle":"Edit accessibility, add Javadoc and edit to resolve coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":3}}},{"hash":"6da928e074d832fb7ec5d798d84fe03a2dfd4b3c","isMergeCommit":false,"messageTitle":"Edit code for exiting loop logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":1}}},{"hash":"597bd744aa3a8af3f037200da66ec4124e067311","isMergeCommit":false,"messageTitle":"Edit code to follow coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-18","commitResults":[{"hash":"5cbc5ff9fbc6f1cd8e2f45f9254dad5522fe73b6","isMergeCommit":true,"messageTitle":"Merge pull request #61 from ziyi105/master","messageBody":"Sync my master ","fileTypesAndContributionMap":{}},{"hash":"c5cd369348c670f00cee3d1057e691e82af5d924","isMergeCommit":true,"messageTitle":"Merge pull request #64 from ziyi105/ziyi105-11-feature-edit-price-v1.0","messageBody":"11 feature edit price v1.0","fileTypesAndContributionMap":{}},{"hash":"cd65ca12b9a4aa2d948b592690f25f2f23c10502","isMergeCommit":false,"messageTitle":"Create parsing logic for add command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":26}}},{"hash":"662573be694dfbb3b724a75cb1523a54ed7d65be","isMergeCommit":false,"messageTitle":"Refactor prepareAdd method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":24}}},{"hash":"1efc60f9586f0d30b7825876730b0b655c88eeb7","isMergeCommit":false,"messageTitle":"Edit error messages for add dish parsing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":3}}},{"hash":"a91ce9760719dd42f2a4f04b5945d19194e15e02","isMergeCommit":false,"messageTitle":"Remove magic numbers in prepareAdd method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"b288c8a7fe69918fc91bbaeaeacb7b0e4a3d3e22","isMergeCommit":false,"messageTitle":"Edit printAddDishMessage method to display price in 2 decimal place","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":2}}},{"hash":"46d545187e45a75040194e17f555938a00c0531a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 24-parser-add-dish-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"bafeabf2525e5166b1ab60cb4f14a6fc7566bf58","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":9}}},{"hash":"dc474694da89328e8858e7a6d0dbd9e3acecd725","isMergeCommit":false,"messageTitle":"Fix regex for checking command format","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"b2cdb4b7ed5c7a53f4c94a59976d9cb9b210fa5f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 48-add-junit-add-dish-command-class-v1.0","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/duke/command/AddDishCommandTest.java\n","fileTypesAndContributionMap":{}},{"hash":"fa8ef0342b58f18674f264f4ccf62ba1c191089e","isMergeCommit":true,"messageTitle":"Merge pull request #68 from ziyi105/65-junit-test-edit_price","messageBody":"65 junit test edit price","fileTypesAndContributionMap":{}},{"hash":"4d15f13e7ddfa5613ca9aeead0a522e7ca345d7d","isMergeCommit":false,"messageTitle":"Migrate code to the proper file to account for refactoring","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":25,"deletions":31}}},{"hash":"21f12ca05d6c12e1ebf594b645ee414aa463f867","isMergeCommit":false,"messageTitle":"Rename assertion test class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"39a749dfb863c53632cfc7fe43940e78ffcbaa36","isMergeCommit":true,"messageTitle":"Merge pull request #71 from NaychiMin/23-parser-for-list-ingredients-v1.0","messageBody":"Task 15 Fulfill user story: As a cafe owner, I want to list the ingredients needed for each dish on the menu","fileTypesAndContributionMap":{}},{"hash":"edf80a2a80eecbec3210162b4005895920dc697f","isMergeCommit":true,"messageTitle":"Merge pull request #70 from Cazh1/master","messageBody":"Update ListMenuCommand JUnit assertion use","fileTypesAndContributionMap":{}},{"hash":"293c66243dde702314e4b2f53db72f638f5a773b","isMergeCommit":false,"messageTitle":"Added JUnit Tests for add dish command parsing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":35,"deletions":0}}},{"hash":"a1c50f66393dc01a4e45c75e9ef33fb975305ec7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 67-junit-test-for-add-dish-v1.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"41cb964a10164e5c327493bac64d1bb053d05657","isMergeCommit":false,"messageTitle":"Update ParserTest.java to resolve checkstyle bug","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"1b21699f299353403aff2b6e37e077e604e675cf","isMergeCommit":true,"messageTitle":"Merge pull request #75 from ShaniceTang/22-implement-delete-feature","messageBody":"Task 17, Implement delete feature","fileTypesAndContributionMap":{}},{"hash":"c694c066583b13ef900278baa32b1df645b43fd6","isMergeCommit":false,"messageTitle":"Edit add dish parsing code to prevent negative price input","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":0}}},{"hash":"d1fa8a2f18fd567e65f8e22359f333e35cda5099","isMergeCommit":false,"messageTitle":"Edit code to solve checkstyle issues","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":6}}}]},{"date":"2023-10-22","commitResults":[{"hash":"bf777c46f6b1718b5e939b83e6b6d710b37ff8ff","isMergeCommit":false,"messageTitle":"build.gradle: Enable assertions","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-23","commitResults":[{"hash":"dd09c3f9be85aa42430c94212437518ea9d53ebe","isMergeCommit":true,"messageTitle":"Merge pull request #98 from ziyi105/73-implement-help-command","messageBody":"73 implement help command","fileTypesAndContributionMap":{}},{"hash":"d4e717104a76ff44bd25aa1ead7a97fb824f026c","isMergeCommit":false,"messageTitle":"Change exception handling for prepareAdd logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":25}}},{"hash":"baf4a1b83f4c0c988a4cd37d3c8feece84a3e541","isMergeCommit":false,"messageTitle":"Change error messages and minor change to AddDishCommand class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":7}}},{"hash":"c0666d970edad17702f9fdaa56d9297c274b0c67","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 102-add-dish-exception-handling-v1.1","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d2c657d8b35474fa8ab79ecdaca5159baf2c2aac","isMergeCommit":false,"messageTitle":"Change ingredientParsing function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"49f5b540ecf1e3ef0ee405221278dc12bbf19b74","isMergeCommit":false,"messageTitle":"Add Javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":1}}}]},{"date":"2023-10-24","commitResults":[{"hash":"50624791c21f56e1f453f446afce153456266da2","isMergeCommit":false,"messageTitle":"Change parsing logic to read ml or g units for ingredient qty","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":15}}},{"hash":"f6a34539b291986a3439ae429844b5a016c7b88a","isMergeCommit":true,"messageTitle":"Merge pull request #108 from Cazh1/#107-Change-Command-Class-execute-method","messageBody":"#107 change command class execute method","fileTypesAndContributionMap":{}},{"hash":"f4dbba3497804b4ceec6a5b68c8fe324ec9e249f","isMergeCommit":false,"messageTitle":"Revert \"#107 change command class execute method\"","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":85,"deletions":334},"test-code":{"insertions":42,"deletions":56}}},{"hash":"bc4b74ad8633b1d37f27b508c78e99918be6a35f","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e66b7355da6b48050d48947d30973317235d1891","isMergeCommit":true,"messageTitle":"Merge pull request #109 from AY2324S1-CS2113-T17-2/revert-108-#107-Change-Command-Class-execute-method","messageBody":"Revert \"#107 change command class execute method\"","fileTypesAndContributionMap":{}},{"hash":"763688f9316bb15ceebec3e5fe7c9747055d46ce","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fcebfff0e3f01ae40591acf89499f89160cec509","isMergeCommit":true,"messageTitle":"Merge pull request #105 from Cazh1/#84-Implement-UI-support-for-Order-class","messageBody":"#84 implement UI support for order class","fileTypesAndContributionMap":{}},{"hash":"463b45b58762eb58809172419a4d88849bc163c7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"868d299a491cff787a4543c64d3d95fc51d85716","isMergeCommit":false,"messageTitle":"Edit parsing logic to divide ingredient qty into name and unit","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3}}},{"hash":"06d4c57a5100fa38963ba199a057f693adb61f69","isMergeCommit":false,"messageTitle":"Rename variables and regex for clarity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":10}}},{"hash":"c726c8364e1b7d52b5f508d0519eb117b1d48a23","isMergeCommit":false,"messageTitle":"Fix BuyIngredient parsing logic to use updated regex","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":6}}},{"hash":"3c40f6dcb8cb7f2ffbb1a5b6195eb0455f63d575","isMergeCommit":false,"messageTitle":"Edit the AddDish parsing error handling and JavaDoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":10}}},{"hash":"5fe0bb191e6c4fb60de7be71cd53d223fa0000e5","isMergeCommit":false,"messageTitle":"Change all definition statements to private","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":16}}},{"hash":"4955e587557a0acf43b478b0c020f21a22ece253","isMergeCommit":false,"messageTitle":"Update test cases for addDish command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":4}}},{"hash":"2eaf137b2222ceb165ec7b2bfd4eb37da13f9ba4","isMergeCommit":true,"messageTitle":"Merge pull request #110 from Cazh1/#107-Change-Command-Class-execute-method","messageBody":"#107 Change Command class execute method","fileTypesAndContributionMap":{}},{"hash":"3c0a0355135e6759f50ef5084bebd5b24cb20f53","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 100-format-read-ingredient-unit-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7c914b24d70c3ee96323c1c59993858be531c15d","isMergeCommit":true,"messageTitle":"Merge pull request #114 from DextheChik3n/100-format-read-ingredient-unit-v1.2","messageBody":"100 format read ingredient unit v1.2","fileTypesAndContributionMap":{}},{"hash":"18c5dc331f026ecb2eab6c20363b82479c68cf4e","isMergeCommit":false,"messageTitle":"Create sequence diagram for AddDish command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":28,"deletions":0}}},{"hash":"2d7ab89f7011b388dbb57e217907d7a4b94de9a2","isMergeCommit":true,"messageTitle":"Merge pull request #119 from ShaniceTang/118-improve-buyIngredient","messageBody":"Task 118, Improve buyIngredient command to accept multiple ingredients","fileTypesAndContributionMap":{}},{"hash":"f279fd2394c61d0c4d1f7691fd30a874786c4795","isMergeCommit":false,"messageTitle":"Refactor printAddDishMessage method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":13}}},{"hash":"8d41e0641a730c2a758054408f4ca018c6c2924e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 123-refactor-add-dish-v1.2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4948df6bbc47975cf084a3d5bd6b17b248b196ef","isMergeCommit":false,"messageTitle":"Fix addDishCommand parsing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"63d0a366759628ad0a96443a3f9c6f02e367df11","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 117-DG-add-dish","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0fbeaaf0766307cf02d5a53018a33d366879f89a","isMergeCommit":false,"messageTitle":"Create sequence diagram for addDish command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":5}}},{"hash":"2095e06b8466275844050c3ec1069e49ebc29159","isMergeCommit":false,"messageTitle":"Update developer guide to explain the implementation of addDish command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":1}}},{"hash":"c1f95056eb4c57270099003ecdc7a8cc69d27b31","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 117-DG-add-dish","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"da87ea78a13f050c5faeb6b76910706d2d1cac45","isMergeCommit":true,"messageTitle":"Merge pull request #126 from ShaniceTang/120-create-deleteDish-uml","messageBody":"Task 120, Update DG for delete dish command","fileTypesAndContributionMap":{}},{"hash":"0549edae1c207ee9cc03b766e7f63fa271494fd2","isMergeCommit":true,"messageTitle":"Merge pull request #127 from NaychiMin/115_DG_for_list_ingredients","messageBody":"Task 115, Edit developer guide for List Ingredient command.","fileTypesAndContributionMap":{}},{"hash":"200d0c4f4cc2132f8d9ded86cdc48f99b9b43da5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 117-DG-add-dish","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"702daf244d44f64fc0b9eeecf2da38c4d93d1904","isMergeCommit":true,"messageTitle":"Merge pull request #129 from Cazh1/128-Update-DG-for-list_menu-feature","messageBody":"Update DG for list_menu feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"4aaf45365970c0b45c780d93e1e264be6efd9244","isMergeCommit":false,"messageTitle":"Create Storage parent class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":0}}},{"hash":"af3570530ca7557025e99fae83b08db3e7b11a62","isMergeCommit":false,"messageTitle":"Create error handling for file and folder saving","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":3}}},{"hash":"e0b1c99d944481e3a58b5b1f4207fcbba3b59c84","isMergeCommit":false,"messageTitle":"Create menu storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":69,"deletions":0}}},{"hash":"2f6306dd6846b8b2807c885bf87befa86b392904","isMergeCommit":false,"messageTitle":"Edit main to do foundational text storage functionality for Menu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":4}}},{"hash":"d7d1074b7d442c5d7dbaea6dd44467fcd185b8ba","isMergeCommit":false,"messageTitle":"Edit messages for storage feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"81762ce619200d8623de91be574608098c69839f","isMergeCommit":false,"messageTitle":"Change messages for opening text file logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"4c8803d8490b01f1ff9b333ac4823702002d556b","isMergeCommit":false,"messageTitle":"Edit add dish parsing logic to accept whitespaces","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":19}}},{"hash":"857b9a8c177620f73a4a81fe8bba331c1acbb1f4","isMergeCommit":false,"messageTitle":"Refactor AddDish command logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":12}}},{"hash":"cdf7ad077e707a50c7bdd6cacf43dfb8456c7b7a","isMergeCommit":false,"messageTitle":"Add more JUnit Tests with respect to bug fix","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":153,"deletions":9}}},{"hash":"e48aecff8ac3a85fc076d7637d6e3127e79b18e1","isMergeCommit":false,"messageTitle":"Add author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2},"test-code":{"insertions":2,"deletions":1}}},{"hash":"7eb0cbed400121c284dd9b92a7f766fa77d46615","isMergeCommit":false,"messageTitle":"Refactor to satisfy coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-28","commitResults":[{"hash":"a5919cc3adf1c086294058972a795b8b9a565829","isMergeCommit":false,"messageTitle":"Edit user input command regex","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"8146494321ad74edd59983b438548e9badf2db06","isMergeCommit":false,"messageTitle":"Add author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":6}}},{"hash":"07c0d58b8b3e124407c1d012f819b4dee545708a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 138-fix-add-dish-command-bugs-v2.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Ui.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"4dff4aacbf5069ed1e685c680112e0fdb2f2f466","isMergeCommit":true,"messageTitle":"Merge pull request #143 from ziyi105/140-more-oop-storage","messageBody":"#140 Refactor Storage System to be more OOP","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"0cc8fe97f31a4acfe4b8375330157da132720ed5","isMergeCommit":false,"messageTitle":"Add error handling for price input overflow","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":2}}},{"hash":"303361945e22679cf8855171c0780ed2c5f5b5ff","isMergeCommit":false,"messageTitle":"Add JUnit tests for priceParseToFloat function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":0}}},{"hash":"0c646fc5dd8dd5b88a45fb363aa0bd214d242881","isMergeCommit":false,"messageTitle":"Edit JUnit tests for AddDish commands","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":17,"deletions":35}}},{"hash":"a961283ef6cb23315121adc83a5b80885069ad6d","isMergeCommit":false,"messageTitle":"Edit classes to standardise spacing for consistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":10}}},{"hash":"5d65c3c89bbfed88ae1fa6e9f567bf7dd904df1e","isMergeCommit":false,"messageTitle":"Update User Guide for v1.0 commands","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":100,"deletions":21}}},{"hash":"c25809b3524b1129f95adcbbe4f20d43e8440696","isMergeCommit":false,"messageTitle":"Edit command summary table","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":8}}}]},{"date":"2023-10-31","commitResults":[{"hash":"30594403954ddec545efb5cad5c7e2bc450d1b10","isMergeCommit":true,"messageTitle":"Merge pull request #156 from ziyi105/147-encode-decode-pantry-stock","messageBody":"147 encode decode pantry stock","fileTypesAndContributionMap":{}},{"hash":"6c0e5578d76a8db5acc29bdd256c802226b1b1a9","isMergeCommit":true,"messageTitle":"Merge pull request #160 from Cazh1/#158-Update-DG-with-Add-Order-feature","messageBody":"#158 update dg with add order feature","fileTypesAndContributionMap":{}},{"hash":"fe1a5cb8ff37cb1980a6eecbe9eaf990a2055e6c","isMergeCommit":true,"messageTitle":"Merge pull request #165 from ziyi105/DG-parser-class","messageBody":"Update DG: parser class and help command","fileTypesAndContributionMap":{}},{"hash":"0de5fe72357608e4d467c589c7fa64d1f0bbf273","isMergeCommit":false,"messageTitle":"Add error handling for repeated dish name in add dish command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":1}}},{"hash":"8592f76712fa8afb25647d0c2bd1549c8f67880d","isMergeCommit":false,"messageTitle":"Add JUnit tests for isRepeatedDishName function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":0}}},{"hash":"4e4c4af31e91166a22a0d154c523650d22ff5fb6","isMergeCommit":false,"messageTitle":"Add error handling for null dish name","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"e4169e6f6b4985aec867b9508be92944f8698774","isMergeCommit":false,"messageTitle":"Add Ui messages for existing dish name detected","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"af9cdf9da0f34acdd84e170ee3741c53bef63782","isMergeCommit":false,"messageTitle":"Refactor function name","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"51787b1c73182e64d245bbe19a612c5e5158255d","isMergeCommit":false,"messageTitle":"Make small changes to comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"d0a459125e57bda70df4a024d4775fea92e09382","isMergeCommit":false,"messageTitle":"Remove error handling from main and redundant code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":12}}},{"hash":"dfb08cba67b8ae335249c1a2ee4a3e88d2860617","isMergeCommit":false,"messageTitle":"Create UML structure for Storage class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":49,"deletions":0}}},{"hash":"f5a82858fcd4b5857ef48fe811f773d63b0b39ab","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 169-dg-order-class-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a1f97402167777e4794df19e01f7f2474f3df372","isMergeCommit":true,"messageTitle":"Merge pull request #161 from ShaniceTang/146-encoding-decoding-menu","messageBody":"Task 146, Create encoding and decoding to text file in menu storage","fileTypesAndContributionMap":{}},{"hash":"e92acc2b430109d31961be2b8ecb2efa5c534c82","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 169-dg-order-class-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8d83eb98f570d76f2d2205e99c29e527c8f38998","isMergeCommit":false,"messageTitle":"Refactor Storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":17}}}]},{"date":"2023-11-01","commitResults":[{"hash":"e5db639676dc93980d77e67e28a96ae4faf71fc1","isMergeCommit":false,"messageTitle":"Create Storage class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":28,"deletions":19}}},{"hash":"af0deb9e8153d900782dbaefa723f505fca29424","isMergeCommit":false,"messageTitle":"Update DG for Storage class","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":1}}},{"hash":"2268167952af4b0da3aba82622b9e2a95e9b7b21","isMergeCommit":false,"messageTitle":"Clean up small error in documentation","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":6}}},{"hash":"893a34c9c61d77bbc175ee77fe790ca4e54a74ad","isMergeCommit":true,"messageTitle":"Merge pull request #177 from ziyi105/176-UG-help-edit-price","messageBody":"176 UG help edit price","fileTypesAndContributionMap":{}},{"hash":"7e6d0d442540090670485a3b261773ad063c264d","isMergeCommit":true,"messageTitle":"Merge pull request #181 from DextheChik3n/169-dg-storage-class-v2.0","messageBody":"169 dg storage class v2.0","fileTypesAndContributionMap":{}},{"hash":"309cd9c8c918cfe102df02fb5e35d7025719a130","isMergeCommit":true,"messageTitle":"Merge pull request #183 from ziyi105/182-standardise-help-command","messageBody":"182 standardise help command","fileTypesAndContributionMap":{}},{"hash":"fd88ff4ca16bdd7d8baee87ea2288806af83a932","isMergeCommit":false,"messageTitle":"Add error handling for name input exceed max characters","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":4}}},{"hash":"ac197685e05b776ba5e9a7094b1e894f4dbf2be0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 178-limit-name-input-char-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ee9fd0770887a9356f3297f46954009a13edef0b","isMergeCommit":false,"messageTitle":"Refactor utility functions to ParserUtil class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":72,"deletions":71},"test-code":{"insertions":6,"deletions":6}}},{"hash":"dd83de059ce69a23d88a057d96db2bae0a1acd5c","isMergeCommit":false,"messageTitle":"Refactor error handling and utility functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":16},"test-code":{"insertions":68,"deletions":56}}},{"hash":"0eb8ef573c7794f5291bab7a85cd3e2f817c8deb","isMergeCommit":false,"messageTitle":"Add JUnit tests for name length checker function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":0}}},{"hash":"fa4345bd4079771ae4d9b1caf90c1a65977f9760","isMergeCommit":false,"messageTitle":"Resolve JUnit test from refactoring error handling","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"fd5187d59068c49a2e39f7e27d78060659c5d0a7","isMergeCommit":false,"messageTitle":"Edit JUnit test code to satisfy coding standards","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"b4b623164b3667549d776a77b7be64f3d1ab01b8","isMergeCommit":true,"messageTitle":"Merge pull request #191 from ShaniceTang/173-buyIngredient-junit-test","messageBody":"Task 173, Implement JUnit Test for buyIngredient function","fileTypesAndContributionMap":{}},{"hash":"d72c1cd30a36518a6b359e955b544260c7f1d412","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 178-limit-name-input-char-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bb362bceaf19daeb4b35af8f5f178f64d6564838","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 142-storage-error-handling-v2.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/CafeCtrl.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}},{"hash":"a176f7b6371d6e446fa5da0cedeb36d2123714f7","isMergeCommit":true,"messageTitle":"Merge pull request #190 from NaychiMin/189_print_orderlist","messageBody":"Task 189, implement function to show total sales for all days and sales by specific days.","fileTypesAndContributionMap":{}},{"hash":"758eac51eaaeb2252725849874f9b16cf9b46c91","isMergeCommit":true,"messageTitle":"Merge pull request #193 from ShaniceTang/188-viewTotalStock-junit-test","messageBody":"Task 188, Add JUnit test for viewTotalStock command","fileTypesAndContributionMap":{}},{"hash":"a08dae0532beb124f16824cda6096e61e17c5103","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 178-limit-name-input-char-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"818b1b37a5cea3e6777053c10a64ac0871dce6d0","isMergeCommit":false,"messageTitle":"Edit error handling in main CafeCtrl class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}},{"hash":"983089ccde232737a16e28d57d5635e9b971dfa9","isMergeCommit":false,"messageTitle":"Resolve errors in ParserTest class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":57}}},{"hash":"4f7cfe1cf5f25608e5ef3ce380cf1a957a3eafb6","isMergeCommit":false,"messageTitle":"Edit error handling for file storage functionality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":71,"deletions":76},"test-code":{"insertions":0,"deletions":12}}},{"hash":"5115b8b25034bdf64ca9dfe329bb5befc1e7090f","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":6}}},{"hash":"7bff627dc74a9fcadc78530f73dbb9da42c59d14","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 142-storage-error-handling-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e66637376701afa4e1e8f018fee7238a73290457","isMergeCommit":true,"messageTitle":"Merge pull request #199 from NaychiMin/198-fix-main-v2.0","messageBody":"Task 198, fix main v2.0","fileTypesAndContributionMap":{}},{"hash":"df8de17fe11838dae6673191f217b201ea55cab4","isMergeCommit":false,"messageTitle":"Resolve issues found when pulling code from local repo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"9dda2b9aa06cb68b2fb5c427bf678edea362f53b","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 142-storage-error-handling-v2.0","messageBody":"# Conflicts:\n#\tdata/orders.txt\n","fileTypesAndContributionMap":{}},{"hash":"1d15b6ca5e88a9b962fd5b7b3bdef331f7ee4f71","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"79ee69fd33aded144ae636d8add17c3f23f4e6f2","isMergeCommit":false,"messageTitle":"Refactor code based on reviewer feedback","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":64},"test-code":{"insertions":74,"deletions":73}}},{"hash":"9bb972ffc4661a279a30be4a67213ad45b9b09e2","isMergeCommit":false,"messageTitle":"Make minor changes for to revert ParserUtil class changes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3},"test-code":{"insertions":0,"deletions":15}}},{"hash":"587d98518f7597da4985bdf3cdca1f0a031ae893","isMergeCommit":false,"messageTitle":"Resolve checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3},"test-code":{"insertions":3,"deletions":1}}},{"hash":"f78c56ac089977184c63e95f58215d968bbb56a1","isMergeCommit":true,"messageTitle":"Merge pull request #192 from DextheChik3n/178-limit-name-input-char-v2.0","messageBody":"178 limit number of characters for dish name and ingredient name input v2.0","fileTypesAndContributionMap":{}},{"hash":"8b92dcedd233d555dc8407a31abd99e9d258a44c","isMergeCommit":true,"messageTitle":"Merge pull request #201 from Cazh1/#200-Bug-Fix-for-AddOrderCommandTest","messageBody":"Fix bug for AddOrderCommandTest","fileTypesAndContributionMap":{}},{"hash":"f58f1e5028775bc0e8bc075b9ad51e49cd900ab0","isMergeCommit":true,"messageTitle":"Merge pull request #202 from NaychiMin/94-user-story-dish-availability-v2.0","messageBody":"Task 94, Fixed minor bugs and add in clearer error messages.","fileTypesAndContributionMap":{}},{"hash":"770508adba038ade4fb3b840d6c0712db05d0ce5","isMergeCommit":true,"messageTitle":"Merge pull request #203 from ziyi105/184-encode-pantrt-stock-with-regex","messageBody":"184 encode pantrt stock with regex","fileTypesAndContributionMap":{}},{"hash":"ff6892e6031e0e1e738f832ef89c1d567e10de5e","isMergeCommit":true,"messageTitle":"Merge pull request #186 from Cazh1/#159-Update-DG-with-Multi-day-Order-feature","messageBody":"#159 Update DG with Multi-day Order feature","fileTypesAndContributionMap":{}},{"hash":"4ac72d1a7644050d559a42213488e4bfc68f6ddf","isMergeCommit":false,"messageTitle":"Add fix to prevent multiple ingredients with same name","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":2},"test-code":{"insertions":4,"deletions":4}}},{"hash":"9bf0d888fcf148d3d6c0b5962d53ef0e22a396a2","isMergeCommit":false,"messageTitle":"Edit Javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"782fa3b95ebea39a45afa2d8e2e5fce93e80df24","isMergeCommit":true,"messageTitle":"Merge pull request #204 from ShaniceTang/185-data-dg","messageBody":"Task 185, Add class diagram for Data component","fileTypesAndContributionMap":{}},{"hash":"ee5db7a1f4bb5514574f7f4e843bc25b30a9c862","isMergeCommit":true,"messageTitle":"Merge pull request #212 from Cazh1/#211-Bug--1-index-Error-when-showing-sales","messageBody":"Fix bug","fileTypesAndContributionMap":{}},{"hash":"8a30636776caef556d6d91cfba7ed3410365cd5e","isMergeCommit":true,"messageTitle":"Merge pull request #207 from Cazh1/Update-UG-for-Add-Order","messageBody":"Update UG for Add Order","fileTypesAndContributionMap":{}},{"hash":"e1074283e30fa07e2459c8fc44a8a8bc30c14577","isMergeCommit":true,"messageTitle":"Merge pull request #208 from ShaniceTang/187-architecture-diagram","messageBody":"Task 187, Add architecture diagram","fileTypesAndContributionMap":{}},{"hash":"75ad7059636a75aec6e778134c8c0bb3233be63d","isMergeCommit":true,"messageTitle":"Merge pull request #213 from ShaniceTang/174-ui-classDiagram","messageBody":"Task 174, Add UI Component to DG","fileTypesAndContributionMap":{}},{"hash":"d80103eb96593deaf5c24784c0e5a5fe48337173","isMergeCommit":true,"messageTitle":"Merge pull request #214 from ziyi105/184-encode-pantrt-stock-with-regex","messageBody":"Debug encoding pantry stock cannot add more than one ingredient","fileTypesAndContributionMap":{}},{"hash":"21edf2f45490a5adf7b88a6c05a0ebaa4036e84a","isMergeCommit":false,"messageTitle":"Remove unused code for printing ingredients in add dish command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":12}}},{"hash":"c339beff59100ce960eb76ec8f333673b535010d","isMergeCommit":false,"messageTitle":"Fix bug for adding same dish name after reloading application","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"3cfc15076bfc67baf39105dec434079cbdc92018","isMergeCommit":false,"messageTitle":"Add author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"43fa69375beab01cc6ad094824d793c2d16a88a3","isMergeCommit":false,"messageTitle":"Update UG and DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":20}}},{"hash":"20a8d133d32a4fff81d4acd4b0fff144c8b6467c","isMergeCommit":true,"messageTitle":"Merge pull request #217 from Cazh1/master","messageBody":"Update Code Quality","fileTypesAndContributionMap":{}},{"hash":"5fd22a1694d408b36976066d6f08043071dc7766","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 94-user-story-dish-availability-v2.0","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"b353ffa86847f49a3b5b765ffe19afc9b75babd6","isMergeCommit":true,"messageTitle":"Merge pull request #215 from NaychiMin/94-user-story-dish-availability-v2.0","messageBody":"Task 94, user story dish availability v2.0","tags":["A-Release-v2.0"],"fileTypesAndContributionMap":{}}]}],"Cazh1":[{"date":"2023-10-05","commitResults":[{"hash":"070155ed53e9e987a79208ac10c5a7942c4cf353","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"723d6d3ec5d4432d2631550b9b22baf980699341","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"7c37a72bf95a8e73203623e2f7bba0d31d980da2","isMergeCommit":false,"messageTitle":"Add Command class","messageBody":"Fixes #10\n","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":0},"test-code":{"insertions":28,"deletions":0}}},{"hash":"41a9cdcf458fc3a5c3263d6a38a86dcd2df4bf24","isMergeCommit":false,"messageTitle":"Update DeleteCommand.java documentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"d97572fd5728f2ca25a88738e0051ea5e7eb8ad0","isMergeCommit":false,"messageTitle":"Update class names to be more specific","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":11},"other":{"insertions":2,"deletions":2},"test-code":{"insertions":20,"deletions":23}}},{"hash":"eb08e382fa90c0fb9bdf8e71b309f20284cd98ad","isMergeCommit":false,"messageTitle":"Add newline at end of test files","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":5}}},{"hash":"3c06e5aa4557a25d90dda38e1a41ae36ca9e6e10","isMergeCommit":false,"messageTitle":"Update execute method in Command class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":6}}},{"hash":"07a56ed80238819e5d1923bc0495342718d6cc60","isMergeCommit":false,"messageTitle":"Update Command class to include index attribute","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":1}}},{"hash":"0571dea28a7a323f5ea3157b5b11efc77a16ad9d","isMergeCommit":false,"messageTitle":"Update ListMenuCommand.java for spacing issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"67f65e2b750751127920b80b45d162c28849b99f","isMergeCommit":false,"messageTitle":"Update Menu.java methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":1}}},{"hash":"dd7c6f2d40a3ed811a03e75cc2af2322965eb214","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027 into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"43905d03b1a0e1e6f237519feb227e5c606d0e3d","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027 into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"188ec8e7c0cd4b376b7ab20baa1b24b4b3a9fce0","isMergeCommit":false,"messageTitle":"Update ListMenuCommand.java function","messageBody":"Fixes #16\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":4}}},{"hash":"960269b67e4aa999773ea1f4dbc28795c369f061","isMergeCommit":false,"messageTitle":"Implement UI support for ListMenu","messageBody":"Fixes #18\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"ad6b223efae6bf4be468bf1ad7cbeb772c58d774","isMergeCommit":false,"messageTitle":"Implement Junit for ListCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0},"test-code":{"insertions":16,"deletions":0}}},{"hash":"ac4e57130e2e050f03f1ccd7411de2e88ee69082","isMergeCommit":false,"messageTitle":"Update ListMenuCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":0}}},{"hash":"00a910fc686c6c00e94650e0d5916547bc5e5ad9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f6297af60c900eefedcceacecce2d08c15276341","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"2856c5f60c980e91be95c745fedd8c9e8ddd6e31","isMergeCommit":false,"messageTitle":"Implement Parser Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":136,"deletions":10}}},{"hash":"0d2d717f903269c31c1ca662023c8ce76f91caa6","isMergeCommit":true,"messageTitle":"Merge branch \u0027#16-View-Menu-Items\u0027 of https://github.com/Cazh1/tp into #16-View-Menu-Items","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b561971875675cd6dbafb42d37fd06e4bf2c8ddf","isMergeCommit":false,"messageTitle":"Implement Parser Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"9ce30642e1d1acc79672f3dcf830307d7482cf42","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"d9714d689f822fffe73a376d3954546775ceaa7d","isMergeCommit":false,"messageTitle":"Update code in reference to Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":20}}},{"hash":"71629404bad7b6184f37a4cff09948061ab74dda","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"ec3ad41cac129fdce30e4415477e1dded5257571","isMergeCommit":false,"messageTitle":"Update Duke.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":29}}},{"hash":"108544c2ee7ab0add14e4add818cec3bd9833423","isMergeCommit":false,"messageTitle":"Update code with regards to Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":47},"test-code":{"insertions":3,"deletions":3}}},{"hash":"dcb4058fbb404099fe3a75a755d95dccb55511a5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #19-Implement-Parser-Support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5f5820c74f52b67d4286d5eb18c96c705fb71c52","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"017b36204c1a5a2dfcec158d84a28b4c8f9bfd0d","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"31be1a09cca6f201e27ca77b56b7b58c660e54fb","isMergeCommit":false,"messageTitle":"Update JUnit to include assertion","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":1}}},{"hash":"0bfb9deb1c64b443917db9cf43fd1941db44c731","isMergeCommit":false,"messageTitle":"Update Parser to support ListMenuCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"2374d2890158c0441811d369ecfb121d1c23bc25","isMergeCommit":false,"messageTitle":"Update JUnit test case name to comply with standards","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-18","commitResults":[{"hash":"aa96baada7a5530ba329e33200dc264f6b09434e","isMergeCommit":false,"messageTitle":"Update code to remove use of Magic String","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":6}}},{"hash":"4d0cc8da2c44626b3abdc3baaac5f28f183e57bc","isMergeCommit":false,"messageTitle":"Update JUnit assertion use","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":27,"deletions":1}}},{"hash":"0956546fb4a59b7037ad7a3e659dc894f97ef3dc","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":4}}},{"hash":"e43dffdab7af41343dd985321360c9d9547d0ff3","isMergeCommit":false,"messageTitle":"Update MenuList appearance","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":2},"test-code":{"insertions":4,"deletions":4}}}]},{"date":"2023-10-19","commitResults":[{"hash":"b18deabd054b19780e3d5cc6eac3fe1e541643d1","isMergeCommit":false,"messageTitle":"Update code to comply Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-22","commitResults":[{"hash":"b1aac1c4b0473c620dcb918ceb878ab12757384a","isMergeCommit":false,"messageTitle":"Add method for empty menu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":2}}},{"hash":"69168a3d641267d405a4019bcbade582689e8d5f","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"927b64d77278cb15a7b0f986d7719a29bb655771","isMergeCommit":false,"messageTitle":"Update JUnit for ListMenu","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":18,"deletions":8}}},{"hash":"c2c3c5c523442a2120fd42ec4c0403a3c32892d5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Edit-List_Menu-appearance","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fffd1c462fa1ec1f8c4f210824670563c458d26e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Edit-List_Menu-appearance","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"65510e0cc0896dd9dbb314673257289143d76e40","isMergeCommit":false,"messageTitle":"Update ListMenu to use Messages.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":1}}},{"hash":"bf9bd2b8a6eb33b17431bede88dc2a51f58c49c1","isMergeCommit":false,"messageTitle":"Add Order Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":0}}}]},{"date":"2023-10-23","commitResults":[{"hash":"6d2ba2ce36b19daf8b6baf44842569ee9ec923a8","isMergeCommit":false,"messageTitle":"Add parser support for Order","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":140,"deletions":0}}},{"hash":"999da2ca70324fe354af44f98cc2ae9e7ced7169","isMergeCommit":false,"messageTitle":"Add toString() in Order.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"28b5c10ffbd796984f446a32ede19d8e69f7f173","isMergeCommit":true,"messageTitle":"Merge branch \u0027#82-Create-Order-Class\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ce93be786fd23cac0983576e9654e2976dca38e8","isMergeCommit":false,"messageTitle":"Update Messages with UI support for Order","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"277d6b480ea0d5ac28fd0572edfbdec3194bf2d6","isMergeCommit":true,"messageTitle":"Merge branch \u0027#84-Implement-UI-support-for-Order-class\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cabad889ab555b6563a97a75e0075e5911d512ea","isMergeCommit":false,"messageTitle":"Create OrderList.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":0}}},{"hash":"9741101389b74a91575214cfd166abff8b62a3a3","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"c184350348434e9d36140d1010ef592d6f98e4d2","isMergeCommit":false,"messageTitle":"Add JavaDoc for Order in Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":44}}},{"hash":"5032b6d32f31a70c2ffd8d85f6c01c4e9f7ea5a1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"974c5c0d82e8a75ac4fe1e985f5eb03bc49923d1","isMergeCommit":false,"messageTitle":"Update ListMenu Code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-24","commitResults":[{"hash":"5d2c79ac86b449d58c9ee372a58864601722bcb3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bfa0891e46c52dcfb3c301d159915bc0d5fcfaf7","isMergeCommit":false,"messageTitle":"Create Chef class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":0}}},{"hash":"a35e40f8136d9c95a5ec2e100a5e930cfc86c5a5","isMergeCommit":false,"messageTitle":"Update AddOrderCommand to use Chef","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":11}}},{"hash":"b22019ca7fff561c382049fc14d97e3174b353a0","isMergeCommit":false,"messageTitle":"Update Order class code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":15}}},{"hash":"affdce44fc86bf9850ec750265f3c3a5e337c750","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"a32a17b831d014945885eacea84b3b14e41c587a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #84-Implement-UI-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"05a92d6223524f43e6e233ea103bd4c4742442dc","isMergeCommit":false,"messageTitle":"Update code to comply with gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"70f16480d5975e0778f245142b7b2819e97a9849","isMergeCommit":false,"messageTitle":"Update Chef class to use Ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4}}},{"hash":"29da53f5b545c4b0ce50154ee2b0dd676b8e8b13","isMergeCommit":false,"messageTitle":"Update code to alter execute method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":127,"deletions":94},"test-code":{"insertions":56,"deletions":42}}},{"hash":"9977e9dbef1cb6980d68e58c14a5fd40a843a711","isMergeCommit":false,"messageTitle":"Update Chef.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":3}}},{"hash":"4e383c745f760820f608f5509bff260a73a88718","isMergeCommit":false,"messageTitle":"Update code with regards to review","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":64,"deletions":66},"test-code":{"insertions":1,"deletions":1}}},{"hash":"768f13442c347a6f40bd991777a4e0c2bdd06976","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #86-Implement-Parser-support","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"22eb421484549850d736ee67ec13c8c1a0de2688","isMergeCommit":false,"messageTitle":"Update Parser to resolve merge conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":2}}},{"hash":"15c038f646a5c0fcec0477ea8cb18b0114c0adfb","isMergeCommit":false,"messageTitle":"Update code to resolve merge conlfict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":6}}},{"hash":"9312315cae7e2625181586376372c22a480bb2b7","isMergeCommit":false,"messageTitle":"Update OrderList.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"ceff204fb713b24ead6620309da5c78f723c3a84","isMergeCommit":false,"messageTitle":"Add Parser support for OrderList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":6},"test-code":{"insertions":27,"deletions":13}}},{"hash":"3e8c796c16b4712623dafe9873a59df8de4ba070","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #107-Change-Command-Class-execute-method","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"42cb0cbf4ee8df6366b64d35e2543834a136bc21","isMergeCommit":false,"messageTitle":"Update code to resolve conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":114,"deletions":90},"test-code":{"insertions":20,"deletions":29}}},{"hash":"f6a67ab891e824d91f90bed8ff5c232c6ad3a451","isMergeCommit":false,"messageTitle":"Update Ui support for Order","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"9f28786d5e63b99b79138746e32c8356b59d4c77","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"d9e8b98a6aa48f3c4d8ff72e80cae61a7f2f6b10","isMergeCommit":false,"messageTitle":"Update Ui support for Chef","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}}]},{"date":"2023-10-26","commitResults":[{"hash":"c3f3597d326961fb2052c775c154fb67f8155481","isMergeCommit":false,"messageTitle":"Update DG for list_menu feature","messageBody":"Fixes #128\n","fileTypesAndContributionMap":{"docs":{"insertions":207,"deletions":0}}}]},{"date":"2023-10-27","commitResults":[{"hash":"79b51513fb2c6566b320cfc034f9d8652f5b30bd","isMergeCommit":false,"messageTitle":"Refactor ListMenu Command process","messageBody":"Fixes #130\n","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":11}}},{"hash":"88340a9be72cd5c73c3c74676d60b742de979b9c","isMergeCommit":false,"messageTitle":"Update DG after refactor","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":37,"deletions":38}}},{"hash":"6b4144af4e10585f41be34b845ccacd39a1aa90c","isMergeCommit":false,"messageTitle":"Refactor Order Class","messageBody":"Fixes #132\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":7}}},{"hash":"abae31307b2929a857db60da6ec5ebac18ffab15","isMergeCommit":false,"messageTitle":"Update ListMenuCommand to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"4844849403ba995597fe64295b0ffd26474d6d07","isMergeCommit":false,"messageTitle":"Update JUnit for ListMenuCommand","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":25,"deletions":0}}},{"hash":"5b66a0bdb9d519577cf7a5ace93d9af934d4ceec","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest to comply Gradle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"029346035f6cdc1e41be5898afcea6452d0e1df2","isMergeCommit":false,"messageTitle":"Update DG after refactor","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":3}}},{"hash":"56566297c9b81e559daf5b81b9fd07198109801b","isMergeCommit":false,"messageTitle":"Implement JUnit for AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":1},"test-code":{"insertions":136,"deletions":0}}},{"hash":"d745b59046f0a41bbf4f55a27a6f6078d6c13c40","isMergeCommit":false,"messageTitle":"Update code to comply with Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":8,"deletions":7}}},{"hash":"287d3f7f2d589db16f9b3026cd28661587e53b81","isMergeCommit":false,"messageTitle":"Update AddOrderCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":3}}},{"hash":"c5a094acfe56c03ef4a9962ffb0b88ae9359a3ba","isMergeCommit":false,"messageTitle":"Update AddOrderCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":13,"deletions":1}}},{"hash":"32025f87af667fe81815c327984f6b4ce357822c","isMergeCommit":false,"messageTitle":"Update Pantry.java for AddOrderCommand JUnit","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"eb38d96a39f2153008a6a0a0e3247fe794451924","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/#132-Refactor-Order-Class\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e7a9e42d83b1befbaadd915c827d487fa6bddbc0","isMergeCommit":false,"messageTitle":"Update ListMenuCommandTest with regards to review","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":8}}},{"hash":"a72b6f9dd133c9cead596c517d45b027129f7798","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"f0bc3aa9956d207f2b05dec0f9fbc9ce8ffd3a4f","isMergeCommit":false,"messageTitle":"Implement MultiDay support","messageBody":"Ability to store orders across days\n","fileTypesAndContributionMap":{"functional-code":{"insertions":339,"deletions":50},"other":{"insertions":4,"deletions":4},"test-code":{"insertions":8,"deletions":9}}},{"hash":"34f14811368ad1853189a555302dbc432fe432ae","isMergeCommit":false,"messageTitle":"Refactor CurrentDate and Sales","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":9},"other":{"insertions":2,"deletions":2}}},{"hash":"5a03a113a3dc747c0fbe57a842bb62f4a1a749b5","isMergeCommit":false,"messageTitle":"Add totalSale in the Sales","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":2}}},{"hash":"70a30d4fcf7aeafd185cd8999301c92aad6bb81f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"45ef83c9737a9ab4cb95c4e15cf8c7ae06b68f14","isMergeCommit":false,"messageTitle":"Update code to resolve merge conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":6},"test-code":{"insertions":2,"deletions":0}}}]},{"date":"2023-10-30","commitResults":[{"hash":"c832dba849812c868cbcdaf162ba21de8bbbb6f6","isMergeCommit":false,"messageTitle":"Refactor Sales to be inside Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":152}}},{"hash":"34149e8ff935871f2ae039b60c34905f222ac9ab","isMergeCommit":false,"messageTitle":"Add JavaDoc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":0}}},{"hash":"5788286a3a57962099261c8009fb1d6edd8805e3","isMergeCommit":false,"messageTitle":"Update ParserTest after changes to Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":60,"deletions":42}}},{"hash":"b03e4895a0945479851eb7582843c5ee9e96c677","isMergeCommit":false,"messageTitle":"Update AddOrderCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":2}}},{"hash":"20dca7e9e3d0e02bdb4847ca7ace65e71cc93b5d","isMergeCommit":false,"messageTitle":"Update CafeCtrl.java to remove unused import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"91d87a0c1068d996643d6ba82e46dd621e383a8a","isMergeCommit":false,"messageTitle":"Update CafeCtrl.java to remove unused import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"c6c139f4a50660a2c9212623a2d2930262ac948f","isMergeCommit":false,"messageTitle":"Remove extra empty line","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"e4657bd5e9bf1799dddc317a739adadd32d88759","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #85-Implement-Multiple-day-support-for-Order-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b71c0700f0f6ef866810a2d1f7ecb7dec8474f3c","isMergeCommit":false,"messageTitle":"Refactor folder for UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":108,"deletions":56}}},{"hash":"a66509ed92b81a12ffd29d754d72c7b8b3a0a9f5","isMergeCommit":false,"messageTitle":"Update code to be more OOP","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":28}}},{"hash":"0ed5896c725fd7e30876675ea72d1cd1be95d5e5","isMergeCommit":false,"messageTitle":"Add Class Diagram for Add Order","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":89,"deletions":0}}},{"hash":"3afca99679fa53c4f386dc81f7da70627aecd5c1","isMergeCommit":false,"messageTitle":"Update UG for NextDayCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4},"docs":{"insertions":109,"deletions":0}}},{"hash":"d57f47ad43d874d8cc133cb53a8a3aa38f527fd5","isMergeCommit":false,"messageTitle":"Update UG for PreviousDayCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":76,"deletions":0}}},{"hash":"88792021c4fde7340348727adf0f22fe01092080","isMergeCommit":false,"messageTitle":"Update UG of AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":1}}}]},{"date":"2023-10-31","commitResults":[{"hash":"99d0527aec4844a0a74d2cdb765e0e9e9d775722","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8ad5d02aef54b2386bf8d53ef5d8364c023c4fc3","isMergeCommit":false,"messageTitle":"Update DG for AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":4}}}]},{"date":"2023-11-01","commitResults":[{"hash":"d1f8b555054498d46b567383bf43a5dc784de808","isMergeCommit":false,"messageTitle":"Update DG for AddOrderCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"docs":{"insertions":12,"deletions":6}}},{"hash":"d8664afaeac13bb2dbb8efea97d47686a4eab695","isMergeCommit":false,"messageTitle":"Update DG for PreviousDayCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":3}}},{"hash":"a7a538774768d43233ab200e650d0ae79f0d376d","isMergeCommit":false,"messageTitle":"Update DG for NextDayCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"0702ccebdb16f751dbe6df6f7542d27cd8e76372","isMergeCommit":false,"messageTitle":"Update DG for ListMenuCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"docs":{"insertions":4,"deletions":4}}},{"hash":"0c67b9bb96636bb1da3821ce6885d40cf402b941","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":42,"deletions":1}}},{"hash":"2a9eceb42d56a25f7198e208010e046a2055fda1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f907eeb625402a37f40a34bbcc913301ceaf5f25","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0a0fb00388a52824d84c2266eded180e62f9b68c","isMergeCommit":false,"messageTitle":"Fix bug for AddOrderCommandTest","messageBody":"Fixes #200\n","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":6},"test-code":{"insertions":181,"deletions":149}}},{"hash":"9c7f19cc801aa35c7a02127bf9c0df49f0f3a17c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into #159-Update-DG-with-Multi-day-Order-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0c3c380b9690720c963ab432ab353a7ac9d4b4b8","isMergeCommit":false,"messageTitle":"Update DG with regards to Code changes","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":16}}},{"hash":"66a5a7e1e441a1708cb1ff60cb91b9dd72c9c06b","isMergeCommit":false,"messageTitle":"Update UG for Add Order","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":31,"deletions":1}}},{"hash":"475695469d6d0f6ea45a1e3d0964cfa91331783e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Update-UG-for-Add-Order","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b1478c142f31ed934d6ab101f9425ce6d8e44b76","isMergeCommit":false,"messageTitle":"Bug Fix","messageBody":"Fixes #211\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"7a4e3f3d1c1172a05f3bed4f9cac12422c03700d","isMergeCommit":false,"messageTitle":"Update Code Quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3},"docs":{"insertions":2,"deletions":2}}}]},{"date":"2023-11-04","commitResults":[{"hash":"7f4dd929f6e8a9ee5cea61e49967063d1cb99a22","isMergeCommit":false,"messageTitle":"Update code to maintain menu form","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}}]},{"date":"2023-11-05","commitResults":[{"hash":"ec350a66c103d9a7aa2a32e444c8fb6b4e81a38a","isMergeCommit":false,"messageTitle":"Update Message to remove inconsistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"6858fddcbfbc441ca33b452235c821b9d0e7de0e","isMergeCommit":false,"messageTitle":"Update code to bring user back to latest date accessed","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":1}}}]}],"ziyi105":[{"date":"2023-10-05","commitResults":[{"hash":"ce55b55eeedfddf78b8dcd41a589ab3097fc943f","isMergeCommit":false,"messageTitle":"Update AboutUs.md with Ziyi\u0027s name and github","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"0a4dab6d434c8f1fce06a3b938c558a2f24cba82","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9ac70fde66fd83d921866a9b4555dd6d59d78e7c","isMergeCommit":true,"messageTitle":"Merge pull request #4 from ziyi105/master","messageBody":"Update AboutUs.md with Ziyi\u0027s name and github","fileTypesAndContributionMap":{}},{"hash":"db3be0d4dbc95092f2a772ee485cf24139f4a960","isMergeCommit":false,"messageTitle":"Update Ziyi\u0027s photo on AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"4c760d59203dc1a28a8eb86763ea3e80f6a71ff2","isMergeCommit":true,"messageTitle":"Merge pull request #6 from ziyi105/master","messageBody":"Update Ziyi\u0027s photo on AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"a58bed14f14de4d92994e46cc136783aba7fd4c3","isMergeCommit":false,"messageTitle":"Add Parser.java","messageBody":"fixes #8\n","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}},{"hash":"5ddffe229dba287cf4773bad97938c3b6659e9ef","isMergeCommit":false,"messageTitle":"Parser.java: move from package Parser to seedu.duke.parser","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"b806594dfa85c2c71007f457c46139694b196274","isMergeCommit":false,"messageTitle":"Add ParserTest.java","messageBody":"fixes #12\n","fileTypesAndContributionMap":{"test-code":{"insertions":7,"deletions":0}}},{"hash":"74d345ea8d7fd35e7906b35ae7c5dea5124d0f2f","isMergeCommit":false,"messageTitle":"ParserTest.java: remove wild card import","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}}]},{"date":"2023-10-15","commitResults":[{"hash":"72f47e36ee6fc50c291c3ba56995c48ca4d7adec","isMergeCommit":false,"messageTitle":"ParserTest.java: add a new line at the end of the file","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"ce21b499b97b8604e902d81c2ffc5d2e5e3dbda1","isMergeCommit":false,"messageTitle":"Add Menu.java, Dish.java, Ingredient.java and their test classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0},"test-code":{"insertions":21,"deletions":0}}},{"hash":"6cd980d30ffc7269100b0e144deb704624108ba4","isMergeCommit":false,"messageTitle":"Add Menu.java","messageBody":"fixes 31\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":13}}},{"hash":"9de4ee60d69353f1d1e32b5a60b5b27991d8219c","isMergeCommit":false,"messageTitle":"Revert \"Add Menu.java\"","messageBody":"This reverts commit 6cd980d30ffc7269100b0e144deb704624108ba4.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":0}}},{"hash":"79afe5da305b841bf11d7be35b464cbfc2ad8134","isMergeCommit":false,"messageTitle":"Dish.java: change price type double to float","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e5534107d88a9f49f4eaa864f24622948c9dc773","isMergeCommit":false,"messageTitle":"ParserTest.java: add javadoc to the class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":0}}}]},{"date":"2023-10-16","commitResults":[{"hash":"2600dcb46108a997b4c7366401b3fd7bcb2b8e44","isMergeCommit":true,"messageTitle":"Merge pull request #42 from Cazh1/master","messageBody":"Update attributes and methods in Command class","fileTypesAndContributionMap":{}},{"hash":"bf1325d50b3a48da0fd72c5ab665f452d4d4f919","isMergeCommit":true,"messageTitle":"Merge pull request #44 from DextheChik3n/edit-classes-v1.0","messageBody":"Edit classes v1.0","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"f079f9950ec7a31a8ce26b0cf50c5a7507d3dd6f","isMergeCommit":false,"messageTitle":"Implement parseCommand() method according to AddressbookLevel2","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0}}},{"hash":"0852e29a9ee8563ff84a34e75b5b0efd5b342e09","isMergeCommit":false,"messageTitle":"Implement ui support for edit price feature","messageBody":"fixes #14\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"0dcf6106d09cef97c0c807f356e3a62be9043b33","isMergeCommit":false,"messageTitle":"Dish.java: add setter for price","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"b67df48ceadf6e7b7d4972f4ab094428396d9293","isMergeCommit":false,"messageTitle":"Create EditPriceCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":0}}},{"hash":"db9131da26048c68ee531e9cf035c0a3045ffa72","isMergeCommit":true,"messageTitle":"Merge pull request #46 from DextheChik3n/43-add-items-v1.0","messageBody":"Implement add dish feature","fileTypesAndContributionMap":{}},{"hash":"c88d9091f99c7c1c13c815b1a926dec91d729117","isMergeCommit":false,"messageTitle":"Parser.java: add parserCommand() method and incomplete prepareEditPriceCommand()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":0}}},{"hash":"38e05b78ff2369a7299c9de1a6c53cfa8560537d","isMergeCommit":false,"messageTitle":"Add constant COMMAND_WORD in executable command classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}},{"hash":"2743a171159dc3e00cc9bf9134802df91516a91c","isMergeCommit":false,"messageTitle":"Declare COMMAND_ARGUMENT_STRING for compiling patterns","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":7}}},{"hash":"fc0ae7663b7c245853f11061b2d7d0531b378f6c","isMergeCommit":false,"messageTitle":"Implement parseCommand with pattern and matcher","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":2}}},{"hash":"87643e1fff76ea1ff58a72c59069501ea1ad8d5d","isMergeCommit":false,"messageTitle":"Parser.java: design the overall structure of different prepareCommands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":10}}},{"hash":"687f3a97f09b7b76fdc37f1647fe310d852dbcaa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into use-pattern-and-matcher-in-parser","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a4588d6428a667606b73729fc4d7b171b814bc0e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into use-pattern-and-matcher-in-parser","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"76f879d8556fefdcdd8426b7ce96f08e9661dcf8","isMergeCommit":false,"messageTitle":"Parser.java: remove argument when creating DeleteDishCommand and ListIngredientCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"3166afc463ac1cf0c36a3c0f02025286408336a9","isMergeCommit":false,"messageTitle":"Parser.java: pass arguments to prepareListIngredient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"4e07571336b93f76098b442a3b7818cc3de7638f","isMergeCommit":false,"messageTitle":"Update ListIngredientCommand.java with constructor that takes in listIndex","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"972c84e4f91f7e6184b2071370f7ce136e27da80","isMergeCommit":false,"messageTitle":"Update Parser.java with correct coding standard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"17930caaedda6b70d54027eabb2b45b299f3429f","isMergeCommit":false,"messageTitle":"Parser.java: split ADD_COMMAND_ARGUMENTS correctly","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"2f877b3b7908caaa0fa8feec1de4bf94936aa508","isMergeCommit":false,"messageTitle":"Parser.java: update ADD_PATTERN to ADD_ARGUMENT_PATTERN","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"fe4ae667b55c28acbef1156b7576731def556694","isMergeCommit":false,"messageTitle":"Parser.java: correct indentation at line 129","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"306797c8dc6fbccf4d7d8ffd573f27301af152d7","isMergeCommit":true,"messageTitle":"Merge branch \u002711-feature-edit-price-v1.0\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"f9822a12af4e06828b3f5dcd72ba6019bfa22186","isMergeCommit":true,"messageTitle":"Merge pull request #57 from DextheChik3n/38-edit-main-class-v1.0","messageBody":"38 edit main class v1.0","fileTypesAndContributionMap":{}},{"hash":"3b01a433e7853ceea15ec017094e14628381c8f6","isMergeCommit":false,"messageTitle":"EditPriceCommand.java: update edit price to edit_price","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"20abc84278a6421e5be06493cdb0619b4103f6f4","isMergeCommit":false,"messageTitle":"Implement parser support for edit_price feature","messageBody":"fixes #13\n","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":6}}},{"hash":"b7b6c987b205a69bc9bfda9bf6b6bb62604a065e","isMergeCommit":false,"messageTitle":"Dish.java: add toString method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"e4a58f40bd283404e96d922aee5bbf1b9c0c7f1b","isMergeCommit":false,"messageTitle":"Ui.java: make showToUser and showEditPriceMessage static","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"d87ddca7b459be077d396635d101e07b267a5036","isMergeCommit":false,"messageTitle":"EditPriceCommand.java: show message after execute","messageBody":"Fixes #14\n","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":1}}},{"hash":"31aec2fa86642f1dc57bcb132c4afd5b60260c6f","isMergeCommit":false,"messageTitle":"Ui.java: add javadoc for showEditPriceMessage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":1}}},{"hash":"a1926699bd7da67ea47b9daa1148860d14cbb2ab","isMergeCommit":false,"messageTitle":"Parser.java: rename ADD_ARGUMENT_STRING and EDIT_DISH_ARGUMENT to camelCase","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":6}}}]},{"date":"2023-10-18","commitResults":[{"hash":"569e182e90d0a3efd3d9e2b08b848914b93e03d0","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/master\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/command/EditPriceCommand.java\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"e991c9db72a04d04051bbd6fef381a324a2f7b05","isMergeCommit":false,"messageTitle":"Parser.java: remove wildcard import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":1}}},{"hash":"d3f5e998de9b97220a2fb1c5de9e42ed1565e310","isMergeCommit":false,"messageTitle":"Parser.java: remove duplicated import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"e7bb131f1de78bf89df8036169b194cca157557d","isMergeCommit":true,"messageTitle":"Merge pull request #60 from Cazh1/master","messageBody":"Update code quality","fileTypesAndContributionMap":{}},{"hash":"4aef10a1aaade726ea889271653dc5f2a7fe17f2","isMergeCommit":true,"messageTitle":"Merge pull request #58 from ShaniceTang/55-deletecommand-junit-test","messageBody":"Task 55, Add JUnit test for Delete Command","fileTypesAndContributionMap":{}},{"hash":"4075a3361550a84ae8b24e23fec324f9db30502c","isMergeCommit":false,"messageTitle":"Menu.java: add isValidDishIndex method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"721151f928162dceba3584c0bd568cef7596a74d","isMergeCommit":false,"messageTitle":"Parser.java: remove catch block for IndexOutOfBoundsException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":11}}},{"hash":"cf6e6994cea30240729079377b6b68476dcfe433","isMergeCommit":true,"messageTitle":"Merge pull request #62 from NaychiMin/56-Junit-test-for-list-ingredient.v1.0","messageBody":"Task 56, Add junit test for List Ingredient command.","fileTypesAndContributionMap":{}},{"hash":"6e6f539c96aa5844eb403591beb81a723bf06059","isMergeCommit":true,"messageTitle":"Merge branch \u002711-feature-edit-price-v1.0\u0027 into ziyi105-11-feature-edit-price-v1.0","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/command/EditPriceCommand.java\n#\tsrc/main/java/seedu/cafectrl/data/Menu.java\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"d8fd274670ac311f83fcb2090492a94c62379017","isMergeCommit":false,"messageTitle":"Ui.java: remove static from showToUser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"edf108043148d24277cf8430c989201972ec2c45","isMergeCommit":false,"messageTitle":"Improve code quality with gradlew","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"d128fc7c9682256fea60137e194f239e52521613","isMergeCommit":false,"messageTitle":"Messages.java: update position of plus operator for strings","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":6}}},{"hash":"bd4181f11168d9c3e1b34bf16a0f7efa37f68418","isMergeCommit":false,"messageTitle":"Parser.java: update position of plus operator","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"defbb3e75f20842edf6faa71e54688a3367ed1d6","isMergeCommit":false,"messageTitle":"Messages.java: Update position of plus operator for MISSING_ARGUMENT_FOR_EDIT_PRICE","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"e7ca9e70c6a75d581ac6d8fa41cf173be97da596","isMergeCommit":false,"messageTitle":"Parser.java: replace matcher.matches() with matcher.find() in line 96","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"54e6c789b799b86d458d6a74ee4d57e8362a1fa2","isMergeCommit":false,"messageTitle":"EditPriceCommand.java: minus offset for menuID","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"908e1da4fe7c6f257b299d05d81fc277440ff8cc","isMergeCommit":false,"messageTitle":"EditPriceCommandTest.ava: add JUnit test for valid input","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2},"test-code":{"insertions":42,"deletions":0}}},{"hash":"7f6ae576969e353434ae08a9b55ead58169bb6f0","isMergeCommit":false,"messageTitle":"ParserTest.java: add JUnit test for parseCommand_unrecognisedInput_unknownCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":2},"test-code":{"insertions":32,"deletions":0}}},{"hash":"b4ae9501b1c0bad09222f0d0d90da681de3da7a0","isMergeCommit":true,"messageTitle":"Merge pull request #66 from DextheChik3n/24-parser-add-dish-v1.0","messageBody":"24 parser add dish v1.0","fileTypesAndContributionMap":{}},{"hash":"a20cbd574d66169d6c7098cc9edeffbadefbf04d","isMergeCommit":false,"messageTitle":"ParserTest.java: add JUnit test for possible user inputs for edit_price command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":2}}},{"hash":"9f593575dd7db9e268f6508508d3a7bb12de40e3","isMergeCommit":true,"messageTitle":"Merge pull request #69 from DextheChik3n/48-add-junit-add-dish-command-class-v1.0","messageBody":"48 add junit add dish command class v1.0","fileTypesAndContributionMap":{}},{"hash":"b47e636e131f0a3984ee2cbd5fb2d149ff029dab","isMergeCommit":true,"messageTitle":"Merge pull request #72 from DextheChik3n/67-junit-test-for-add-dish-v1.0","messageBody":"Added JUnit Tests for add dish command parsing","fileTypesAndContributionMap":{}},{"hash":"e677079202361a2f65f201103b146ae13c1a143b","isMergeCommit":true,"messageTitle":"Merge pull request #76 from DextheChik3n/74-resolve-negative-price-input-v1.0","messageBody":"Edit add dish parsing code to prevent negative price input","tags":["A-Release-v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-22","commitResults":[{"hash":"96882eb9101008776de82b957a9ae270e0af3bff","isMergeCommit":true,"messageTitle":"Merge pull request #80 from ShaniceTang/78-combine-messages","messageBody":"Task 78, Add UserOutput enumeration messages to Message class","fileTypesAndContributionMap":{}},{"hash":"06fb6a449152d4bbcb83c66a33ea8e1f5fce6457","isMergeCommit":true,"messageTitle":"Merge pull request #81 from Cazh1/Edit-List_Menu-appearance","messageBody":"Edit list menu appearance","fileTypesAndContributionMap":{}},{"hash":"793446992cc666d6865910f66025374082ad37d9","isMergeCommit":false,"messageTitle":"Ui.java: rename showToUerFormat to formatListMenu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"cec3c524bbd1d3ef76e0e833435fef721827d145","isMergeCommit":false,"messageTitle":"Implement help command","messageBody":"fixes #73\n","fileTypesAndContributionMap":{"functional-code":{"insertions":70,"deletions":31},"test-code":{"insertions":1,"deletions":1}}},{"hash":"cfe46d6d3284681a80fa99ef46fbc4f4c0c2963c","isMergeCommit":false,"messageTitle":"Complete messages for help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":5}}},{"hash":"494813d67cce020f13b6bf14eaa9268b838fbbde","isMergeCommit":false,"messageTitle":"Ui.java: add method showToUserWithSpaceBetweenLines for showHelp()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":2}}},{"hash":"56fbe7c76d7c928a696fb1a31922f88a13947a25","isMergeCommit":false,"messageTitle":"Add JUnit test for HelpCommand (incomplete)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":37,"deletions":0}}},{"hash":"b6f15b18161b307a88ec6e2cb43f496e908bfcba","isMergeCommit":false,"messageTitle":"HelpCommandtest.java: improve code quality","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":4}}},{"hash":"318b4e7f859ad0a4f8b4fff81731e5472fad9a08","isMergeCommit":true,"messageTitle":"Merge pull request #97 from DextheChik3n/77-enable-assertions-v1.1","messageBody":"77 enable assertions v1.1","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"37a70ddcb2b047143d26d65a8cb7dfb94cf64716","isMergeCommit":false,"messageTitle":"Move LINE_STRING from Ui.java to Messages.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"756e97ebc15c91ca89be53688609d5a60b6ec466","isMergeCommit":false,"messageTitle":"Complete helpCommandTest for execute","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":21,"deletions":4}}},{"hash":"44b84aacf3a7c12558a9a63902a1e97604c0c0d7","isMergeCommit":false,"messageTitle":"ListMenuCommand.java: add space around operator","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"efdc7cab49f6c35295221cee69a79ca1e4ef76e1","isMergeCommit":false,"messageTitle":"Parser.java: update formatting of single line comment","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"2cd77bfba70bf778f72bcde41df599c94a610cc2","isMergeCommit":false,"messageTitle":"Messages.java: update string spliting indentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"0ecc4dec59a6571cb3dfea65183a6d88157d5a39","isMergeCommit":true,"messageTitle":"Merge pull request #103 from DextheChik3n/102-add-dish-exception-handling-v1.1","messageBody":"102 AddDish Command exception handling v1.1","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"f131f3098fc876525832b3fcbd5bcd962f506755","isMergeCommit":true,"messageTitle":"Merge pull request #95 from ShaniceTang/90-91-implement-pantry-class","messageBody":"Task 90 and Task 91 Implement View Total Stock and Buy Ingredients","fileTypesAndContributionMap":{}},{"hash":"f0a24cc9c932148cdae5eeac35c617b2553594c9","isMergeCommit":true,"messageTitle":"Merge pull request #96 from NaychiMin/implement-low-stock","messageBody":"Task 92, Task 93 Implement stock checking of ingredients in Pantry class","fileTypesAndContributionMap":{}},{"hash":"0ef8819a85677bad5ef007538da629f078230bb6","isMergeCommit":true,"messageTitle":"Merge pull request #106 from Cazh1/#86-Implement-Parser-support","messageBody":"#86 Implement parser support for addOrder command","fileTypesAndContributionMap":{}},{"hash":"0e41f3d102afc76c03d8897e5bf4785aa1cb3990","isMergeCommit":false,"messageTitle":"Add DG for how parser parse command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":1}}},{"hash":"2a56a3509b1546802275085a1e58cfd8678ee2ad","isMergeCommit":false,"messageTitle":"Edit formatting of DeveloperGuide.md for Parser","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":9}}},{"hash":"f3efe12eb9d02b02b41179c689888b6aa472ab77","isMergeCommit":false,"messageTitle":"Add UML for EditPriceCommand execute method","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":0}}},{"hash":"04ac7375b6e5e7bcd5e7736ee1b9e93449547986","isMergeCommit":false,"messageTitle":"Add DG for edit price feature","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":0}}},{"hash":"8e8d9daf3c5849ce51268e256a71da41d61614b1","isMergeCommit":false,"messageTitle":"Add description for edit_price feature in DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":2}}}]},{"date":"2023-10-25","commitResults":[{"hash":"c876030a1267e79016085c1705e9dbfefdac002e","isMergeCommit":false,"messageTitle":"EditPriceCommand_execute.puml: include parameter type","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"f901af8c281e088afc7adfed87e3c657151f8267","isMergeCommit":false,"messageTitle":"Update Parser.puml with parameter type","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"147db2d52616ab5e56d8a9ffc06f822bd13b6f8c","isMergeCommit":false,"messageTitle":"Update Parser and editPriceCommand_execute UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"55a5805dd6df74abbb2bb7c254a638c7958c481c","isMergeCommit":true,"messageTitle":"Merge branch \u0027111-DG-parser\u0027 into DG-merge-conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"57e73e5992156ef76ddbbd15084af051e2c8bb39","isMergeCommit":true,"messageTitle":"Merge pull request #113 from ziyi105/111-DG-parser","messageBody":"Update DG for Parser and edit_price","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"dd5c5d6ea7099cc2514e52438a6de53d6d615e6e","isMergeCommit":true,"messageTitle":"Merge pull request #125 from DextheChik3n/117-DG-add-dish","messageBody":"117 developer guide: add dish","fileTypesAndContributionMap":{}},{"hash":"b651a3fdc315a636a7be69985c33880c66073b88","isMergeCommit":true,"messageTitle":"Merge pull request #124 from DextheChik3n/123-refactor-add-dish-v1.2","messageBody":"123 refactor add dish v1.2","fileTypesAndContributionMap":{}},{"hash":"9790239580356a28e53a7b1132c78dab9a8d6bd2","isMergeCommit":true,"messageTitle":"Merge pull request #133 from Cazh1/#132-Refactor-Order-Class","messageBody":"132 Refactor Order Class","fileTypesAndContributionMap":{}},{"hash":"a3bfd53e20c8482a1dede926ce3511b05dd5f231","isMergeCommit":true,"messageTitle":"Merge pull request #134 from Cazh1/#83-Add-JUnit-Test-for-Order-class","messageBody":"#83 add JUnit test for order class","fileTypesAndContributionMap":{}},{"hash":"f9925f2bf0351a95ec21b48789c4c6868319f745","isMergeCommit":true,"messageTitle":"Merge pull request #137 from Cazh1/130-Refactor-ListMenu-Command-process","messageBody":"Update ListMenuCommandTest with regards to review","fileTypesAndContributionMap":{}},{"hash":"a993819f1789b67348c69074dcfd2093fa32550c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 135-create-storage-parent-class-v2.0","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ad5fa6ce9dde0555128323479745530ba8980c47","isMergeCommit":true,"messageTitle":"Merge pull request #136 from DextheChik3n/135-create-storage-parent-class-v2.0","messageBody":"135 create storage parent class v2.0","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"a05446d86bafd9f552939ea0cb92ab49eedb20d9","isMergeCommit":true,"messageTitle":"Merge pull request #141 from DextheChik3n/138-fix-add-dish-command-bugs-v2.0","messageBody":"138 fix add dish command bugs v2.0","fileTypesAndContributionMap":{}},{"hash":"59850307c55d41d9b21c28fa95dd377c7a095c45","isMergeCommit":false,"messageTitle":"Add Decoder.java and Encoder.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":103,"deletions":0}}},{"hash":"be88ba168065a14b68ad07c595d96889faa7be8f","isMergeCommit":false,"messageTitle":"Add FileManager.java and move relevant methods from Storage to there","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":154,"deletions":165}}},{"hash":"6e22e140757e7c85c0bb69d744c3bcc4d975d638","isMergeCommit":false,"messageTitle":"Pantry.java: remove unused methods related to storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":19}}},{"hash":"4ee74bb5029bde5542a27876363d51958ff05b66","isMergeCommit":false,"messageTitle":"Refactor CafeCtrl to use the new storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":26}}},{"hash":"52b8d168fb68bba71af3237dfb06931f12468c7f","isMergeCommit":false,"messageTitle":"Move pantry.writeToPantry storage from ExitCommand.java to run() in CafeCtrl","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"fd122345e20957b8be59dd498b82a94072c811b9","isMergeCommit":false,"messageTitle":"Pantry.java: create a constructor with ui as param","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"bede707287c62189fc34f96108917d752da2611d","isMergeCommit":false,"messageTitle":"Add author and update code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":9}}},{"hash":"a267e8a023f8a988fbca090bc35f0112fcf101cb","isMergeCommit":false,"messageTitle":"Modify expected io test file and related classes to ignore error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"e917e241833c49959daf67a6c0dab67e864a4845","isMergeCommit":false,"messageTitle":"Storage.java: remove unused import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"b96e7f50f9e3542024be8542c6ac5b6da503e642","isMergeCommit":false,"messageTitle":"Storage.java: add author","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"ceaf0dd8aed2f375b3c587fe1f25ed42f8aef6f7","isMergeCommit":false,"messageTitle":"Add Javadoc comments in FileManager and Storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":5}}}]},{"date":"2023-10-29","commitResults":[{"hash":"0633d5e927d22d0618c6427aca12cabf5316411f","isMergeCommit":false,"messageTitle":"Encoder.java: add encodePantryStock method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":1}}}]},{"date":"2023-10-30","commitResults":[{"hash":"979613151ef041f0a5f8177e83c6ba7c0d429601","isMergeCommit":false,"messageTitle":"Encoder.java: modify the encodePantryStock method to encode the ingredient with space in between attributes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"9de19f24186d2236113c837193dab90fe42bd921","isMergeCommit":false,"messageTitle":"Move all error messages to one class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":58,"deletions":52},"test-code":{"insertions":10,"deletions":10}}},{"hash":"855ca78a90af72f7bb1142eb031b36ee25a0a0de","isMergeCommit":false,"messageTitle":"Add line between methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"b14ef3a2eec5d2b5204244fa70fe4535a8d53dff","isMergeCommit":false,"messageTitle":"Decoder.java: modify isValidQuantityFormat toisValidPantryStockFormat","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":6}}},{"hash":"e3b6b17a80a742c17725b7eeaa0ce0917a06fade","isMergeCommit":false,"messageTitle":"Add dummy try-catch in readTextFile to avoid error throwing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":12}}},{"hash":"fbcf11472ca6c030735fe89448e36fa65497ed9e","isMergeCommit":true,"messageTitle":"Merge pull request #150 from DextheChik3n/149-price-float-overflow-v2.0","messageBody":"149 price float overflow v2.0","fileTypesAndContributionMap":{}},{"hash":"31f5684de60c59be21a1f9ad7e5e9073632795e5","isMergeCommit":false,"messageTitle":"DecodePantryStockData: return new empty pantry if the data file is empty","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"12dc5a4508ab9c43778ca9832107287152d560df","isMergeCommit":false,"messageTitle":"Uncomment lines related to pantry storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":11}}},{"hash":"f210efecc30ea09310c3c13a9814f2a1d7eda853","isMergeCommit":false,"messageTitle":"Format line that is too long","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"0ca8c232030d80d94838a40fbae8eb1e923918e8","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 147-encode-decode-pantry-stock","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"621b6d503771130c4b9beeb39d245e07217c8f7c","isMergeCommit":false,"messageTitle":"Move error messages to ErrorMessages.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":4}}},{"hash":"18c5809253755e10dbc742b300345262086a7a19","isMergeCommit":false,"messageTitle":"FileManager.overwriteFile(): call openTextFile() before writing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"7a4512f101d1bc24ff31caa542b90a23541a16bd","isMergeCommit":true,"messageTitle":"Merge pull request #153 from Cazh1/#85-Implement-Multiple-day-support-for-Order-class","messageBody":"#85 implement multiple day support for order class","fileTypesAndContributionMap":{}},{"hash":"af7bcfe27b39c6f366f729c322b8c473f13949f8","isMergeCommit":false,"messageTitle":"FileManger.openTextFile(): remove extra lines","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":5}}},{"hash":"7e6e178f1bf1e4405f0ac44e7ad00a68ecaad655","isMergeCommit":false,"messageTitle":"Add import in Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"73f1188f059760fa22547319f481356a92af954f","isMergeCommit":true,"messageTitle":"Merge branch \u0027147-encode-decode-pantry-stock\u0027 into merge-conflicts-pr-255","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ff49fe4a800cc5417830abfc4822a499b1f5c411","isMergeCommit":true,"messageTitle":"Merge pull request #155 from DextheChik3n/152-edit-UG-v2.0","messageBody":"152 edit UG for v2.0","fileTypesAndContributionMap":{}},{"hash":"be43b8ab6fc16b26e938d6cff3dc58331013438e","isMergeCommit":false,"messageTitle":"Change OrderList to Sales","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":7}}},{"hash":"74db276cf7be8bfcf8c432b665fa608b4f30a498","isMergeCommit":false,"messageTitle":"Add author tag","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":9}}},{"hash":"d90fdbd457dfb81106f5546bb50dc44a373085ac","isMergeCommit":false,"messageTitle":"Use MESSAGE_USESAGE from command class for help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}},{"hash":"516b914db4f68faee0d5ba21c433b0d0073f22ec","isMergeCommit":false,"messageTitle":"Update HelpCommandTest expected output to use MESSAGE.USAGE","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3},"test-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-31","commitResults":[{"hash":"90040b3bba40c2dbb837ac1026d0814d9d33bf5c","isMergeCommit":false,"messageTitle":"Add Parser class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":34,"deletions":0}}},{"hash":"f65b8c7397f2bd3b2bb4f42b9568641ae3ed3efa","isMergeCommit":false,"messageTitle":"Add more details to Parser sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":10}}},{"hash":"6432dada325f4e09e24eeb277700b7959fec24c8","isMergeCommit":false,"messageTitle":"Add more details to EditPriceCommand_execute sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":3}}},{"hash":"dc6b47809e0a4b1cce58c2d9fffd2d5de7dd766c","isMergeCommit":false,"messageTitle":"Deactivate Parser in Parser sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"18dd8d023d63c47b9080ea51e908e1b66af840ac","isMergeCommit":false,"messageTitle":"Update DG parser class and sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":4}}},{"hash":"26c2c129fdd9655468314efc5b18b8d67df818c9","isMergeCommit":false,"messageTitle":"Add sequence diagram for HelpCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":0}}},{"hash":"f2f70860af4f62008bdbd3e6f2ab03a533b18d04","isMergeCommit":false,"messageTitle":"Update DG for HelpCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":0}}},{"hash":"b76a27ac45ab37dfc98d6d621b1c149b788c6101","isMergeCommit":true,"messageTitle":"Merge pull request #168 from DextheChik3n/151-same-dish-name-bug-v2.0","messageBody":"151 same dish name bug v2.0","fileTypesAndContributionMap":{}},{"hash":"f23ad963a59d4582af953707581c8421250f13bd","isMergeCommit":false,"messageTitle":"Create ParserUtil.java interface","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0}}},{"hash":"5835531232082192f75c0428c22a31e4ed4d94eb","isMergeCommit":false,"messageTitle":"Refactor classes that use Parser to use ParserUtil instead","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4},"test-code":{"insertions":39,"deletions":21}}},{"hash":"b14e681521aa81fa54c695862477148462b84065","isMergeCommit":true,"messageTitle":"Merge branch \u0027171-ParserUtil-interface\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"132908e11ab5307b408e396e9d20e5584996a364","isMergeCommit":true,"messageTitle":"Merge pull request #170 from NaychiMin/148_encoding_decoding_orders_v2.0","messageBody":"Task 148, Encoding and Decoding of Sales object v2.0","fileTypesAndContributionMap":{}},{"hash":"2d0a09c584797365dbe5668cd07a1b4fa5847963","isMergeCommit":false,"messageTitle":"Update UG: help command and edit_price command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":33,"deletions":2}}},{"hash":"31bdccaf67723a7f29eef1f43ffd66cc31f7597c","isMergeCommit":true,"messageTitle":"Merge pull request #175 from ShaniceTang/89-implement-buy-ingredient","messageBody":"Task 89, Implement buy ingredient to fulfill user story","fileTypesAndContributionMap":{}},{"hash":"a75ffcb86cadbc86a9e8f8d9691353fd55dadda9","isMergeCommit":false,"messageTitle":"Update ParserUtil.java with correct indentation","messageBody":"Co-authored-by: Dexter \u003c35828587+DextheChik3n@users.noreply.github.com\u003e","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"379dd270740cc009553a17b2815614407d0dacd6","isMergeCommit":false,"messageTitle":"Update Parser.java with correct indentation","messageBody":"Co-authored-by: Dexter \u003c35828587+DextheChik3n@users.noreply.github.com\u003e","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}}]},{"date":"2023-11-01","commitResults":[{"hash":"815114c29fdcda2bdf9e3081baf806b0d197b7b6","isMergeCommit":false,"messageTitle":"Correct typo in Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"f84fb017afda95cae5cb58b5583a173067193e28","isMergeCommit":true,"messageTitle":"Merge pull request #172 from ziyi105/171-ParserUtil-interface","messageBody":"171 ParserUtil interface","fileTypesAndContributionMap":{}},{"hash":"39176035be5332dc9be26b0877c34ebc8f37f061","isMergeCommit":true,"messageTitle":"Merge pull request #167 from Cazh1/#159-Update-DG-with-Multi-day-Order-feature","messageBody":"#159 Update DG with Multi-day Order feature","fileTypesAndContributionMap":{}},{"hash":"219c6e5433d6c027853c144cc3f357e0855f9fe4","isMergeCommit":false,"messageTitle":"Move MESSAGE_USAGE to command classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":37}}},{"hash":"e7b6978f6bdb0fbdbb8ecaeca7c93da8041f8a47","isMergeCommit":false,"messageTitle":"Update HelpCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":14,"deletions":8}}},{"hash":"b5060fbfce81f007679561e25684f33b82633011","isMergeCommit":false,"messageTitle":"Ui.java: remove wildcard import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":1}}},{"hash":"2fb89d49b8ebd1e722827d1f74b2b6153610dbd4","isMergeCommit":false,"messageTitle":"Ui.java: correct typo in import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":12}}},{"hash":"4702e0e142728a6011156f8be933b6c00db5e5c3","isMergeCommit":true,"messageTitle":"Merge pull request #197 from DextheChik3n/142-storage-error-handling-v2.0","messageBody":"142 storage error handling v2.0","fileTypesAndContributionMap":{}},{"hash":"273572b9c7fb1bdc8e11681ddcf37cdff1460add","isMergeCommit":false,"messageTitle":"Use divider for decoding and encoding of pantry stock Fixes #184","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"95c58ee1734a71b074043b32dd2f5533cdfa89ca","isMergeCommit":false,"messageTitle":"Add javadoc for encoding and decoding pantry stock","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":0}}},{"hash":"d88d1df37b0b6ed12b94a172be937e4339d622f5","isMergeCommit":false,"messageTitle":"Add author tag","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"13ffe6114d7e010d2ad5b3e652fb8f9448dee456","isMergeCommit":false,"messageTitle":"Use string builder for encoding pantryStock and add a new line after every ingredient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":3}}},{"hash":"290857cf6c34a1dfe2f50a891f7fb512a7ff23d9","isMergeCommit":false,"messageTitle":"Standardise formating of help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"2b6b642a324b69b20185fb492c9ae8a47e3c4497","isMergeCommit":false,"messageTitle":"Decoding of pantryStock: trim the quantity before parseInt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"17d681a19cd66cc227cd60a0f6b0c24653b562cf","isMergeCommit":true,"messageTitle":"Merge pull request #206 from DextheChik3n/205-bug-same-name-ingredients-v2.0","messageBody":"205 bug same name ingredients v2.0","fileTypesAndContributionMap":{}},{"hash":"7f2fe276408207a30640b3217302e9ad8c8e36fc","isMergeCommit":true,"messageTitle":"Merge pull request #218 from DextheChik3n/216-repeat-dish-name-bug-v2.0","messageBody":"216 repeat dish name bug v2.0","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"47e16eb6b43a922697358f9c63e02fe1008beba7","isMergeCommit":false,"messageTitle":"EditPriceCommand_execute.puml: add semicolon before class name","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":0}}},{"hash":"5d51e868872984081e196078539d8f7af466300a","isMergeCommit":false,"messageTitle":"Parser.puml: add semicolon before class name","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"51d051c3b91e97b0db505b780e5a87a0e3777b40","isMergeCommit":false,"messageTitle":"DG: add theme Time Machine","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"c213917a876476a6d34e84b01a674b11d14e31ea","isMergeCommit":false,"messageTitle":"DeveloperGuide: change theme","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"d6a8f4160a03633d8cd0e01a9afb31baf05704b6","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"8fc06cedbf86155647063f2bed787bcd52a0a23d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"eef5c8d65ac7b47b036f195121e6f65b8d890d46","isMergeCommit":false,"messageTitle":"DG: add table of contents","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":29,"deletions":0}}},{"hash":"cf750643d7b6581fd6347ca6fcb7971efd5b34e5","isMergeCommit":false,"messageTitle":"DG: add hyperlink to data folder","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"119b662088b026d34f667ca3a1f6d7621a071beb","isMergeCommit":false,"messageTitle":"DG: Add user stories","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":0}}},{"hash":"41cadabac1ccb35a14e70c78149b050d96b59ffe","isMergeCommit":false,"messageTitle":"DG: format the title and subtitle","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":29,"deletions":21}}},{"hash":"ad66f75b8fec0f95db3d53901bc9a034a5ea7dba","isMergeCommit":false,"messageTitle":"DG: correct typo","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b5074aaab342b7c8f8b5aba583e0b84ed1c6d642","isMergeCommit":false,"messageTitle":"DG: hyperlink to user guide for setting up","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6b9a52b698b0a282babbee55accd445ac676c440","isMergeCommit":false,"messageTitle":"DG: add new line at the end of the file","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"b3440c42db5086516b8ec0b694505f62a724425a","isMergeCommit":false,"messageTitle":"DG: add acknowledgement","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"d99f51dfbebab2ba344da96bbf769a3b8522bbe4","isMergeCommit":false,"messageTitle":"UG: remove extra |","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-03","commitResults":[{"hash":"aba15d03ddaa9b6d8ed398c75f8dfadb5d9660a7","isMergeCommit":false,"messageTitle":"UG: add table of content","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":29,"deletions":3}}},{"hash":"b565e25467d52010b666dcbc8ce944cf1410c03a","isMergeCommit":false,"messageTitle":"Add author tag","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"7662bcf8345ee6c295227dfbf08e6347001ca4a3","isMergeCommit":true,"messageTitle":"Merge pull request #221 from ziyi105/220-standardise-UG-DG","messageBody":"220 Standardise DG","fileTypesAndContributionMap":{}},{"hash":"ec6e7689f4e61bd8272c8cb04225383d150ace92","isMergeCommit":false,"messageTitle":"UG: edit command summary table","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":6}}},{"hash":"99d7542fdc5d67f01e19d57b9fa9e781611eb4c5","isMergeCommit":true,"messageTitle":"Merge pull request #222 from ziyi105/220-standardise-UG-DG","messageBody":"UG: edit command summary table","fileTypesAndContributionMap":{}}]},{"date":"2023-11-05","commitResults":[{"hash":"760e9d7e3b08d4b671369e71fb7921185c7d8c25","isMergeCommit":true,"messageTitle":"Merge pull request #258 from Cazh1/Bug-fix-List-Menu-display-long-dish-name","messageBody":"Update code to maintain menu form","fileTypesAndContributionMap":{}},{"hash":"b168dd50f92948165c5e5e41ffc6d4cb9e184b01","isMergeCommit":true,"messageTitle":"Merge pull request #260 from Cazh1/Bug-fix-Previous-Day-message-inconsistency","messageBody":"Update Message to remove inconsistency","fileTypesAndContributionMap":{}},{"hash":"523f5c21e09639b36faf7f161103c36919714ab3","isMergeCommit":true,"messageTitle":"Merge pull request #261 from Cazh1/Bug-fix-Days-reset-to-day-1-when-relaunch","messageBody":"Update code to bring user back to latest date accessed","fileTypesAndContributionMap":{}}]}],"ShaniceTang":[{"date":"2023-10-05","commitResults":[{"hash":"88288a4ee312a4a3906c0c7f8ecad9003abaf8fa","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"cea95da46d699ef3d7182ed840e860be204a6270","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"6b3c432ddb95359f5c4f9dee044cba3b53dc4b62","isMergeCommit":true,"messageTitle":"Merge pull request #2 from ShaniceTang/master","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"dadae0261aa4778ac64d68cbc66ec345da97f599","isMergeCommit":false,"messageTitle":"Fixes #27","messageBody":"Create UiTest JUnit Class\n","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":0}}},{"hash":"ba46ad20ecedd9d0cb49290bd75ba7df3e989b11","isMergeCommit":false,"messageTitle":"Add javadoc to UiTest class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":0}}}]},{"date":"2023-10-17","commitResults":[{"hash":"c4e118ce054a0eed4b0d076aadeaf5059f04853a","isMergeCommit":false,"messageTitle":"Add delete message to Ui class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"93ca9601f61702c86011451a21e6c3a097ff8f11","isMergeCommit":false,"messageTitle":"Fixes #21","messageBody":"Add javadoc to delete message method\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"812654327335924346f337a4102942a40b05df4e","isMergeCommit":false,"messageTitle":"Edit delete message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"ddd3d5049a361d1bc8b66e1fc77f7b4ea24ed638","isMergeCommit":false,"messageTitle":"Update delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":1}}},{"hash":"2a3d1fdcc0f08aba6e15f425fd490c8ffa5eb1b7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5e69f2317cb5536d4b0bbad556082b7c831439a8","isMergeCommit":false,"messageTitle":"Rename remove to removeDish method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"0ea6f655d06d20f1b3ff16724412856b42269ca4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/command/DeleteDishCommand.java\n","fileTypesAndContributionMap":{}},{"hash":"be50d359eeb512d129d052773bddfd07c2982b9f","isMergeCommit":false,"messageTitle":"Handle invalid index error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":5}}},{"hash":"411253bc7049f64567ed3785d19fc9e8d93c4dbb","isMergeCommit":false,"messageTitle":"Reformat printed string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"2e861f26e20a182639268add85bec7b82792038c","isMergeCommit":false,"messageTitle":"Fixes #22","messageBody":"Implement parser support for deleting a dish\n","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":12}}},{"hash":"e94d49fcda0fa69ee9d80bab03b075c94b7c80e5","isMergeCommit":false,"messageTitle":"Improve code standard","messageBody":"Fixes #22\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3}}},{"hash":"1c1742d4902012be02dfe7409ac94eb0e17f45e9","isMergeCommit":false,"messageTitle":"Handle out of bounds input index","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":5}}},{"hash":"39edc4758bf49b45c071bbe3f2bb0612d87381b3","isMergeCommit":false,"messageTitle":"Add JUnit test for Delete Command valid and invalid input","messageBody":"Fixes #55\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":59,"deletions":0}}},{"hash":"d2dfdeed55d7eb2b519262ccd86d50d2dcb86e3f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 55-deletecommand-junit-test","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1bd674a5beecdb86bfec754b7b106c70180ce148","isMergeCommit":false,"messageTitle":"Update import path","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":3}}}]},{"date":"2023-10-18","commitResults":[{"hash":"02f561afd0972856a346bb73cfd099c3414c1fd7","isMergeCommit":false,"messageTitle":"Add try-catch error handler","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3}}},{"hash":"40341fbba23130d1bb37d570eabbe1422bcf451b","isMergeCommit":false,"messageTitle":"Throw Index Out Of Bounds Exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"aca573016cb7a28d67fb0cb705e45fe9f562d15f","isMergeCommit":false,"messageTitle":"Update prepareDelete to match other methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":5}}},{"hash":"eed4152ad902aee18c1690be1c2b8e5d1264823a","isMergeCommit":false,"messageTitle":"Assert exception instead of equal string","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":7,"deletions":18}}},{"hash":"7f02a0de9aac1ed99944fc0c4beebc648b1d7d60","isMergeCommit":false,"messageTitle":"Create JUnit test for prepareDelete in Parser class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":17,"deletions":0}}},{"hash":"19a2ba9679b87ce118bc75987aed02a6207c6236","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"4881d95845ceae0c637849d3fa0142af1402db66","isMergeCommit":false,"messageTitle":"Use message string from Messages class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"695a304ae83f3e437f8ad2ed792591a1a624f2f6","isMergeCommit":false,"messageTitle":"Update prepareDelete method to standardize","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":10}}},{"hash":"cdea65514d1e4bc676cec5623e13bc10b96da8b3","isMergeCommit":false,"messageTitle":"Add JUnit test for delete command for parseCommand method","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":15,"deletions":4}}},{"hash":"b366ac5c0f59c71cbe7964111908f0f4e3cbb2d5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 22-implement-delete-feature","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"72da852206244ef87bcd8f2f765de519177317d0","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"Fixes #17\n","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"d2c8fd89be220ad3d1ddf9ce4f4e2a0f734dc9c0","isMergeCommit":false,"messageTitle":"Remove duplicate import statement","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}}]},{"date":"2023-10-22","commitResults":[{"hash":"8e589d37d341acdb4abcb34da25475bdc8a04e33","isMergeCommit":false,"messageTitle":"Move all messages in to Message class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":26},"test-code":{"insertions":1,"deletions":2}}},{"hash":"12bc39306efa8ba725bcbe10c93079d745569e03","isMergeCommit":false,"messageTitle":"Update unknown command message","messageBody":"Fixes #78\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"82d0bd4a04fc3ed9706de6e21369c75a97131511","isMergeCommit":false,"messageTitle":"Implement view total stock in pantry feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":0}}},{"hash":"bb4541ec67ee47679cd5f9b0d8b14da1c57841b9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into implement-pantry-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"851cba3e9f44f4e438b57a904820b0cf3cd7c870","isMergeCommit":false,"messageTitle":"Implement Pantry class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":119,"deletions":0}}},{"hash":"8a23bd2fcd39cb9e460fd15fa31884e5e6513ad8","isMergeCommit":false,"messageTitle":"Add view total stock command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":2}}},{"hash":"c421353e71a17d12dedffd0c40d9f3a0026b2522","isMergeCommit":false,"messageTitle":"Add buy ingredient command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":0}}},{"hash":"19276cf1582acf1ef53f0733417a6af8a3422933","isMergeCommit":false,"messageTitle":"Add Ui support for viewTotalStock and buyIngredients","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0}}},{"hash":"a3094cde4ebc7ec9c301bf89bff04137ba67dd69","isMergeCommit":false,"messageTitle":"Add parser support for viewTotalStock and buyIngredient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":2}}},{"hash":"9e878bd8f5dc5c24e8af6fba9b466b96b86af67b","isMergeCommit":false,"messageTitle":"Add setter for quantity varibale","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":1}}},{"hash":"0b2987ab90909285001d2ae7dfbc04a414b527fc","isMergeCommit":false,"messageTitle":"Add messages to display when error occurs","messageBody":"Fixes #90, Fixes #91\n","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":2}}}]},{"date":"2023-10-23","commitResults":[{"hash":"c50dc144cba53b1a2bd193f84223cff096a6eb31","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 90-91-implement-pantry-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5c073191d93908f8c98a6a0c812ff0c16f62def3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 90-91-implement-pantry-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"108c001310e4783c66ebda734490b70c5ec923d4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 90-91-implement-pantry-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"2d8533c6fff09e6ba664424cf1eefec4b897c76a","isMergeCommit":true,"messageTitle":"Merge branch \u002790-91-implement-pantry-class\u0027 of https://github.com/ShaniceTang/tp into 90-91-implement-pantry-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n","fileTypesAndContributionMap":{}},{"hash":"2dae7a2dfb59ee73d09ed981ea3c94faf6345f85","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"Fixes #90, Fixes #91\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2},"test-code":{"insertions":1,"deletions":1}}},{"hash":"f9a255fb362187b5b41de91f2f9dea4d3985c04c","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":8}}},{"hash":"f61f1d549bd4af23fa2aa533b60b6c10dd0d39c2","isMergeCommit":false,"messageTitle":"Add method to write pantry list to storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":4}}},{"hash":"57eb8502badae1d6fdaaec17f5c8bddc07e337f9","isMergeCommit":false,"messageTitle":"Improve coding quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":2}}},{"hash":"c94591a0a0b63758478a837cdc66bbca828db743","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":4}}},{"hash":"5c0fb17c294a54c982dfcc760a0f860c6617dfbd","isMergeCommit":false,"messageTitle":"Instantiate pantry object at main and add pantry parameter to execute methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":14}}},{"hash":"7f63281f8d0d6607f26211dd1d6913febd008b32","isMergeCommit":false,"messageTitle":"Update parameters of execute method in JUnit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":20,"deletions":14}}}]},{"date":"2023-10-25","commitResults":[{"hash":"82231b9c3b4516bd26def3be6505aff3a90a7255","isMergeCommit":false,"messageTitle":"Improve buyIngredient command to accept multiple ingredients","messageBody":"Fixes #118\n","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":28}}},{"hash":"b173c22fb1b2fc6ba116fa45ff8bf85c1e3cb369","isMergeCommit":false,"messageTitle":"Add sequence diagram for deleteDishCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":28,"deletions":0}}},{"hash":"282fef71ed9d6aadf2d575b1c109a7fd443dd885","isMergeCommit":false,"messageTitle":"Update according comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"325d1c9f813429bcde54284dccb3aac13ed19772","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 118-improve-buyIngredient","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5594273db85e94c376db067fa0386baacf5c4446","isMergeCommit":false,"messageTitle":"Fix AddDish command test cases","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"fba840c4e6b3e86319d03cd1b04ab24bdee42a32","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 118-improve-buyIngredient","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"54f3a0994268f20c1a901553c569d313b349848c","isMergeCommit":true,"messageTitle":"Merge branch \u0027118-improve-buyIngredient\u0027 of https://github.com/ShaniceTang/tp into 118-improve-buyIngredient","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"14255c37af68c2974097b50e39241bc7253387cb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 120-create-deleteDish-uml","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"586400675d2601337b0b797dda8e8d7fd0d37ff1","isMergeCommit":false,"messageTitle":"Update sequence diagram for deleteDishCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":0}}},{"hash":"3dc567ebb9594123d8904c61d3f9854750964ac7","isMergeCommit":false,"messageTitle":"Update DG for delete dish command","messageBody":"Fixes #120\n","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":13}}},{"hash":"8b437c243edf3e5b013fea057b55d44b11d6ef74","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 120-create-deleteDish-uml","messageBody":"# Conflicts:\n#\tdocs/DeveloperGuide.md\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"64ea82e107bd47eb8edce8f92fcedc3451cf8eae","isMergeCommit":false,"messageTitle":"Handle all file related exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"53b6ce1ec8ce6edab618b891219ad458b14125c2","isMergeCommit":false,"messageTitle":"Include appropriate author tags","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"39f9a51bcfa20e7c10ab0214cf2f5ae0c7a13172","isMergeCommit":false,"messageTitle":"Remove unecessary code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":32}}},{"hash":"eb4fe9c2be104ced8c51c20b6fabed88a32034c1","isMergeCommit":false,"messageTitle":"Implement decoder for Menu to parse text file as ArrayList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":20}}},{"hash":"4daafb7e583578324146488811440027fc38b50d","isMergeCommit":false,"messageTitle":"Implement encoder for Menu to parse ArrayList as text file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":26}}},{"hash":"b927d22f26bc291ebec9e2594537ae8c10f64e21","isMergeCommit":false,"messageTitle":"Import class java.nio.file.Path and java.nio.file.Paths","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4}}},{"hash":"e9578fb16e68469deeabaf0e806de3da3be24840","isMergeCommit":false,"messageTitle":"Implement loadMenu and saveMenu","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":16}}},{"hash":"8613f8c8880e5a3bd0250a5652fa675fe3117732","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n\nFixes #146\n","fileTypesAndContributionMap":{}},{"hash":"bb021f4078b7821de7f78b0172991d0cbd1039a9","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"Fixes #146\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"05920cbd9f15e15f41f3ecc35822ee5739b8774a","isMergeCommit":false,"messageTitle":"Remove unused imports","messageBody":"Fixes #146\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}}]},{"date":"2023-10-31","commitResults":[{"hash":"e3c10021bd8821e821d38c9614bbce9017abc013","isMergeCommit":false,"messageTitle":"Handle case when quantity units are different","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":12}}},{"hash":"a96a45859608ba3f76d362be47f59e9d642ab9be","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/FileManager.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n#\ttext-ui-test/EXPECTED.TXT\n","fileTypesAndContributionMap":{}},{"hash":"05ad0ba200029d311504649786e6baeb08365c56","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 89-implement-buy-ingredient","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/parser/Parser.java\n#\tsrc/main/java/seedu/cafectrl/ui/Messages.java\n#\ttext-ui-test/EXPECTED.TXT\n","fileTypesAndContributionMap":{}},{"hash":"d4fadf57a3a9fee6210f7a484bd34ef7bba92e85","isMergeCommit":false,"messageTitle":"Add message usage in list menu to standardize all command related messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"72198af146fde796143753c7d7c4443b388c155a","isMergeCommit":false,"messageTitle":"Remove unused messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":11}}},{"hash":"1f41243b552b2facf6a7a00b4e68bd49b32750b8","isMergeCommit":false,"messageTitle":"Improve code quality to standard all command guides to be from command classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":3},"test-code":{"insertions":2,"deletions":2}}},{"hash":"8c69b653a65eeb141148fba96f152eab96454a0e","isMergeCommit":false,"messageTitle":"Standarize origin of messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":13}}},{"hash":"2f2bd1478a3c4ba9df83939fedd0ace006067ea6","isMergeCommit":false,"messageTitle":"Update buyIngredientCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":5}}},{"hash":"343528dc20565797f0ce17553ac6ee5d031c6757","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c73a2ce648424056ff8221661c98681453941a92","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 89-implement-buy-ingredient","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3d247c2480d9f08bbe47a989ed63a8f840eeb7c6","isMergeCommit":false,"messageTitle":"Improve code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"811ad4bd8331ab410d1094af1c36db4f5f225532","isMergeCommit":false,"messageTitle":"Update expectedOutput in helpCommand JUnit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":5}}},{"hash":"222782638243434ac402101d5da7d3655e3a118c","isMergeCommit":false,"messageTitle":"Improve coding quality and standard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"89dc29ea6111c1d9943a21e01c23b745d666908d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into 146-encoding-decoding-menu","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"652a7078d8ca4df46a3b0def78d06fa53126c415","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Encoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}},{"hash":"6f96737021fbe784f4cfa2f1cbd7d02c93b133a1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\t.gitignore\n","fileTypesAndContributionMap":{}},{"hash":"998fd8b9d7f5f3a3d27bc646626737d350e5592d","isMergeCommit":true,"messageTitle":"Merge branch \u0027146-encoding-decoding-menu\u0027 of https://github.com/ShaniceTang/tp into 146-encoding-decoding-menu","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/cafectrl/storage/Decoder.java\n#\tsrc/main/java/seedu/cafectrl/storage/Storage.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"5382fc052080ed435b935b65d0394537f7d081e2","isMergeCommit":false,"messageTitle":"Implement JUnit test for buyIngredient command parsing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":23,"deletions":2}}},{"hash":"dca0f60b741dedef767c909c1f68ffa45e0e576a","isMergeCommit":false,"messageTitle":"Implement JUnit test for buyIngredient execute command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":73,"deletions":0}}},{"hash":"6f01021fa34f2e7b2253de60e3491c6ce8ddee4a","isMergeCommit":false,"messageTitle":"Implement JUnit test for addIngredientToStock method","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":29,"deletions":0}}},{"hash":"ae5054f3ae5a4f371673c8cf49a33c996b045c79","isMergeCommit":false,"messageTitle":"Add new line in message usage string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"6913515ec669be5a7908d0a3261b755b1a2a466b","isMergeCommit":false,"messageTitle":"Handle error for invalid units for buyIngredient command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"32d49b7a3148c963a41168801514fa38c1a4398f","isMergeCommit":false,"messageTitle":"Implement JUnit test for invalid arguments for buyIngredient command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":19,"deletions":0}}},{"hash":"29253e2e1018d614f6dcf618e11a90ab3f978a74","isMergeCommit":false,"messageTitle":"Implement JUnit test for parseCommand to ensure viewTotalStockCommand is returned","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":22,"deletions":3}}},{"hash":"ec613ebbb2c1bae995517c2afcb1ed10f53fce3f","isMergeCommit":false,"messageTitle":"Implement JUnit test for ViewTotalStock execute command","messageBody":"Fixes #188\n","fileTypesAndContributionMap":{"test-code":{"insertions":43,"deletions":0}}},{"hash":"baa8b22c14a551c665738672d918561fe2984cd0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 188-viewTotalStock-junit-test","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/cafectrl/parser/ParserTest.java\n\nFixes #188\n","fileTypesAndContributionMap":{}},{"hash":"278b1516a87a76176f891778437a395ea6f31623","isMergeCommit":false,"messageTitle":"Update UG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":74,"deletions":6}}},{"hash":"1d02a9fbf49a0cbabaf8f437d95d3cbd159b1f94","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"c5a2b0ef9936b401c32364503e4730f27696190c","isMergeCommit":false,"messageTitle":"Add @@author tags","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":1}}},{"hash":"9c0e45dd659c80bb166e6ee9c4b7b9cd66e0b49e","isMergeCommit":false,"messageTitle":"Add author tags to UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":6}}},{"hash":"1dc83dd05a3ce5f80975ff3353e4be286e599576","isMergeCommit":false,"messageTitle":"Draw class diagram for UI package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"docs":{"insertions":56,"deletions":0}}},{"hash":"77e1e6dea5f60607f544c3c2b1a8350e63ff90e6","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into update-ug-dg","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cb3e1975b8d54b510471b5d675477cf69d5b3f73","isMergeCommit":false,"messageTitle":"Draw the class diagram for data component","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":7},"docs":{"insertions":54,"deletions":6}}},{"hash":"4a1c2b32d283a346266d32be6e483ace441ee794","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into update-ug-dg","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b4fc894fac1d20e5e6de7069f0a79322a27f846c","isMergeCommit":false,"messageTitle":"Remove unused variables and methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":10}}},{"hash":"48741b829bf3fa47f52d6e56dd73bb62eb70865d","isMergeCommit":false,"messageTitle":"Remove unused imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"f6dfe9524b88ea4c0b95aa885f6dcafd28ed4ee0","isMergeCommit":false,"messageTitle":"Add architecture diagram for overall CafeCtrl","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":31,"deletions":0}}},{"hash":"ca14decf88ec93ec1c98b465b35d0bf91cff01a1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-2/tp into 187-architecture-diagram","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8ef15951ac271f3295237fdd82bb5ea0703d2691","isMergeCommit":false,"messageTitle":"Add Ui component to DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":15,"deletions":0}}},{"hash":"db150a3cd0039f7b40b98ca945a7dd8084e92416","isMergeCommit":false,"messageTitle":"Remove unused method and standardise methid names","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":16}}},{"hash":"631d9ed7945b05139b984b91a87c27e9183ed523","isMergeCommit":false,"messageTitle":"Add Ui class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":0}}}]}]},"authorFileTypeContributionMap":{"NaychiMin":{"docs":172,"functional-code":682,"test-code":93},"DextheChik3n":{"docs":177,"functional-code":545,"test-code":297,"other":3},"Cazh1":{"docs":694,"functional-code":696,"test-code":332},"ziyi105":{"docs":280,"functional-code":538,"test-code":198},"ShaniceTang":{"docs":319,"functional-code":434,"test-code":330}},"authorContributionVariance":{"NaychiMin":50064.21,"DextheChik3n":39955.145,"Cazh1":48662.695,"ziyi105":13333.482,"ShaniceTang":10968.0},"authorDisplayNameMap":{"NaychiMin":"CS2113-T17-2 SAUN.. MIN","DextheChik3n":"CS2113-T17-2 DEXT..G EN","Cazh1":"CS2113-T17-2 CHUA..HENG","ziyi105":"CS2113-T17-2 NG Z..I YI","ShaniceTang":"CS2113-T17-2 TANG..NICE"}} diff --git a/AY2324S1-CS2113-T17-3_tp_master/authorship.json b/AY2324S1-CS2113-T17-3_tp_master/authorship.json index 3a19f79..fa14023 100644 --- a/AY2324S1-CS2113-T17-3_tp_master/authorship.json +++ b/AY2324S1-CS2113-T17-3_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" mainClass.set(\"seedu.stocker.Stocker\")","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" archiveBaseName.set(\"stocker\")","lastModifiedDate":"2023-10-09"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"martinschnder":2,"TeoHaoZhi":1,"-":44}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"|-----------------------------|:----------------:|:------------------------------------------:|:--------------------------------:|","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"| ![](team/Martin.jpeg) | Martin Schneider | [Github](https://github.com/martinschnder) | [Portfolio](docs/team/Martin.md) |","lastModifiedDate":"2023-10-07"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"| ![](team/Karishma.png) | Karishma | [Github](https://github.com/karishma-t) | [Portfolio](team/karishma.md) |","lastModifiedDate":"2023-10-06"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"| ![](team/Barbara_image.JPG) | Barbara Chong | [Github](https://github.com/barbaracwx) | [Portfolio](team/Barbara.md) |","lastModifiedDate":"2023-10-05"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"| ![](team/HaoZhi.png) | Teo Hao Zhi | [Github](https://github.com/TeoHaoZhi) | [Portfolio](team/HaoZhi.md) |","lastModifiedDate":"2023-10-06"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"| ![](team/Azfarul.JPG) | Azfarul Matin | [Github](https://github.com/azfarulmatin) | [Portfolio](team/Azfarul.md) |","lastModifiedDate":"2023-10-07"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-06"}],"authorContributionMap":{"karishma-t":1,"martinschnder":1,"azfarulmatin":2,"TeoHaoZhi":5,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"1. Reference to AB-3 Developer Guide","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"- [Source](https://se-education.org/addressbook-level3/DeveloperGuide.html#proposed-undoredo-feature)","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"- Used as template to structure this Developer Guide","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"-"},"content":"## Design \u0026 implementation","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"\u003cimg src\u003d\"UML Diagrams/Architecture_Diagram.png\" width\u003d\"280\"\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"The architecture diagram given above explains the high level design of the application. The diagram depicts the key","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"component of the application that enables it to provide its functionalities.","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"Majority of the app\u0027s work is done by the following components","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"- Login System : Handles user authentication before enabling app usage","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"- Ui : Asks for user input by handling output messages","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"- Parser : Makes sense of user input","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"- Commands : List of various commands","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"- CommandResult : Execution of various commands","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"The section below will explain in more detail the design considerations, implementations and rationale of the various","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"components listed above.","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"### Login System Component","lastModifiedDate":"2023-10-21"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-21"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":"The login system component seeks to authenticate and login existing users or register a new user.","lastModifiedDate":"2023-10-21"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":"#### Design considerations","lastModifiedDate":"2023-10-21"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":"- There must be a way to check and verify users with a master list","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":"- The search for existing users username and password must be fast","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":"- Master list must be stored separately on hard drive of machine","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"#### Implementation and rationale","lastModifiedDate":"2023-10-21"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":"The login system class works in the following way. Upon booting up the application, a txt file","lastModifiedDate":"2023-10-21"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"containing a current list of existing users will be loaded into a users attribute within the class in the form of a hash","lastModifiedDate":"2023-10-21"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":"table.When a user attempts to login to their account, the entered username and password is checked against","lastModifiedDate":"2023-10-21"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":"the current list of users in the hashtable. If the username and password matches, the user is logged in.","lastModifiedDate":"2023-10-21"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":"As for registering new users, newly inputted username and password will be saved to the users attribute and this","lastModifiedDate":"2023-10-21"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":"pair of username and password is then appended to the txt file containing current users. The updated user list will be","lastModifiedDate":"2023-10-21"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":"loaded into the users attribute when the application is booted up again.","lastModifiedDate":"2023-10-21"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":"The login system class uses the below methods to achieve its functionality","lastModifiedDate":"2023-10-21"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"- `authenticateUserChoice()` -Decides whether the user chooses to register or login","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":"- `newUserCreator()` -Creates a new user for future login","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":"- `loginExistingUser()` -Login existing user","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":"- `loadExistingUsers()` -Load existing users into hashtable for reference","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":60,"author":{"gitId":"TeoHaoZhi"},"content":"Given below is an example of how the login system class works.","lastModifiedDate":"2023-10-21"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":"When the user first launches the programme, the Stocker object will be instantiated. The object will","lastModifiedDate":"2023-10-21"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":"invoke its own `run()` method which will call its own `start()` method. The Stocker object then instantiates a","lastModifiedDate":"2023-10-21"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":"new UI object which displays the login message by invoking `showLoginMessage()` method. At this point, Stocker object","lastModifiedDate":"2023-10-21"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":"will also instantiate a new login system object.","lastModifiedDate":"2023-10-21"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":67,"author":{"gitId":"TeoHaoZhi"},"content":"The login system object will invoke its own `run()` method to begin the login process. This method begins by loading","lastModifiedDate":"2023-10-21"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":"existing users into the users attribute of the login system class by `loadExistingusers()` method. it then invokes","lastModifiedDate":"2023-10-21"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":"`authenticateUserChoice()` to receive an input from the user to whether register or login a user. Based on the input of","lastModifiedDate":"2023-10-21"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":"the user, either `newUserCreator()` is launched or `loginExistingUser()` methods will be called to register or login a","lastModifiedDate":"2023-10-21"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":"user.","lastModifiedDate":"2023-10-21"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":"The following sequence diagram shows how the login system class works when the program is launched.","lastModifiedDate":"2023-10-21"},{"lineNumber":74,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":"\u003cimg src\u003d\"UML Diagrams/StockerToLoginSystem.png\" width\u003d\"280\"\u003e","lastModifiedDate":"2023-10-21"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":77,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"Barbaracwx"},"content":"### Parser Component","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"Barbaracwx"},"content":"The Parser component is responsible for interpreting user input and converting it into executable commands. It plays a","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"Barbaracwx"},"content":"critical role in bridging the user interface (UI) and the command execution components of the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"Barbaracwx"},"content":"#### Design considerations","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"Barbaracwx"},"content":"- **User Input Parsing:** The Parser must effectively break down user input into its constituent parts, such as the command","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"Barbaracwx"},"content":"keyword and any associated arguments.","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"Barbaracwx"},"content":"- **Command Recognition:** The Parser must recognize the specific command the user intends to execute. This involves matching","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"Barbaracwx"},"content":"the command keyword to a predefined set of commands.","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"Barbaracwx"},"content":"- **Arguments Extraction:** For commands that require additional information, the Parser should correctly extract and format","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"Barbaracwx"},"content":"arguments, ensuring they are ready for command execution.","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"Barbaracwx"},"content":"- **Error Handling:** In cases where the input does not match any recognized command or has formatting errors, the Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"Barbaracwx"},"content":"should generate appropriate error messages.","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"Barbaracwx"},"content":"#### Implementation and rationale","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"Barbaracwx"},"content":"The Parser class is designed to handle these considerations through a well-structured parsing process. Here\u0027s how it","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"Barbaracwx"},"content":"works:","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"Barbaracwx"},"content":"1. Splitting User Input: The Parser takes the full user input and splits it into two parts: the command word and the","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"Barbaracwx"},"content":"remaining arguments.","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"Barbaracwx"},"content":"2. Command Recognition: It matches the command word to a predefined set of commands. If a valid command is recognized, it","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"Barbaracwx"},"content":"proceeds to the next step.","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"Barbaracwx"},"content":"3. Arguments Extraction: Depending on the specific command, the Parser may further parse and extract arguments. For","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"Barbaracwx"},"content":"instance, for the \"AddCommand,\" it extracts drug-related details like name, expiry date, serial number, and quantity.","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"Barbaracwx"},"content":"4. Command Creation: The Parser creates an instance of the appropriate Command class, passing along any required arguments.","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"Barbaracwx"},"content":"This encapsulates the user\u0027s request in an executable command object.","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"Barbaracwx"},"content":"5. Error Handling: If the user input does not match any recognized command or has formatting errors, the Parser generates","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"Barbaracwx"},"content":"an \"IncorrectCommand\" with an error message, providing feedback to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"Barbaracwx"},"content":"By structuring the parsing process this way, the application ensures that user input is correctly interpreted and","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"Barbaracwx"},"content":"translated into executable commands for the subsequent phases of the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"Barbaracwx"},"content":"The parser class uses the below method to achieve its functionality","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"Barbaracwx"},"content":"- `parseCommand(String userInput)` - This method takes the user\u0027s input as a parameter and processes it to identify the","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"Barbaracwx"},"content":" command keyword and any associated arguments. It then recognizes the specific command and prepares it for execution.","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"Barbaracwx"},"content":"Given below is an example of how the login system class works.","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"Barbaracwx"},"content":"Suppose a user enters the command `add /n Paracetamol /d 2023-12-31 /s ABC123 /q 100`. The Parser first splits this input","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"Barbaracwx"},"content":"into the command word \"add\" and the arguments. It then recognizes the \"add\" command, extracts the drug details (name,","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"Barbaracwx"},"content":"expiry date, serial number, and quantity), and creates an instance of the \"`AddCommand`\" with these details. If the user","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"Barbaracwx"},"content":"enters an invalid command or incorrect formatting, the Parser provides feedback to guide the user, ensuring a seamless","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"Barbaracwx"},"content":"interaction between the user and the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"Barbaracwx"},"content":"The Parser is a crucial component that forms the bridge between user intentions and the core functionality of the stock","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"Barbaracwx"},"content":"management system.","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"Barbaracwx"},"content":"The following sequence diagram shows how the parser class works when the program is running.","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"Barbaracwx"},"content":"\u003cimg src\u003d\"UML Diagrams/ParserDiagram.png\" width\u003d\"500\"\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"martinschnder"},"content":"### Main data structures","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"martinschnder"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"martinschnder"},"content":"#### Implementation","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"martinschnder"},"content":"##### Drug","lastModifiedDate":"2023-10-25"},{"lineNumber":152,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":153,"author":{"gitId":"Barbaracwx"},"content":"The Drug class is very basic class for now. It only contains the product name as well as it\u0027s expiry date, but we will","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"Barbaracwx"},"content":"soon add some new properties such as product description, etc...","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":156,"author":{"gitId":"martinschnder"},"content":"##### Inventory","lastModifiedDate":"2023-10-25"},{"lineNumber":157,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":158,"author":{"gitId":"Barbaracwx"},"content":"The Inventory class is used to keep track of the quantity of product in stock. The hash map seemed to be the most","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"Barbaracwx"},"content":"appropriate data structure to match a product id to a quantity and a product entity which are encapsulated in a \"","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"Barbaracwx"},"content":"StockEntry\" class.","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":162,"author":{"gitId":"martinschnder"},"content":"##### Cart","lastModifiedDate":"2023-10-25"},{"lineNumber":163,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":164,"author":{"gitId":"Barbaracwx"},"content":"The Cart class is used to represent an ongoing transaction : to perform a sale, the vendor can add different products","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"Barbaracwx"},"content":"with their respective quantities in a cart which will be deducted from the inventory at the checkout.","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"martinschnder"},"content":"To represent this, we chose to use an arraylist of \"CartEntry\" classes which reprensent a product/quantity tuple.","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":168,"author":{"gitId":"martinschnder"},"content":"##### SalesList","lastModifiedDate":"2023-10-25"},{"lineNumber":169,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":170,"author":{"gitId":"Barbaracwx"},"content":"The SalesList is used to represent every past sales in order to create some statistics and reports. This class is only a","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"Barbaracwx"},"content":"list of subclasses representing validated carts.","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":173,"author":{"gitId":"martinschnder"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"Barbaracwx"},"content":"## Commands","lastModifiedDate":"2023-10-25"},{"lineNumber":176,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":177,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":178,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":179,"author":{"gitId":"Barbaracwx"},"content":"## 1. Find Function","lastModifiedDate":"2023-10-25"},{"lineNumber":180,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":181,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function is designed to enable users to search for specific drugs in the inventory using either the drug\u0027s","lastModifiedDate":"2023-10-25"},{"lineNumber":182,"author":{"gitId":"Barbaracwx"},"content":"name or the drugs expiry date. This component assists in locating and retrieving relevant drugs efficiently.","lastModifiedDate":"2023-10-25"},{"lineNumber":183,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":184,"author":{"gitId":"Barbaracwx"},"content":"**Design Considerations**","lastModifiedDate":"2023-10-25"},{"lineNumber":185,"author":{"gitId":"Barbaracwx"},"content":"The design of the \"Find\" function takes into account the following considerations:","lastModifiedDate":"2023-10-25"},{"lineNumber":186,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":187,"author":{"gitId":"Barbaracwx"},"content":"1. **Search Criteria:** The function must provide users with the ability to specify each criteria, such as keywords or","lastModifiedDate":"2023-10-25"},{"lineNumber":188,"author":{"gitId":"Barbaracwx"},"content":" attributes, to filter the items they are looking for.","lastModifiedDate":"2023-10-25"},{"lineNumber":189,"author":{"gitId":"Barbaracwx"},"content":"2. **Search Speed:** To enhance user experience, the search process should be fast and responsive, ensuring that users","lastModifiedDate":"2023-10-25"},{"lineNumber":190,"author":{"gitId":"Barbaracwx"},"content":" receive search results quickly.","lastModifiedDate":"2023-10-25"},{"lineNumber":191,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":192,"author":{"gitId":"Barbaracwx"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-10-25"},{"lineNumber":193,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":194,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function is implemented as follows:","lastModifiedDate":"2023-10-25"},{"lineNumber":195,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":196,"author":{"gitId":"Barbaracwx"},"content":"- **User-Defined Search Criteria:** Users provide search criteria, such as keywords, to define what they","lastModifiedDate":"2023-10-25"},{"lineNumber":197,"author":{"gitId":"Barbaracwx"},"content":" are looking for. The \"Find\" function processes these criteria to locate relevant items.","lastModifiedDate":"2023-10-25"},{"lineNumber":198,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":199,"author":{"gitId":"Barbaracwx"},"content":"- **Search Algorithm:** A robust search algorithm is employed to efficiently scan through the list of items and identify","lastModifiedDate":"2023-10-25"},{"lineNumber":200,"author":{"gitId":"Barbaracwx"},"content":" those","lastModifiedDate":"2023-10-25"},{"lineNumber":201,"author":{"gitId":"Barbaracwx"},"content":" that match the specified criteria.","lastModifiedDate":"2023-10-25"},{"lineNumber":202,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":203,"author":{"gitId":"Barbaracwx"},"content":"- **Result Presentation:** The function displays the search results, presenting users with a list of items that meet the","lastModifiedDate":"2023-10-25"},{"lineNumber":204,"author":{"gitId":"Barbaracwx"},"content":" search criteria, allowing them to quickly identify the items they are interested in.","lastModifiedDate":"2023-10-25"},{"lineNumber":205,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":206,"author":{"gitId":"Barbaracwx"},"content":"- **User-Friendly Interface:** The \"Find\" function is integrated into the user interface, making it easily accessible","lastModifiedDate":"2023-10-25"},{"lineNumber":207,"author":{"gitId":"Barbaracwx"},"content":" and intuitive for users to perform searches.","lastModifiedDate":"2023-10-25"},{"lineNumber":208,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":209,"author":{"gitId":"Barbaracwx"},"content":"- **Alternative Consideration:** During the design process, alternative approaches to searching are evaluated to ensure","lastModifiedDate":"2023-10-25"},{"lineNumber":210,"author":{"gitId":"Barbaracwx"},"content":" the","lastModifiedDate":"2023-10-25"},{"lineNumber":211,"author":{"gitId":"Barbaracwx"},"content":" most effective and user-friendly method is implemented.","lastModifiedDate":"2023-10-25"},{"lineNumber":212,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":213,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function offers a valuable way for users to narrow down their searches, find specific items of interest, and","lastModifiedDate":"2023-10-25"},{"lineNumber":214,"author":{"gitId":"Barbaracwx"},"content":"enhance the usability of the application.","lastModifiedDate":"2023-10-25"},{"lineNumber":215,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":216,"author":{"gitId":"Barbaracwx"},"content":"**Function Methods**","lastModifiedDate":"2023-10-25"},{"lineNumber":217,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":218,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function includes the following method to achieve its functionality:","lastModifiedDate":"2023-10-25"},{"lineNumber":219,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":220,"author":{"gitId":"Barbaracwx"},"content":"- `execute()` - This method is responsible for executing the \"Find\" command, searching for drugs that match the","lastModifiedDate":"2023-10-25"},{"lineNumber":221,"author":{"gitId":"Barbaracwx"},"content":" user-specified keyword within the inventory.","lastModifiedDate":"2023-10-25"},{"lineNumber":222,"author":{"gitId":"Barbaracwx"},"content":"- It returns a `CommandResult` containing the outcome of the command execution,","lastModifiedDate":"2023-10-25"},{"lineNumber":223,"author":{"gitId":"Barbaracwx"},"content":" which includes a success message and a list of found StockEntry objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":224,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":225,"author":{"gitId":"Barbaracwx"},"content":"**Example Usage**","lastModifiedDate":"2023-10-25"},{"lineNumber":226,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":227,"author":{"gitId":"Barbaracwx"},"content":"To illustrate how the \"Find\" function works, consider the following example usage:","lastModifiedDate":"2023-10-25"},{"lineNumber":228,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":229,"author":{"gitId":"Barbaracwx"},"content":"1. **User Input:** The user initiates the \"Find\" command by typing something like the following:","lastModifiedDate":"2023-10-25"},{"lineNumber":230,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":231,"author":{"gitId":"Barbaracwx"},"content":"`find /n panadol` - This command instructs the program to search for drugs in the inventory based on the name criteria","lastModifiedDate":"2023-10-25"},{"lineNumber":232,"author":{"gitId":"Barbaracwx"},"content":"and the keyword \"panadol.\"","lastModifiedDate":"2023-10-25"},{"lineNumber":233,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":234,"author":{"gitId":"Barbaracwx"},"content":"`find /d 12/03/2026` - This command instructs the program to search for drugs in the inventory based on the expiry date","lastModifiedDate":"2023-10-25"},{"lineNumber":235,"author":{"gitId":"Barbaracwx"},"content":"criteria and the keyword \"12/03/2026.\"","lastModifiedDate":"2023-10-25"},{"lineNumber":236,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":237,"author":{"gitId":"azfarulmatin"},"content":"`find /s PARC3189` - This command instructs the program to search for drugs in the inventory based on the serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":238,"author":{"gitId":"azfarulmatin"},"content":"criteria and the keyword \"PARC3189.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":239,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":240,"author":{"gitId":"Barbaracwx"},"content":"2. **Method Execution:** The `execute()` method within the \"FindCommand\" class is called. It takes the provided keyword","lastModifiedDate":"2023-10-25"},{"lineNumber":241,"author":{"gitId":"Barbaracwx"},"content":" and criterion as input.","lastModifiedDate":"2023-10-25"},{"lineNumber":242,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":243,"author":{"gitId":"Barbaracwx"},"content":"3. **Search Process:** The method processes the search by iterating through the list of `StockEntry` objects in the","lastModifiedDate":"2023-10-25"},{"lineNumber":244,"author":{"gitId":"Barbaracwx"},"content":" inventory.","lastModifiedDate":"2023-10-25"},{"lineNumber":245,"author":{"gitId":"Barbaracwx"},"content":" For each entry, it checks if the `matches` method returns `true`, which means that the drug name or expiry date","lastModifiedDate":"2023-10-25"},{"lineNumber":246,"author":{"gitId":"Barbaracwx"},"content":" contains the given keyword.","lastModifiedDate":"2023-10-25"},{"lineNumber":247,"author":{"gitId":"Barbaracwx"},"content":"4. **Building Results:** As matching entries are found, they are added to a list called `foundEntries`.","lastModifiedDate":"2023-10-25"},{"lineNumber":248,"author":{"gitId":"Barbaracwx"},"content":"5. **Result Display:** The `CommandResult` is prepared, containing a success message (e.g., \"Listed all drugs with the","lastModifiedDate":"2023-10-25"},{"lineNumber":249,"author":{"gitId":"Barbaracwx"},"content":" keyword","lastModifiedDate":"2023-10-25"},{"lineNumber":250,"author":{"gitId":"Barbaracwx"},"content":" in the inventory.\") and the list of found `StockEntry` objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":251,"author":{"gitId":"Barbaracwx"},"content":"6. `User Feedback:` The result is then displayed to the user, showing a list of drugs in the inventory that match the","lastModifiedDate":"2023-10-25"},{"lineNumber":252,"author":{"gitId":"Barbaracwx"},"content":" specified keyword.","lastModifiedDate":"2023-10-25"},{"lineNumber":253,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":254,"author":{"gitId":"Barbaracwx"},"content":"The following sequence diagram shows how the Find Command function works.","lastModifiedDate":"2023-10-25"},{"lineNumber":255,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":256,"author":{"gitId":"Barbaracwx"},"content":"\u003cimg src\u003d\"UML Diagrams/FindCommandDiagram.png\" width\u003d\"350\"\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":257,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":258,"author":{"gitId":"Barbaracwx"},"content":"Architecture Diagram of find command function:","lastModifiedDate":"2023-10-25"},{"lineNumber":259,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":260,"author":{"gitId":"Barbaracwx"},"content":"\u003cimg src\u003d\"UML Diagrams/FindCommandArchitectureDiagram.png\" width\u003d\"500\"\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":261,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":262,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":263,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":264,"author":{"gitId":"azfarulmatin"},"content":"## 2. ListCommand","lastModifiedDate":"2023-10-26"},{"lineNumber":265,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":266,"author":{"gitId":"Barbaracwx"},"content":"The `ListCommand` is responsible for listing all drugs in the inventory. This command retrieves the list of drugs from","lastModifiedDate":"2023-10-31"},{"lineNumber":267,"author":{"gitId":"Barbaracwx"},"content":"the inventory and provides it as part of the command result. If the inventory is empty, it informs the user that the","lastModifiedDate":"2023-10-31"},{"lineNumber":268,"author":{"gitId":"Barbaracwx"},"content":"inventory has no drugs.","lastModifiedDate":"2023-10-31"},{"lineNumber":269,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":270,"author":{"gitId":"azfarulmatin"},"content":"### Design Considerations","lastModifiedDate":"2023-10-26"},{"lineNumber":271,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":272,"author":{"gitId":"Barbaracwx"},"content":"- **User-Friendly Listing:** The primary goal of the `ListCommand` is to provide a user-friendly way to list all drugs","lastModifiedDate":"2023-10-31"},{"lineNumber":273,"author":{"gitId":"Barbaracwx"},"content":" in the inventory, enhancing the user\u0027s experience in accessing inventory information.","lastModifiedDate":"2023-10-31"},{"lineNumber":274,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":275,"author":{"gitId":"Barbaracwx"},"content":"- **Data Presentation:** The design considers how to present the list of drugs in a clear and organized manner to","lastModifiedDate":"2023-10-31"},{"lineNumber":276,"author":{"gitId":"Barbaracwx"},"content":" provide valuable information to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":277,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":278,"author":{"gitId":"Barbaracwx"},"content":"- **Performance:** The implementation should be optimized to list the inventory efficiently, even if it contains a large","lastModifiedDate":"2023-10-31"},{"lineNumber":279,"author":{"gitId":"Barbaracwx"},"content":" number of drugs.","lastModifiedDate":"2023-10-31"},{"lineNumber":280,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":281,"author":{"gitId":"azfarulmatin"},"content":"### Implementation","lastModifiedDate":"2023-10-26"},{"lineNumber":282,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":283,"author":{"gitId":"azfarulmatin"},"content":"The `ListCommand` is implemented as follows:","lastModifiedDate":"2023-10-26"},{"lineNumber":284,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":285,"author":{"gitId":"azfarulmatin"},"content":"- **Retrieving Drug List:** The command retrieves the list of drugs from the inventory using the `getAllDrugs` method.","lastModifiedDate":"2023-10-26"},{"lineNumber":286,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":287,"author":{"gitId":"Barbaracwx"},"content":"- **Handling Empty Inventory:** It checks if the list of drugs is empty. If the inventory is empty, it returns a","lastModifiedDate":"2023-10-31"},{"lineNumber":288,"author":{"gitId":"Barbaracwx"},"content":" user-friendly message indicating that the inventory is empty.","lastModifiedDate":"2023-10-31"},{"lineNumber":289,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":290,"author":{"gitId":"Barbaracwx"},"content":"- **Listing Drugs:** If the inventory contains drugs, the command constructs a success message and includes the list of","lastModifiedDate":"2023-10-31"},{"lineNumber":291,"author":{"gitId":"Barbaracwx"},"content":" drugs in the command result.","lastModifiedDate":"2023-10-31"},{"lineNumber":292,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":293,"author":{"gitId":"Barbaracwx"},"content":"- **User-Friendly Presentation:** The implementation ensures that the list of drugs is presented in a clear and","lastModifiedDate":"2023-10-31"},{"lineNumber":294,"author":{"gitId":"Barbaracwx"},"content":" organized format, including relevant details such as drug names, quantities, and other attributes.","lastModifiedDate":"2023-10-31"},{"lineNumber":295,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":296,"author":{"gitId":"Barbaracwx"},"content":"- **Optimized Performance:** To enhance user experience, the command is designed to list the inventory efficiently,","lastModifiedDate":"2023-10-31"},{"lineNumber":297,"author":{"gitId":"Barbaracwx"},"content":" ensuring that users receive search results quickly.","lastModifiedDate":"2023-10-31"},{"lineNumber":298,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":299,"author":{"gitId":"azfarulmatin"},"content":"### Function Methods","lastModifiedDate":"2023-10-26"},{"lineNumber":300,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":301,"author":{"gitId":"azfarulmatin"},"content":"The `ListCommand` includes the following method to achieve its functionality:","lastModifiedDate":"2023-10-26"},{"lineNumber":302,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":303,"author":{"gitId":"Barbaracwx"},"content":"- `execute()`: This method is responsible for executing the `ListCommand`, listing all drugs in the inventory. It checks","lastModifiedDate":"2023-10-31"},{"lineNumber":304,"author":{"gitId":"Barbaracwx"},"content":" the inventory, prepares a user-friendly result message, and returns a `CommandResult` containing the outcome of the","lastModifiedDate":"2023-10-31"},{"lineNumber":305,"author":{"gitId":"Barbaracwx"},"content":" command execution, which includes a success message and the list of found `Drug` objects.","lastModifiedDate":"2023-10-31"},{"lineNumber":306,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":307,"author":{"gitId":"azfarulmatin"},"content":"### Example Usage","lastModifiedDate":"2023-10-26"},{"lineNumber":308,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":309,"author":{"gitId":"azfarulmatin"},"content":"To illustrate how the `ListCommand` works, consider the following example usage:","lastModifiedDate":"2023-10-26"},{"lineNumber":310,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":311,"author":{"gitId":"azfarulmatin"},"content":"1. **User Input:** The user initiates the `ListCommand` by entering the following command:","lastModifiedDate":"2023-10-26"},{"lineNumber":312,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":313,"author":{"gitId":"azfarulmatin"},"content":"2. **Method Execution:** The `execute()` method within the \"ListCommand\" class is called.","lastModifiedDate":"2023-10-30"},{"lineNumber":314,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":315,"author":{"gitId":"azfarulmatin"},"content":"3. **Inventory Check:** The method checks the inventory to retrieve the list of drugs.","lastModifiedDate":"2023-10-30"},{"lineNumber":316,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":317,"author":{"gitId":"Barbaracwx"},"content":"4. **Result Building:** If the inventory contains drugs, the method constructs a success message (e.g., \"Listed all","lastModifiedDate":"2023-10-31"},{"lineNumber":318,"author":{"gitId":"Barbaracwx"},"content":" drugs in the inventory.\") and includes the list of drugs with relevant details.","lastModifiedDate":"2023-10-31"},{"lineNumber":319,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":320,"author":{"gitId":"azfarulmatin"},"content":"5. **User Feedback:** The result is displayed to the user, showing a clear and organized list of drugs in the inventory.","lastModifiedDate":"2023-10-30"},{"lineNumber":321,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":322,"author":{"gitId":"Barbaracwx"},"content":"The \"ListCommand\" enhances the user\u0027s ability to access inventory information efficiently and is designed to handle","lastModifiedDate":"2023-10-31"},{"lineNumber":323,"author":{"gitId":"Barbaracwx"},"content":"various inventory sizes while providing a user-friendly experience.","lastModifiedDate":"2023-10-31"},{"lineNumber":324,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":325,"author":{"gitId":"azfarulmatin"},"content":"The following sequence diagram shows how the Find Command function works.","lastModifiedDate":"2023-10-30"},{"lineNumber":326,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":327,"author":{"gitId":"azfarulmatin"},"content":"\u003cimg src\u003d\"UML Diagrams/ListCommandDiagram.png\" width\u003d\"350\"\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":328,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":329,"author":{"gitId":"azfarulmatin"},"content":"---","lastModifiedDate":"2023-10-26"},{"lineNumber":330,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":331,"author":{"gitId":"TeoHaoZhi"},"content":"## 3. Delete Command","lastModifiedDate":"2023-10-29"},{"lineNumber":332,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":333,"author":{"gitId":"karishma-t"},"content":"The \"Delete\" function is designed to enable users to remove specific drugs from the inventory based on the drug\u0027s name, ","lastModifiedDate":"2023-11-02"},{"lineNumber":334,"author":{"gitId":"karishma-t"},"content":"to remove drugs they no longer need, fully depleted or discontinued.","lastModifiedDate":"2023-11-02"},{"lineNumber":335,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":336,"author":{"gitId":"karishma-t"},"content":"**Design Considerations**","lastModifiedDate":"2023-10-26"},{"lineNumber":337,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":338,"author":{"gitId":"Barbaracwx"},"content":"1. **User-Specified Drug Name:** The function allows users to specify the drug name they want to delete from the","lastModifiedDate":"2023-10-31"},{"lineNumber":339,"author":{"gitId":"Barbaracwx"},"content":" inventory.","lastModifiedDate":"2023-10-31"},{"lineNumber":340,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":341,"author":{"gitId":"Barbaracwx"},"content":"2. **Data Integrity:** It ensures that the deletion operation maintains the integrity of the inventory data structure,","lastModifiedDate":"2023-10-31"},{"lineNumber":342,"author":{"gitId":"Barbaracwx"},"content":" updating it correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":343,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":344,"author":{"gitId":"karishma-t"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-10-26"},{"lineNumber":345,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":346,"author":{"gitId":"karishma-t"},"content":"This method is executed when the delete command is invoked. First, it attempts to delete a drug from the inventory ","lastModifiedDate":"2023-11-02"},{"lineNumber":347,"author":{"gitId":"karishma-t"},"content":"using the inventory.deleteDrug(this.keyToDelete) method. If successful, it retrieves the deleted entry.","lastModifiedDate":"2023-11-02"},{"lineNumber":348,"author":{"gitId":"karishma-t"},"content":"If the drug is successfully deleted, it returns a success message. ","lastModifiedDate":"2023-11-02"},{"lineNumber":349,"author":{"gitId":"karishma-t"},"content":"If the drug is not found (i.e., a DrugNotFoundException is thrown), it returns a failure message.","lastModifiedDate":"2023-11-02"},{"lineNumber":350,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":351,"author":{"gitId":"karishma-t"},"content":"---","lastModifiedDate":"2023-10-26"},{"lineNumber":352,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":353,"author":{"gitId":"TeoHaoZhi"},"content":"## 4. Help Command","lastModifiedDate":"2023-10-29"},{"lineNumber":354,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":355,"author":{"gitId":"TeoHaoZhi"},"content":"The command is responsible for showing users a list of all possible commands.","lastModifiedDate":"2023-10-29"},{"lineNumber":356,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":357,"author":{"gitId":"TeoHaoZhi"},"content":"**Design Considerations**","lastModifiedDate":"2023-10-29"},{"lineNumber":358,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":359,"author":{"gitId":"TeoHaoZhi"},"content":"The command was designed to print out and show how to use a list of all possible commands in a neat and concise way.","lastModifiedDate":"2023-10-29"},{"lineNumber":360,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":361,"author":{"gitId":"TeoHaoZhi"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-10-29"},{"lineNumber":362,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":363,"author":{"gitId":"TeoHaoZhi"},"content":"Command will use java\u0027s system out to print out all required information with a blank line in between for clarity.","lastModifiedDate":"2023-10-29"},{"lineNumber":364,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":365,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":366,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":367,"author":{"gitId":"TeoHaoZhi"},"content":"## 5. Save Command","lastModifiedDate":"2023-10-29"},{"lineNumber":368,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":369,"author":{"gitId":"TeoHaoZhi"},"content":"The save command was made as a means to backup user entered drug data into the hard drive of the computer to ensure","lastModifiedDate":"2023-10-29"},{"lineNumber":370,"author":{"gitId":"TeoHaoZhi"},"content":"previously entered data is saved and accessable whenever the app is launched.","lastModifiedDate":"2023-10-29"},{"lineNumber":371,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":372,"author":{"gitId":"TeoHaoZhi"},"content":"### Design Considerations","lastModifiedDate":"2023-10-29"},{"lineNumber":373,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":374,"author":{"gitId":"TeoHaoZhi"},"content":"The save command had to be implemented in a way to enable direct writing of files onto the hard drive and a function had","lastModifiedDate":"2023-10-29"},{"lineNumber":375,"author":{"gitId":"TeoHaoZhi"},"content":"to be made to load said file back into the drug inventory upon starting the application.","lastModifiedDate":"2023-10-29"},{"lineNumber":376,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":377,"author":{"gitId":"TeoHaoZhi"},"content":"### Implementation","lastModifiedDate":"2023-10-29"},{"lineNumber":378,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":379,"author":{"gitId":"TeoHaoZhi"},"content":"There is a method to access the drugs within the inventory class. a separate method from the inventory class would then","lastModifiedDate":"2023-10-29"},{"lineNumber":380,"author":{"gitId":"TeoHaoZhi"},"content":"write the contents of these drugs back to the txt file for saving.","lastModifiedDate":"2023-10-29"},{"lineNumber":381,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":382,"author":{"gitId":"TeoHaoZhi"},"content":"Upon booting up the system, a method from the inventory class goes through the contents of the txt file and copies it to","lastModifiedDate":"2023-10-29"},{"lineNumber":383,"author":{"gitId":"TeoHaoZhi"},"content":"the inventory drug list.","lastModifiedDate":"2023-10-29"},{"lineNumber":384,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":385,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":386,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":387,"author":{"gitId":"TeoHaoZhi"},"content":"## 6. addVendor Command","lastModifiedDate":"2023-10-29"},{"lineNumber":388,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":389,"author":{"gitId":"TeoHaoZhi"},"content":"The command was made to add vendors to a list of vendors so as to have access to it when needed.","lastModifiedDate":"2023-10-29"},{"lineNumber":390,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":391,"author":{"gitId":"TeoHaoZhi"},"content":"### Design Considerations","lastModifiedDate":"2023-10-29"},{"lineNumber":392,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":393,"author":{"gitId":"TeoHaoZhi"},"content":"The storage must be size adjustable based on the number of objects, in this case vendors placed into it.","lastModifiedDate":"2023-10-29"},{"lineNumber":394,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":395,"author":{"gitId":"TeoHaoZhi"},"content":"### Implementation","lastModifiedDate":"2023-10-29"},{"lineNumber":396,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":397,"author":{"gitId":"TeoHaoZhi"},"content":"In order to attain the adjustable storage based on numebr of objects, an ArrayList was used as additional vendors can be","lastModifiedDate":"2023-10-29"},{"lineNumber":398,"author":{"gitId":"TeoHaoZhi"},"content":"appended to the ArrayList whenever a new entry is required.","lastModifiedDate":"2023-10-29"},{"lineNumber":399,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":400,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":401,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":402,"author":{"gitId":"TeoHaoZhi"},"content":"## 7. listVendors Command","lastModifiedDate":"2023-10-29"},{"lineNumber":403,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":404,"author":{"gitId":"TeoHaoZhi"},"content":"The command was made to list all vendors being tracked by the system in a neat way to the user","lastModifiedDate":"2023-10-29"},{"lineNumber":405,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":406,"author":{"gitId":"TeoHaoZhi"},"content":"### Design Considerations","lastModifiedDate":"2023-10-29"},{"lineNumber":407,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":408,"author":{"gitId":"TeoHaoZhi"},"content":"The possibility of an empty list had to be considered","lastModifiedDate":"2023-10-29"},{"lineNumber":409,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":410,"author":{"gitId":"TeoHaoZhi"},"content":"### Implementation","lastModifiedDate":"2023-10-29"},{"lineNumber":411,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":412,"author":{"gitId":"TeoHaoZhi"},"content":"The list of vendors could be printed by using streams to efficiently collect and print out the information of vendors","lastModifiedDate":"2023-10-29"},{"lineNumber":413,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":414,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":415,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":416,"author":{"gitId":"karishma-t"},"content":"## 7. addVendorSupply Command","lastModifiedDate":"2023-11-02"},{"lineNumber":417,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":418,"author":{"gitId":"karishma-t"},"content":"This method adds a drug to a vendor\u0027s supply list in the inventory management system, to track ","lastModifiedDate":"2023-11-02"},{"lineNumber":419,"author":{"gitId":"karishma-t"},"content":"what vendors supply what products. ","lastModifiedDate":"2023-11-02"},{"lineNumber":420,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":421,"author":{"gitId":"karishma-t"},"content":"### Design Considerations","lastModifiedDate":"2023-11-02"},{"lineNumber":422,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":423,"author":{"gitId":"karishma-t"},"content":"This method checks if the specified vendor exists and, if so, adds the drug to their supply list.","lastModifiedDate":"2023-11-02"},{"lineNumber":424,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":425,"author":{"gitId":"karishma-t"},"content":"### Implementation","lastModifiedDate":"2023-11-02"},{"lineNumber":426,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":427,"author":{"gitId":"karishma-t"},"content":"The execute method in the AddVendorSupplyCommand class checks if a specified vendor exists, adds a drug to their supply ","lastModifiedDate":"2023-11-02"},{"lineNumber":428,"author":{"gitId":"karishma-t"},"content":"list, and returns a success message. If the vendor is not found, it returns a message indicating that the vendor was ","lastModifiedDate":"2023-11-02"},{"lineNumber":429,"author":{"gitId":"karishma-t"},"content":"not found.","lastModifiedDate":"2023-11-02"},{"lineNumber":430,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":431,"author":{"gitId":"karishma-t"},"content":"---","lastModifiedDate":"2023-11-02"},{"lineNumber":432,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":433,"author":{"gitId":"azfarulmatin"},"content":"## 5. CommandResult Class","lastModifiedDate":"2023-11-01"},{"lineNumber":434,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":435,"author":{"gitId":"azfarulmatin"},"content":"The `CommandResult` class is a crucial part of the Stocker application, responsible for providing feedback and results to the user after executing various commands. It contains a feedback message to describe the outcome of the command execution, as well as an optional list of relevant elements produced by the command.","lastModifiedDate":"2023-11-01"},{"lineNumber":436,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":437,"author":{"gitId":"azfarulmatin"},"content":"**Design Considerations**","lastModifiedDate":"2023-11-01"},{"lineNumber":438,"author":{"gitId":"azfarulmatin"},"content":"The design of the `CommandResult` class considers the following aspects:","lastModifiedDate":"2023-11-01"},{"lineNumber":439,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":440,"author":{"gitId":"azfarulmatin"},"content":"1. **Feedback Message:** The class stores a feedback message to inform the user about the outcome of the executed command.","lastModifiedDate":"2023-11-01"},{"lineNumber":441,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":442,"author":{"gitId":"azfarulmatin"},"content":"2. **Relevant Elements:** For commands that produce a list of relevant elements, the `CommandResult` can store this list for display.","lastModifiedDate":"2023-11-01"},{"lineNumber":443,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":444,"author":{"gitId":"azfarulmatin"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"azfarulmatin"},"content":"The `CommandResult` class is implemented with two constructors and methods to access relevant elements and construct feedback messages.","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"azfarulmatin"},"content":"- `CommandResult(String feedbackToUser)`: This constructor is used when there are no relevant elements to be included in the result. It sets the feedback message.","lastModifiedDate":"2023-11-01"},{"lineNumber":449,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"azfarulmatin"},"content":"- `CommandResult(String feedbackToUser, List\u003cT\u003e relevantElements)`: This constructor is used when the command produces a list of relevant elements (e.g., a list of drugs). It sets both the feedback message and the list of relevant elements.","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":452,"author":{"gitId":"azfarulmatin"},"content":"- `getRelevantElements()`: This method returns an optional list of relevant elements. It can be used to check if relevant elements are present.","lastModifiedDate":"2023-11-01"},{"lineNumber":453,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":454,"author":{"gitId":"azfarulmatin"},"content":"- `getFeedbackToUser()`: This method returns the feedback message as a string.","lastModifiedDate":"2023-11-01"},{"lineNumber":455,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":456,"author":{"gitId":"azfarulmatin"},"content":"- `getFeedbackToUserWithElements()`: This method constructs a feedback message that includes the relevant elements. It formats the list of elements with serial numbers (if applicable) and includes the feedback message.","lastModifiedDate":"2023-11-01"},{"lineNumber":457,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":458,"author":{"gitId":"azfarulmatin"},"content":"**Example Usage**","lastModifiedDate":"2023-11-01"},{"lineNumber":459,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":460,"author":{"gitId":"azfarulmatin"},"content":"The `CommandResult` class is used throughout the Stocker application to provide feedback to the user after executing commands. For example, when a user issues a `list` command, the `CommandResult` includes a list of drugs produced by the command along with the success message. The feedback message is then displayed to the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":461,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":462,"author":{"gitId":"azfarulmatin"},"content":"The following sequence diagram shows how the Command Result function works.","lastModifiedDate":"2023-11-01"},{"lineNumber":463,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":464,"author":{"gitId":"azfarulmatin"},"content":"\u003cimg src\u003d\"UML Diagrams/CommandResultDiagram.png\" width\u003d\"350\"\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":465,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":466,"author":{"gitId":"azfarulmatin"},"content":"---","lastModifiedDate":"2023-11-01"},{"lineNumber":467,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":468,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":469,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":470,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":471,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":472,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":473,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":474,"author":{"gitId":"Barbaracwx"},"content":"- Works in the field of drug distribution, such as pharmacies and doctors\u0027 offices.","lastModifiedDate":"2023-10-25"},{"lineNumber":475,"author":{"gitId":"Barbaracwx"},"content":"- Manages a large inventory of pharmaceuticals with varying details (expiration dates, manufacturers, storage","lastModifiedDate":"2023-10-25"},{"lineNumber":476,"author":{"gitId":"Barbaracwx"},"content":" conditions).","lastModifiedDate":"2023-10-25"},{"lineNumber":477,"author":{"gitId":"Barbaracwx"},"content":"- Prefers desktop applications for their work.","lastModifiedDate":"2023-10-25"},{"lineNumber":478,"author":{"gitId":"Barbaracwx"},"content":"- Proficient in fast typing.","lastModifiedDate":"2023-10-25"},{"lineNumber":479,"author":{"gitId":"Barbaracwx"},"content":"- Favors typing over mouse interactions.","lastModifiedDate":"2023-10-25"},{"lineNumber":480,"author":{"gitId":"Barbaracwx"},"content":"- Comfortable using Command Line Interface (CLI) applications for efficiency.","lastModifiedDate":"2023-10-25"},{"lineNumber":481,"author":{"gitId":"Barbaracwx"},"content":"- Requires password-protected access to sensitive patient healthcare information.","lastModifiedDate":"2023-10-25"},{"lineNumber":482,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":483,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":484,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":485,"author":{"gitId":"Barbaracwx"},"content":"**Stocker** is designed to cater to the specific needs of drug distributors by offering the following benefits:","lastModifiedDate":"2023-10-25"},{"lineNumber":486,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":487,"author":{"gitId":"Barbaracwx"},"content":"1. Quick access to real-time inventory information.","lastModifiedDate":"2023-10-25"},{"lineNumber":488,"author":{"gitId":"Barbaracwx"},"content":"2. Efficient tracking of incoming stock.","lastModifiedDate":"2023-10-25"},{"lineNumber":489,"author":{"gitId":"Barbaracwx"},"content":"3. Categorization of drugs based on various labels.","lastModifiedDate":"2023-10-25"},{"lineNumber":490,"author":{"gitId":"Barbaracwx"},"content":"4. A prioritized list of urgently needed restocks for timely replenishment.","lastModifiedDate":"2023-10-25"},{"lineNumber":491,"author":{"gitId":"Barbaracwx"},"content":"5. Assistance in generating comprehensive reports for stock turnover analysis.","lastModifiedDate":"2023-10-25"},{"lineNumber":492,"author":{"gitId":"Barbaracwx"},"content":"6. Secure access through individual user accounts to safeguard patient healthcare data.","lastModifiedDate":"2023-10-25"},{"lineNumber":493,"author":{"gitId":"Barbaracwx"},"content":"7. Enhanced user experience for experienced professionals who prefer keyboard commands and CLI interactions for seamless","lastModifiedDate":"2023-10-25"},{"lineNumber":494,"author":{"gitId":"Barbaracwx"},"content":" stock management.","lastModifiedDate":"2023-10-25"},{"lineNumber":495,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":496,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":497,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":498,"author":{"gitId":"martinschnder"},"content":"Priorities: High (must have) - \\* \\* _, Medium (nice to have) - _ _, Low (unlikely to have) - _","lastModifiedDate":"2023-10-25"},{"lineNumber":499,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":500,"author":{"gitId":"Barbaracwx"},"content":"| Priority | Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2023-10-25"},{"lineNumber":501,"author":{"gitId":"Barbaracwx"},"content":"|----------|---------|----------------------|------------------------------------------------------|-------------------------------------------------------------|","lastModifiedDate":"2023-10-31"},{"lineNumber":502,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Pharmacist | Add drugs to track what drugs are available in stock | Reduce manual errors |","lastModifiedDate":"2023-10-25"},{"lineNumber":503,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Pharmacist | Remove drugs to track what are no longer in used | Ensure compliance |","lastModifiedDate":"2023-10-25"},{"lineNumber":504,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Receptionist | View a list of products of that category | Easily obtain an overview of the products |","lastModifiedDate":"2023-10-25"},{"lineNumber":505,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | First-time user | See a list of all available actions | Better understand how to use the application |","lastModifiedDate":"2023-10-25"},{"lineNumber":506,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Inventory Manager | Find a specific drug currently in the system | Check up its details and quantities specifically |","lastModifiedDate":"2023-10-25"},{"lineNumber":507,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v2.0 | user | Find a to-do item by name | Locate a to-do without having to go through the entire list |","lastModifiedDate":"2023-10-30"},{"lineNumber":508,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v1.0 | user | Have a way to login to the system | Access the system only if i am allowed to |","lastModifiedDate":"2023-10-30"},{"lineNumber":509,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* | v2.0 | System Administrator | Perfrom regular backup of inventory database | Safeguard against data loss and system failure |","lastModifiedDate":"2023-10-30"},{"lineNumber":510,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v2.0 | Receptionist | Add vendors supplying drugs into the system | Keep track of what vendors i am working with |","lastModifiedDate":"2023-10-30"},{"lineNumber":511,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v2.0 | Receptionist | View a list of vendors | Easily know who to contact if drugs need to be restocked |","lastModifiedDate":"2023-10-30"},{"lineNumber":512,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":513,"author":{"gitId":"martinschnder"},"content":"_(More to be added)_","lastModifiedDate":"2023-10-25"},{"lineNumber":514,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":515,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":516,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":517,"author":{"gitId":"Barbaracwx"},"content":"1. Should work on any mainstream OS as long as it has Java 11 or above installed.","lastModifiedDate":"2023-10-25"},{"lineNumber":518,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":519,"author":{"gitId":"Barbaracwx"},"content":"2. Should be able to hold up to 1000 drug entries without a noticeable sluggishness in performance for typical usage.","lastModifiedDate":"2023-10-25"},{"lineNumber":520,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":521,"author":{"gitId":"Barbaracwx"},"content":"3. A user with above-average typing speed for regular English text (i.e. not code, not system admin commands) should be","lastModifiedDate":"2023-10-25"},{"lineNumber":522,"author":{"gitId":"Barbaracwx"},"content":" able to accomplish most of the tasks faster using commands than using the mouse.","lastModifiedDate":"2023-10-25"},{"lineNumber":523,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":524,"author":{"gitId":"martinschnder"},"content":"_(More to be added)_","lastModifiedDate":"2023-10-25"},{"lineNumber":525,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":526,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":527,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":528,"author":{"gitId":"martinschnder"},"content":"- _glossary item_ - Definition","lastModifiedDate":"2023-10-25"},{"lineNumber":529,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":530,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":531,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":532,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"karishma-t":34,"martinschnder":40,"azfarulmatin":79,"TeoHaoZhi":120,"-":30,"Barbaracwx":229}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"# Stocker","lastModifiedDate":"2023-10-10"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker v1.o is a desktop app that will provide quick access to currently available stock,","lastModifiedDate":"2023-10-10"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"track incoming stock and expiration dates, and categorize drugs based on different labels.","lastModifiedDate":"2023-10-10"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"It is optimized for use via a Command Line Interface (CLI). If you can type fast, Stocker","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"can get your inventory management tasks done faster than traditional GUI apps.","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":8,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"TeoHaoZhi":5,"-":6}},{"path":"docs/UML Diagrams/ArchitectureDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"title Architecture Diagram","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"skinparam component {","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"BackgroundColor lightblue","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"[Parser]","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"[Commands]","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"[CommandResult]","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"[LoginSystem and Ui] as interactor","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"interface \"user\"","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"user -[hidden]- Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"CommandResult -[hidden]- Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"interactor --\u003e Parser : Makes sense of input","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"Parser -\u003e Commands : Searches for inputted command","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"Commands -\u003e CommandResult : Executes relevant command","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"CommandResult -\u003e interactor : Return control","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"user -[#red]-\u003e interactor : Logs in or Register","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"TeoHaoZhi":25}},{"path":"docs/UML Diagrams/CommandResultDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"title CommandResult Sequence Diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"actor User","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"participant Command","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"participant CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":"User -\u003e Command: Execute Command","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"activate Command","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":"Command -\u003e CommandResult: Create CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"azfarulmatin"},"content":"activate CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":"CommandResult --\u003e Command: Return CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":"deactivate CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":"Command -\u003e User: Return CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":"deactivate Command","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"azfarulmatin":20}},{"path":"docs/UML Diagrams/FindCommandArchitectureDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"@startuml FindCommandArchitectureDiagram","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"!define LOGIC_COLOR #3333C4","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"!define ARROW_STYLE [-[#LOGIC_COLOR]-\u003e]","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"actor User as U","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"package \"Your Application\" {","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":" [User Interface] as UI","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" [FindCommand] as FindCmd","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":" [Inventory] as Inv","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":" [StockEntry] as Entry","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" [CommandResult] as CmdResult","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"U -down-\u003e UI: Initiates \u0027Find\u0027 Command","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"UI -down-\u003e FindCmd: Invokes \u0027FindCommand\u0027","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"UI -down-\u003e Inv: Accesses \u0027Inventory\u0027","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"FindCmd -down-\u003e Entry: Iterates Through Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"Entry -down-\u003e Entry: Checks Each Entry","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"Entry --\u003e FindCmd: Match/No Match","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":"FindCmd --\u003e CmdResult: Prepares Result","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":"CmdResult -up-\u003e UI: Returns Result","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":"CmdResult -up-\u003e U: Displays Search Results","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"Barbaracwx":26}},{"path":"docs/UML Diagrams/FindCommandDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"@startuml FindCommandDiagram","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"!define LOGIC_COLOR #3333C4","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"!define LOGIC_COLOR_T1 #7777DB","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"hide footbox","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"actor User","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"participant \"FindCommand\" as FindCmd LOGIC_COLOR_T1","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"participant \"Inventory\" as Inventory LOGIC_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"User -\u003e FindCmd: Execute \u0027Find\u0027 Command","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"activate FindCmd","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"User \u003c-- FindCmd: CommandResult","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"FindCmd -\u003e Inventory: Retrieve Stock Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"activate Inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"Inventory --\u003e FindCmd: List of Stock Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"FindCmd -\u003e FindCmd: Process Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"FindCmd --\u003e User: Display Search Results","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"Barbaracwx":22}},{"path":"docs/UML Diagrams/ListCommandDiagram.uml.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"@startuml ListCommandDiagram","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"!define LOGIC_COLOR #3333C4","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"!define LOGIC_COLOR_T1 #7777DB","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"hide footbox","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"azfarulmatin"},"content":"actor User","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":"participant \"ListCommand\" as ListCmd LOGIC_COLOR_T1","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"participant \"Inventory\" as Inventory LOGIC_COLOR","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":"User -\u003e ListCmd: Execute \u0027List\u0027 Command","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"azfarulmatin"},"content":"activate ListCmd","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":"User \u003c-- ListCmd: CommandResult","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":"ListCmd -\u003e Inventory: Retrieve Stock Entries","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":"activate Inventory","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":"Inventory --\u003e ListCmd: List of Stock Entries","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":"ListCmd -\u003e ListCmd: Process Entries","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":"ListCmd --\u003e User: Display List Results","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"azfarulmatin":21}},{"path":"docs/UML Diagrams/ParserDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"hide footbox","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"actor User","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"participant \"User Input\" as UserInput","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"participant \"Parser\" as Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"participant \"IncorrectCommand\" as IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"User -\u003e UserInput: Enter command","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"UserInput -\u003e Parser: parseCommand(userInput)","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"activate Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e Parser: Split the input into command and arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"alt Command found","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e Parser: commandWord \u003d Extract command word","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e Parser: arguments \u003d Extract arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"else Command not found","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e IncorrectCommand: Create IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"Parser --\u003e Parser: return IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"end","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e IncorrectCommand: Create IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"Parser --\u003e Parser: return IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"deactivate Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"Barbaracwx":21}},{"path":"docs/UML Diagrams/StockerToLoginSystem.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"@startuml","lastModifiedDate":"2023-10-21"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-21"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"hide footbox","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"actor User","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"Participant \":Stocker\" as Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"Participant \":Ui\" as Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"Participant \":LoginSystem\" as LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"User -\u003e Stocker : Stocker()","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"activate Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e Stocker : run()","lastModifiedDate":"2023-10-21"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"activate Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e Stocker :start()","lastModifiedDate":"2023-10-21"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e Ui : Ui()","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"activate Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"Ui -\u003e Ui : showLoginMessage()","lastModifiedDate":"2023-10-21"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"activate Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"Ui -\u003e Ui : ShowToUser()","lastModifiedDate":"2023-10-21"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"Ui --\u003e User : LoginMessage","lastModifiedDate":"2023-10-21"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e LoginSystem :LoginSystem()","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"activate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem : run()","lastModifiedDate":"2023-10-21"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"activate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem : loadExistingUsers()","lastModifiedDate":"2023-10-21"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem: authenticateUserChoice()","lastModifiedDate":"2023-10-21"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":"User -\u003e LoginSystem : register or login input","lastModifiedDate":"2023-10-21"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":"alt Register","lastModifiedDate":"2023-10-21"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem : newUserCreator()","lastModifiedDate":"2023-10-21"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem --\u003e User : showSuccessfulRegistrationMessage()","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":"else Login","lastModifiedDate":"2023-10-21"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003eLoginSystem : loginExistingUser()","lastModifiedDate":"2023-10-21"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem --\u003e User: showSuccessfulLoginMessage()","lastModifiedDate":"2023-10-21"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"end","lastModifiedDate":"2023-10-21"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":"@enduml","lastModifiedDate":"2023-10-21"}],"authorContributionMap":{"TeoHaoZhi":47}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# User Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"## Table of contents","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"- [Introduction](#introduction)","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"- [Quick Start](#quick-start)","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"- [Features](#features)","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"- [Usage](#usage)","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"- [FAQ](#faq)","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"- [Command Summary](#command-summary)","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker is a desktop app that will provide quick access to currently available stock,","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"track incoming stock and expiration dates, and categorize drugs based on different labels.","lastModifiedDate":"2023-10-10"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"It is optimized for use via a Command Line Interface (CLI). If you can type fast, Stocker","lastModifiedDate":"2023-10-10"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"can get your inventory management tasks done faster than traditional GUI apps.","lastModifiedDate":"2023-10-10"},{"lineNumber":17,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":20,"author":{"gitId":"-"},"content":"{Give steps to get started quickly}","lastModifiedDate":"2020-05-24"},{"lineNumber":21,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":22,"author":{"gitId":"-"},"content":"1. Ensure that you have Java 11 or above installed.","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"2. Down the latest version of `Stocker` from [here](https://github.com/AY2324S1-CS2113-T17-3/tp/releases).","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"3. Copy the absolute filepath to where the jar file is","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"4. Run the following JAR file with the following command","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"java -jar \"\u003cFile path of jar file\u003e\"","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"-"},"content":"## Features","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-Login System","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":"Authentication system that allows user to register as a user or login","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":"as an existing user.","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-add","lastModifiedDate":"2023-10-10"},{"lineNumber":38,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a drug into the inventory list.","lastModifiedDate":"2023-10-10"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-delete","lastModifiedDate":"2023-10-10"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":"Deletes a drug being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-list","lastModifiedDate":"2023-10-10"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":"List all drug information that is being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-find","lastModifiedDate":"2023-10-10"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":"Finds drugs using their name or expiry date.","lastModifiedDate":"2023-10-20"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-help","lastModifiedDate":"2023-10-10"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":"List all currently available commands in current version, their","lastModifiedDate":"2023-10-10"},{"lineNumber":56,"author":{"gitId":"TeoHaoZhi"},"content":"uses and how to format them in the command line.","lastModifiedDate":"2023-10-10"},{"lineNumber":57,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":58,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-register","lastModifiedDate":"2023-10-20"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":60,"author":{"gitId":"TeoHaoZhi"},"content":"Register a new user into the login system.","lastModifiedDate":"2023-10-20"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-login","lastModifiedDate":"2023-10-20"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":"Login an existing user into the system.","lastModifiedDate":"2023-10-20"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-save","lastModifiedDate":"2023-10-21"},{"lineNumber":67,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":"Save existing drugs from inventory list onto a txt file.","lastModifiedDate":"2023-10-21"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":"File is then used to update inventory list when stocker is ran.","lastModifiedDate":"2023-10-21"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-add vendor","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a vendor into a list to be tracked by the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-list vendors","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":"Displays the name of all vendors being tracked by the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"karishma-t"},"content":"### Feature-add vendor supply","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"karishma-t"},"content":"Adds a drug into a vendor\u0027s supply list to be tracked by the system. ","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"karishma-t"},"content":"### Feature-list vendor supply","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"karishma-t"},"content":"Displays the list of all drugs being supplied by a particular vendor. ","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"karishma-t"},"content":"### Feature-find vendor supply","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"karishma-t"},"content":"Displays the list of all vendors that supply a particular drug. ","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"martinschnder"},"content":"### Feature-add to cart","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"martinschnder"},"content":"Adds a drug to the current cart if the requested quantity is available in the inventory.","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"martinschnder"},"content":"### Feature-view cart","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"karishma-t"},"content":"List all added drugs in the current cart.","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"martinschnder"},"content":"### Feature-checkout","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"martinschnder"},"content":"Empty the current cart and retrieve the specified items and quantity from the inventory.","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"karishma-t"},"content":"### Feature-add description","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"karishma-t"},"content":"Adds a drug\u0027s description into a list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"karishma-t"},"content":"### Feature-get description","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"karishma-t"},"content":"Retrieves the description of a particular drug. ","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"karishma-t"},"content":"### Feature-list description","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"karishma-t"},"content":"Displays a list of all the descriptions for all corresponding drugs","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":"## Usage","lastModifiedDate":"2023-10-10"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":116,"author":{"gitId":"TeoHaoZhi"},"content":"### `Login System`- Create new user or login existing user","lastModifiedDate":"2023-10-15"},{"lineNumber":117,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":118,"author":{"gitId":"TeoHaoZhi"},"content":"Login system is automatically launched at the start of the programme.","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":120,"author":{"gitId":"TeoHaoZhi"},"content":"**Registering a user**","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":122,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 1 : Enter register to select option to register a user.","lastModifiedDate":"2023-10-20"},{"lineNumber":123,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e ","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e `register`","lastModifiedDate":"2023-11-04"},{"lineNumber":125,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 2: Enter desired username and password.","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-10-15"},{"lineNumber":128,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Upon successful creation, registration success message is observed","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"TeoHaoZhi"},"content":"Registration successful.","lastModifiedDate":"2023-10-15"},{"lineNumber":134,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"TeoHaoZhi"},"content":"**Login an existing user**","lastModifiedDate":"2023-10-15"},{"lineNumber":137,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":138,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 1 : Enter login to select option to login a user.","lastModifiedDate":"2023-10-20"},{"lineNumber":139,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-10-15"},{"lineNumber":140,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e `login`","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e ","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 2: Enter registered username and password.","lastModifiedDate":"2023-10-15"},{"lineNumber":143,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-10-15"},{"lineNumber":144,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Upon successful creation, successful login message is observed.","lastModifiedDate":"2023-10-15"},{"lineNumber":145,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":146,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-15"},{"lineNumber":147,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":148,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":149,"author":{"gitId":"TeoHaoZhi"},"content":"Login Successful.","lastModifiedDate":"2023-10-15"},{"lineNumber":150,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":151,"author":{"gitId":"TeoHaoZhi"},"content":"Note","lastModifiedDate":"2023-11-04"},{"lineNumber":152,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":153,"author":{"gitId":"TeoHaoZhi"},"content":"### `add` - Adds drug into inventory list","lastModifiedDate":"2023-10-10"},{"lineNumber":154,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":155,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a drug to be tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":156,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":157,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":158,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":159,"author":{"gitId":"TeoHaoZhi"},"content":"add /n DRUG_NAME /d EXPIRY_DATE /s SERIAL_NUMBER /q QUANTITY","lastModifiedDate":"2023-11-04"},{"lineNumber":160,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":161,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":162,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":163,"author":{"gitId":"TeoHaoZhi"},"content":"`add /n Panadol /d 12 June 2026 /s ABC123 /q 52","lastModifiedDate":"2023-11-04"},{"lineNumber":164,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":165,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":166,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":167,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":168,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":169,"author":{"gitId":"Barbaracwx"},"content":"|| New drug added in the inventory: Panadol","lastModifiedDate":"2023-10-29"},{"lineNumber":170,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":171,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"TeoHaoZhi"},"content":"### `delete` - Deletes a drug being tracked by the system","lastModifiedDate":"2023-10-10"},{"lineNumber":173,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":174,"author":{"gitId":"TeoHaoZhi"},"content":"Deletes a drug being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":175,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":176,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":177,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":178,"author":{"gitId":"TeoHaoZhi"},"content":"delete /n DRUG_NAM","lastModifiedDate":"2023-10-10"},{"lineNumber":179,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":180,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":181,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":182,"author":{"gitId":"TeoHaoZhi"},"content":"`delete /n Panadol","lastModifiedDate":"2023-10-10"},{"lineNumber":183,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":184,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":185,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":186,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":187,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":188,"author":{"gitId":"Barbaracwx"},"content":"|| removed : Panadol","lastModifiedDate":"2023-10-29"},{"lineNumber":189,"author":{"gitId":"Barbaracwx"},"content":"|| There are now 0 drugs in the system","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":191,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":192,"author":{"gitId":"TeoHaoZhi"},"content":"### `list` - List all drug information that is being tracked by the system","lastModifiedDate":"2023-10-10"},{"lineNumber":193,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":194,"author":{"gitId":"TeoHaoZhi"},"content":"List all drug information that is being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":195,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":196,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":197,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":198,"author":{"gitId":"TeoHaoZhi"},"content":"list","lastModifiedDate":"2023-10-10"},{"lineNumber":199,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":200,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":201,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":202,"author":{"gitId":"TeoHaoZhi"},"content":"`list","lastModifiedDate":"2023-10-10"},{"lineNumber":203,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":204,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":205,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":206,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":207,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":208,"author":{"gitId":"TeoHaoZhi"},"content":"|| 1. Name: Panadol, Expiry Date: 12 June 2026/ Quantity: 300","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"Barbaracwx"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"Barbaracwx"},"content":"|| Listed all drugs in the inventory.","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"Barbaracwx"},"content":"### `stocklevel` - List all drugs by quantity level in ascending order","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"Barbaracwx"},"content":"List all drugs by quantity level in ascending order.","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"Barbaracwx"},"content":"stocklevel","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"Barbaracwx"},"content":"`stocklevel","lastModifiedDate":"2023-10-29"},{"lineNumber":224,"author":{"gitId":"Barbaracwx"},"content":"`","lastModifiedDate":"2023-10-29"},{"lineNumber":225,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":228,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":229,"author":{"gitId":"Barbaracwx"},"content":"|| \t1. Name: histamine, Expiry date: 101010, Quantity: 10","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"Barbaracwx"},"content":"|| \t2. Name: paracetamol, Expiry date: 101010, Quantity: 50","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"Barbaracwx"},"content":"|| \t3. Name: panadol, Expiry date: 101010, Quantity: 120","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"Barbaracwx"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":233,"author":{"gitId":"Barbaracwx"},"content":"|| Stock Level Report (Sorted by Quantity)","lastModifiedDate":"2023-10-29"},{"lineNumber":234,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"Barbaracwx"},"content":"### `find` - Finds drugs using their name or expiry date","lastModifiedDate":"2023-10-20"},{"lineNumber":237,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":238,"author":{"gitId":"Barbaracwx"},"content":"1. Finds drugs whose **names** contain any of the given keywords.","lastModifiedDate":"2023-10-20"},{"lineNumber":239,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":240,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":241,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":242,"author":{"gitId":"Barbaracwx"},"content":"find /n panadol","lastModifiedDate":"2023-10-20"},{"lineNumber":243,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":244,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":245,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":246,"author":{"gitId":"martinschnder"},"content":"`find /n KEYWORD `","lastModifiedDate":"2023-10-31"},{"lineNumber":247,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"Barbaracwx"},"content":"- The search is case-insensitive, meaning that \"aspirin\" will match \"Aspirin.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":249,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":250,"author":{"gitId":"Barbaracwx"},"content":"- The order of the keywords does not matter. For example, \"Painkiller Relief\" will match \"Relief Painkiller.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":251,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":252,"author":{"gitId":"Barbaracwx"},"content":"- Only the drug name is searched.","lastModifiedDate":"2023-10-20"},{"lineNumber":253,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":254,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-10-20"},{"lineNumber":255,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":256,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":257,"author":{"gitId":"Barbaracwx"},"content":"|| 1. Name: panadol, Expiry Date: 12 sep, Quantity: 120","lastModifiedDate":"2023-10-29"},{"lineNumber":258,"author":{"gitId":"Barbaracwx"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":259,"author":{"gitId":"Barbaracwx"},"content":"|| Listed all drugs with the keyword in the inventory.","lastModifiedDate":"2023-10-29"},{"lineNumber":260,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":261,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"Barbaracwx"},"content":"2. Finds drugs whose **expiry dates** contain any of the given keywords.","lastModifiedDate":"2023-10-20"},{"lineNumber":263,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":264,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-10-20"},{"lineNumber":265,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":266,"author":{"gitId":"Barbaracwx"},"content":"find /d sep","lastModifiedDate":"2023-10-20"},{"lineNumber":267,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":268,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-10-20"},{"lineNumber":269,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":270,"author":{"gitId":"martinschnder"},"content":"`find /d KEYWORD`","lastModifiedDate":"2023-10-31"},{"lineNumber":271,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":272,"author":{"gitId":"Barbaracwx"},"content":"- Only the drug\u0027s expiry date is searched.","lastModifiedDate":"2023-10-20"},{"lineNumber":273,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":274,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":275,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":276,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":277,"author":{"gitId":"Barbaracwx"},"content":"1. Name: panadol, Expiry Date: 12 sep, Quantity: 120","lastModifiedDate":"2023-10-20"},{"lineNumber":278,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":279,"author":{"gitId":"Barbaracwx"},"content":"Listed all drugs with the keyword in the inventory.","lastModifiedDate":"2023-10-20"},{"lineNumber":280,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":281,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":282,"author":{"gitId":"TeoHaoZhi"},"content":"### `help` - List currently available commands in current version, their uses and how to format them in the command line","lastModifiedDate":"2023-10-10"},{"lineNumber":283,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":284,"author":{"gitId":"TeoHaoZhi"},"content":"List all currently available commands in current version,","lastModifiedDate":"2023-10-10"},{"lineNumber":285,"author":{"gitId":"TeoHaoZhi"},"content":"their uses and how to format them in the command line","lastModifiedDate":"2023-10-10"},{"lineNumber":286,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":287,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":288,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":289,"author":{"gitId":"TeoHaoZhi"},"content":"help","lastModifiedDate":"2023-10-10"},{"lineNumber":290,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":291,"author":{"gitId":"-"},"content":"Example of usage:","lastModifiedDate":"2020-05-24"},{"lineNumber":292,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":293,"author":{"gitId":"TeoHaoZhi"},"content":"`help","lastModifiedDate":"2023-10-10"},{"lineNumber":294,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":295,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":296,"author":{"gitId":"TeoHaoZhi"},"content":"### `register` - Register a new user into the system","lastModifiedDate":"2023-10-20"},{"lineNumber":297,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":298,"author":{"gitId":"TeoHaoZhi"},"content":"Asks for user input for a username and password field which","lastModifiedDate":"2023-10-20"},{"lineNumber":299,"author":{"gitId":"TeoHaoZhi"},"content":"will be used to create a new user for the system.","lastModifiedDate":"2023-10-20"},{"lineNumber":300,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":301,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-20"},{"lineNumber":302,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":303,"author":{"gitId":"TeoHaoZhi"},"content":"register","lastModifiedDate":"2023-10-20"},{"lineNumber":304,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":305,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-20"},{"lineNumber":306,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":307,"author":{"gitId":"TeoHaoZhi"},"content":"`register`","lastModifiedDate":"2023-10-20"},{"lineNumber":308,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":309,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-20"},{"lineNumber":310,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":311,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":312,"author":{"gitId":"TeoHaoZhi"},"content":"Registration Successful.","lastModifiedDate":"2023-10-20"},{"lineNumber":313,"author":{"gitId":"TeoHaoZhi"},"content":"New User Created.","lastModifiedDate":"2023-10-20"},{"lineNumber":314,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":315,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":316,"author":{"gitId":"TeoHaoZhi"},"content":"### `login` - login an existing user into the system","lastModifiedDate":"2023-10-20"},{"lineNumber":317,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":318,"author":{"gitId":"TeoHaoZhi"},"content":"Asks for user input for a username and password field which","lastModifiedDate":"2023-10-20"},{"lineNumber":319,"author":{"gitId":"TeoHaoZhi"},"content":"will be used to check if such a user exists for the system","lastModifiedDate":"2023-10-20"},{"lineNumber":320,"author":{"gitId":"TeoHaoZhi"},"content":"and log the user in.","lastModifiedDate":"2023-10-20"},{"lineNumber":321,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":322,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-20"},{"lineNumber":323,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":324,"author":{"gitId":"TeoHaoZhi"},"content":"login","lastModifiedDate":"2023-10-20"},{"lineNumber":325,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":326,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-20"},{"lineNumber":327,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":328,"author":{"gitId":"TeoHaoZhi"},"content":"`login`","lastModifiedDate":"2023-10-20"},{"lineNumber":329,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":330,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-20"},{"lineNumber":331,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":332,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":333,"author":{"gitId":"TeoHaoZhi"},"content":"Login Sucessful","lastModifiedDate":"2023-10-20"},{"lineNumber":334,"author":{"gitId":"TeoHaoZhi"},"content":"Welcome Back!","lastModifiedDate":"2023-10-20"},{"lineNumber":335,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":336,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":337,"author":{"gitId":"TeoHaoZhi"},"content":"### `save` - save existing drugs onto hard drive of computer","lastModifiedDate":"2023-10-21"},{"lineNumber":338,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":339,"author":{"gitId":"TeoHaoZhi"},"content":"Saves existing drugs onto hard drive of computer. The txt file","lastModifiedDate":"2023-10-21"},{"lineNumber":340,"author":{"gitId":"TeoHaoZhi"},"content":"is then used as reference to update drug inventory when stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":341,"author":{"gitId":"TeoHaoZhi"},"content":"is booted up.","lastModifiedDate":"2023-10-21"},{"lineNumber":342,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":343,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-21"},{"lineNumber":344,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":345,"author":{"gitId":"TeoHaoZhi"},"content":"save","lastModifiedDate":"2023-10-21"},{"lineNumber":346,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":347,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-21"},{"lineNumber":348,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":349,"author":{"gitId":"TeoHaoZhi"},"content":"`save`","lastModifiedDate":"2023-10-21"},{"lineNumber":350,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":351,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-21"},{"lineNumber":352,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":353,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-21"},{"lineNumber":354,"author":{"gitId":"TeoHaoZhi"},"content":"Drugs successfully saved.","lastModifiedDate":"2023-10-21"},{"lineNumber":355,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-21"},{"lineNumber":356,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":357,"author":{"gitId":"TeoHaoZhi"},"content":"### `addVendor` - adds a vendor into list of vendors being tracked by system","lastModifiedDate":"2023-10-29"},{"lineNumber":358,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":359,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a vendor to be tracked by the system. The enteries are used to form a list of summarised vendors.","lastModifiedDate":"2023-10-29"},{"lineNumber":360,"author":{"gitId":"TeoHaoZhi"},"content":"is booted up.","lastModifiedDate":"2023-10-29"},{"lineNumber":361,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":362,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-29"},{"lineNumber":363,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":364,"author":{"gitId":"TeoHaoZhi"},"content":"addVendor DRUGNAME","lastModifiedDate":"2023-10-29"},{"lineNumber":365,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":366,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-29"},{"lineNumber":367,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":368,"author":{"gitId":"TeoHaoZhi"},"content":"`addVendor Moderna`","lastModifiedDate":"2023-10-29"},{"lineNumber":369,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":370,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-29"},{"lineNumber":371,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":372,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":373,"author":{"gitId":"TeoHaoZhi"},"content":"New vendor added into the vendors list: Moderna","lastModifiedDate":"2023-10-29"},{"lineNumber":374,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":375,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":376,"author":{"gitId":"TeoHaoZhi"},"content":"### `listVendors` - list all vendors currently being tracked by the system","lastModifiedDate":"2023-10-29"},{"lineNumber":377,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":378,"author":{"gitId":"TeoHaoZhi"},"content":"Displays a list of all vendors currently being tracked by the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":379,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":380,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-29"},{"lineNumber":381,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":382,"author":{"gitId":"TeoHaoZhi"},"content":"listVendors","lastModifiedDate":"2023-10-29"},{"lineNumber":383,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":384,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-29"},{"lineNumber":385,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":386,"author":{"gitId":"TeoHaoZhi"},"content":"`listVendors`","lastModifiedDate":"2023-10-29"},{"lineNumber":387,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":388,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-29"},{"lineNumber":389,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":390,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":391,"author":{"gitId":"TeoHaoZhi"},"content":"|| 1. Name : Moderna","lastModifiedDate":"2023-10-29"},{"lineNumber":392,"author":{"gitId":"TeoHaoZhi"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":393,"author":{"gitId":"TeoHaoZhi"},"content":"||Listed all vendors in the list.","lastModifiedDate":"2023-10-29"},{"lineNumber":394,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":395,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":396,"author":{"gitId":"karishma-t"},"content":"### `addVendorSupply` - Adds a drug into a vendor\u0027s supply list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":397,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":398,"author":{"gitId":"karishma-t"},"content":"Adds a drug into a vendor\u0027s supply list to be tracked by the system, and vendor must already be added into the system. ","lastModifiedDate":"2023-11-01"},{"lineNumber":399,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":400,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":401,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":402,"author":{"gitId":"karishma-t"},"content":"addVendorSupply VENDOR_NAME DRUG_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":403,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":404,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":405,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":406,"author":{"gitId":"karishma-t"},"content":"`addVendorSupply Moderna Paracetamol`","lastModifiedDate":"2023-11-01"},{"lineNumber":407,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":408,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":409,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":410,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":411,"author":{"gitId":"karishma-t"},"content":"|| New drug added to moderna\u0027s supply list: paracetamol","lastModifiedDate":"2023-11-01"},{"lineNumber":412,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":413,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":414,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":415,"author":{"gitId":"karishma-t"},"content":"### `listVendorSupply` - Displays the list of all drugs being supplied by a particular vendor.","lastModifiedDate":"2023-11-01"},{"lineNumber":416,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":417,"author":{"gitId":"karishma-t"},"content":"Displays the list of all drugs being supplied by a particular vendor.","lastModifiedDate":"2023-11-01"},{"lineNumber":418,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":419,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":420,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":421,"author":{"gitId":"karishma-t"},"content":"listVendorSupply VENDOR_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":422,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":423,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":424,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":425,"author":{"gitId":"karishma-t"},"content":"`listVendorSupply Moderna`","lastModifiedDate":"2023-11-01"},{"lineNumber":426,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":427,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":428,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":429,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":430,"author":{"gitId":"karishma-t"},"content":"|| Drugs supplied by Moderna: paracetamol, panadol","lastModifiedDate":"2023-11-01"},{"lineNumber":431,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":432,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":433,"author":{"gitId":"karishma-t"},"content":"### `findVendorSupply` -Displays the list of all vendors that supply a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":434,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":435,"author":{"gitId":"karishma-t"},"content":"Displays the list of all vendors that supply a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":436,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":437,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":438,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":439,"author":{"gitId":"karishma-t"},"content":"findVendorSupply DRUG_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":440,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":441,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":442,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":443,"author":{"gitId":"karishma-t"},"content":"`findVendorSupply paracetamol`","lastModifiedDate":"2023-11-01"},{"lineNumber":444,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"karishma-t"},"content":"|| Vendors supplying the drug paracetamol: moderna, apotheca","lastModifiedDate":"2023-11-01"},{"lineNumber":449,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"martinschnder"},"content":"### `addtocart` - Adds drug into current cart","lastModifiedDate":"2023-10-31"},{"lineNumber":452,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":453,"author":{"gitId":"martinschnder"},"content":"Adds a drug in a specified quantity in the current cart.","lastModifiedDate":"2023-10-31"},{"lineNumber":454,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":455,"author":{"gitId":"martinschnder"},"content":"Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":456,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":457,"author":{"gitId":"martinschnder"},"content":"addtocart /n DRUG_NAME /q QUANTITY","lastModifiedDate":"2023-10-31"},{"lineNumber":458,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":459,"author":{"gitId":"martinschnder"},"content":"Example of usage:","lastModifiedDate":"2023-10-31"},{"lineNumber":460,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":461,"author":{"gitId":"martinschnder"},"content":"`addtocart /n Panadol /q 3","lastModifiedDate":"2023-10-31"},{"lineNumber":462,"author":{"gitId":"martinschnder"},"content":"`","lastModifiedDate":"2023-10-31"},{"lineNumber":463,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":464,"author":{"gitId":"martinschnder"},"content":"Expected outcome:","lastModifiedDate":"2023-10-31"},{"lineNumber":465,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":466,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":467,"author":{"gitId":"martinschnder"},"content":"|| New drug added in the cart : Panadol","lastModifiedDate":"2023-10-31"},{"lineNumber":468,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":469,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":470,"author":{"gitId":"martinschnder"},"content":"### `viewcart` - Lists all the entries in the cart","lastModifiedDate":"2023-10-31"},{"lineNumber":471,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":472,"author":{"gitId":"martinschnder"},"content":"Lists all the added drugs and quantity in the cart.","lastModifiedDate":"2023-10-31"},{"lineNumber":473,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":474,"author":{"gitId":"martinschnder"},"content":"Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":475,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":476,"author":{"gitId":"martinschnder"},"content":"viewcart","lastModifiedDate":"2023-10-31"},{"lineNumber":477,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":478,"author":{"gitId":"martinschnder"},"content":"Example of usage:","lastModifiedDate":"2023-10-31"},{"lineNumber":479,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":480,"author":{"gitId":"martinschnder"},"content":"`viewcart","lastModifiedDate":"2023-10-31"},{"lineNumber":481,"author":{"gitId":"martinschnder"},"content":"`","lastModifiedDate":"2023-10-31"},{"lineNumber":482,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":483,"author":{"gitId":"martinschnder"},"content":"Expected outcome:","lastModifiedDate":"2023-10-31"},{"lineNumber":484,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":485,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":486,"author":{"gitId":"martinschnder"},"content":"|| 1. Key : Panadole, Quantity: 10","lastModifiedDate":"2023-10-31"},{"lineNumber":487,"author":{"gitId":"martinschnder"},"content":"||","lastModifiedDate":"2023-10-31"},{"lineNumber":488,"author":{"gitId":"martinschnder"},"content":"||Listed all the content of your cart.","lastModifiedDate":"2023-10-31"},{"lineNumber":489,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":490,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":491,"author":{"gitId":"martinschnder"},"content":"### `checkout` - Checks out the current cart","lastModifiedDate":"2023-10-31"},{"lineNumber":492,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":493,"author":{"gitId":"martinschnder"},"content":"Empty the current cart and retrieve all the specified drugs and quantity from the inventory","lastModifiedDate":"2023-10-31"},{"lineNumber":494,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":495,"author":{"gitId":"martinschnder"},"content":"Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":496,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":497,"author":{"gitId":"martinschnder"},"content":"checkout","lastModifiedDate":"2023-10-31"},{"lineNumber":498,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":499,"author":{"gitId":"martinschnder"},"content":"Example of usage:","lastModifiedDate":"2023-10-31"},{"lineNumber":500,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":501,"author":{"gitId":"martinschnder"},"content":"`checkout","lastModifiedDate":"2023-10-31"},{"lineNumber":502,"author":{"gitId":"martinschnder"},"content":"`","lastModifiedDate":"2023-10-31"},{"lineNumber":503,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":504,"author":{"gitId":"martinschnder"},"content":"Expected outcome:","lastModifiedDate":"2023-10-31"},{"lineNumber":505,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":506,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":507,"author":{"gitId":"martinschnder"},"content":"|| The current cart has been checked out.","lastModifiedDate":"2023-10-31"},{"lineNumber":508,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":509,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":510,"author":{"gitId":"Barbaracwx"},"content":"### `setthreshold` - Set the threshold quantity for a drug","lastModifiedDate":"2023-11-01"},{"lineNumber":511,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":512,"author":{"gitId":"Barbaracwx"},"content":"Set the threshold quantity for a specific drug in your inventory. The threshold quantity is the minimum quantity of the","lastModifiedDate":"2023-11-01"},{"lineNumber":513,"author":{"gitId":"Barbaracwx"},"content":"drug that you want to keep in stock.","lastModifiedDate":"2023-11-01"},{"lineNumber":514,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":515,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":516,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":517,"author":{"gitId":"Barbaracwx"},"content":"setthreshold /n [Drug Name] /tq [Threshold Quantity]","lastModifiedDate":"2023-11-01"},{"lineNumber":518,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":519,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":520,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":521,"author":{"gitId":"Barbaracwx"},"content":"`setthreshold /n Doliprane /tq 50","lastModifiedDate":"2023-11-01"},{"lineNumber":522,"author":{"gitId":"Barbaracwx"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":523,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":526,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":527,"author":{"gitId":"Barbaracwx"},"content":"|| Threshold quantity set for Doliprane: 50","lastModifiedDate":"2023-11-01"},{"lineNumber":528,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":529,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":530,"author":{"gitId":"Barbaracwx"},"content":"### `listthreshold` - List all drugs and their threshold levels","lastModifiedDate":"2023-11-01"},{"lineNumber":531,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"Barbaracwx"},"content":"Retrieve a list of all drugs in your inventory and their corresponding threshold levels. The threshold level is the","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"Barbaracwx"},"content":"minimum quantity of each drug that you want to keep in stock.","lastModifiedDate":"2023-11-01"},{"lineNumber":534,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"Barbaracwx"},"content":"listthreshold","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":540,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"Barbaracwx"},"content":"`listthreshold","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"Barbaracwx"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":546,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":547,"author":{"gitId":"Barbaracwx"},"content":"|| 1. Doliprane: 50","lastModifiedDate":"2023-11-01"},{"lineNumber":548,"author":{"gitId":"Barbaracwx"},"content":"|| ","lastModifiedDate":"2023-11-01"},{"lineNumber":549,"author":{"gitId":"Barbaracwx"},"content":"|| Listed all drugs by threshold level in the inventory.","lastModifiedDate":"2023-11-01"},{"lineNumber":550,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":551,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":552,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":553,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":554,"author":{"gitId":"karishma-t"},"content":"### `addDescription` - Adds a drug\u0027s description into a list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":555,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":556,"author":{"gitId":"karishma-t"},"content":"Adds a drug\u0027s description into a list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":557,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":558,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":559,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":560,"author":{"gitId":"karishma-t"},"content":"addDescription /n DRUG_NAME /desc DESCRIPTION ","lastModifiedDate":"2023-11-01"},{"lineNumber":561,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":562,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":563,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":564,"author":{"gitId":"karishma-t"},"content":"`addDescription /n Panadol /desc Pain Relief","lastModifiedDate":"2023-11-01"},{"lineNumber":565,"author":{"gitId":"karishma-t"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":566,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":567,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":568,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":569,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":570,"author":{"gitId":"karishma-t"},"content":"|| New drug description added for Panadol: Pain Relief ","lastModifiedDate":"2023-11-01"},{"lineNumber":571,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":572,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":573,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":574,"author":{"gitId":"karishma-t"},"content":"### `getDescription` - Retrieves the description of a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":575,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":576,"author":{"gitId":"karishma-t"},"content":"Retrieves the description of a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":577,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":578,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":579,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":580,"author":{"gitId":"karishma-t"},"content":"getDescription /n DRUG_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":581,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":582,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":583,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":584,"author":{"gitId":"karishma-t"},"content":"`getDescription /n Panadol","lastModifiedDate":"2023-11-01"},{"lineNumber":585,"author":{"gitId":"karishma-t"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":586,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":587,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":588,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":589,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":590,"author":{"gitId":"karishma-t"},"content":"|| Pain Relief","lastModifiedDate":"2023-11-01"},{"lineNumber":591,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":592,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":593,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":594,"author":{"gitId":"karishma-t"},"content":"### `listDescriptions` - Displays a list of all the descriptions for all corresponding drugs","lastModifiedDate":"2023-11-01"},{"lineNumber":595,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":596,"author":{"gitId":"karishma-t"},"content":"Displays a list of all the descriptions for all corresponding drugs","lastModifiedDate":"2023-11-01"},{"lineNumber":597,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":598,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":599,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":600,"author":{"gitId":"karishma-t"},"content":"listDescriptions ","lastModifiedDate":"2023-11-01"},{"lineNumber":601,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":602,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":603,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":604,"author":{"gitId":"karishma-t"},"content":"`listDescriptions","lastModifiedDate":"2023-11-01"},{"lineNumber":605,"author":{"gitId":"karishma-t"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":606,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":607,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":608,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":609,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":610,"author":{"gitId":"karishma-t"},"content":"|| List of Drug Descriptions:","lastModifiedDate":"2023-11-01"},{"lineNumber":611,"author":{"gitId":"karishma-t"},"content":"|| Panadol: Pain Relief","lastModifiedDate":"2023-11-01"},{"lineNumber":612,"author":{"gitId":"karishma-t"},"content":"|| Dolo: Stomache Discomfort","lastModifiedDate":"2023-11-01"},{"lineNumber":613,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":614,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":615,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":616,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":617,"author":{"gitId":"TeoHaoZhi"},"content":"**Q**: Can i register with blank username and password","lastModifiedDate":"2023-10-17"},{"lineNumber":618,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":619,"author":{"gitId":"TeoHaoZhi"},"content":"**A**: No. Ensure your entries are not blank.","lastModifiedDate":"2023-10-17"},{"lineNumber":620,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":621,"author":{"gitId":"TeoHaoZhi"},"content":"**Q**: Why can i register and login again even after being logged in","lastModifiedDate":"2023-11-04"},{"lineNumber":622,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":623,"author":{"gitId":"TeoHaoZhi"},"content":"**A**: A user is able to login another user or can help to register a new user without rebooting the application","lastModifiedDate":"2023-11-04"},{"lineNumber":624,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":625,"author":{"gitId":"TeoHaoZhi"},"content":"**Q**: Why is my registration and login details not masked","lastModifiedDate":"2023-11-04"},{"lineNumber":626,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":627,"author":{"gitId":"TeoHaoZhi"},"content":"**A**: Masking of input is a security concern that will be developed on in future iterations","lastModifiedDate":"2023-11-04"},{"lineNumber":628,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":629,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":630,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":631,"author":{"gitId":"martinschnder"},"content":"- add : `add /n DRUG_NAME /d EXPIRY_DATE /q QUANTITY`","lastModifiedDate":"2023-10-31"},{"lineNumber":632,"author":{"gitId":"martinschnder"},"content":"- delete : `delete /n DRUG_NAME`","lastModifiedDate":"2023-10-31"},{"lineNumber":633,"author":{"gitId":"martinschnder"},"content":"- list : `list`","lastModifiedDate":"2023-10-31"},{"lineNumber":634,"author":{"gitId":"martinschnder"},"content":"- find : `find /n KEYWORD` or `find /d KEYWORD`","lastModifiedDate":"2023-10-31"},{"lineNumber":635,"author":{"gitId":"martinschnder"},"content":"- help : `help`","lastModifiedDate":"2023-10-31"},{"lineNumber":636,"author":{"gitId":"martinschnder"},"content":"- register : `register`","lastModifiedDate":"2023-10-31"},{"lineNumber":637,"author":{"gitId":"martinschnder"},"content":"- login : `login`","lastModifiedDate":"2023-10-31"},{"lineNumber":638,"author":{"gitId":"martinschnder"},"content":"- save : `save`","lastModifiedDate":"2023-10-31"},{"lineNumber":639,"author":{"gitId":"martinschnder"},"content":"- add Vendor : `addVendor`","lastModifiedDate":"2023-10-31"},{"lineNumber":640,"author":{"gitId":"martinschnder"},"content":"- list Vendor : `listVendors`","lastModifiedDate":"2023-10-31"},{"lineNumber":641,"author":{"gitId":"karishma-t"},"content":"- add Vendor Supply : `addVendorSupply VENDOR_NAME DRUG_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":642,"author":{"gitId":"karishma-t"},"content":"- list Vendor Supply : `listVendorSupply VENDOR_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":643,"author":{"gitId":"karishma-t"},"content":"- find Vendor Supply : `findVendorSupply DRUG_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":644,"author":{"gitId":"karishma-t"},"content":"- add description : `addDescription /n DRUG_NAME /desc DESCRIPTION`","lastModifiedDate":"2023-11-01"},{"lineNumber":645,"author":{"gitId":"karishma-t"},"content":"- get description : `getDescription /n DRUG_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":646,"author":{"gitId":"karishma-t"},"content":"- list descriptions : `listDescriptions`","lastModifiedDate":"2023-11-01"},{"lineNumber":647,"author":{"gitId":"TeoHaoZhi"},"content":"- bye : `bye`","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"karishma-t":146,"martinschnder":89,"TeoHaoZhi":280,"-":34,"Barbaracwx":98}},{"path":"docs/team/Azfarul.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"# Azfarul Matin - Project Portfolio Page","lastModifiedDate":"2023-10-07"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"## Overview","lastModifiedDate":"2023-10-07"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-07"}],"authorContributionMap":{"azfarulmatin":6}},{"path":"docs/team/Barbara.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"# Barbara Chong - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"Barbaracwx":6}},{"path":"docs/team/HaoZhi.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"# Hao Zhi - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"TeoHaoZhi":6}},{"path":"docs/team/Karishma.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"# Karishma - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"karishma-t":5}},{"path":"docs/team/Martin.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"# Martin Schneider - Project Portfolio Page","lastModifiedDate":"2023-10-07"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"## Overview","lastModifiedDate":"2023-10-07"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-07"}],"authorContributionMap":{"martinschnder":5}},{"path":"src/main/java/seedu/stocker/Stocker.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.authentication.LoginSystem;","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.storage.Storage;","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.ui.Ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.parser.Parser;","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.Command;","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.CommandResult;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.ExitCommand;","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"import static seedu.stocker.common.Messages.MESSAGE_EXECUTION_FAILED;","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"public class Stocker {","lastModifiedDate":"2023-10-08"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" private Ui ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" private Inventory inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" private SalesList salesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" private Cart currentCart;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" private VendorsList vendorsList;","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" public static void main(String[] launchArgs) {","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" new Stocker().run();","lastModifiedDate":"2023-10-09"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * Runs Login System.","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" public boolean startLogin() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" this.ui \u003d new Ui();","lastModifiedDate":"2023-10-12"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" ui.showLoginMessage();","lastModifiedDate":"2023-10-12"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" LoginSystem system \u003d new LoginSystem();","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" system.run();","lastModifiedDate":"2023-10-11"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":" return system.loginStatus;","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":" * Runs the program until termination.","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":" public void run() {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" start();","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"martinschnder"},"content":" runCommandLoopUntilExitCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":50,"author":{"gitId":"martinschnder"},"content":" exit();","lastModifiedDate":"2023-10-09"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" * Sets up the required objects, and prints the welcome message.","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" private void start() {","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" this.ui \u003d new Ui();","lastModifiedDate":"2023-10-09"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":" this.inventory \u003d new Inventory();","lastModifiedDate":"2023-10-09"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" this.salesList \u003d new SalesList();","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" this.currentCart \u003d new Cart();","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":" this.vendorsList \u003d new VendorsList();","lastModifiedDate":"2023-10-28"},{"lineNumber":63,"author":{"gitId":"martinschnder"},"content":" Storage storage \u003d new Storage(inventory);","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":" storage.loadFileContents(\"drugs.txt\");","lastModifiedDate":"2023-10-21"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":" boolean checker \u003d startLogin();","lastModifiedDate":"2023-10-12"},{"lineNumber":66,"author":{"gitId":"martinschnder"},"content":" assert checker;","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" ui.showWelcomeMessage();","lastModifiedDate":"2023-10-09"},{"lineNumber":68,"author":{"gitId":"martinschnder"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"martinschnder"},"content":" ui.showInitFailedMessage();","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"martinschnder"},"content":" System.exit(0);","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":74,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":" * Prints the Goodbye message and exits.","lastModifiedDate":"2023-10-11"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":78,"author":{"gitId":"martinschnder"},"content":" private void exit() {","lastModifiedDate":"2023-10-09"},{"lineNumber":79,"author":{"gitId":"martinschnder"},"content":" ui.showGoodbyeMessage();","lastModifiedDate":"2023-10-09"},{"lineNumber":80,"author":{"gitId":"martinschnder"},"content":" System.exit(0);","lastModifiedDate":"2023-10-09"},{"lineNumber":81,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":83,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":" * Reads the user command and executes it, until the user issues the exit command.","lastModifiedDate":"2023-10-11"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":86,"author":{"gitId":"martinschnder"},"content":" private void runCommandLoopUntilExitCommand() {","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"martinschnder"},"content":" Command command;","lastModifiedDate":"2023-10-09"},{"lineNumber":88,"author":{"gitId":"martinschnder"},"content":" do {","lastModifiedDate":"2023-10-09"},{"lineNumber":89,"author":{"gitId":"martinschnder"},"content":" String userCommandText \u003d ui.getUserCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":90,"author":{"gitId":"martinschnder"},"content":" command \u003d new Parser().parseCommand(userCommandText);","lastModifiedDate":"2023-10-09"},{"lineNumber":91,"author":{"gitId":"martinschnder"},"content":" ui.showResultToUser(executeCommand(command));","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"martinschnder"},"content":" } while (!ExitCommand.isExit(command));","lastModifiedDate":"2023-10-09"},{"lineNumber":93,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":94,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":95,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":96,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2020-05-24"},{"lineNumber":97,"author":{"gitId":"martinschnder"},"content":" * Executes the command and returns the result.","lastModifiedDate":"2023-10-09"},{"lineNumber":98,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":99,"author":{"gitId":"martinschnder"},"content":" * @param command user command","lastModifiedDate":"2023-10-09"},{"lineNumber":100,"author":{"gitId":"martinschnder"},"content":" * @return result of the command","lastModifiedDate":"2023-10-09"},{"lineNumber":101,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":102,"author":{"gitId":"martinschnder"},"content":" private CommandResult\u003cObject\u003e executeCommand(Command command) {","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, salesList, currentCart, vendorsList);","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"martinschnder"},"content":" return command.execute();","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"martinschnder"},"content":" } catch (IOException ioe) {","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"martinschnder"},"content":" return new CommandResult\u003c\u003e(MESSAGE_EXECUTION_FAILED);","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":110,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"martinschnder":71,"TeoHaoZhi":33,"-":6}},{"path":"src/main/java/seedu/stocker/authentication/LoginSystem.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.authentication;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.ui.Ui;","lastModifiedDate":"2023-10-14"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.FileReader;","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.BufferedReader;","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.BufferedWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.File;","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" * Represents a login system used for authentication of users.","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" * User information is saved within a hashtable and uploaded","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" * into txt file for future reference.","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"public class LoginSystem {","lastModifiedDate":"2023-10-11"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public boolean loginStatus;","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" private final Scanner in;","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" private Ui interactor;","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" private final HashMap\u003cString, String\u003e users;","lastModifiedDate":"2023-10-12"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" public LoginSystem() throws IOException {","lastModifiedDate":"2023-10-11"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" users \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-11"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" loginStatus \u003d false;","lastModifiedDate":"2023-10-11"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" this.in \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-12"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" interactor \u003d new Ui();","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" File holder \u003d new File(\"./users.txt\");","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" if (!holder.exists()) {","lastModifiedDate":"2023-10-12"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" holder.createNewFile();","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" * Returns user choice of whether they wish to register a new user","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" * or if they would want to login using an existing user.","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" * @return choice of user to login or register","lastModifiedDate":"2023-10-21"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":" public String authenticateUserChoice() {","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" while (in.hasNextLine()) {","lastModifiedDate":"2023-10-12"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":" String choice \u003d in.nextLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":" if (choice.trim().equals(\"register\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" return \"register\";","lastModifiedDate":"2023-10-20"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (choice.trim().equals(\"login\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":" return \"login\";","lastModifiedDate":"2023-10-20"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidChoiceMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":" return authenticateUserChoice();","lastModifiedDate":"2023-10-12"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"TeoHaoZhi"},"content":" return \"error\";","lastModifiedDate":"2023-10-12"},{"lineNumber":58,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":60,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":" * Creates a new user with input username and password from user.","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":" * Username and password are saved into a txt file for future","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":" * reference.","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if inappropriate output is entered.","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" public void newUserCreator() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showUsernameMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":" String username \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":" while (username.trim().equals(\"\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showBlankNameMessage();","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":" username \u003d in.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" while (username.trim().contains(\":\")){","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidLoginCharacterMessage();","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"TeoHaoZhi"},"content":" username \u003d in.nextLine();","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":83,"author":{"gitId":"TeoHaoZhi"},"content":" String password \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" while (password.trim().equals(\"\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":86,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showBlankPasswordMessage();","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":" password \u003d in.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"TeoHaoZhi"},"content":" while(password.trim().contains(\":\")){","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidLoginCharacterMessage();","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"TeoHaoZhi"},"content":" password \u003d in.nextLine();","lastModifiedDate":"2023-11-04"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":" assert (username.equals(\"\") \u003d\u003d false);","lastModifiedDate":"2023-10-15"},{"lineNumber":96,"author":{"gitId":"TeoHaoZhi"},"content":" assert (password.equals(\"\") \u003d\u003d false);","lastModifiedDate":"2023-10-15"},{"lineNumber":97,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":98,"author":{"gitId":"TeoHaoZhi"},"content":" if (users.containsKey(username)) {","lastModifiedDate":"2023-10-11"},{"lineNumber":99,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showUserAlreadyExistMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":" System.out.println();","lastModifiedDate":"2023-10-11"},{"lineNumber":101,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showEnterChoiceAgainMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":102,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":103,"author":{"gitId":"TeoHaoZhi"},"content":" String reselect \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":104,"author":{"gitId":"TeoHaoZhi"},"content":" if (reselect.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":105,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":106,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":107,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (reselect.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":111,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":112,"author":{"gitId":"TeoHaoZhi"},"content":" users.put(username, password);","lastModifiedDate":"2023-10-11"},{"lineNumber":113,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showSuccessfulRegistrationMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":" loginStatus \u003d true;","lastModifiedDate":"2023-10-11"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":116,"author":{"gitId":"TeoHaoZhi"},"content":" writeNewUserToFile();","lastModifiedDate":"2023-10-11"},{"lineNumber":117,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":118,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":119,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":120,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":121,"author":{"gitId":"TeoHaoZhi"},"content":" * Login existing user by asking for username and password input","lastModifiedDate":"2023-10-14"},{"lineNumber":122,"author":{"gitId":"TeoHaoZhi"},"content":" * from user.","lastModifiedDate":"2023-10-14"},{"lineNumber":123,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":124,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if inappropriate input is entered.","lastModifiedDate":"2023-10-14"},{"lineNumber":125,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":126,"author":{"gitId":"martinschnder"},"content":" public void loginExistingUser() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":128,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":129,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showUsernameMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":130,"author":{"gitId":"TeoHaoZhi"},"content":" String usernameInput \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":131,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":132,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":133,"author":{"gitId":"TeoHaoZhi"},"content":" String passwordInput \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":134,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":135,"author":{"gitId":"TeoHaoZhi"},"content":" if (!users.containsKey(usernameInput)) {","lastModifiedDate":"2023-10-11"},{"lineNumber":136,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidUsernameOrPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":137,"author":{"gitId":"TeoHaoZhi"},"content":" System.out.println();","lastModifiedDate":"2023-10-11"},{"lineNumber":138,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showEnterChoiceAgainMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":139,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":140,"author":{"gitId":"TeoHaoZhi"},"content":" String reselect \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":141,"author":{"gitId":"TeoHaoZhi"},"content":" if (reselect.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":142,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":143,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":144,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (reselect.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":145,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":146,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":147,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":148,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":149,"author":{"gitId":"TeoHaoZhi"},"content":" if (users.get(usernameInput).equals(passwordInput)) {","lastModifiedDate":"2023-10-11"},{"lineNumber":150,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showSuccessfulLoginMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":151,"author":{"gitId":"TeoHaoZhi"},"content":" loginStatus \u003d true;","lastModifiedDate":"2023-10-11"},{"lineNumber":152,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":153,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidUsernameOrPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":154,"author":{"gitId":"TeoHaoZhi"},"content":" System.out.println();","lastModifiedDate":"2023-10-11"},{"lineNumber":155,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showEnterChoiceAgainMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":156,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":157,"author":{"gitId":"TeoHaoZhi"},"content":" String reselect \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":158,"author":{"gitId":"TeoHaoZhi"},"content":" if (reselect.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":159,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":160,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":161,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (reselect.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":162,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":163,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":164,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":165,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":166,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":167,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":168,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":169,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":170,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":171,"author":{"gitId":"TeoHaoZhi"},"content":" * Writes new user creation into a txt file to save for future reference","lastModifiedDate":"2023-10-14"},{"lineNumber":172,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":173,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException","lastModifiedDate":"2023-10-14"},{"lineNumber":174,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":175,"author":{"gitId":"TeoHaoZhi"},"content":" public void writeNewUserToFile() throws IOException {","lastModifiedDate":"2023-10-11"},{"lineNumber":176,"author":{"gitId":"TeoHaoZhi"},"content":" BufferedWriter writer \u003d new BufferedWriter(new FileWriter(\"./users.txt\", true));","lastModifiedDate":"2023-10-11"},{"lineNumber":177,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":178,"author":{"gitId":"TeoHaoZhi"},"content":" for (Map.Entry\u003cString, String\u003e entry :","lastModifiedDate":"2023-10-11"},{"lineNumber":179,"author":{"gitId":"TeoHaoZhi"},"content":" users.entrySet()) {","lastModifiedDate":"2023-10-11"},{"lineNumber":180,"author":{"gitId":"TeoHaoZhi"},"content":" // put key and value separated by a colon","lastModifiedDate":"2023-10-11"},{"lineNumber":181,"author":{"gitId":"TeoHaoZhi"},"content":" writer.write(entry.getKey() + \":\"","lastModifiedDate":"2023-10-11"},{"lineNumber":182,"author":{"gitId":"TeoHaoZhi"},"content":" + entry.getValue());","lastModifiedDate":"2023-10-11"},{"lineNumber":183,"author":{"gitId":"TeoHaoZhi"},"content":" // new line","lastModifiedDate":"2023-10-11"},{"lineNumber":184,"author":{"gitId":"TeoHaoZhi"},"content":" writer.newLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":185,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":186,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":187,"author":{"gitId":"TeoHaoZhi"},"content":" writer.flush();","lastModifiedDate":"2023-10-11"},{"lineNumber":188,"author":{"gitId":"TeoHaoZhi"},"content":" writer.close();","lastModifiedDate":"2023-10-11"},{"lineNumber":189,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":190,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":191,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":192,"author":{"gitId":"TeoHaoZhi"},"content":" * Loads existing users from txt file into hash table","lastModifiedDate":"2023-10-14"},{"lineNumber":193,"author":{"gitId":"TeoHaoZhi"},"content":" * for login system to use for authentication when","lastModifiedDate":"2023-10-14"},{"lineNumber":194,"author":{"gitId":"TeoHaoZhi"},"content":" * user tries to login.","lastModifiedDate":"2023-10-14"},{"lineNumber":195,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":196,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if fail to read from txt file","lastModifiedDate":"2023-10-14"},{"lineNumber":197,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":198,"author":{"gitId":"TeoHaoZhi"},"content":" public void loadExistingUsers() throws IOException {","lastModifiedDate":"2023-10-11"},{"lineNumber":199,"author":{"gitId":"TeoHaoZhi"},"content":" BufferedReader reader \u003d new BufferedReader(new FileReader(\"./users.txt\"));","lastModifiedDate":"2023-10-11"},{"lineNumber":200,"author":{"gitId":"TeoHaoZhi"},"content":" String line;","lastModifiedDate":"2023-10-11"},{"lineNumber":201,"author":{"gitId":"TeoHaoZhi"},"content":" while ((line \u003d reader.readLine()) !\u003d null) {","lastModifiedDate":"2023-10-11"},{"lineNumber":202,"author":{"gitId":"TeoHaoZhi"},"content":" String[] parts \u003d line.split(\":\", 2);","lastModifiedDate":"2023-10-11"},{"lineNumber":203,"author":{"gitId":"TeoHaoZhi"},"content":" if (parts.length \u003e\u003d 2) {","lastModifiedDate":"2023-10-11"},{"lineNumber":204,"author":{"gitId":"TeoHaoZhi"},"content":" String key \u003d parts[0];","lastModifiedDate":"2023-10-11"},{"lineNumber":205,"author":{"gitId":"TeoHaoZhi"},"content":" String value \u003d parts[1];","lastModifiedDate":"2023-10-11"},{"lineNumber":206,"author":{"gitId":"TeoHaoZhi"},"content":" users.put(key, value);","lastModifiedDate":"2023-10-11"},{"lineNumber":207,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":208,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":209,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":210,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":211,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":212,"author":{"gitId":"TeoHaoZhi"},"content":" * Runs login system by loading user information into hash table","lastModifiedDate":"2023-10-14"},{"lineNumber":213,"author":{"gitId":"TeoHaoZhi"},"content":" * and get input for user to check for authentication.","lastModifiedDate":"2023-10-14"},{"lineNumber":214,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":215,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if unable to read from txt file to","lastModifiedDate":"2023-10-14"},{"lineNumber":216,"author":{"gitId":"TeoHaoZhi"},"content":" * load users","lastModifiedDate":"2023-10-14"},{"lineNumber":217,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":218,"author":{"gitId":"martinschnder"},"content":" public void run() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"TeoHaoZhi"},"content":" loadExistingUsers();","lastModifiedDate":"2023-10-11"},{"lineNumber":220,"author":{"gitId":"TeoHaoZhi"},"content":" String choice \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":221,"author":{"gitId":"TeoHaoZhi"},"content":" if (choice.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":222,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":223,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":224,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (choice.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":225,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":226,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":227,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":228,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":229,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":230,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"martinschnder":5,"TeoHaoZhi":225}},{"path":"src/main/java/seedu/stocker/commands/AddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" * Adds a drug into the inventory","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"public class AddCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"add\";","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a new drug to the drug list. \"","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" + \"Parameters: NAME, EXPIRY DATE, SERIAL NUMBER, QUANTITY, \" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" + \" /n Doliprane /d 12/06/2035 /s ABC123 /q 52\";","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug added in the inventory: %1$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" private final Drug toAdd;","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" private final long quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":" private final String serialNumber;","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"azfarulmatin"},"content":" public AddCommand(String name, String expiryDate, String serialNumber, Long quantity) {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.toAdd \u003d new Drug(name, expiryDate);","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":" this.serialNumber \u003d serialNumber;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" public Drug getDrug() {","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" return this.toAdd;","lastModifiedDate":"2023-10-09"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":" public String getSerialNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"azfarulmatin"},"content":" return this.serialNumber;","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(toAdd.getName(), toAdd, serialNumber, quantity);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, toAdd.getName()));","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":30,"azfarulmatin":10,"TeoHaoZhi":1,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/AddDescriptionCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":" * Adds a drug description to the description list.","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"public class AddDescriptionCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"addDescription\";","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a new description for a specific drug \"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: NAME, DESCRIPTION\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" /n Panadol /desc Pain Relief \";","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug description added for %1$s: %2$s\";","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" private final String drugDescription;","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" * Creates an AddDescriptionCommand to add a drug description to the description list.","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug for which the description is added.","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * @param drugDescription The description to be added for the drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" public AddDescriptionCommand(String drugName, String drugDescription ) {","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" this.drugDescription \u003d drugDescription;","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * Executes the command to add the drug description.","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult indicating the success of adding the description.","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" seedu.stocker.drugs.Description.addDescription(drugName, drugDescription);","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, drugName, drugDescription));","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":40}},{"path":"src/main/java/seedu/stocker/commands/AddToCartCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" * Adds a certain quantity of one drug into the current cart","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"public class AddToCartCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"addtocart\";","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD ","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" + \": Adds a new drug to the current cart. \"","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" + \"Parameters: NAME, QUANTITY,\" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" + \" /n Doliprane /q 2\";","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug added in the current cart: %1$s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" private final String drugName;","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" private final long quantity;","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" public AddToCartCommand(String name, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.drugName \u003d name;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" StockEntry matchingEntry \u003d inventory.getStockEntries().stream()","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" .filter(entry -\u003e entry","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" .getDrug().getName()","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" .equalsIgnoreCase(this.drugName) \u0026\u0026 ","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" entry.getQuantity() \u003e this.quantity)","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" .findAny()","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" .orElse(null);","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" if (matchingEntry !\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":" currentCart.addEntry(this.drugName, this.quantity);","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, matchingEntry.getDrug().getName()));","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(\"This drug is not in stock. \");","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":40,"TeoHaoZhi":1,"Barbaracwx":4}},{"path":"src/main/java/seedu/stocker/commands/AddVendorCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.vendors.Vendor;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":" * Adds a vendor into the inventory","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"public class AddVendorCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"addVendor\";","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a new vendor to the vendors list. \"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Parameter: NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + \" Moderna\";","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New vendor added in the vendors list: %1$s\";","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" private final Vendor toAdd;","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public AddVendorCommand(String name) {","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" this.toAdd \u003d new Vendor(name);","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003e CommandResult\u003cT\u003e execute() {","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" this.vendorsList.addNewVendor(toAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, toAdd.getName()));","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"martinschnder":3,"TeoHaoZhi":27}},{"path":"src/main/java/seedu/stocker/commands/AddVendorSupplyCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.vendors.VendorSupplyList;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":" * Adds a drug to a vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"public class AddVendorSupplyCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"addVendorSupply\";","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a drug to a vendor\u0027s supply list. \"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: VENDOR_NAME DRUG_NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" Moderna Paracetamol\";","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug added to %1$s\u0027s supply list: %2$s\";","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_VENDOR_NOT_FOUND \u003d \"Vendor not found: %1$s\";","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" private final String vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * Creates an AddVendorSupplyCommand to add a drug to a vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug to be added to the vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" public AddVendorSupplyCommand(String vendorName, String drugName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" this.vendorName \u003d vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" * Executes the command to add a drug to the specified vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult indicating the success of adding the drug or a message indicating the vendor was not found.","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003e CommandResult\u003cT\u003e execute() {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" String lowercaseVendorName \u003d vendorName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" String lowercaseDrugName \u003d drugName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" if (this.vendorsList.getVendorEntries().stream().anyMatch(vendor -\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":" vendor.getName().equalsIgnoreCase(lowercaseVendorName))) {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"karishma-t"},"content":" VendorSupplyList.addDrugToVendor(lowercaseVendorName, lowercaseDrugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, lowercaseVendorName, lowercaseDrugName));","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_VENDOR_NOT_FOUND, lowercaseVendorName));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":49,"martinschnder":2}},{"path":"src/main/java/seedu/stocker/commands/CheckOutCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" * Remove a drug from inventory and add it into the sales list","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"public class CheckOutCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"checkout\";","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Checks out current cart. \"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" + \"Parameters:\" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"The current cart has been checked out. \";","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public CheckOutCommand() {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" currentCart.checkOut(salesList, inventory);","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS));","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":22,"TeoHaoZhi":1,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" protected Inventory inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" protected SalesList salesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" protected Cart currentCart;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" protected VendorsList vendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" protected Command() {","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" public void setData(Inventory inventory, SalesList salesList, Cart currentCart, VendorsList vendorsList) {","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" this.inventory \u003d inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" this.salesList \u003d salesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.currentCart \u003d currentCart;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" this.vendorsList \u003d vendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" public abstract \u003cT\u003e CommandResult\u003cT\u003e execute() throws IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":28,"TeoHaoZhi":3}},{"path":"src/main/java/seedu/stocker/commands/CommandResult.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"// import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.Optional;","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" * Represents the result of a command execution.","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"public class CommandResult\u003cT\u003e {","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" * The feedback message to be shown to the user. Contains a description of the execution result","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" * The list of drugs that was produced by the command","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" private final List\u003cT\u003e relevantElements;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" public CommandResult(String feedbackToUser) {","lastModifiedDate":"2023-10-09"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" relevantElements \u003d null;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" public CommandResult(String feedbackToUser, List\u003cT\u003e relevantElements) {","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" this.relevantElements \u003d relevantElements;","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" * Returns a list of drugs that was produced by the command, if any.","lastModifiedDate":"2023-10-09"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" public Optional\u003cList\u003cT\u003e\u003e getRelevantElements() {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" return Optional.ofNullable(relevantElements);","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" public String getFeedbackToUserFindTest() {","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" if (relevantElements !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" StringBuilder feedback \u003d new StringBuilder();","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" for (int i \u003d 0; i \u003c relevantElements.size(); i++) {","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(i + 1).append(\". \").append(relevantElements.get(i));","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(System.lineSeparator());","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(System.lineSeparator());","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(feedbackToUser);","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" return feedback.toString();","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" return feedbackToUser;","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":34,"Barbaracwx":21}},{"path":"src/main/java/seedu/stocker/commands/DeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.exceptions.DrugNotFoundException;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"public class DeleteCommand extends Command{","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"delete\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Removes a drug from drug list. \"","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Parameters: Name \" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" + \" \u003cDrug Name\u003e\";","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Drug removed from inventory: %1$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_FAILURE \u003d \"Drug not found in the inventory. \";","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" private final String keyToDelete;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * Constructs a DeleteCommand with the specified drug name.","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public DeleteCommand(String key) {","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" this.keyToDelete \u003d key.trim().toLowerCase();","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * Executes the \u0027delete\u0027 command, removing a drug from the inventory list by name.","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" * @return A CommandResult indicating the result of the deletion operation.","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":" StockEntry deletedEntry \u003d inventory.deleteDrug(this.keyToDelete);","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, deletedEntry.getDrug().getName()));","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":" } catch (DrugNotFoundException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_FAILURE);","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"karishma-t":14,"martinschnder":8,"TeoHaoZhi":20,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/commands/ExitCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" * Terminates the program.","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"public class ExitCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"bye\";","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Exits the program.\"+ System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_EXIT_ACKNOWEDGEMENT \u003d \"Exiting Stocker as requested ...\";","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_EXIT_ACKNOWEDGEMENT);","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" public static boolean isExit(Command command) {","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" return command instanceof ExitCommand; // instanceof returns false if it is null","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":19,"TeoHaoZhi":2,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/commands/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import java.util.List;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_COMMAND_FORMAT;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to find drugs in the inventory that match a given keyword.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"find\";","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" * Usage message for the \u0027find\u0027 command.","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \" /n\" + \": Finds drug in inventory using name.\" +","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" \"Example: \" + COMMAND_WORD + \" /n panadol\" +","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" COMMAND_WORD + \" /d\" + \": Finds drug in inventory using date.\" +","lastModifiedDate":"2023-10-20"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"azfarulmatin"},"content":" \"Example: \" + COMMAND_WORD + \" /d panadol\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"azfarulmatin"},"content":" COMMAND_WORD + \" /s\" + \": Finds drug in inventory using serial number.\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" \"Example: \" + COMMAND_WORD + \" /s ABC123\";","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" * Success message displayed after successfully finding drugs in the inventory.","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" private final String keyword;","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" private final String criterion;","lastModifiedDate":"2023-10-20"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" * Creates a FindCommand with the specified keyword.","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" * @param keyword The keyword to search for in the inventory.","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" public FindCommand(String keyword, String criterion) {","lastModifiedDate":"2023-10-20"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" this.keyword \u003d keyword.toLowerCase();","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" this.criterion \u003d criterion;","lastModifiedDate":"2023-10-20"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"azfarulmatin"},"content":" private String getResultString(StockEntry entry) {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"azfarulmatin"},"content":" String result \u003d \"Name: \" + entry.getDrug().getName()","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"azfarulmatin"},"content":" + \", Expiry date: \" + entry.getDrug().getExpiryDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"azfarulmatin"},"content":" + \", Serial number: \" + entry.getSerialNumber()","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"azfarulmatin"},"content":" + \", Quantity: \" + entry.getQuantity();","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"azfarulmatin"},"content":" return result;","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" private static boolean matches(String criterion, String keyword, StockEntry entry) {","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" if (criterion.equals(\"/n\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":" return entry.getDrug().getName().toLowerCase().contains(keyword);","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"azfarulmatin"},"content":" } else if (criterion.equals(\"/d\")) {","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"martinschnder"},"content":" return entry.getDrug().getExpiryDate().toLowerCase().contains(keyword);","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"azfarulmatin"},"content":" } else if (criterion.equals(\"/s\")) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"azfarulmatin"},"content":" return entry.getSerialNumber().toLowerCase().contains(keyword);","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"azfarulmatin"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"azfarulmatin"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"Barbaracwx"},"content":" * Executes the \u0027find\u0027 command, searching for drugs that match the keyword.","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult containing the outcome of the command execution.","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":79,"author":{"gitId":"Barbaracwx"},"content":" if (keyword \u003d\u003d null || keyword.trim().isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_INVALID_COMMAND_FORMAT, MESSAGE_USAGE));","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":82,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":" List\u003cStockEntry\u003e entries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"azfarulmatin"},"content":" List\u003cString\u003e foundResults \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"martinschnder"},"content":" for (StockEntry entry : entries) {","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"martinschnder"},"content":" if (matches(this.criterion, this.keyword, entry)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":88,"author":{"gitId":"azfarulmatin"},"content":" foundResults.add(getResultString(entry));","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":91,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"azfarulmatin"},"content":" if (foundResults.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"azfarulmatin"},"content":" return new CommandResult\u003c\u003e(\"No drugs found with the specified criteria.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"azfarulmatin"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"azfarulmatin"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS, foundResults);","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":98,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":12,"azfarulmatin":26,"TeoHaoZhi":12,"Barbaracwx":50}},{"path":"src/main/java/seedu/stocker/commands/FindVendorSupplyCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.vendors.VendorSupplyList;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"import java.util.stream.Collectors;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" * Lists the vendors that supply a specific drug.","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"public class FindVendorSupplyCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"findVendorSupply\";","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Lists the vendors that supply a specific drug. \"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: DRUG_NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" Paracetamol\";","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" * Creates a FindVendorSupplyCommand to list the vendors that supply a specific drug.","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug to search for.","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" public FindVendorSupplyCommand(String drugName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" * Executes the command to list the vendors that supply the specified drug.","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult indicating the vendors that supply the drug or an error message.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" String lowercaseDrugName \u003d drugName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" if (lowercaseDrugName.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(MESSAGE_USAGE);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" List\u003cString\u003e supplyingVendors \u003d VendorSupplyList.getVendorSuppliedDrugs()","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" .entrySet()","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":" .stream()","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":" .filter(entry -\u003e entry.getValue().contains(lowercaseDrugName))","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"karishma-t"},"content":" .map(Map.Entry::getKey)","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"karishma-t"},"content":" .collect(Collectors.toList());","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"karishma-t"},"content":" if (supplyingVendors.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"No vendors supply the drug: \" + drugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"Vendors supplying the drug \" + drugName + \": \"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"karishma-t"},"content":" + String.join(\", \", supplyingVendors));","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":56}},{"path":"src/main/java/seedu/stocker/commands/GetDescriptionCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":" * Gets the description of a specific drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"public class GetDescriptionCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"getDescription\";","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Gets the description of a specific drug.\"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" /n Panadol\";","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_DESCRIPTION_NOT_FOUND \u003d \"Description not found for %1$s\";","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" * Creates a GetDescriptionCommand to retrieve the description of a specific drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug for which the description should be retrieved.","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" public GetDescriptionCommand(String drugName) {","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" * Executes the command to retrieve the description of the specified drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult containing the drug description if found, or an error message if not found.","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" String description \u003d seedu.stocker.drugs.Description.getDescription(drugName);","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" if (description !\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(description);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_DESCRIPTION_NOT_FOUND, drugName));","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":43}},{"path":"src/main/java/seedu/stocker/commands/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Shows help instructions.","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"help\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Shows program usage instructions. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" System.lineSeparator() + AddCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + DeleteCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + HelpCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + ListCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator() + ShowStockLevelCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + FindCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator() + AddToCartCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator() + CheckOutCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator() + ViewCartCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + LoginCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-20"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + RegisterCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-20"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + SaveCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-21"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-21"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + AddVendorCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + ListVendorCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator() + SetThresholdCommand.MESSAGE_USAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator() + ListThresholdCommand.MESSAGE_USAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + ExitCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" );","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":21,"TeoHaoZhi":25,"Barbaracwx":7}},{"path":"src/main/java/seedu/stocker/commands/IncorrectCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Represents an incorrect command. Upon execution, produces some feedback to the user.","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class IncorrectCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public IncorrectCommand(String feedbackToUser) {","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(feedbackToUser);","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":17,"TeoHaoZhi":1,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"import java.util.List;","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"azfarulmatin"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":" * Represents a command to list all drugs in the inventory.","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":" * This command retrieves the list of drugs from the inventory and provides it as part of the command result.","lastModifiedDate":"2023-10-14"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":" * If the inventory is empty, it informs the user that the inventory has no drugs.","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"list\";","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all drug information that is being \"","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" + \"tracked by the system. \" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all drugs in the inventory.\";","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"azfarulmatin"},"content":" * Executes the list command.","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":" * @return A CommandResult containing the success message and the list of drugs.","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"azfarulmatin"},"content":" // Assertion: Check if the inventory is properly initialized","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"azfarulmatin"},"content":" assert inventory !\u003d null : \"Inventory should be initialized before executing ListCommand.\";","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" // Retrieve the list of drugs from the inventory","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" List\u003cStockEntry\u003e stockEntries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"azfarulmatin"},"content":" // Check if the inventory is empty","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" if (stockEntries.isEmpty()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":" // Return a CommandResult indicating that the inventory is empty","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(\"The inventory is empty.\");","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"azfarulmatin"},"content":" } else {","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":" // Prepare a StringBuilder to construct the output message","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"azfarulmatin"},"content":" StringBuilder resultMessage \u003d new StringBuilder(MESSAGE_SUCCESS + System.lineSeparator());","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"azfarulmatin"},"content":" int index \u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"azfarulmatin"},"content":" for (StockEntry entry : stockEntries) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"azfarulmatin"},"content":" resultMessage.append(\"\\t\").append(index).append(\". \")","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"azfarulmatin"},"content":" .append(\"Name: \").append(entry.getDrug().getName())","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"azfarulmatin"},"content":" .append(\", Expiry date: \").append(entry.getDrug().getExpiryDate())","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"azfarulmatin"},"content":" .append(\", Serial number: \").append(entry.getSerialNumber()) // Add this line","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"azfarulmatin"},"content":" .append(\", Quantity: \").append(entry.getQuantity())","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"azfarulmatin"},"content":" .append(System.lineSeparator());","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"azfarulmatin"},"content":" index++;","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"azfarulmatin"},"content":" // Return a CommandResult with the success message and the list of drugs","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"azfarulmatin"},"content":" return new CommandResult\u003c\u003e(resultMessage.toString().trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":3,"azfarulmatin":38,"TeoHaoZhi":13,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/ListDescriptionsCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":" * Lists all descriptions for corresponding drugs.","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"public class ListDescriptionsCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"listDescriptions\";","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_SUCCESS \u003d \"List of Drug Descriptions:\";","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Lists all the descriptions for all drugs \"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" * Creates a ListDescriptionsCommand to list all drug descriptions for all corresponding drugs.","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" public ListDescriptionsCommand() {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * Executes the command to list all drug descriptions.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult that displays the list of drug descriptions.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" Map\u003cString, String\u003e descriptions \u003d seedu.stocker.drugs.Description.getAllDescriptions();","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" StringBuilder result \u003d new StringBuilder(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" for (Map.Entry\u003cString, String\u003e entry : descriptions.entrySet()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" result.append(System.lineSeparator());","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" result.append(entry.getKey()).append(\": \").append(entry.getValue());","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(result.toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":39}},{"path":"src/main/java/seedu/stocker/commands/ListThresholdCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to list all drugs and their threshold levels in the inventory.","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"public class ListThresholdCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" public static final String COMMAND_WORD \u003d \"listthreshold\";","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all drugs and their threshold levels.\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all drugs by threshold level in the inventory.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" * Executes the ListThresholdCommand by retrieving a list of StockEntry objects and their threshold levels.","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult containing the list of drugs and their threshold levels or a message indicating the","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" * inventory is empty.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" assert inventory !\u003d null : \"Inventory should be initialized before executing ListThresholdCommand.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" List\u003cStockEntry\u003e stockEntries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntries.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(\"The inventory is empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" List\u003cString\u003e resultElements \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" for (StockEntry entry : stockEntries) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" long thresholdQuantity \u003d entry.getThresholdQuantity();","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" String drugName \u003d entry.getDrug().getName();","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" resultElements.add(drugName + \": \" + thresholdQuantity);","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS, resultElements);","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Barbaracwx":45}},{"path":"src/main/java/seedu/stocker/commands/ListVendorCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.vendors.Vendor;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" * Generates a list of vendors tracked by system","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"public class ListVendorCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"listVendors\";","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all vendor information that is being \"","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + \"tracked by the system.\" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all vendors in the list.\";","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" * Executes the list command.","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" * @return A CommandResult containing the success message and the list of drugs.","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public CommandResult\u003cVendor\u003e execute() {","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" // Retrieve the list of vendors from the inventory","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" List\u003cVendor\u003e vendorEntries \u003d this.vendorsList.getVendorEntries();","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" // Check if the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" if (vendorEntries.isEmpty()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" // Return a CommandResult indicating that the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" return new CommandResult\u003c\u003e(\"The inventory is empty.\");","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" // Return a CommandResult with the success message and the list of vendors","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" return new CommandResult\u003cVendor\u003e(MESSAGE_SUCCESS, vendorEntries);","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"karishma-t":2,"martinschnder":3,"TeoHaoZhi":34}},{"path":"src/main/java/seedu/stocker/commands/ListVendorSupplyCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.vendors.VendorSupplyList;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":" * Lists the drugs supplied by a specific vendor in a case-insensitive manner.","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":"public class ListVendorSupplyCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"listVendorSupply\";","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Lists the drugs supplied by a specific vendor. \"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: VENDOR_NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" Moderna\";","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" private final String vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" * Creates a ListVendorSupplyCommand to list the drugs supplied by a specific vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" public ListVendorSupplyCommand(String vendorName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" this.vendorName \u003d vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" * Executes the command to list the drugs supplied by the specified vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult containing the list of supplied drugs or a message indicating none were supplied.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" String lowercaseVendorName \u003d vendorName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" if (lowercaseVendorName.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(MESSAGE_USAGE);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" List\u003cString\u003e suppliedDrugs \u003d VendorSupplyList.getDrugsSuppliedByVendor(lowercaseVendorName);","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" if (suppliedDrugs.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"No drugs supplied by \" + vendorName);","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"Drugs supplied by \" + vendorName + \": \" + String.join(\", \", suppliedDrugs));","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":48}},{"path":"src/main/java/seedu/stocker/commands/LoginCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-20"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.authentication.LoginSystem;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":" * Login existing user into system.","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"public class LoginCommand extends Command {","lastModifiedDate":"2023-10-20"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"login\";","lastModifiedDate":"2023-10-20"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Login new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Welcome back!\";","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" public CommandResult execute() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" LoginSystem system \u003d new LoginSystem();","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" system.loadExistingUsers();","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" system.loginExistingUser();","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-20"}],"authorContributionMap":{"martinschnder":1,"TeoHaoZhi":24,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/RegisterCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-20"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.authentication.LoginSystem;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" * Registers new user into login system.","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"public class RegisterCommand extends Command {","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"register\";","lastModifiedDate":"2023-10-20"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Register new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New User Created.\";","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003e CommandResult\u003cT\u003e execute() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" LoginSystem system \u003d new LoginSystem();","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" system.loadExistingUsers();","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" system.newUserCreator();","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-20"}],"authorContributionMap":{"martinschnder":1,"TeoHaoZhi":24,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/SaveCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-21"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.storage.Storage;","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.File;","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.List;","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-21"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" * Backups existing drug list inventory into txt file to be uploaded later.","lastModifiedDate":"2023-10-21"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"public class SaveCommand extends Command{","lastModifiedDate":"2023-10-21"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"save\";","lastModifiedDate":"2023-10-21"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Saves existing druglist that is loaded \"","lastModifiedDate":"2023-10-21"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" +\"into inventory when system is booted up.\"","lastModifiedDate":"2023-10-21"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-21"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-21"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Drugs successfully saved.\";","lastModifiedDate":"2023-10-21"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" File holder \u003d new File(\"./drugs.txt\");","lastModifiedDate":"2023-10-21"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" if (!holder.exists()) {","lastModifiedDate":"2023-10-21"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" holder.createNewFile();","lastModifiedDate":"2023-10-21"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" List\u003cStockEntry\u003e entries\u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" Storage storageManager \u003d new Storage(inventory);","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" storageManager.writeToFile(\"drugs.txt\", \"\");","lastModifiedDate":"2023-10-21"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" for(int i \u003d 0; i \u003c entries.size(); i +\u003d 1){","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" storageManager.appendToFile(\"drugs.txt\",entries.get(i).toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-21"}],"authorContributionMap":{"martinschnder":5,"TeoHaoZhi":33,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/SetThresholdCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to set the threshold quantity for a drug in the inventory.","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"public class SetThresholdCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" public static final String COMMAND_WORD \u003d \"setthreshold\";","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" + \": Set the threshold quantity for a drug. \"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" + \"(default 100)\" + System.lineSeparator()","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: \" + COMMAND_WORD + \" /n Doliprane /tq 50\";","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Threshold quantity set for %1$s: %2$d\";","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" private final String drugName;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" private final long threshold;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" * Constructs a SetThresholdCommand with a specified drug name and threshold quantity.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" * @param name The name of the drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" * @param threshold The threshold quantity to set.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" public SetThresholdCommand(String name, long threshold) {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" this.drugName \u003d name;","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" this.threshold \u003d threshold;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" * Executes the SetThresholdCommand by setting the threshold quantity for the specified drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult indicating the success or failure of the command.","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" if (inventory.getStockEntries().isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(\"Inventory is empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" StockEntry stockEntry \u003d inventory.getStockEntry(drugName);","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntry !\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" stockEntry.setThresholdQuantity(threshold);","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(String.format(MESSAGE_SUCCESS, drugName, threshold));","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(\"Drug not found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Barbaracwx":53}},{"path":"src/main/java/seedu/stocker/commands/ShowStockLevelCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import java.util.Comparator;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to display a report of stock levels sorted by quantity in ascending order.","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"public class ShowStockLevelCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" public static final String COMMAND_WORD \u003d \"stocklevel\";","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all drugs by quantity level \"","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" + \"tracked by the system in ascending order. \" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Stock Level Report (Sorted by Quantity)\";","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" * Executes the \"stocklevel\" command. Displays a report of stock levels sorted by quantity in ascending order.","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult containing the success message and a list of stock entries sorted by quantity.","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" // Assertion: Check if the inventory is properly initialized","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":" assert inventory !\u003d null : \"Inventory should be initialized before executing ShowStockLevelCommand.\";","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" // Retrieve the list of drugs from the inventory","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" List\u003cStockEntry\u003e stockEntries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" // Check if the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntries.isEmpty()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" // Return a CommandResult indicating that the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(\"The inventory is empty.\");","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" // Sort the stockEntries by quantity in ascending order","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" stockEntries.sort(Comparator.comparingLong(StockEntry::getQuantity));","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" // Create a new list to store the sorted stockEntries","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" List\u003cStockEntry\u003e arrangedListbyQuantity \u003d new ArrayList\u003c\u003e(stockEntries);","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS, arrangedListbyQuantity);","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"TeoHaoZhi":1,"Barbaracwx":46}},{"path":"src/main/java/seedu/stocker/commands/ViewCartCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" * Represents a command to list all drugs in the current cart.","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" * This command retrieves the list of drugs from the current cart and provides it as part of the command result.","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" * If the inventory is empty, it informs the user that the inventory has no drugs.","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"public class ViewCartCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"viewcart\";","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" + \": View the current cart items.\" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all the content of your cart. \";","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_FAILURE \u003d \"Your cart is empty. \";","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" * Execute the ViewCartCommand","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" if (currentCart.isEmpty()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_FAILURE);","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return new CommandResult(MESSAGE_SUCCESS, currentCart.getCurrentCart());","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":29,"TeoHaoZhi":1,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/common/Messages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.common;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Container for user visible messages.","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class Messages {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_WELCOME \u003d \"Welcome to your Stocker!\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_GOODBYE \u003d \"Good bye!\";","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_INVALID_COMMAND_FORMAT \u003d \"Invalid command format! \\n%1$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_INVALID_QUANTITY \u003d \"A quantity must be an integer superior than 0.\\n\";","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_LOGIN_WELCOME \u003d \"Welcome! \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Key in register or login based on your needs \\n\"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" + \"1.Register user \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + \"2.Login\";","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USERNAME_INPUT \u003d \"Enter your username:\";","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_PASSWORD_INPUT \u003d \"Enter Your Password:\";","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESSFUL_REGISTRATION \u003d \"Registration successful.\";","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESSFUL_LOGIN \u003d \"Login successful.\";","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_INVALID_CHOICE \u003d \"Invalid Input, enter register or login only!\";","lastModifiedDate":"2023-10-20"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USER_ALREADY_EXIST \u003d \"User already exists. Please make user with \"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" + \"different name or login instead\";","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_INVALID_USERNAME_OR_PASSWORD \u003d \"Invalid username or password. Please try again.\";","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_NO_BLANK_NAME_ALLOWED \u003d \"No blank name allowed. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Enter your desired username again\";","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_NO_BLANK_PASSWORD_ALLOWED \u003d \"No blank password allowed. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Enter your desired password again\";","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_INIT_FAILED \u003d \"Failed to initialise Stocker application. Exiting...\";","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_EXECUTION_FAILED \u003d \"Exection of the command failed because of I/O error, \"","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" + \"please try later.\";","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_INVALID_LOGIN_CHARACTER \u003d \" Do not include : in the username or password, enter\"","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" + \" another username or password\";","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":16,"TeoHaoZhi":19}},{"path":"src/main/java/seedu/stocker/drugs/Cart.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class Cart {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" private ArrayList\u003cCartEntry\u003e entries;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public Cart() {","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" this.entries \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public void addEntry(String key, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" this.entries.add(new CartEntry(key, quantity));","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public List\u003cCartEntry\u003e getCurrentCart() {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" return this.entries;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" public boolean isEmpty() {","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" return entries.isEmpty();","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" public void checkOut(SalesList salesList, Inventory inventory) {","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" salesList.addSale(this);","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" for (CartEntry entry : entries) {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" inventory.removeFromStock(entry.getKey(), entry.getQuantity());","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" this.entries \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":32}},{"path":"src/main/java/seedu/stocker/drugs/CartEntry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"public class CartEntry {","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" private String key;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" private long quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public CartEntry(String key, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" this.key \u003d key;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public String getKey() {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" return this.key;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public long getQuantity() {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" return this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" * Returns a string representation of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" * @return A string containing the key and quantity date of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return \"Key: \" + this.key","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" + \", Quantity: \" + this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":31}},{"path":"src/main/java/seedu/stocker/drugs/Description.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"public class Description {","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":" private static Map\u003cString, String\u003e descriptions \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" public static void addDescription(String drugName, String description) {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" descriptions.put(drugName, description);","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" public static String getDescription(String drugName) {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" return descriptions.get(drugName);","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" public static Map\u003cString, String\u003e getAllDescriptions() {","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" return descriptions;","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":21}},{"path":"src/main/java/seedu/stocker/drugs/Drug.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"public class Drug {","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":" public String name;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":" String expiryDate;","lastModifiedDate":"2023-10-08"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public Drug(String name, String expiryDate) {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" this.expiryDate \u003d expiryDate;","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":" * Gets the name of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":" * @return The name of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" public String getName() {","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" return name;","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"azfarulmatin"},"content":" * Sets the name of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":" * @param name The new name to set for the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"azfarulmatin"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"azfarulmatin"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"azfarulmatin"},"content":" * Gets the expiry date of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"azfarulmatin"},"content":" * @return The expiry date of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":" public String getExpiryDate() {","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"azfarulmatin"},"content":" return expiryDate;","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"azfarulmatin"},"content":" * Sets the expiry date of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"azfarulmatin"},"content":" * @param expiryDate The new expiry date to set for the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"azfarulmatin"},"content":" public void setExpiryDate(String expiryDate) {","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"azfarulmatin"},"content":" this.expiryDate \u003d expiryDate;","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":48,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":50,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"azfarulmatin"},"content":" * Returns a string representation of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" * @return A string containing the name and expiry date of the drug.","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"azfarulmatin"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":56,"author":{"gitId":"azfarulmatin"},"content":" public String toString() {","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" return \"Name: \" + name + \", Expiry Date: \" + expiryDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"martinschnder":5,"azfarulmatin":43,"TeoHaoZhi":11}},{"path":"src/main/java/seedu/stocker/drugs/Inventory.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"import java.util.List;","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.stream.Collectors;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.exceptions.DrugNotFoundException;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"public class Inventory {","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" public HashMap\u003cString, StockEntry\u003e stock;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public Inventory() {","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" this.stock \u003d new HashMap\u003cString, StockEntry\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" public void addNewDrug(String key, Drug drug, String serialNumber, long quantity) {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" this.stock.put(key, new StockEntry(drug, quantity, serialNumber));","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" public void removeFromStock(String key, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" this.stock.get(key).decrQuantity(quantity);","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public List\u003cStockEntry\u003e getStockEntries() {","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" return this.stock.values().stream()","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" .collect(Collectors.toCollection(ArrayList::new));","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" public StockEntry deleteDrug(String key) throws DrugNotFoundException {","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" if (this.stock.containsKey(key)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" return stock.remove(key);","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" throw new DrugNotFoundException(\"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" public StockEntry getStockEntry(String drugName) {","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" for (StockEntry stockEntry : stock.values()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntry.getDrug().getName().equalsIgnoreCase(drugName)) {","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" return stockEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" return null; // Drug not found in inventory","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":33,"azfarulmatin":5,"Barbaracwx":10}},{"path":"src/main/java/seedu/stocker/drugs/SalesList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class SalesList {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" private ArrayList\u003cCart\u003e validatedCarts;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public SalesList() {","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" this.validatedCarts \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public void addSale(Cart cart) {","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" this.validatedCarts.add(cart);","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" public List\u003cCart\u003e getAllSales() {","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" return this.validatedCarts;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":22}},{"path":"src/main/java/seedu/stocker/drugs/StockEntry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"public class StockEntry {","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":" private final Drug drug;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":" private final String serialNumber; // Add serial number field","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" private long quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":" private long thresholdQuantity;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":" public StockEntry(Drug drug, long quantity, String serialNumber) {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" this.drug \u003d drug;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":" this.serialNumber \u003d serialNumber; // Initialise serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" this.thresholdQuantity \u003d 100;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" public String getSerialNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" return this.serialNumber; // Getter for serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" public Drug getDrug() {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" return this.drug;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public long getQuantity() {","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" return this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" public void setQuantity(long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" public void setThresholdQuantity(long thresholdQuantity) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" this.thresholdQuantity \u003d thresholdQuantity;","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" public long getThresholdQuantity() {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" return this.thresholdQuantity;","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":" public void incrQuantity(long delta) {","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" this.quantity +\u003d delta;","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"martinschnder"},"content":" public void decrQuantity(long delta) {","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":" assert(this.quantity \u003e delta);","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" this.quantity -\u003d delta;","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":" * Returns a string representation of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" * @return A string containing the key and quantity date of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" return \"Name: \" + this.drug.getName()","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":" + \", Expiry date: \" + this.drug.getExpiryDate()","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" + \", Quantity: \" + this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":44,"azfarulmatin":7,"Barbaracwx":11}},{"path":"src/main/java/seedu/stocker/exceptions/DrugNotFoundException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.exceptions;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Signals that the drug has not been found in a specific list.","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class DrugNotFoundException extends Exception {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" public DrugNotFoundException(String message) {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" super(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":10}},{"path":"src/main/java/seedu/stocker/exceptions/InvalidDrugFormatException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.exceptions;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Signals that the laod function cannot read the serialized drug.","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class InvalidDrugFormatException extends Exception {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" public InvalidDrugFormatException(String message) {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" super(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":10}},{"path":"src/main/java/seedu/stocker/exceptions/StockerException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.exceptions;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"public class StockerException extends Exception{","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"TeoHaoZhi":4}},{"path":"src/main/java/seedu/stocker/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.parser;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.DeleteCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ExitCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.FindCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.HelpCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.IncorrectCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.LoginCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.RegisterCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.SaveCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddVendorCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ShowStockLevelCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ViewCartCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddToCartCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.CheckOutCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListVendorCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.SetThresholdCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListThresholdCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddDescriptionCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.GetDescriptionCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListDescriptionsCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddVendorSupplyCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.FindVendorSupplyCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListVendorSupplyCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_COMMAND_FORMAT;","lastModifiedDate":"2023-10-09"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_QUANTITY;","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":"public class Parser {","lastModifiedDate":"2023-10-09"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" public Parser() {","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":" * Parses user input into command for execution.","lastModifiedDate":"2023-10-09"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":44,"author":{"gitId":"martinschnder"},"content":" * @param userInput full user input string","lastModifiedDate":"2023-10-09"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":" * @return the command based on the user input","lastModifiedDate":"2023-10-09"},{"lineNumber":46,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":" public Command parseCommand(String userInput) {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" String[] words \u003d userInput.trim().split(\" \", 2); // split the input into command and arguments","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"martinschnder"},"content":" if (words.length \u003d\u003d 0) {","lastModifiedDate":"2023-10-09"},{"lineNumber":50,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, HelpCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-09"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" final String commandWord \u003d words[0];","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" final String arguments \u003d userInput.replaceFirst(commandWord, \"\").trim();","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" switch (commandWord) {","lastModifiedDate":"2023-10-09"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" case AddCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-09"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" return prepareAddCommand(arguments);","lastModifiedDate":"2023-10-09"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":60,"author":{"gitId":"Barbaracwx"},"content":" case FindCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"Barbaracwx"},"content":" return prepareFindCommand(arguments);","lastModifiedDate":"2023-10-20"},{"lineNumber":62,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"martinschnder"},"content":" case AddToCartCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"martinschnder"},"content":" return prepareAddToCartCommand(arguments);","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"karishma-t"},"content":" case AddDescriptionCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"karishma-t"},"content":" return prepareAddDescriptionCommand(arguments);","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"karishma-t"},"content":" case GetDescriptionCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"karishma-t"},"content":" return prepareGetDescriptionCommand(arguments);","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"karishma-t"},"content":" case AddVendorSupplyCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"karishma-t"},"content":" return prepareAddVendorSupplyCommand(arguments);","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"karishma-t"},"content":" case DeleteCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":76,"author":{"gitId":"karishma-t"},"content":" return new DeleteCommand(arguments);","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"martinschnder"},"content":" case CheckOutCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"martinschnder"},"content":" return new CheckOutCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"martinschnder"},"content":" case ExitCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-09"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":" return new ExitCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":84,"author":{"gitId":"martinschnder"},"content":" case HelpCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-09"},{"lineNumber":85,"author":{"gitId":"martinschnder"},"content":" return new HelpCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":86,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":87,"author":{"gitId":"azfarulmatin"},"content":" case ListCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-14"},{"lineNumber":88,"author":{"gitId":"azfarulmatin"},"content":" return new ListCommand();","lastModifiedDate":"2023-10-14"},{"lineNumber":89,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":90,"author":{"gitId":"martinschnder"},"content":" case ViewCartCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"martinschnder"},"content":" return new ViewCartCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" case RegisterCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-20"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":" return new RegisterCommand();","lastModifiedDate":"2023-10-20"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":96,"author":{"gitId":"TeoHaoZhi"},"content":" case LoginCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-20"},{"lineNumber":97,"author":{"gitId":"TeoHaoZhi"},"content":" return new LoginCommand();","lastModifiedDate":"2023-10-20"},{"lineNumber":98,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":99,"author":{"gitId":"TeoHaoZhi"},"content":" case SaveCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-21"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":" return new SaveCommand();","lastModifiedDate":"2023-10-21"},{"lineNumber":101,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":102,"author":{"gitId":"TeoHaoZhi"},"content":" case AddVendorCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-28"},{"lineNumber":103,"author":{"gitId":"TeoHaoZhi"},"content":" return prepareAddVendorCommand(arguments);","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":105,"author":{"gitId":"Barbaracwx"},"content":" case ShowStockLevelCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"Barbaracwx"},"content":" return new ShowStockLevelCommand();","lastModifiedDate":"2023-10-28"},{"lineNumber":107,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" case ListVendorCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" return new ListVendorCommand();","lastModifiedDate":"2023-10-28"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"Barbaracwx"},"content":" case SetThresholdCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-29"},{"lineNumber":112,"author":{"gitId":"Barbaracwx"},"content":" return prepareSetThresholdCommand(arguments);","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":114,"author":{"gitId":"Barbaracwx"},"content":" case ListThresholdCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"Barbaracwx"},"content":" return new ListThresholdCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"karishma-t"},"content":" case ListDescriptionsCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"karishma-t"},"content":" return new ListDescriptionsCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"karishma-t"},"content":" case ListVendorSupplyCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"karishma-t"},"content":" return new ListVendorSupplyCommand(arguments);","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"karishma-t"},"content":" case FindVendorSupplyCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"karishma-t"},"content":" return new FindVendorSupplyCommand(arguments);","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"martinschnder"},"content":" default:","lastModifiedDate":"2023-10-09"},{"lineNumber":127,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, HelpCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-09"},{"lineNumber":128,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":129,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":130,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":131,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":132,"author":{"gitId":"martinschnder"},"content":" * Parses arguments in the context of the add drug command.","lastModifiedDate":"2023-10-09"},{"lineNumber":133,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":134,"author":{"gitId":"martinschnder"},"content":" * @param args full command args string","lastModifiedDate":"2023-10-09"},{"lineNumber":135,"author":{"gitId":"martinschnder"},"content":" * @return the prepared command","lastModifiedDate":"2023-10-09"},{"lineNumber":136,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":137,"author":{"gitId":"martinschnder"},"content":" private Command prepareAddCommand(String args) {","lastModifiedDate":"2023-10-09"},{"lineNumber":138,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":139,"author":{"gitId":"azfarulmatin"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /d (.*) /s (.*) /q (.*)\");","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"martinschnder"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-09"},{"lineNumber":141,"author":{"gitId":"azfarulmatin"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 4) {","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"martinschnder"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-09"},{"lineNumber":143,"author":{"gitId":"martinschnder"},"content":" String expiryDate \u003d matcher.group(2);","lastModifiedDate":"2023-10-09"},{"lineNumber":144,"author":{"gitId":"azfarulmatin"},"content":" String serialNumber \u003d matcher.group(3);","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"azfarulmatin"},"content":" Long quantity \u003d Long.parseLong(matcher.group(4));","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"martinschnder"},"content":" if (quantity \u003c 1) {","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_QUANTITY, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"azfarulmatin"},"content":" return new AddCommand(name, expiryDate, serialNumber, quantity);","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-09"},{"lineNumber":151,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-09"},{"lineNumber":152,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":153,"author":{"gitId":"martinschnder"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":154,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-23"},{"lineNumber":155,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":156,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":157,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":158,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":159,"author":{"gitId":"martinschnder"},"content":" * Parses arguments in the context of the add drug to cart command.","lastModifiedDate":"2023-10-23"},{"lineNumber":160,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":161,"author":{"gitId":"martinschnder"},"content":" * @param args full command args string","lastModifiedDate":"2023-10-23"},{"lineNumber":162,"author":{"gitId":"martinschnder"},"content":" * @return the prepared command","lastModifiedDate":"2023-10-23"},{"lineNumber":163,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":164,"author":{"gitId":"martinschnder"},"content":" private Command prepareAddToCartCommand(String args) {","lastModifiedDate":"2023-10-23"},{"lineNumber":165,"author":{"gitId":"martinschnder"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /q (.*)\");","lastModifiedDate":"2023-10-23"},{"lineNumber":166,"author":{"gitId":"martinschnder"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-23"},{"lineNumber":167,"author":{"gitId":"martinschnder"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 2) {","lastModifiedDate":"2023-10-23"},{"lineNumber":168,"author":{"gitId":"martinschnder"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-23"},{"lineNumber":169,"author":{"gitId":"Barbaracwx"},"content":" long quantity \u003d Long.parseLong(matcher.group(2));","lastModifiedDate":"2023-10-28"},{"lineNumber":170,"author":{"gitId":"martinschnder"},"content":" if (quantity \u003c 1) {","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_QUANTITY, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":173,"author":{"gitId":"martinschnder"},"content":" return new AddToCartCommand(name, quantity);","lastModifiedDate":"2023-10-23"},{"lineNumber":174,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":175,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddToCartCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-29"},{"lineNumber":176,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":177,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":178,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":179,"author":{"gitId":"Barbaracwx"},"content":" private Command prepareFindCommand(String args) {","lastModifiedDate":"2023-10-20"},{"lineNumber":180,"author":{"gitId":"Barbaracwx"},"content":" String[] findArgs \u003d args.split(\" \", 2);","lastModifiedDate":"2023-10-20"},{"lineNumber":181,"author":{"gitId":"Barbaracwx"},"content":" if (findArgs.length \u003d\u003d 2) {","lastModifiedDate":"2023-10-20"},{"lineNumber":182,"author":{"gitId":"Barbaracwx"},"content":" String criterion \u003d findArgs[0];","lastModifiedDate":"2023-10-20"},{"lineNumber":183,"author":{"gitId":"Barbaracwx"},"content":" String keyword \u003d findArgs[1];","lastModifiedDate":"2023-10-20"},{"lineNumber":184,"author":{"gitId":"azfarulmatin"},"content":" if (criterion.equals(\"/n\") || criterion.equals(\"/d\") || criterion.equals(\"/s\")) {","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"Barbaracwx"},"content":" return new FindCommand(keyword, criterion);","lastModifiedDate":"2023-10-20"},{"lineNumber":186,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-20"},{"lineNumber":187,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, FindCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-20"},{"lineNumber":188,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":189,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-20"},{"lineNumber":190,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, FindCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-20"},{"lineNumber":191,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":192,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":193,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"martinschnder"},"content":" private Command prepareAddVendorCommand(String args) {","lastModifiedDate":"2023-11-02"},{"lineNumber":195,"author":{"gitId":"TeoHaoZhi"},"content":" String[] vendorArgs \u003d args.split(\" \", 1);","lastModifiedDate":"2023-10-28"},{"lineNumber":196,"author":{"gitId":"TeoHaoZhi"},"content":" String vendorName \u003d vendorArgs[0];","lastModifiedDate":"2023-10-28"},{"lineNumber":197,"author":{"gitId":"TeoHaoZhi"},"content":" if (vendorName.equals(null) || vendorName.equals(\"\") || vendorName.equals(\" \")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":198,"author":{"gitId":"TeoHaoZhi"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddVendorCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-28"},{"lineNumber":199,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":200,"author":{"gitId":"TeoHaoZhi"},"content":" return new AddVendorCommand(vendorName);","lastModifiedDate":"2023-10-28"},{"lineNumber":201,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":202,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"Barbaracwx"},"content":" private Command prepareSetThresholdCommand(String args) {","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"Barbaracwx"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"Barbaracwx"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /tq (.*)\");","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"Barbaracwx"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"Barbaracwx"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 2) {","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"Barbaracwx"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"Barbaracwx"},"content":" Long threshold \u003d Long.parseLong(matcher.group(2));","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"Barbaracwx"},"content":" return new SetThresholdCommand(name, threshold);","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"Barbaracwx"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"karishma-t"},"content":" private Command prepareAddDescriptionCommand(String args) {","lastModifiedDate":"2023-10-30"},{"lineNumber":222,"author":{"gitId":"karishma-t"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /desc (.*)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":223,"author":{"gitId":"karishma-t"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-30"},{"lineNumber":224,"author":{"gitId":"karishma-t"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 2) {","lastModifiedDate":"2023-10-30"},{"lineNumber":225,"author":{"gitId":"karishma-t"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":226,"author":{"gitId":"karishma-t"},"content":" String description \u003d matcher.group(2);","lastModifiedDate":"2023-10-30"},{"lineNumber":227,"author":{"gitId":"karishma-t"},"content":" if (name !\u003d null \u0026\u0026 !name.isEmpty() \u0026\u0026 description !\u003d null \u0026\u0026 !description.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":228,"author":{"gitId":"karishma-t"},"content":" return new AddDescriptionCommand(name, description);","lastModifiedDate":"2023-10-30"},{"lineNumber":229,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":230,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":231,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":232,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":234,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":235,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":236,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":237,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":238,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":239,"author":{"gitId":"karishma-t"},"content":" private Command prepareGetDescriptionCommand(String args) {","lastModifiedDate":"2023-10-30"},{"lineNumber":240,"author":{"gitId":"karishma-t"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":241,"author":{"gitId":"karishma-t"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-30"},{"lineNumber":242,"author":{"gitId":"karishma-t"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 1) {","lastModifiedDate":"2023-10-30"},{"lineNumber":243,"author":{"gitId":"karishma-t"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":244,"author":{"gitId":"karishma-t"},"content":" if (name !\u003d null \u0026\u0026 !name.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"karishma-t"},"content":" return new GetDescriptionCommand(name);","lastModifiedDate":"2023-10-30"},{"lineNumber":246,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":248,"author":{"gitId":"karishma-t"},"content":" GetDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":249,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":250,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":251,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":252,"author":{"gitId":"karishma-t"},"content":" GetDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":253,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":254,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":255,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":256,"author":{"gitId":"karishma-t"},"content":" private Command prepareAddVendorSupplyCommand(String args) {","lastModifiedDate":"2023-10-31"},{"lineNumber":257,"author":{"gitId":"karishma-t"},"content":" String[] parts \u003d args.trim().split(\" \", 2);","lastModifiedDate":"2023-10-31"},{"lineNumber":258,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":259,"author":{"gitId":"karishma-t"},"content":" if (parts.length \u003d\u003d 2) {","lastModifiedDate":"2023-10-31"},{"lineNumber":260,"author":{"gitId":"karishma-t"},"content":" String vendorName \u003d parts[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":261,"author":{"gitId":"karishma-t"},"content":" String drugName \u003d parts[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":263,"author":{"gitId":"karishma-t"},"content":" return new AddVendorSupplyCommand(vendorName, drugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":264,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":265,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-31"},{"lineNumber":266,"author":{"gitId":"karishma-t"},"content":" AddVendorSupplyCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-31"},{"lineNumber":267,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":268,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":269,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":270,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":271,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"karishma-t":98,"martinschnder":91,"azfarulmatin":10,"TeoHaoZhi":25,"Barbaracwx":47}},{"path":"src/main/java/seedu/stocker/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.storage;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.exceptions.InvalidDrugFormatException;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.BufferedWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.File;","lastModifiedDate":"2023-10-21"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-21"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" * Represents an object to handle writing to txt files and appending to them.","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"public class Storage {","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" private Inventory inventory;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" public Storage(Inventory inventory) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.inventory \u003d inventory;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" * Writes to the first line of a txt file","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" * can be used to clear a txt file as well.","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" * @param filePath relative path of file to write to","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" * @param textToAdd what to write to the file","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if invalid input is entered","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" public void writeToFile(String filePath, String textToAdd) throws IOException {","lastModifiedDate":"2023-10-21"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" FileWriter fw \u003d new FileWriter(filePath);","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-11"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" fw.close();","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" * Appends given text to next line of txt file.","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" * @param filePath relative path of file to write to","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" * @param textToAppend what to write to the file","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if invalid input is given","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":" public void appendToFile(String filePath, String textToAppend) throws IOException {","lastModifiedDate":"2023-10-21"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":" BufferedWriter bf \u003d new BufferedWriter(new FileWriter(filePath,true));","lastModifiedDate":"2023-10-21"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" bf.write(textToAppend);","lastModifiedDate":"2023-10-11"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":" bf.newLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":" bf.close();","lastModifiedDate":"2023-10-11"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-21"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":" * Loads drugs from txt file into inventory system.","lastModifiedDate":"2023-10-21"},{"lineNumber":56,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-21"},{"lineNumber":57,"author":{"gitId":"TeoHaoZhi"},"content":" * @param filePath Relative path to file containing list of drugs to be loaded.","lastModifiedDate":"2023-10-21"},{"lineNumber":58,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if file is not found","lastModifiedDate":"2023-10-21"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" public void loadFileContents(String filePath) throws IOException, InvalidDrugFormatException {","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":" File holder \u003d new File(\"./drugs.txt\");","lastModifiedDate":"2023-10-21"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":" if (!holder.exists()) {","lastModifiedDate":"2023-10-21"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":" holder.createNewFile();","lastModifiedDate":"2023-10-21"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":" File f \u003d new File(filePath);","lastModifiedDate":"2023-10-21"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":" Scanner reader \u003d new Scanner(f);","lastModifiedDate":"2023-10-21"},{"lineNumber":67,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":68,"author":{"gitId":"azfarulmatin"},"content":" Pattern pattern \u003d Pattern.compile(","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"azfarulmatin"},"content":" \"Name: (.*), Expiry date: (.*), Serial Number: (.*), Quantity: (.*)\"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"azfarulmatin"},"content":" );","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":" while (reader.hasNextLine()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"martinschnder"},"content":" Matcher matcher \u003d pattern.matcher(reader.nextLine());","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"azfarulmatin"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 4) {","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"martinschnder"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"martinschnder"},"content":" String expiryDate \u003d matcher.group(2);","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"azfarulmatin"},"content":" String serialNumber \u003d matcher.group(3); // Extract serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"azfarulmatin"},"content":" Long quantity \u003d Long.parseLong(matcher.group(4));","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":79,"author":{"gitId":"martinschnder"},"content":" Drug drug \u003d new Drug(name, expiryDate);","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(name, drug, serialNumber, quantity);","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":" throw new InvalidDrugFormatException(\"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":86,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":88,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":22,"azfarulmatin":7,"TeoHaoZhi":59}},{"path":"src/main/java/seedu/stocker/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import java.io.InputStream;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.Optional;","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.CommandResult;","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_USERNAME_INPUT;","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_USER_ALREADY_EXIST;","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_LOGIN_WELCOME;","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_SUCCESSFUL_LOGIN;","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_NO_BLANK_NAME_ALLOWED;","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_NO_BLANK_PASSWORD_ALLOWED;","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_PASSWORD_INPUT;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_WELCOME;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_CHOICE;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_GOODBYE;","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_USERNAME_OR_PASSWORD;","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_SUCCESSFUL_REGISTRATION;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INIT_FAILED;","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_EXECUTION_FAILED;","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_LOGIN_CHARACTER;","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"public class Ui {","lastModifiedDate":"2023-10-08"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * Offset required to convert between 1-indexing and 0-indexing.","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" public static final int DISPLAYED_INDEX_OFFSET \u003d 1;","lastModifiedDate":"2023-10-09"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" * A decorative prefix added to the beginning of lines printed by Jerry","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":" private static final String LINE_PREFIX \u003d \"|| \";","lastModifiedDate":"2023-10-09"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":41,"author":{"gitId":"martinschnder"},"content":" private static final String DIVIDER \u003d \"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\";","lastModifiedDate":"2023-10-09"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" * A platform independent line separator.","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"martinschnder"},"content":" private static final String LS \u003d System.lineSeparator();","lastModifiedDate":"2023-10-09"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" * Format of indexed list item","lastModifiedDate":"2023-10-14"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" private static final String MESSAGE_INDEXED_LIST_ITEM \u003d \"\\t%1$d. %2$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" private final Scanner in;","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" private final PrintStream out;","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":56,"author":{"gitId":"TeoHaoZhi"},"content":" public Ui() {","lastModifiedDate":"2023-10-08"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" this(System.in, System.out);","lastModifiedDate":"2023-10-09"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" public Ui(InputStream in, PrintStream out) {","lastModifiedDate":"2023-10-09"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" this.in \u003d new Scanner(in);","lastModifiedDate":"2023-10-09"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":" this.out \u003d out;","lastModifiedDate":"2023-10-09"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":65,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":66,"author":{"gitId":"martinschnder"},"content":" * Prompts for the command and reads the text entered by the user.","lastModifiedDate":"2023-10-09"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" * Ignores empty, pure whitespace, and comment lines.","lastModifiedDate":"2023-10-09"},{"lineNumber":68,"author":{"gitId":"martinschnder"},"content":" * Echos the command back to the user.","lastModifiedDate":"2023-10-09"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"martinschnder"},"content":" * @return command (full line) entered by the user","lastModifiedDate":"2023-10-09"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":72,"author":{"gitId":"martinschnder"},"content":" public String getUserCommand() {","lastModifiedDate":"2023-10-09"},{"lineNumber":73,"author":{"gitId":"martinschnder"},"content":" out.print(LINE_PREFIX + \"Enter command: \");","lastModifiedDate":"2023-10-09"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":" String fullUserInput \u003d in.nextLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":75,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":" return fullUserInput;","lastModifiedDate":"2023-10-14"},{"lineNumber":77,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":79,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":80,"author":{"gitId":"TeoHaoZhi"},"content":" * Shows message(s) to the user","lastModifiedDate":"2023-10-14"},{"lineNumber":81,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-09"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":" for (String m : message) {","lastModifiedDate":"2023-10-09"},{"lineNumber":84,"author":{"gitId":"martinschnder"},"content":" out.println(LINE_PREFIX + m.replace(\"\\n\", LS + LINE_PREFIX));","lastModifiedDate":"2023-10-09"},{"lineNumber":85,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":86,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":88,"author":{"gitId":"TeoHaoZhi"},"content":" public void showLoginMessage() {","lastModifiedDate":"2023-10-12"},{"lineNumber":89,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(DIVIDER, MESSAGE_LOGIN_WELCOME, DIVIDER);","lastModifiedDate":"2023-10-12"},{"lineNumber":90,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":91,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":92,"author":{"gitId":"TeoHaoZhi"},"content":" public void showUsernameMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_USERNAME_INPUT);","lastModifiedDate":"2023-10-14"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":96,"author":{"gitId":"martinschnder"},"content":" public void showExecutionFailedMessage() {","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_EXECUTION_FAILED);","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":" public void showPasswordMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":101,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_PASSWORD_INPUT);","lastModifiedDate":"2023-10-14"},{"lineNumber":102,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":103,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":104,"author":{"gitId":"TeoHaoZhi"},"content":" public void showSuccessfulRegistrationMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":105,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_SUCCESSFUL_REGISTRATION);","lastModifiedDate":"2023-10-14"},{"lineNumber":106,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":107,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" public void showSuccessfulLoginMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_SUCCESSFUL_LOGIN);","lastModifiedDate":"2023-10-14"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":111,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":112,"author":{"gitId":"TeoHaoZhi"},"content":" public void showInvalidChoiceMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":113,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_INVALID_CHOICE);","lastModifiedDate":"2023-10-14"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":116,"author":{"gitId":"TeoHaoZhi"},"content":" public void showUserAlreadyExistMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":117,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_USER_ALREADY_EXIST);","lastModifiedDate":"2023-10-14"},{"lineNumber":118,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":119,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":120,"author":{"gitId":"TeoHaoZhi"},"content":" public void showEnterChoiceAgainMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":121,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_LOGIN_WELCOME);","lastModifiedDate":"2023-10-14"},{"lineNumber":122,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":123,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":124,"author":{"gitId":"TeoHaoZhi"},"content":" public void showInvalidUsernameOrPasswordMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":125,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_INVALID_USERNAME_OR_PASSWORD);","lastModifiedDate":"2023-10-14"},{"lineNumber":126,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":127,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":128,"author":{"gitId":"TeoHaoZhi"},"content":" public void showBlankNameMessage() {","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_NO_BLANK_NAME_ALLOWED);","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"TeoHaoZhi"},"content":" public void showBlankPasswordMessage() {","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_NO_BLANK_PASSWORD_ALLOWED);","lastModifiedDate":"2023-10-15"},{"lineNumber":134,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"martinschnder"},"content":" public void showWelcomeMessage() {","lastModifiedDate":"2023-10-09"},{"lineNumber":137,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_WELCOME, DIVIDER, DIVIDER);","lastModifiedDate":"2023-10-09"},{"lineNumber":138,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":139,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":140,"author":{"gitId":"TeoHaoZhi"},"content":" public void showInvalidLoginCharacterMessage(){showToUser(MESSAGE_INVALID_LOGIN_CHARACTER);}","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"martinschnder"},"content":" public void showGoodbyeMessage() {","lastModifiedDate":"2023-10-09"},{"lineNumber":143,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_GOODBYE, DIVIDER, DIVIDER);","lastModifiedDate":"2023-10-09"},{"lineNumber":144,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":145,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":146,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":147,"author":{"gitId":"martinschnder"},"content":" * Shows the result of a command execution to the user. Includes additional formatting to demarcate different","lastModifiedDate":"2023-10-09"},{"lineNumber":148,"author":{"gitId":"martinschnder"},"content":" * command execution segments.","lastModifiedDate":"2023-10-09"},{"lineNumber":149,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":150,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003evoid showResultToUser(CommandResult\u003cT\u003e result) {","lastModifiedDate":"2023-10-23"},{"lineNumber":151,"author":{"gitId":"martinschnder"},"content":" final Optional\u003cList\u003cT\u003e\u003e resultElements \u003d result.getRelevantElements();","lastModifiedDate":"2023-10-23"},{"lineNumber":152,"author":{"gitId":"martinschnder"},"content":" if (resultElements.isPresent()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":153,"author":{"gitId":"martinschnder"},"content":" showElementsListView(resultElements.get());","lastModifiedDate":"2023-10-23"},{"lineNumber":154,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":155,"author":{"gitId":"martinschnder"},"content":" showToUser(result.feedbackToUser, DIVIDER);","lastModifiedDate":"2023-10-09"},{"lineNumber":156,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":157,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":158,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":159,"author":{"gitId":"TeoHaoZhi"},"content":" * Shows a list of strings to the user, formatted as an indexed list.","lastModifiedDate":"2023-10-14"},{"lineNumber":160,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":161,"author":{"gitId":"martinschnder"},"content":" private void showToUserAsIndexedList(List\u003cString\u003e list) {","lastModifiedDate":"2023-10-09"},{"lineNumber":162,"author":{"gitId":"martinschnder"},"content":" showToUser(getIndexedListForViewing(list));","lastModifiedDate":"2023-10-09"},{"lineNumber":163,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":164,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":165,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":166,"author":{"gitId":"martinschnder"},"content":" * Shows a list of drugs to the user, formatted as an indexed list.","lastModifiedDate":"2023-10-09"},{"lineNumber":167,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":168,"author":{"gitId":"martinschnder"},"content":" private \u003cT\u003evoid showElementsListView(List\u003cT\u003e elements) {","lastModifiedDate":"2023-10-23"},{"lineNumber":169,"author":{"gitId":"martinschnder"},"content":" final List\u003cString\u003e formattedElements \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":170,"author":{"gitId":"martinschnder"},"content":" for (int i \u003d 0; i \u003c elements.size(); i++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":171,"author":{"gitId":"martinschnder"},"content":" formattedElements.add(elements.get(i).toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":172,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":173,"author":{"gitId":"martinschnder"},"content":" showToUserAsIndexedList(formattedElements);","lastModifiedDate":"2023-10-23"},{"lineNumber":174,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":175,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":176,"author":{"gitId":"martinschnder"},"content":" public void showInitFailedMessage() {","lastModifiedDate":"2023-10-23"},{"lineNumber":177,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_INIT_FAILED, DIVIDER, DIVIDER);","lastModifiedDate":"2023-10-23"},{"lineNumber":178,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":179,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":180,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":181,"author":{"gitId":"TeoHaoZhi"},"content":" * Formats a list of strings as a viewable indexed list.","lastModifiedDate":"2023-10-14"},{"lineNumber":182,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":183,"author":{"gitId":"martinschnder"},"content":" public static String getIndexedListForViewing(List\u003cString\u003e listItems) {","lastModifiedDate":"2023-10-10"},{"lineNumber":184,"author":{"gitId":"martinschnder"},"content":" final StringBuilder formatted \u003d new StringBuilder();","lastModifiedDate":"2023-10-09"},{"lineNumber":185,"author":{"gitId":"martinschnder"},"content":" int displayIndex \u003d DISPLAYED_INDEX_OFFSET;","lastModifiedDate":"2023-10-09"},{"lineNumber":186,"author":{"gitId":"martinschnder"},"content":" for (String listItem : listItems) {","lastModifiedDate":"2023-10-09"},{"lineNumber":187,"author":{"gitId":"martinschnder"},"content":" formatted.append(getIndexedListItem(displayIndex, listItem)).append(LS);","lastModifiedDate":"2023-10-11"},{"lineNumber":188,"author":{"gitId":"martinschnder"},"content":" displayIndex++;","lastModifiedDate":"2023-10-09"},{"lineNumber":189,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":190,"author":{"gitId":"martinschnder"},"content":" return formatted.toString();","lastModifiedDate":"2023-10-09"},{"lineNumber":191,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":192,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":193,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":194,"author":{"gitId":"martinschnder"},"content":" * Formats a string as a viewable indexed list item.","lastModifiedDate":"2023-10-09"},{"lineNumber":195,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":196,"author":{"gitId":"martinschnder"},"content":" * @param visibleIndex visible index for this listing","lastModifiedDate":"2023-10-09"},{"lineNumber":197,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":198,"author":{"gitId":"martinschnder"},"content":" private static String getIndexedListItem(int visibleIndex, String listItem) {","lastModifiedDate":"2023-10-09"},{"lineNumber":199,"author":{"gitId":"martinschnder"},"content":" return String.format(MESSAGE_INDEXED_LIST_ITEM, visibleIndex, listItem);","lastModifiedDate":"2023-10-09"},{"lineNumber":200,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":201,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":202,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"martinschnder":100,"TeoHaoZhi":102}},{"path":"src/main/java/seedu/stocker/vendors/Vendor.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.vendors;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"public class Vendor {","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":" public String name;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":" public Vendor(String name) {","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" * Gets the name of the vendor.","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" * @return The name of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public String getName() {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" return name;","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" * Sets the name of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" * @param name The new name to set for the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" * Returns a string representation of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * @return A string containing the name of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" public String toString() {","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" return \"Name: \" + name;","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"TeoHaoZhi":38}},{"path":"src/main/java/seedu/stocker/vendors/VendorSupplyList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.vendors;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" * Represents a class to manage the association between vendors and the drugs they supply.","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"public class VendorSupplyList {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" private static final Map\u003cString, List\u003cString\u003e\u003e vendorSuppliedDrugs \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" * Adds a drug to a vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug to be added to the vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" public static void addDrugToVendor(String vendorName, String drugName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" vendorSuppliedDrugs.computeIfAbsent(vendorName, k -\u003e new ArrayList\u003c\u003e()).add(drugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" * Retrieves the list of drugs supplied by a specific vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" * @return A list of drug names supplied by the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" public static List\u003cString\u003e getDrugsSuppliedByVendor(String vendorName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" return vendorSuppliedDrugs.getOrDefault(vendorName, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" * Returns the mapping of vendors to the drugs they supply.","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" * @return A map where each key (vendor name) is associated with a list of drugs they supply.","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" public static Map\u003cString, List\u003cString\u003e\u003e getVendorSuppliedDrugs() {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" return vendorSuppliedDrugs;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":42}},{"path":"src/main/java/seedu/stocker/vendors/VendorsList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.vendors;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"public class VendorsList {","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" protected ArrayList\u003cVendor\u003e vendorArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public VendorsList(){","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" vendorArrayList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" * Adds new vendor to vendor list","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" * @param vendor","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" public void addNewVendor(Vendor vendor){","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" vendorArrayList.add(vendor);","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" * Gets details of all vendors","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" * @return List vendor","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" public List\u003cVendor\u003e getVendorEntries() {","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return new ArrayList\u003c\u003e(this.vendorArrayList);","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"martinschnder":6,"TeoHaoZhi":24}},{"path":"src/test/java/seedu/stocker/StockerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"class StockerTest {","lastModifiedDate":"2023-10-08"},{"lineNumber":8,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":" public void sampleTest() {","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"TeoHaoZhi":2,"-":10}},{"path":"src/test/java/seedu/stocker/commands/AddCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-10"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-10"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-10"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"class AddCommandTest {","lastModifiedDate":"2023-10-10"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" @Test","lastModifiedDate":"2023-10-10"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-10"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":" AddCommand command \u003d new AddCommand(\"Paracetamol\", \"12/05/2024\", \"12345\",12L);","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" command.setData(new Inventory(), new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" String expectedOutput \u003d \"New drug added in the inventory: Paracetamol\";","lastModifiedDate":"2023-10-10"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" assertEquals(command.execute().feedbackToUser, new CommandResult(expectedOutput).feedbackToUser);","lastModifiedDate":"2023-10-10"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" assertEquals(command.execute().getRelevantElements(), new CommandResult(expectedOutput).getRelevantElements());","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-10"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-10"}],"authorContributionMap":{"martinschnder":21,"azfarulmatin":1}},{"path":"src/test/java/seedu/stocker/commands/AddDescriptionCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"public class AddDescriptionCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand command \u003d new AddDescriptionCommand(\"Panadol\", \"Pain Relief\");","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" CommandResult\u003cString\u003e result \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" String feedbackMessage \u003d result.feedbackToUser;","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" assertEquals(\"New drug description added for Panadol: Pain Relief\", feedbackMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":17}},{"path":"src/test/java/seedu/stocker/commands/AddToCartCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"class AddToCartCommandTest {","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" ","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" @Test","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" AddCommand command \u003d new AddCommand(\"Paracetamol\", \"12/05/2024\", \"12345\", 12L);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" Cart cart \u003d new Cart();","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" assertEquals(0, cart.getCurrentCart().size());","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" SalesList salesList \u003d new SalesList();","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, salesList, cart, new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" command.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" AddToCartCommand command2 \u003d new AddToCartCommand(\"paracetamol\", 2L);","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" command2.setData(inventory, salesList, cart, new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" command2.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" assertEquals(command2.execute().feedbackToUser, \"New drug added in the current cart: Paracetamol\");","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"martinschnder":27,"azfarulmatin":1}},{"path":"src/test/java/seedu/stocker/commands/DeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"class DeleteCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" // Create an inventory and add a drug to it","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" Drug doliprane \u003d new Drug(\"Doliprane\", \"12/06/2035\");","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"doliprane\", doliprane, \"ABC1234\", 52L);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" // Create a DeleteCommand for the drug","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(\"Doliprane\");","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" deleteCommand.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" // Test the execution of the DeleteCommand","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" String expectedOutput \u003d \"Drug removed from inventory: Doliprane\";","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" assertEquals(deleteCommand.execute().feedbackToUser, expectedOutput);","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" // Ensure that the drug is no longer in the inventory","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" assertEquals(0, inventory.getStockEntries().size());","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"karishma-t":25,"martinschnder":7,"azfarulmatin":1}},{"path":"src/test/java/seedu/stocker/commands/FindCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_COMMAND_FORMAT;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" * JUnit test class for the FindCommand.","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"class FindCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" * Tests the execution of the FindCommand with a keyword for drug names.","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestByName() {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" // Create an instance of FindCommand with a keyword","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" FindCommand command \u003d new FindCommand(\"Pa\", \"/n\");","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" Drug drug2 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug2, \"PAN123\", 20L);","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" // Define expected output","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"1. Name: Panadol, Expiry date: 04/07/2030, Serial number: PAN123, Quantity: 20\"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"azfarulmatin"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with the modified inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" * Tests the execution of the FindCommand with a keyword for drug expiry dates.","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestByExpiryDate() {","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" // Create an instance of FindCommand with a keyword for expiry date","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":" FindCommand command \u003d new FindCommand(\"01/03/2027\", \"/d\");","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Paracetamol\", \"01/03/2027\");","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Paracetamol\", drug1, \"PARC124\", 12L);","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"Barbaracwx"},"content":" // Define expected output for drugs with matching expiry date","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"1. Name: Paracetamol, Expiry date: 01/03/2027, Serial number: PARC124, Quantity: 12\"","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"azfarulmatin"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"Barbaracwx"},"content":" \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"Barbaracwx"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with the modified inventory","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"Barbaracwx"},"content":" * Tests the execution of the FindCommand with a null keyword, expecting an invalid format message.","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestWithNullKeyword() {","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"Barbaracwx"},"content":" // Create an instance of FindCommand with a null keyword","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"Barbaracwx"},"content":" FindCommand command \u003d new FindCommand(\"\", \"/n\");","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"Barbaracwx"},"content":" // Define expected output for invalid format","lastModifiedDate":"2023-10-26"},{"lineNumber":90,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d String.format(MESSAGE_INVALID_COMMAND_FORMAT, FindCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"Barbaracwx"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with a null keyword","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"azfarulmatin"},"content":" * Tests the execution of the FindCommand with a keyword for drug serial numbers.","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"azfarulmatin"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"azfarulmatin"},"content":" public void executeTestBySerialNumber() {","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"azfarulmatin"},"content":" // Create an instance of FindCommand with a keyword for serial number","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"azfarulmatin"},"content":" FindCommand command \u003d new FindCommand(\"SER123\", \"/s\");","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"azfarulmatin"},"content":" // Create a new inventory","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"azfarulmatin"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"azfarulmatin"},"content":" Drug drug3 \u003d new Drug(\"Aspirin\", \"02/05/2028\");","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Aspirin\", drug3, \"SER123\", 15L);","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"azfarulmatin"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"azfarulmatin"},"content":" // Define expected output for drugs with matching serial number","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"1. Name: Aspirin, Expiry date: 02/05/2028, Serial number: SER123, Quantity: 15\"","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"azfarulmatin"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"azfarulmatin"},"content":" \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"azfarulmatin"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"azfarulmatin"},"content":" // Test the command\u0027s execute method with the modified inventory","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"azfarulmatin"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"martinschnder":7,"azfarulmatin":33,"Barbaracwx":85}},{"path":"src/test/java/seedu/stocker/commands/GetDescriptionCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"public class GetDescriptionCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand addDescriptionCommand \u003d new AddDescriptionCommand(\"Panadol\", \"Pain Relief\");","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" addDescriptionCommand.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" GetDescriptionCommand command \u003d new GetDescriptionCommand(\"Panadol\");","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" CommandResult\u003cString\u003e result \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" String feedbackMessage \u003d result.feedbackToUser;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" assertEquals(\"Pain Relief\", feedbackMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":20}},{"path":"src/test/java/seedu/stocker/commands/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-10"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-10"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"class HelpCommandTest {","lastModifiedDate":"2023-10-10"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" @Test","lastModifiedDate":"2023-10-10"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-10"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" HelpCommand command \u003d new HelpCommand();","lastModifiedDate":"2023-10-10"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" String expectedOutput \u003d System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" + \"add: Adds a new drug to the drug list. Parameters: NAME, EXPIRY DATE, SERIAL NUMBER, QUANTITY, \"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" + \"Example: add /n Doliprane /d 12/06/2035 /s ABC123 /q 52\"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + \"delete: Removes a drug from drug list. Parameters: Name \"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: delete \u003cDrug Name\u003e\"","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" + \"help: Shows program usage instructions. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: help\"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" + \"list: List all drug information that is being tracked by the system. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: list\"","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" + \"stocklevel: List all drugs by quantity level tracked by the system in ascending order. \"","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: stocklevel\"","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" + \"find /n: Finds drug in inventory using name.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: find /n panadol\"","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" + \"find /d: Finds drug in inventory using date.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":45,"author":{"gitId":"azfarulmatin"},"content":" + \"Example: find /d panadol\"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"azfarulmatin"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"azfarulmatin"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"azfarulmatin"},"content":" + \"find /s: Finds drug in inventory using serial number.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"azfarulmatin"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"azfarulmatin"},"content":" + \"Example: find /s ABC123\"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" + \"addtocart: Adds a new drug to the current cart. Parameters: NAME, QUANTITY,\"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":" + \"Example: addtocart /n Doliprane /q 2\"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" + \"checkout: Checks out current cart. Parameters:\"","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" + \"Example: checkout\"","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"martinschnder"},"content":" + \"viewcart: View the current cart items.\"","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"martinschnder"},"content":" + \"Example: viewcart\"","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":" + \"login: Login new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: login\"","lastModifiedDate":"2023-10-20"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":" + \"register: Register new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: register\"","lastModifiedDate":"2023-10-20"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":" + \"save: Saves existing druglist that is loaded into inventory when system is booted up.\"","lastModifiedDate":"2023-10-21"},{"lineNumber":79,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-21"},{"lineNumber":80,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: save\"","lastModifiedDate":"2023-10-21"},{"lineNumber":81,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-21"},{"lineNumber":82,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-21"},{"lineNumber":83,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":" + \"addVendor: Adds a new vendor to the vendors list. Parameter: NAME\"","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: addVendor Moderna\"","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"TeoHaoZhi"},"content":" + \"listVendors: List all vendor information that is being tracked by the system.\"","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: listVendors\"","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"Barbaracwx"},"content":" + \"setthreshold: Set the threshold quantity for a drug. (default 100)\"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: setthreshold /n Doliprane /tq 50\"","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"Barbaracwx"},"content":" + \"listthreshold: List all drugs and their threshold levels.\"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: listthreshold\"","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" + \"bye: Exits the program.\"","lastModifiedDate":"2023-10-15"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: bye\";","lastModifiedDate":"2023-10-11"},{"lineNumber":111,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":112,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":113,"author":{"gitId":"TeoHaoZhi"},"content":" assertEquals(new CommandResult(expectedOutput).feedbackToUser, command.execute().feedbackToUser);","lastModifiedDate":"2023-10-11"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-10"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-10"}],"authorContributionMap":{"martinschnder":15,"azfarulmatin":8,"TeoHaoZhi":71,"Barbaracwx":21}},{"path":"src/test/java/seedu/stocker/commands/ListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"//test for list","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"azfarulmatin"},"content":"class ListCommandTest {","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" @Test","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" ListCommand command \u003d new ListCommand();","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" command.setData(new Inventory(), new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"The inventory is empty.\";","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" assertEquals( new CommandResult(expectedOutput).feedbackToUser,command.execute().feedbackToUser);","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":"}","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"martinschnder":4,"azfarulmatin":17,"Barbaracwx":1}},{"path":"src/test/java/seedu/stocker/commands/ListThresholdCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"public class ListThresholdCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN437\", 120);","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" Drug drug2 \u003d new Drug(\"paracetamol\", \"01/07/2020\");","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"paracetamol\", drug2, \"PARC578\", 50);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" // Create the SetThresholdCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" ListThresholdCommand command \u003d new ListThresholdCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" CommandResult initialResult \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" String expectedInitialOutput \u003d \"1. Panadol: 100\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" \"2. paracetamol: 100\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" \"Listed all drugs by threshold level in the inventory.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with a null keyword","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedInitialOutput, initialResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"martinschnder":2,"azfarulmatin":2,"Barbaracwx":37}},{"path":"src/test/java/seedu/stocker/commands/SetThresholdCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"public class SetThresholdCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN345\", 120);","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" // Create the SetThresholdCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand command \u003d new SetThresholdCommand(\"Panadol\", 75);","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"Threshold quantity set for Panadol: 75\";","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(command.execute().feedbackToUser, expectedOutput);","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestWithNoDrug() {","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN341\", 120);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" // Create the SetThresholdCommand for a drug that doesn\u0027t exist","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand command \u003d new SetThresholdCommand(\"Paracetamol\", 75);","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"Drug not found.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" // Check if the result indicates the drug was not found","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(command.execute().feedbackToUser, expectedOutput);","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"martinschnder":3,"azfarulmatin":2,"Barbaracwx":46}},{"path":"src/test/java/seedu/stocker/commands/StockLevelCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"//test for list","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"class StockLevelCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestEmpty(){","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" ShowStockLevelCommand command \u003d new ShowStockLevelCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" // Execute the command","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" CommandResult result \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"The inventory is empty.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, result.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN947\",120);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" Drug drug2 \u003d new Drug(\"paracetamol\", \"01/07/2020\");","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"paracetamol\", drug2, \"PARC347\",50);","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" Drug drug3 \u003d new Drug(\"histamine\", \"09/05/2070\");","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"histamine\", drug3, \"HIS9447\",10);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" ShowStockLevelCommand command \u003d new ShowStockLevelCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" // Execute the command","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" CommandResult result \u003d command.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"1. Name: histamine, Expiry date: 09/05/2070, Quantity: 10\" +","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" \"2. Name: paracetamol, Expiry date: 01/07/2020, Quantity: 50\" +","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" \"3. Name: Panadol, Expiry date: 04/07/2030, Quantity: 120\" +","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" \"Stock Level Report (Sorted by Quantity)\";","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, result.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"martinschnder":3,"azfarulmatin":3,"Barbaracwx":51}},{"path":"src/test/java/seedu/stocker/ui/UiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-08"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"class UiTest {","lastModifiedDate":"2023-10-08"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" @Test","lastModifiedDate":"2023-10-10"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public void getIndexedListForViewing_success() {","lastModifiedDate":"2023-10-10"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" String expectedOutput \u003d \"\\t1. Paracetamol\" + System.lineSeparator()","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" + \"\\t2. Ibuprofene\" + System.lineSeparator()","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" + \"\\t3. Doliprane\" + System.lineSeparator();","lastModifiedDate":"2023-10-11"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" List\u003cString\u003e input \u003d Arrays.asList(\"Paracetamol\", \"Ibuprofene\", \"Doliprane\");","lastModifiedDate":"2023-10-10"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" assertEquals(expectedOutput, new Ui().getIndexedListForViewing(input));","lastModifiedDate":"2023-10-10"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-10"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"martinschnder":11,"TeoHaoZhi":11}},{"path":"text-ui-test/runtest.bat","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"@echo off","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"setlocal enableextensions","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"pushd %~dp0","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"call gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"cd build\\libs","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"for /f \"tokens\u003d*\" %%a in (","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" \u0027dir /b *.jar\u0027","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":") do (","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" set jarloc\u003d%%a","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":")","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":15,"author":{"gitId":"-"},"content":"java -jar %jarloc% \u003c ..\\..\\text-ui-test\\input.txt \u003e ..\\..\\text-ui-test\\ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":"cd ..\\..\\text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"FC ACTUAL.TXT ACTUAL.TXT \u003eNUL \u0026\u0026 ECHO Test passed! || Echo Test failed!","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"TeoHaoZhi":1,"-":18}},{"path":"text-ui-test/runtest.sh","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"#!/usr/bin/env bash","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":"# change to script directory","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"cd \"${0%/*}\"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"./gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":"cd text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"java -jar $(find ../build/libs/ -mindepth 1 -print -quit) \u003c input.txt \u003e ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":"cp EXPECTED.TXT EXPECTED-UNIX.TXT","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"dos2unix EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"diff EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"if [ ACTUAL.TXT \u003d\u003d ACTUAL.TXT ]","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"-"},"content":"then","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" echo \"Test passed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":19,"author":{"gitId":"-"},"content":" exit 0","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":"else","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" echo \"Test failed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":22,"author":{"gitId":"-"},"content":" exit 1","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":"fi","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"TeoHaoZhi":1,"-":22}}] +[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" mainClass.set(\"seedu.stocker.Stocker\")","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" archiveBaseName.set(\"stocker\")","lastModifiedDate":"2023-10-09"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"martinschnder":2,"TeoHaoZhi":1,"-":44}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"|-----------------------------|:----------------:|:------------------------------------------:|:--------------------------------:|","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"| ![](team/Martin.jpeg) | Martin Schneider | [Github](https://github.com/martinschnder) | [Portfolio](docs/team/Martin.md) |","lastModifiedDate":"2023-10-07"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"| ![](team/Karishma.png) | Karishma | [Github](https://github.com/karishma-t) | [Portfolio](team/karishma.md) |","lastModifiedDate":"2023-10-06"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"| ![](team/Barbara_image.JPG) | Barbara Chong | [Github](https://github.com/barbaracwx) | [Portfolio](team/Barbara.md) |","lastModifiedDate":"2023-10-05"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"| ![](team/HaoZhi.png) | Teo Hao Zhi | [Github](https://github.com/TeoHaoZhi) | [Portfolio](team/HaoZhi.md) |","lastModifiedDate":"2023-10-06"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"| ![](team/Azfarul.JPG) | Azfarul Matin | [Github](https://github.com/azfarulmatin) | [Portfolio](team/Azfarul.md) |","lastModifiedDate":"2023-10-07"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-06"}],"authorContributionMap":{"karishma-t":1,"martinschnder":1,"azfarulmatin":2,"TeoHaoZhi":5,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"1. Reference to AB-3 Developer Guide","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"- [Source](https://se-education.org/addressbook-level3/DeveloperGuide.html#proposed-undoredo-feature)","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"- Used as template to structure this Developer Guide","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"-"},"content":"## Design \u0026 implementation","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"\u003cimg src\u003d\"UML Diagrams/Architecture_Diagram.png\" width\u003d\"280\"\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"The architecture diagram given above explains the high level design of the application. The diagram depicts the key","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"component of the application that enables it to provide its functionalities.","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"Majority of the app\u0027s work is done by the following components","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"- Login System : Handles user authentication before enabling app usage","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"- Ui : Asks for user input by handling output messages","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"- Parser : Makes sense of user input","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"- Commands : List of various commands","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"- CommandResult : Execution of various commands","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"The section below will explain in more detail the design considerations, implementations and rationale of the various","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"components listed above.","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"### Login System Component","lastModifiedDate":"2023-10-21"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-21"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":"The login system component seeks to authenticate and login existing users or register a new user.","lastModifiedDate":"2023-10-21"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":"#### Design considerations","lastModifiedDate":"2023-10-21"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":"- There must be a way to check and verify users with a master list","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":"- The search for existing users username and password must be fast","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":"- Master list must be stored separately on hard drive of machine","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"#### Implementation and rationale","lastModifiedDate":"2023-10-21"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":"The login system class works in the following way. Upon booting up the application, a txt file","lastModifiedDate":"2023-10-21"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"containing a current list of existing users will be loaded into a users attribute within the class in the form of a hash","lastModifiedDate":"2023-10-21"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":"table.When a user attempts to login to their account, the entered username and password is checked against","lastModifiedDate":"2023-10-21"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":"the current list of users in the hashtable. If the username and password matches, the user is logged in.","lastModifiedDate":"2023-10-21"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":"As for registering new users, newly inputted username and password will be saved to the users attribute and this","lastModifiedDate":"2023-10-21"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":"pair of username and password is then appended to the txt file containing current users. The updated user list will be","lastModifiedDate":"2023-10-21"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":"loaded into the users attribute when the application is booted up again.","lastModifiedDate":"2023-10-21"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":"The login system class uses the below methods to achieve its functionality","lastModifiedDate":"2023-10-21"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"- `authenticateUserChoice()` -Decides whether the user chooses to register or login","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":"- `newUserCreator()` -Creates a new user for future login","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":"- `loginExistingUser()` -Login existing user","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":"- `loadExistingUsers()` -Load existing users into hashtable for reference","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":60,"author":{"gitId":"TeoHaoZhi"},"content":"Given below is an example of how the login system class works.","lastModifiedDate":"2023-10-21"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":"When the user first launches the programme, the Stocker object will be instantiated. The object will","lastModifiedDate":"2023-10-21"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":"invoke its own `run()` method which will call its own `start()` method. The Stocker object then instantiates a","lastModifiedDate":"2023-10-21"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":"new UI object which displays the login message by invoking `showLoginMessage()` method. At this point, Stocker object","lastModifiedDate":"2023-10-21"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":"will also instantiate a new login system object.","lastModifiedDate":"2023-10-21"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":67,"author":{"gitId":"TeoHaoZhi"},"content":"The login system object will invoke its own `run()` method to begin the login process. This method begins by loading","lastModifiedDate":"2023-10-21"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":"existing users into the users attribute of the login system class by `loadExistingusers()` method. it then invokes","lastModifiedDate":"2023-10-21"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":"`authenticateUserChoice()` to receive an input from the user to whether register or login a user. Based on the input of","lastModifiedDate":"2023-10-21"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":"the user, either `newUserCreator()` is launched or `loginExistingUser()` methods will be called to register or login a","lastModifiedDate":"2023-10-21"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":"user.","lastModifiedDate":"2023-10-21"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":"The following sequence diagram shows how the login system class works when the program is launched.","lastModifiedDate":"2023-10-21"},{"lineNumber":74,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":"\u003cimg src\u003d\"UML Diagrams/StockerToLoginSystem.png\" width\u003d\"280\"\u003e","lastModifiedDate":"2023-10-21"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":77,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"Barbaracwx"},"content":"### Parser Component","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"Barbaracwx"},"content":"The Parser component is responsible for interpreting user input and converting it into executable commands. It plays a","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"Barbaracwx"},"content":"critical role in bridging the user interface (UI) and the command execution components of the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"Barbaracwx"},"content":"#### Design considerations","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"Barbaracwx"},"content":"- **User Input Parsing:** The Parser must effectively break down user input into its constituent parts, such as the command","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"Barbaracwx"},"content":"keyword and any associated arguments.","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"Barbaracwx"},"content":"- **Command Recognition:** The Parser must recognize the specific command the user intends to execute. This involves matching","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"Barbaracwx"},"content":"the command keyword to a predefined set of commands.","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"Barbaracwx"},"content":"- **Arguments Extraction:** For commands that require additional information, the Parser should correctly extract and format","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"Barbaracwx"},"content":"arguments, ensuring they are ready for command execution.","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"Barbaracwx"},"content":"- **Error Handling:** In cases where the input does not match any recognized command or has formatting errors, the Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"Barbaracwx"},"content":"should generate appropriate error messages.","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"Barbaracwx"},"content":"#### Implementation and rationale","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"Barbaracwx"},"content":"The Parser class is designed to handle these considerations through a well-structured parsing process. Here\u0027s how it","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"Barbaracwx"},"content":"works:","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"Barbaracwx"},"content":"1. Splitting User Input: The Parser takes the full user input and splits it into two parts: the command word and the","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"Barbaracwx"},"content":"remaining arguments.","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"Barbaracwx"},"content":"2. Command Recognition: It matches the command word to a predefined set of commands. If a valid command is recognized, it","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"Barbaracwx"},"content":"proceeds to the next step.","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"Barbaracwx"},"content":"3. Arguments Extraction: Depending on the specific command, the Parser may further parse and extract arguments. For","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"Barbaracwx"},"content":"instance, for the \"AddCommand,\" it extracts drug-related details like name, expiry date, serial number, and quantity.","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"Barbaracwx"},"content":"4. Command Creation: The Parser creates an instance of the appropriate Command class, passing along any required arguments.","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"Barbaracwx"},"content":"This encapsulates the user\u0027s request in an executable command object.","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"Barbaracwx"},"content":"5. Error Handling: If the user input does not match any recognized command or has formatting errors, the Parser generates","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"Barbaracwx"},"content":"an \"IncorrectCommand\" with an error message, providing feedback to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"Barbaracwx"},"content":"By structuring the parsing process this way, the application ensures that user input is correctly interpreted and","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"Barbaracwx"},"content":"translated into executable commands for the subsequent phases of the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"Barbaracwx"},"content":"The parser class uses the below method to achieve its functionality","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"Barbaracwx"},"content":"- `parseCommand(String userInput)` - This method takes the user\u0027s input as a parameter and processes it to identify the","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"Barbaracwx"},"content":" command keyword and any associated arguments. It then recognizes the specific command and prepares it for execution.","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"Barbaracwx"},"content":"Given below is an example of how the login system class works.","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"Barbaracwx"},"content":"Suppose a user enters the command `add /n Paracetamol /d 2023-12-31 /s ABC123 /q 100`. The Parser first splits this input","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"Barbaracwx"},"content":"into the command word \"add\" and the arguments. It then recognizes the \"add\" command, extracts the drug details (name,","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"Barbaracwx"},"content":"expiry date, serial number, and quantity), and creates an instance of the \"`AddCommand`\" with these details. If the user","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"Barbaracwx"},"content":"enters an invalid command or incorrect formatting, the Parser provides feedback to guide the user, ensuring a seamless","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"Barbaracwx"},"content":"interaction between the user and the application.","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"Barbaracwx"},"content":"The Parser is a crucial component that forms the bridge between user intentions and the core functionality of the stock","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"Barbaracwx"},"content":"management system.","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"Barbaracwx"},"content":"The following sequence diagram shows how the parser class works when the program is running.","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"Barbaracwx"},"content":"\u003cimg src\u003d\"UML Diagrams/ParserDiagram.png\" width\u003d\"500\"\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"martinschnder"},"content":"### Main data structures","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"martinschnder"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"martinschnder"},"content":"#### Implementation","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"martinschnder"},"content":"##### Drug","lastModifiedDate":"2023-10-25"},{"lineNumber":152,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":153,"author":{"gitId":"Barbaracwx"},"content":"The Drug class is very basic class for now. It only contains the product name as well as it\u0027s expiry date, but we will","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"Barbaracwx"},"content":"soon add some new properties such as product description, etc...","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":156,"author":{"gitId":"martinschnder"},"content":"##### Inventory","lastModifiedDate":"2023-10-25"},{"lineNumber":157,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":158,"author":{"gitId":"Barbaracwx"},"content":"The Inventory class is used to keep track of the quantity of product in stock. The hash map seemed to be the most","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"Barbaracwx"},"content":"appropriate data structure to match a product id to a quantity and a product entity which are encapsulated in a \"","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"Barbaracwx"},"content":"StockEntry\" class.","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":162,"author":{"gitId":"martinschnder"},"content":"##### Cart","lastModifiedDate":"2023-10-25"},{"lineNumber":163,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":164,"author":{"gitId":"Barbaracwx"},"content":"The Cart class is used to represent an ongoing transaction : to perform a sale, the vendor can add different products","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"Barbaracwx"},"content":"with their respective quantities in a cart which will be deducted from the inventory at the checkout.","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"martinschnder"},"content":"To represent this, we chose to use an arraylist of \"CartEntry\" classes which reprensent a product/quantity tuple.","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":168,"author":{"gitId":"martinschnder"},"content":"##### SalesList","lastModifiedDate":"2023-10-25"},{"lineNumber":169,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":170,"author":{"gitId":"Barbaracwx"},"content":"The SalesList is used to represent every past sales in order to create some statistics and reports. This class is only a","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"Barbaracwx"},"content":"list of subclasses representing validated carts.","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":173,"author":{"gitId":"martinschnder"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"Barbaracwx"},"content":"## Commands","lastModifiedDate":"2023-10-25"},{"lineNumber":176,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":177,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":178,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":179,"author":{"gitId":"Barbaracwx"},"content":"## 1. Find Function","lastModifiedDate":"2023-10-25"},{"lineNumber":180,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":181,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function is designed to enable users to search for specific drugs in the inventory using either the drug\u0027s","lastModifiedDate":"2023-10-25"},{"lineNumber":182,"author":{"gitId":"Barbaracwx"},"content":"name or the drugs expiry date. This component assists in locating and retrieving relevant drugs efficiently.","lastModifiedDate":"2023-10-25"},{"lineNumber":183,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":184,"author":{"gitId":"Barbaracwx"},"content":"**Design Considerations**","lastModifiedDate":"2023-10-25"},{"lineNumber":185,"author":{"gitId":"Barbaracwx"},"content":"The design of the \"Find\" function takes into account the following considerations:","lastModifiedDate":"2023-10-25"},{"lineNumber":186,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":187,"author":{"gitId":"Barbaracwx"},"content":"1. **Search Criteria:** The function must provide users with the ability to specify each criteria, such as keywords or","lastModifiedDate":"2023-10-25"},{"lineNumber":188,"author":{"gitId":"Barbaracwx"},"content":" attributes, to filter the items they are looking for.","lastModifiedDate":"2023-10-25"},{"lineNumber":189,"author":{"gitId":"Barbaracwx"},"content":"2. **Search Speed:** To enhance user experience, the search process should be fast and responsive, ensuring that users","lastModifiedDate":"2023-10-25"},{"lineNumber":190,"author":{"gitId":"Barbaracwx"},"content":" receive search results quickly.","lastModifiedDate":"2023-10-25"},{"lineNumber":191,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":192,"author":{"gitId":"Barbaracwx"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-10-25"},{"lineNumber":193,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":194,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function is implemented as follows:","lastModifiedDate":"2023-10-25"},{"lineNumber":195,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":196,"author":{"gitId":"Barbaracwx"},"content":"- **User-Defined Search Criteria:** Users provide search criteria, such as keywords, to define what they","lastModifiedDate":"2023-10-25"},{"lineNumber":197,"author":{"gitId":"Barbaracwx"},"content":" are looking for. The \"Find\" function processes these criteria to locate relevant items.","lastModifiedDate":"2023-10-25"},{"lineNumber":198,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":199,"author":{"gitId":"Barbaracwx"},"content":"- **Search Algorithm:** A robust search algorithm is employed to efficiently scan through the list of items and identify","lastModifiedDate":"2023-10-25"},{"lineNumber":200,"author":{"gitId":"Barbaracwx"},"content":" those","lastModifiedDate":"2023-10-25"},{"lineNumber":201,"author":{"gitId":"Barbaracwx"},"content":" that match the specified criteria.","lastModifiedDate":"2023-10-25"},{"lineNumber":202,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":203,"author":{"gitId":"Barbaracwx"},"content":"- **Result Presentation:** The function displays the search results, presenting users with a list of items that meet the","lastModifiedDate":"2023-10-25"},{"lineNumber":204,"author":{"gitId":"Barbaracwx"},"content":" search criteria, allowing them to quickly identify the items they are interested in.","lastModifiedDate":"2023-10-25"},{"lineNumber":205,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":206,"author":{"gitId":"Barbaracwx"},"content":"- **User-Friendly Interface:** The \"Find\" function is integrated into the user interface, making it easily accessible","lastModifiedDate":"2023-10-25"},{"lineNumber":207,"author":{"gitId":"Barbaracwx"},"content":" and intuitive for users to perform searches.","lastModifiedDate":"2023-10-25"},{"lineNumber":208,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":209,"author":{"gitId":"Barbaracwx"},"content":"- **Alternative Consideration:** During the design process, alternative approaches to searching are evaluated to ensure","lastModifiedDate":"2023-10-25"},{"lineNumber":210,"author":{"gitId":"Barbaracwx"},"content":" the","lastModifiedDate":"2023-10-25"},{"lineNumber":211,"author":{"gitId":"Barbaracwx"},"content":" most effective and user-friendly method is implemented.","lastModifiedDate":"2023-10-25"},{"lineNumber":212,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":213,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function offers a valuable way for users to narrow down their searches, find specific items of interest, and","lastModifiedDate":"2023-10-25"},{"lineNumber":214,"author":{"gitId":"Barbaracwx"},"content":"enhance the usability of the application.","lastModifiedDate":"2023-10-25"},{"lineNumber":215,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":216,"author":{"gitId":"Barbaracwx"},"content":"**Function Methods**","lastModifiedDate":"2023-10-25"},{"lineNumber":217,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":218,"author":{"gitId":"Barbaracwx"},"content":"The \"Find\" function includes the following method to achieve its functionality:","lastModifiedDate":"2023-10-25"},{"lineNumber":219,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":220,"author":{"gitId":"Barbaracwx"},"content":"- `execute()` - This method is responsible for executing the \"Find\" command, searching for drugs that match the","lastModifiedDate":"2023-10-25"},{"lineNumber":221,"author":{"gitId":"Barbaracwx"},"content":" user-specified keyword within the inventory.","lastModifiedDate":"2023-10-25"},{"lineNumber":222,"author":{"gitId":"Barbaracwx"},"content":"- It returns a `CommandResult` containing the outcome of the command execution,","lastModifiedDate":"2023-10-25"},{"lineNumber":223,"author":{"gitId":"Barbaracwx"},"content":" which includes a success message and a list of found StockEntry objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":224,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":225,"author":{"gitId":"Barbaracwx"},"content":"**Example Usage**","lastModifiedDate":"2023-10-25"},{"lineNumber":226,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":227,"author":{"gitId":"Barbaracwx"},"content":"To illustrate how the \"Find\" function works, consider the following example usage:","lastModifiedDate":"2023-10-25"},{"lineNumber":228,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":229,"author":{"gitId":"Barbaracwx"},"content":"1. **User Input:** The user initiates the \"Find\" command by typing something like the following:","lastModifiedDate":"2023-10-25"},{"lineNumber":230,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":231,"author":{"gitId":"Barbaracwx"},"content":"`find /n panadol` - This command instructs the program to search for drugs in the inventory based on the name criteria","lastModifiedDate":"2023-10-25"},{"lineNumber":232,"author":{"gitId":"Barbaracwx"},"content":"and the keyword \"panadol.\"","lastModifiedDate":"2023-10-25"},{"lineNumber":233,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":234,"author":{"gitId":"Barbaracwx"},"content":"`find /d 12/03/2026` - This command instructs the program to search for drugs in the inventory based on the expiry date","lastModifiedDate":"2023-10-25"},{"lineNumber":235,"author":{"gitId":"Barbaracwx"},"content":"criteria and the keyword \"12/03/2026.\"","lastModifiedDate":"2023-10-25"},{"lineNumber":236,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":237,"author":{"gitId":"azfarulmatin"},"content":"`find /s PARC3189` - This command instructs the program to search for drugs in the inventory based on the serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":238,"author":{"gitId":"azfarulmatin"},"content":"criteria and the keyword \"PARC3189.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":239,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":240,"author":{"gitId":"Barbaracwx"},"content":"2. **Method Execution:** The `execute()` method within the \"FindCommand\" class is called. It takes the provided keyword","lastModifiedDate":"2023-10-25"},{"lineNumber":241,"author":{"gitId":"Barbaracwx"},"content":" and criterion as input.","lastModifiedDate":"2023-10-25"},{"lineNumber":242,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":243,"author":{"gitId":"Barbaracwx"},"content":"3. **Search Process:** The method processes the search by iterating through the list of `StockEntry` objects in the","lastModifiedDate":"2023-10-25"},{"lineNumber":244,"author":{"gitId":"Barbaracwx"},"content":" inventory.","lastModifiedDate":"2023-10-25"},{"lineNumber":245,"author":{"gitId":"Barbaracwx"},"content":" For each entry, it checks if the `matches` method returns `true`, which means that the drug name or expiry date","lastModifiedDate":"2023-10-25"},{"lineNumber":246,"author":{"gitId":"Barbaracwx"},"content":" contains the given keyword.","lastModifiedDate":"2023-10-25"},{"lineNumber":247,"author":{"gitId":"Barbaracwx"},"content":"4. **Building Results:** As matching entries are found, they are added to a list called `foundEntries`.","lastModifiedDate":"2023-10-25"},{"lineNumber":248,"author":{"gitId":"Barbaracwx"},"content":"5. **Result Display:** The `CommandResult` is prepared, containing a success message (e.g., \"Listed all drugs with the","lastModifiedDate":"2023-10-25"},{"lineNumber":249,"author":{"gitId":"Barbaracwx"},"content":" keyword","lastModifiedDate":"2023-10-25"},{"lineNumber":250,"author":{"gitId":"Barbaracwx"},"content":" in the inventory.\") and the list of found `StockEntry` objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":251,"author":{"gitId":"Barbaracwx"},"content":"6. `User Feedback:` The result is then displayed to the user, showing a list of drugs in the inventory that match the","lastModifiedDate":"2023-10-25"},{"lineNumber":252,"author":{"gitId":"Barbaracwx"},"content":" specified keyword.","lastModifiedDate":"2023-10-25"},{"lineNumber":253,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":254,"author":{"gitId":"Barbaracwx"},"content":"The following sequence diagram shows how the Find Command function works.","lastModifiedDate":"2023-10-25"},{"lineNumber":255,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":256,"author":{"gitId":"Barbaracwx"},"content":"\u003cimg src\u003d\"UML Diagrams/FindCommandDiagram.png\" width\u003d\"350\"\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":257,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":258,"author":{"gitId":"Barbaracwx"},"content":"Architecture Diagram of find command function:","lastModifiedDate":"2023-10-25"},{"lineNumber":259,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":260,"author":{"gitId":"Barbaracwx"},"content":"\u003cimg src\u003d\"UML Diagrams/FindCommandArchitectureDiagram.png\" width\u003d\"500\"\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":261,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":262,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":263,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":264,"author":{"gitId":"azfarulmatin"},"content":"## 2. ListCommand","lastModifiedDate":"2023-10-26"},{"lineNumber":265,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":266,"author":{"gitId":"Barbaracwx"},"content":"The `ListCommand` is responsible for listing all drugs in the inventory. This command retrieves the list of drugs from","lastModifiedDate":"2023-10-31"},{"lineNumber":267,"author":{"gitId":"Barbaracwx"},"content":"the inventory and provides it as part of the command result. If the inventory is empty, it informs the user that the","lastModifiedDate":"2023-10-31"},{"lineNumber":268,"author":{"gitId":"Barbaracwx"},"content":"inventory has no drugs.","lastModifiedDate":"2023-10-31"},{"lineNumber":269,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":270,"author":{"gitId":"azfarulmatin"},"content":"### Design Considerations","lastModifiedDate":"2023-10-26"},{"lineNumber":271,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":272,"author":{"gitId":"Barbaracwx"},"content":"- **User-Friendly Listing:** The primary goal of the `ListCommand` is to provide a user-friendly way to list all drugs","lastModifiedDate":"2023-10-31"},{"lineNumber":273,"author":{"gitId":"Barbaracwx"},"content":" in the inventory, enhancing the user\u0027s experience in accessing inventory information.","lastModifiedDate":"2023-10-31"},{"lineNumber":274,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":275,"author":{"gitId":"Barbaracwx"},"content":"- **Data Presentation:** The design considers how to present the list of drugs in a clear and organized manner to","lastModifiedDate":"2023-10-31"},{"lineNumber":276,"author":{"gitId":"Barbaracwx"},"content":" provide valuable information to the user.","lastModifiedDate":"2023-10-31"},{"lineNumber":277,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":278,"author":{"gitId":"Barbaracwx"},"content":"- **Performance:** The implementation should be optimized to list the inventory efficiently, even if it contains a large","lastModifiedDate":"2023-10-31"},{"lineNumber":279,"author":{"gitId":"Barbaracwx"},"content":" number of drugs.","lastModifiedDate":"2023-10-31"},{"lineNumber":280,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":281,"author":{"gitId":"azfarulmatin"},"content":"### Implementation","lastModifiedDate":"2023-10-26"},{"lineNumber":282,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":283,"author":{"gitId":"azfarulmatin"},"content":"The `ListCommand` is implemented as follows:","lastModifiedDate":"2023-10-26"},{"lineNumber":284,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":285,"author":{"gitId":"azfarulmatin"},"content":"- **Retrieving Drug List:** The command retrieves the list of drugs from the inventory using the `getAllDrugs` method.","lastModifiedDate":"2023-10-26"},{"lineNumber":286,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":287,"author":{"gitId":"Barbaracwx"},"content":"- **Handling Empty Inventory:** It checks if the list of drugs is empty. If the inventory is empty, it returns a","lastModifiedDate":"2023-10-31"},{"lineNumber":288,"author":{"gitId":"Barbaracwx"},"content":" user-friendly message indicating that the inventory is empty.","lastModifiedDate":"2023-10-31"},{"lineNumber":289,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":290,"author":{"gitId":"Barbaracwx"},"content":"- **Listing Drugs:** If the inventory contains drugs, the command constructs a success message and includes the list of","lastModifiedDate":"2023-10-31"},{"lineNumber":291,"author":{"gitId":"Barbaracwx"},"content":" drugs in the command result.","lastModifiedDate":"2023-10-31"},{"lineNumber":292,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":293,"author":{"gitId":"Barbaracwx"},"content":"- **User-Friendly Presentation:** The implementation ensures that the list of drugs is presented in a clear and","lastModifiedDate":"2023-10-31"},{"lineNumber":294,"author":{"gitId":"Barbaracwx"},"content":" organized format, including relevant details such as drug names, quantities, and other attributes.","lastModifiedDate":"2023-10-31"},{"lineNumber":295,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":296,"author":{"gitId":"Barbaracwx"},"content":"- **Optimized Performance:** To enhance user experience, the command is designed to list the inventory efficiently,","lastModifiedDate":"2023-10-31"},{"lineNumber":297,"author":{"gitId":"Barbaracwx"},"content":" ensuring that users receive search results quickly.","lastModifiedDate":"2023-10-31"},{"lineNumber":298,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":299,"author":{"gitId":"azfarulmatin"},"content":"### Function Methods","lastModifiedDate":"2023-10-26"},{"lineNumber":300,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":301,"author":{"gitId":"azfarulmatin"},"content":"The `ListCommand` includes the following method to achieve its functionality:","lastModifiedDate":"2023-10-26"},{"lineNumber":302,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":303,"author":{"gitId":"Barbaracwx"},"content":"- `execute()`: This method is responsible for executing the `ListCommand`, listing all drugs in the inventory. It checks","lastModifiedDate":"2023-10-31"},{"lineNumber":304,"author":{"gitId":"Barbaracwx"},"content":" the inventory, prepares a user-friendly result message, and returns a `CommandResult` containing the outcome of the","lastModifiedDate":"2023-10-31"},{"lineNumber":305,"author":{"gitId":"Barbaracwx"},"content":" command execution, which includes a success message and the list of found `Drug` objects.","lastModifiedDate":"2023-10-31"},{"lineNumber":306,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":307,"author":{"gitId":"azfarulmatin"},"content":"### Example Usage","lastModifiedDate":"2023-10-26"},{"lineNumber":308,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":309,"author":{"gitId":"azfarulmatin"},"content":"To illustrate how the `ListCommand` works, consider the following example usage:","lastModifiedDate":"2023-10-26"},{"lineNumber":310,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":311,"author":{"gitId":"azfarulmatin"},"content":"1. **User Input:** The user initiates the `ListCommand` by entering the following command:","lastModifiedDate":"2023-10-26"},{"lineNumber":312,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":313,"author":{"gitId":"azfarulmatin"},"content":"2. **Method Execution:** The `execute()` method within the \"ListCommand\" class is called.","lastModifiedDate":"2023-10-30"},{"lineNumber":314,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":315,"author":{"gitId":"azfarulmatin"},"content":"3. **Inventory Check:** The method checks the inventory to retrieve the list of drugs.","lastModifiedDate":"2023-10-30"},{"lineNumber":316,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":317,"author":{"gitId":"Barbaracwx"},"content":"4. **Result Building:** If the inventory contains drugs, the method constructs a success message (e.g., \"Listed all","lastModifiedDate":"2023-10-31"},{"lineNumber":318,"author":{"gitId":"Barbaracwx"},"content":" drugs in the inventory.\") and includes the list of drugs with relevant details.","lastModifiedDate":"2023-10-31"},{"lineNumber":319,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":320,"author":{"gitId":"azfarulmatin"},"content":"5. **User Feedback:** The result is displayed to the user, showing a clear and organized list of drugs in the inventory.","lastModifiedDate":"2023-10-30"},{"lineNumber":321,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":322,"author":{"gitId":"Barbaracwx"},"content":"The \"ListCommand\" enhances the user\u0027s ability to access inventory information efficiently and is designed to handle","lastModifiedDate":"2023-10-31"},{"lineNumber":323,"author":{"gitId":"Barbaracwx"},"content":"various inventory sizes while providing a user-friendly experience.","lastModifiedDate":"2023-10-31"},{"lineNumber":324,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":325,"author":{"gitId":"azfarulmatin"},"content":"The following sequence diagram shows how the Find Command function works.","lastModifiedDate":"2023-10-30"},{"lineNumber":326,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":327,"author":{"gitId":"azfarulmatin"},"content":"\u003cimg src\u003d\"UML Diagrams/ListCommandDiagram.png\" width\u003d\"350\"\u003e","lastModifiedDate":"2023-10-30"},{"lineNumber":328,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":329,"author":{"gitId":"azfarulmatin"},"content":"---","lastModifiedDate":"2023-10-26"},{"lineNumber":330,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":331,"author":{"gitId":"TeoHaoZhi"},"content":"## 3. Delete Command","lastModifiedDate":"2023-10-29"},{"lineNumber":332,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":333,"author":{"gitId":"karishma-t"},"content":"The \"Delete\" function is designed to enable users to remove specific drugs from the inventory based on the drug\u0027s name, ","lastModifiedDate":"2023-11-02"},{"lineNumber":334,"author":{"gitId":"karishma-t"},"content":"to remove drugs they no longer need, fully depleted or discontinued.","lastModifiedDate":"2023-11-02"},{"lineNumber":335,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":336,"author":{"gitId":"karishma-t"},"content":"**Design Considerations**","lastModifiedDate":"2023-10-26"},{"lineNumber":337,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":338,"author":{"gitId":"Barbaracwx"},"content":"1. **User-Specified Drug Name:** The function allows users to specify the drug name they want to delete from the","lastModifiedDate":"2023-10-31"},{"lineNumber":339,"author":{"gitId":"Barbaracwx"},"content":" inventory.","lastModifiedDate":"2023-10-31"},{"lineNumber":340,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":341,"author":{"gitId":"Barbaracwx"},"content":"2. **Data Integrity:** It ensures that the deletion operation maintains the integrity of the inventory data structure,","lastModifiedDate":"2023-10-31"},{"lineNumber":342,"author":{"gitId":"Barbaracwx"},"content":" updating it correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":343,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":344,"author":{"gitId":"karishma-t"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-10-26"},{"lineNumber":345,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":346,"author":{"gitId":"karishma-t"},"content":"This method is executed when the delete command is invoked. First, it attempts to delete a drug from the inventory ","lastModifiedDate":"2023-11-02"},{"lineNumber":347,"author":{"gitId":"karishma-t"},"content":"using the inventory.deleteDrug(this.keyToDelete) method. If successful, it retrieves the deleted entry.","lastModifiedDate":"2023-11-02"},{"lineNumber":348,"author":{"gitId":"karishma-t"},"content":"If the drug is successfully deleted, it returns a success message. ","lastModifiedDate":"2023-11-02"},{"lineNumber":349,"author":{"gitId":"karishma-t"},"content":"If the drug is not found (i.e., a DrugNotFoundException is thrown), it returns a failure message.","lastModifiedDate":"2023-11-02"},{"lineNumber":350,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":351,"author":{"gitId":"karishma-t"},"content":"---","lastModifiedDate":"2023-10-26"},{"lineNumber":352,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":353,"author":{"gitId":"TeoHaoZhi"},"content":"## 4. Help Command","lastModifiedDate":"2023-10-29"},{"lineNumber":354,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":355,"author":{"gitId":"TeoHaoZhi"},"content":"The command is responsible for showing users a list of all possible commands.","lastModifiedDate":"2023-10-29"},{"lineNumber":356,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":357,"author":{"gitId":"TeoHaoZhi"},"content":"**Design Considerations**","lastModifiedDate":"2023-10-29"},{"lineNumber":358,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":359,"author":{"gitId":"TeoHaoZhi"},"content":"The command was designed to print out and show how to use a list of all possible commands in a neat and concise way.","lastModifiedDate":"2023-10-29"},{"lineNumber":360,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":361,"author":{"gitId":"TeoHaoZhi"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-10-29"},{"lineNumber":362,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":363,"author":{"gitId":"TeoHaoZhi"},"content":"Command will use java\u0027s system out to print out all required information with a blank line in between for clarity.","lastModifiedDate":"2023-10-29"},{"lineNumber":364,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":365,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":366,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":367,"author":{"gitId":"TeoHaoZhi"},"content":"## 5. Save Command","lastModifiedDate":"2023-10-29"},{"lineNumber":368,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":369,"author":{"gitId":"TeoHaoZhi"},"content":"The save command was made as a means to backup user entered drug data into the hard drive of the computer to ensure","lastModifiedDate":"2023-10-29"},{"lineNumber":370,"author":{"gitId":"TeoHaoZhi"},"content":"previously entered data is saved and accessable whenever the app is launched.","lastModifiedDate":"2023-10-29"},{"lineNumber":371,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":372,"author":{"gitId":"TeoHaoZhi"},"content":"### Design Considerations","lastModifiedDate":"2023-10-29"},{"lineNumber":373,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":374,"author":{"gitId":"TeoHaoZhi"},"content":"The save command had to be implemented in a way to enable direct writing of files onto the hard drive and a function had","lastModifiedDate":"2023-10-29"},{"lineNumber":375,"author":{"gitId":"TeoHaoZhi"},"content":"to be made to load said file back into the drug inventory upon starting the application.","lastModifiedDate":"2023-10-29"},{"lineNumber":376,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":377,"author":{"gitId":"TeoHaoZhi"},"content":"### Implementation","lastModifiedDate":"2023-10-29"},{"lineNumber":378,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":379,"author":{"gitId":"TeoHaoZhi"},"content":"There is a method to access the drugs within the inventory class. a separate method from the inventory class would then","lastModifiedDate":"2023-10-29"},{"lineNumber":380,"author":{"gitId":"TeoHaoZhi"},"content":"write the contents of these drugs back to the txt file for saving.","lastModifiedDate":"2023-10-29"},{"lineNumber":381,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":382,"author":{"gitId":"TeoHaoZhi"},"content":"Upon booting up the system, a method from the inventory class goes through the contents of the txt file and copies it to","lastModifiedDate":"2023-10-29"},{"lineNumber":383,"author":{"gitId":"TeoHaoZhi"},"content":"the inventory drug list.","lastModifiedDate":"2023-10-29"},{"lineNumber":384,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":385,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":386,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":387,"author":{"gitId":"TeoHaoZhi"},"content":"## 6. addVendor Command","lastModifiedDate":"2023-10-29"},{"lineNumber":388,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":389,"author":{"gitId":"TeoHaoZhi"},"content":"The command was made to add vendors to a list of vendors so as to have access to it when needed.","lastModifiedDate":"2023-10-29"},{"lineNumber":390,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":391,"author":{"gitId":"TeoHaoZhi"},"content":"### Design Considerations","lastModifiedDate":"2023-10-29"},{"lineNumber":392,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":393,"author":{"gitId":"TeoHaoZhi"},"content":"The storage must be size adjustable based on the number of objects, in this case vendors placed into it.","lastModifiedDate":"2023-10-29"},{"lineNumber":394,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":395,"author":{"gitId":"TeoHaoZhi"},"content":"### Implementation","lastModifiedDate":"2023-10-29"},{"lineNumber":396,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":397,"author":{"gitId":"TeoHaoZhi"},"content":"In order to attain the adjustable storage based on numebr of objects, an ArrayList was used as additional vendors can be","lastModifiedDate":"2023-10-29"},{"lineNumber":398,"author":{"gitId":"TeoHaoZhi"},"content":"appended to the ArrayList whenever a new entry is required.","lastModifiedDate":"2023-10-29"},{"lineNumber":399,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":400,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":401,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":402,"author":{"gitId":"TeoHaoZhi"},"content":"## 7. listVendors Command","lastModifiedDate":"2023-10-29"},{"lineNumber":403,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":404,"author":{"gitId":"TeoHaoZhi"},"content":"The command was made to list all vendors being tracked by the system in a neat way to the user","lastModifiedDate":"2023-10-29"},{"lineNumber":405,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":406,"author":{"gitId":"TeoHaoZhi"},"content":"### Design Considerations","lastModifiedDate":"2023-10-29"},{"lineNumber":407,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":408,"author":{"gitId":"TeoHaoZhi"},"content":"The possibility of an empty list had to be considered","lastModifiedDate":"2023-10-29"},{"lineNumber":409,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":410,"author":{"gitId":"TeoHaoZhi"},"content":"### Implementation","lastModifiedDate":"2023-10-29"},{"lineNumber":411,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":412,"author":{"gitId":"TeoHaoZhi"},"content":"The list of vendors could be printed by using streams to efficiently collect and print out the information of vendors","lastModifiedDate":"2023-10-29"},{"lineNumber":413,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":414,"author":{"gitId":"TeoHaoZhi"},"content":"---","lastModifiedDate":"2023-10-29"},{"lineNumber":415,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":416,"author":{"gitId":"karishma-t"},"content":"## 7. addVendorSupply Command","lastModifiedDate":"2023-11-02"},{"lineNumber":417,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":418,"author":{"gitId":"karishma-t"},"content":"This method adds a drug to a vendor\u0027s supply list in the inventory management system, to track ","lastModifiedDate":"2023-11-02"},{"lineNumber":419,"author":{"gitId":"karishma-t"},"content":"what vendors supply what products. ","lastModifiedDate":"2023-11-02"},{"lineNumber":420,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":421,"author":{"gitId":"karishma-t"},"content":"### Design Considerations","lastModifiedDate":"2023-11-02"},{"lineNumber":422,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":423,"author":{"gitId":"karishma-t"},"content":"This method checks if the specified vendor exists and, if so, adds the drug to their supply list.","lastModifiedDate":"2023-11-02"},{"lineNumber":424,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":425,"author":{"gitId":"karishma-t"},"content":"### Implementation","lastModifiedDate":"2023-11-02"},{"lineNumber":426,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":427,"author":{"gitId":"karishma-t"},"content":"The execute method in the AddVendorSupplyCommand class checks if a specified vendor exists, adds a drug to their supply ","lastModifiedDate":"2023-11-02"},{"lineNumber":428,"author":{"gitId":"karishma-t"},"content":"list, and returns a success message. If the vendor is not found, it returns a message indicating that the vendor was ","lastModifiedDate":"2023-11-02"},{"lineNumber":429,"author":{"gitId":"karishma-t"},"content":"not found.","lastModifiedDate":"2023-11-02"},{"lineNumber":430,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":431,"author":{"gitId":"karishma-t"},"content":"---","lastModifiedDate":"2023-11-02"},{"lineNumber":432,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":433,"author":{"gitId":"azfarulmatin"},"content":"## 5. CommandResult Class","lastModifiedDate":"2023-11-01"},{"lineNumber":434,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":435,"author":{"gitId":"azfarulmatin"},"content":"The `CommandResult` class is a crucial part of the Stocker application, responsible for providing feedback and results to the user after executing various commands. It contains a feedback message to describe the outcome of the command execution, as well as an optional list of relevant elements produced by the command.","lastModifiedDate":"2023-11-01"},{"lineNumber":436,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":437,"author":{"gitId":"azfarulmatin"},"content":"**Design Considerations**","lastModifiedDate":"2023-11-01"},{"lineNumber":438,"author":{"gitId":"azfarulmatin"},"content":"The design of the `CommandResult` class considers the following aspects:","lastModifiedDate":"2023-11-01"},{"lineNumber":439,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":440,"author":{"gitId":"azfarulmatin"},"content":"1. **Feedback Message:** The class stores a feedback message to inform the user about the outcome of the executed command.","lastModifiedDate":"2023-11-01"},{"lineNumber":441,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":442,"author":{"gitId":"azfarulmatin"},"content":"2. **Relevant Elements:** For commands that produce a list of relevant elements, the `CommandResult` can store this list for display.","lastModifiedDate":"2023-11-01"},{"lineNumber":443,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":444,"author":{"gitId":"azfarulmatin"},"content":"**Implementation and Rationale**","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"azfarulmatin"},"content":"The `CommandResult` class is implemented with two constructors and methods to access relevant elements and construct feedback messages.","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"azfarulmatin"},"content":"- `CommandResult(String feedbackToUser)`: This constructor is used when there are no relevant elements to be included in the result. It sets the feedback message.","lastModifiedDate":"2023-11-01"},{"lineNumber":449,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"azfarulmatin"},"content":"- `CommandResult(String feedbackToUser, List\u003cT\u003e relevantElements)`: This constructor is used when the command produces a list of relevant elements (e.g., a list of drugs). It sets both the feedback message and the list of relevant elements.","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":452,"author":{"gitId":"azfarulmatin"},"content":"- `getRelevantElements()`: This method returns an optional list of relevant elements. It can be used to check if relevant elements are present.","lastModifiedDate":"2023-11-01"},{"lineNumber":453,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":454,"author":{"gitId":"azfarulmatin"},"content":"- `getFeedbackToUser()`: This method returns the feedback message as a string.","lastModifiedDate":"2023-11-01"},{"lineNumber":455,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":456,"author":{"gitId":"azfarulmatin"},"content":"- `getFeedbackToUserWithElements()`: This method constructs a feedback message that includes the relevant elements. It formats the list of elements with serial numbers (if applicable) and includes the feedback message.","lastModifiedDate":"2023-11-01"},{"lineNumber":457,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":458,"author":{"gitId":"azfarulmatin"},"content":"**Example Usage**","lastModifiedDate":"2023-11-01"},{"lineNumber":459,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":460,"author":{"gitId":"azfarulmatin"},"content":"The `CommandResult` class is used throughout the Stocker application to provide feedback to the user after executing commands. For example, when a user issues a `list` command, the `CommandResult` includes a list of drugs produced by the command along with the success message. The feedback message is then displayed to the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":461,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":462,"author":{"gitId":"azfarulmatin"},"content":"The following sequence diagram shows how the Command Result function works.","lastModifiedDate":"2023-11-01"},{"lineNumber":463,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":464,"author":{"gitId":"azfarulmatin"},"content":"\u003cimg src\u003d\"UML Diagrams/CommandResultDiagram.png\" width\u003d\"350\"\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":465,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":466,"author":{"gitId":"azfarulmatin"},"content":"---","lastModifiedDate":"2023-11-01"},{"lineNumber":467,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":468,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":469,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":470,"author":{"gitId":"Barbaracwx"},"content":"---","lastModifiedDate":"2023-10-25"},{"lineNumber":471,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":472,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":473,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":474,"author":{"gitId":"Barbaracwx"},"content":"- Works in the field of drug distribution, such as pharmacies and doctors\u0027 offices.","lastModifiedDate":"2023-10-25"},{"lineNumber":475,"author":{"gitId":"Barbaracwx"},"content":"- Manages a large inventory of pharmaceuticals with varying details (expiration dates, manufacturers, storage","lastModifiedDate":"2023-10-25"},{"lineNumber":476,"author":{"gitId":"Barbaracwx"},"content":" conditions).","lastModifiedDate":"2023-10-25"},{"lineNumber":477,"author":{"gitId":"Barbaracwx"},"content":"- Prefers desktop applications for their work.","lastModifiedDate":"2023-10-25"},{"lineNumber":478,"author":{"gitId":"Barbaracwx"},"content":"- Proficient in fast typing.","lastModifiedDate":"2023-10-25"},{"lineNumber":479,"author":{"gitId":"Barbaracwx"},"content":"- Favors typing over mouse interactions.","lastModifiedDate":"2023-10-25"},{"lineNumber":480,"author":{"gitId":"Barbaracwx"},"content":"- Comfortable using Command Line Interface (CLI) applications for efficiency.","lastModifiedDate":"2023-10-25"},{"lineNumber":481,"author":{"gitId":"Barbaracwx"},"content":"- Requires password-protected access to sensitive patient healthcare information.","lastModifiedDate":"2023-10-25"},{"lineNumber":482,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":483,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":484,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":485,"author":{"gitId":"Barbaracwx"},"content":"**Stocker** is designed to cater to the specific needs of drug distributors by offering the following benefits:","lastModifiedDate":"2023-10-25"},{"lineNumber":486,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":487,"author":{"gitId":"Barbaracwx"},"content":"1. Quick access to real-time inventory information.","lastModifiedDate":"2023-10-25"},{"lineNumber":488,"author":{"gitId":"Barbaracwx"},"content":"2. Efficient tracking of incoming stock.","lastModifiedDate":"2023-10-25"},{"lineNumber":489,"author":{"gitId":"Barbaracwx"},"content":"3. Categorization of drugs based on various labels.","lastModifiedDate":"2023-10-25"},{"lineNumber":490,"author":{"gitId":"Barbaracwx"},"content":"4. A prioritized list of urgently needed restocks for timely replenishment.","lastModifiedDate":"2023-10-25"},{"lineNumber":491,"author":{"gitId":"Barbaracwx"},"content":"5. Assistance in generating comprehensive reports for stock turnover analysis.","lastModifiedDate":"2023-10-25"},{"lineNumber":492,"author":{"gitId":"Barbaracwx"},"content":"6. Secure access through individual user accounts to safeguard patient healthcare data.","lastModifiedDate":"2023-10-25"},{"lineNumber":493,"author":{"gitId":"Barbaracwx"},"content":"7. Enhanced user experience for experienced professionals who prefer keyboard commands and CLI interactions for seamless","lastModifiedDate":"2023-10-25"},{"lineNumber":494,"author":{"gitId":"Barbaracwx"},"content":" stock management.","lastModifiedDate":"2023-10-25"},{"lineNumber":495,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":496,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":497,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":498,"author":{"gitId":"martinschnder"},"content":"Priorities: High (must have) - \\* \\* _, Medium (nice to have) - _ _, Low (unlikely to have) - _","lastModifiedDate":"2023-10-25"},{"lineNumber":499,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":500,"author":{"gitId":"Barbaracwx"},"content":"| Priority | Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2023-10-25"},{"lineNumber":501,"author":{"gitId":"Barbaracwx"},"content":"|----------|---------|----------------------|------------------------------------------------------|-------------------------------------------------------------|","lastModifiedDate":"2023-10-31"},{"lineNumber":502,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Pharmacist | Add drugs to track what drugs are available in stock | Reduce manual errors |","lastModifiedDate":"2023-10-25"},{"lineNumber":503,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Pharmacist | Remove drugs to track what are no longer in used | Ensure compliance |","lastModifiedDate":"2023-10-25"},{"lineNumber":504,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Receptionist | View a list of products of that category | Easily obtain an overview of the products |","lastModifiedDate":"2023-10-25"},{"lineNumber":505,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | First-time user | See a list of all available actions | Better understand how to use the application |","lastModifiedDate":"2023-10-25"},{"lineNumber":506,"author":{"gitId":"martinschnder"},"content":"| \\* \\* \\* | v1.0 | Inventory Manager | Find a specific drug currently in the system | Check up its details and quantities specifically |","lastModifiedDate":"2023-10-25"},{"lineNumber":507,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v2.0 | user | Find a to-do item by name | Locate a to-do without having to go through the entire list |","lastModifiedDate":"2023-10-30"},{"lineNumber":508,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v1.0 | user | Have a way to login to the system | Access the system only if i am allowed to |","lastModifiedDate":"2023-10-30"},{"lineNumber":509,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* | v2.0 | System Administrator | Perfrom regular backup of inventory database | Safeguard against data loss and system failure |","lastModifiedDate":"2023-10-30"},{"lineNumber":510,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v2.0 | Receptionist | Add vendors supplying drugs into the system | Keep track of what vendors i am working with |","lastModifiedDate":"2023-10-30"},{"lineNumber":511,"author":{"gitId":"TeoHaoZhi"},"content":"| \\* \\* \\* | v2.0 | Receptionist | View a list of vendors | Easily know who to contact if drugs need to be restocked |","lastModifiedDate":"2023-10-30"},{"lineNumber":512,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":513,"author":{"gitId":"martinschnder"},"content":"_(More to be added)_","lastModifiedDate":"2023-10-25"},{"lineNumber":514,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":515,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":516,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":517,"author":{"gitId":"Barbaracwx"},"content":"1. Should work on any mainstream OS as long as it has Java 11 or above installed.","lastModifiedDate":"2023-10-25"},{"lineNumber":518,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":519,"author":{"gitId":"Barbaracwx"},"content":"2. Should be able to hold up to 1000 drug entries without a noticeable sluggishness in performance for typical usage.","lastModifiedDate":"2023-10-25"},{"lineNumber":520,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":521,"author":{"gitId":"Barbaracwx"},"content":"3. A user with above-average typing speed for regular English text (i.e. not code, not system admin commands) should be","lastModifiedDate":"2023-10-25"},{"lineNumber":522,"author":{"gitId":"Barbaracwx"},"content":" able to accomplish most of the tasks faster using commands than using the mouse.","lastModifiedDate":"2023-10-25"},{"lineNumber":523,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":524,"author":{"gitId":"martinschnder"},"content":"_(More to be added)_","lastModifiedDate":"2023-10-25"},{"lineNumber":525,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":526,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":527,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":528,"author":{"gitId":"martinschnder"},"content":"- _glossary item_ - Definition","lastModifiedDate":"2023-10-25"},{"lineNumber":529,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":530,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":531,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":532,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"karishma-t":34,"martinschnder":40,"azfarulmatin":79,"TeoHaoZhi":120,"-":30,"Barbaracwx":229}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"# Stocker","lastModifiedDate":"2023-10-10"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker v1.o is a desktop app that will provide quick access to currently available stock,","lastModifiedDate":"2023-10-10"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"track incoming stock and expiration dates, and categorize drugs based on different labels.","lastModifiedDate":"2023-10-10"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"It is optimized for use via a Command Line Interface (CLI). If you can type fast, Stocker","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"can get your inventory management tasks done faster than traditional GUI apps.","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":8,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"TeoHaoZhi":5,"-":6}},{"path":"docs/UML Diagrams/ArchitectureDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"title Architecture Diagram","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"skinparam component {","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"BackgroundColor lightblue","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"[Parser]","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"[Commands]","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"[CommandResult]","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"[LoginSystem and Ui] as interactor","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"interface \"user\"","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"user -[hidden]- Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"CommandResult -[hidden]- Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"interactor --\u003e Parser : Makes sense of input","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"Parser -\u003e Commands : Searches for inputted command","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"Commands -\u003e CommandResult : Executes relevant command","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"CommandResult -\u003e interactor : Return control","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"user -[#red]-\u003e interactor : Logs in or Register","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"TeoHaoZhi":25}},{"path":"docs/UML Diagrams/CommandResultDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"title CommandResult Sequence Diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"actor User","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"participant Command","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"participant CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":"User -\u003e Command: Execute Command","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"activate Command","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":"Command -\u003e CommandResult: Create CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"azfarulmatin"},"content":"activate CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":"CommandResult --\u003e Command: Return CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":"deactivate CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":"Command -\u003e User: Return CommandResult","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":"deactivate Command","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"azfarulmatin":20}},{"path":"docs/UML Diagrams/FindCommandArchitectureDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"@startuml FindCommandArchitectureDiagram","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"!define LOGIC_COLOR #3333C4","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"!define ARROW_STYLE [-[#LOGIC_COLOR]-\u003e]","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"actor User as U","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"package \"Your Application\" {","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":" [User Interface] as UI","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" [FindCommand] as FindCmd","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":" [Inventory] as Inv","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":" [StockEntry] as Entry","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" [CommandResult] as CmdResult","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"U -down-\u003e UI: Initiates \u0027Find\u0027 Command","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"UI -down-\u003e FindCmd: Invokes \u0027FindCommand\u0027","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"UI -down-\u003e Inv: Accesses \u0027Inventory\u0027","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"FindCmd -down-\u003e Entry: Iterates Through Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"Entry -down-\u003e Entry: Checks Each Entry","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"Entry --\u003e FindCmd: Match/No Match","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":"FindCmd --\u003e CmdResult: Prepares Result","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":"CmdResult -up-\u003e UI: Returns Result","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":"CmdResult -up-\u003e U: Displays Search Results","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"Barbaracwx":26}},{"path":"docs/UML Diagrams/FindCommandDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"@startuml FindCommandDiagram","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"!define LOGIC_COLOR #3333C4","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"!define LOGIC_COLOR_T1 #7777DB","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"hide footbox","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"actor User","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"participant \"FindCommand\" as FindCmd LOGIC_COLOR_T1","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"participant \"Inventory\" as Inventory LOGIC_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"User -\u003e FindCmd: Execute \u0027Find\u0027 Command","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"activate FindCmd","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"User \u003c-- FindCmd: CommandResult","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"FindCmd -\u003e Inventory: Retrieve Stock Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"activate Inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"Inventory --\u003e FindCmd: List of Stock Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"FindCmd -\u003e FindCmd: Process Entries","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"FindCmd --\u003e User: Display Search Results","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"Barbaracwx":22}},{"path":"docs/UML Diagrams/ListCommandDiagram.uml.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"@startuml ListCommandDiagram","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"!define LOGIC_COLOR #3333C4","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"!define LOGIC_COLOR_T1 #7777DB","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"hide footbox","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"azfarulmatin"},"content":"actor User","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":"participant \"ListCommand\" as ListCmd LOGIC_COLOR_T1","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"participant \"Inventory\" as Inventory LOGIC_COLOR","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":"User -\u003e ListCmd: Execute \u0027List\u0027 Command","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"azfarulmatin"},"content":"activate ListCmd","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":"User \u003c-- ListCmd: CommandResult","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":"ListCmd -\u003e Inventory: Retrieve Stock Entries","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":"activate Inventory","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":"Inventory --\u003e ListCmd: List of Stock Entries","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":"ListCmd -\u003e ListCmd: Process Entries","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":"ListCmd --\u003e User: Display List Results","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"@enduml","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"azfarulmatin":21}},{"path":"docs/UML Diagrams/ParserDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"@startuml","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"hide footbox","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"actor User","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"participant \"User Input\" as UserInput","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"participant \"Parser\" as Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"participant \"IncorrectCommand\" as IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"User -\u003e UserInput: Enter command","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"UserInput -\u003e Parser: parseCommand(userInput)","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"activate Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e Parser: Split the input into command and arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"alt Command found","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e Parser: commandWord \u003d Extract command word","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e Parser: arguments \u003d Extract arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"else Command not found","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e IncorrectCommand: Create IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"Parser --\u003e Parser: return IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"end","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"Parser -\u003e IncorrectCommand: Create IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"Parser --\u003e Parser: return IncorrectCommand","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"deactivate Parser","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"@enduml","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"Barbaracwx":21}},{"path":"docs/UML Diagrams/StockerToLoginSystem.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"@startuml","lastModifiedDate":"2023-10-21"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-21"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"hide footbox","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"actor User","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"Participant \":Stocker\" as Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"Participant \":Ui\" as Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"Participant \":LoginSystem\" as LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"User -\u003e Stocker : Stocker()","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"activate Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e Stocker : run()","lastModifiedDate":"2023-10-21"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"activate Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e Stocker :start()","lastModifiedDate":"2023-10-21"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e Ui : Ui()","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate Stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"activate Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"Ui -\u003e Ui : showLoginMessage()","lastModifiedDate":"2023-10-21"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"activate Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"Ui -\u003e Ui : ShowToUser()","lastModifiedDate":"2023-10-21"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate Ui","lastModifiedDate":"2023-10-21"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"Ui --\u003e User : LoginMessage","lastModifiedDate":"2023-10-21"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker -\u003e LoginSystem :LoginSystem()","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"activate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem : run()","lastModifiedDate":"2023-10-21"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"activate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem : loadExistingUsers()","lastModifiedDate":"2023-10-21"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem: authenticateUserChoice()","lastModifiedDate":"2023-10-21"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":"User -\u003e LoginSystem : register or login input","lastModifiedDate":"2023-10-21"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":"alt Register","lastModifiedDate":"2023-10-21"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003e LoginSystem : newUserCreator()","lastModifiedDate":"2023-10-21"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem --\u003e User : showSuccessfulRegistrationMessage()","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":"else Login","lastModifiedDate":"2023-10-21"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem -\u003eLoginSystem : loginExistingUser()","lastModifiedDate":"2023-10-21"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":"LoginSystem --\u003e User: showSuccessfulLoginMessage()","lastModifiedDate":"2023-10-21"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"end","lastModifiedDate":"2023-10-21"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"deactivate LoginSystem","lastModifiedDate":"2023-10-21"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":"@enduml","lastModifiedDate":"2023-10-21"}],"authorContributionMap":{"TeoHaoZhi":47}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# User Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"## Table of contents","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"- [Introduction](#introduction)","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"- [Quick Start](#quick-start)","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"- [Features](#features)","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"- [Usage](#usage)","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"- [FAQ](#faq)","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"- [Command Summary](#command-summary)","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"Stocker is a desktop app that will provide quick access to currently available stock,","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"track incoming stock and expiration dates, and categorize drugs based on different labels.","lastModifiedDate":"2023-10-10"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"It is optimized for use via a Command Line Interface (CLI). If you can type fast, Stocker","lastModifiedDate":"2023-10-10"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"can get your inventory management tasks done faster than traditional GUI apps.","lastModifiedDate":"2023-10-10"},{"lineNumber":17,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":20,"author":{"gitId":"-"},"content":"{Give steps to get started quickly}","lastModifiedDate":"2020-05-24"},{"lineNumber":21,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":22,"author":{"gitId":"-"},"content":"1. Ensure that you have Java 11 or above installed.","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"2. Down the latest version of `Stocker` from [here](https://github.com/AY2324S1-CS2113-T17-3/tp/releases).","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"3. Copy the absolute filepath to where the jar file is","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"4. Run the following JAR file with the following command","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"java -jar \"\u003cFile path of jar file\u003e\"","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"-"},"content":"## Features","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-Login System","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":"Authentication system that allows user to register as a user or login","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":"as an existing user.","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-add","lastModifiedDate":"2023-10-10"},{"lineNumber":38,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a drug into the inventory list.","lastModifiedDate":"2023-10-10"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-delete","lastModifiedDate":"2023-10-10"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":"Deletes a drug being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-list","lastModifiedDate":"2023-10-10"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":"List all drug information that is being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-find","lastModifiedDate":"2023-10-10"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":"Finds drugs using their name or expiry date.","lastModifiedDate":"2023-10-20"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-help","lastModifiedDate":"2023-10-10"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":"List all currently available commands in current version, their","lastModifiedDate":"2023-10-10"},{"lineNumber":56,"author":{"gitId":"TeoHaoZhi"},"content":"uses and how to format them in the command line.","lastModifiedDate":"2023-10-10"},{"lineNumber":57,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":58,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-register","lastModifiedDate":"2023-10-20"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":60,"author":{"gitId":"TeoHaoZhi"},"content":"Register a new user into the login system.","lastModifiedDate":"2023-10-20"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-login","lastModifiedDate":"2023-10-20"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":"Login an existing user into the system.","lastModifiedDate":"2023-10-20"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-save","lastModifiedDate":"2023-10-21"},{"lineNumber":67,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":"Save existing drugs from inventory list onto a txt file.","lastModifiedDate":"2023-10-21"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":"File is then used to update inventory list when stocker is ran.","lastModifiedDate":"2023-10-21"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-add vendor","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a vendor into a list to be tracked by the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":"### Feature-list vendors","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":"Displays the name of all vendors being tracked by the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"karishma-t"},"content":"### Feature-add vendor supply","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"karishma-t"},"content":"Adds a drug into a vendor\u0027s supply list to be tracked by the system. ","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"karishma-t"},"content":"### Feature-list vendor supply","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"karishma-t"},"content":"Displays the list of all drugs being supplied by a particular vendor. ","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"karishma-t"},"content":"### Feature-find vendor supply","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"karishma-t"},"content":"Displays the list of all vendors that supply a particular drug. ","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"martinschnder"},"content":"### Feature-add to cart","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"martinschnder"},"content":"Adds a drug to the current cart if the requested quantity is available in the inventory.","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"martinschnder"},"content":"### Feature-view cart","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"karishma-t"},"content":"List all added drugs in the current cart.","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"martinschnder"},"content":"### Feature-checkout","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"martinschnder"},"content":"Empty the current cart and retrieve the specified items and quantity from the inventory.","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"karishma-t"},"content":"### Feature-add description","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"karishma-t"},"content":"Adds a drug\u0027s description into a list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"karishma-t"},"content":"### Feature-get description","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"karishma-t"},"content":"Retrieves the description of a particular drug. ","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"karishma-t"},"content":"### Feature-list description","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"karishma-t"},"content":"Displays a list of all the descriptions for all corresponding drugs","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":"## Usage","lastModifiedDate":"2023-10-10"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":116,"author":{"gitId":"TeoHaoZhi"},"content":"### `Login System`- Create new user or login existing user","lastModifiedDate":"2023-10-15"},{"lineNumber":117,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":118,"author":{"gitId":"TeoHaoZhi"},"content":"Login system is automatically launched at the start of the programme.","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":120,"author":{"gitId":"TeoHaoZhi"},"content":"**Registering a user**","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":122,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 1 : Enter register to select option to register a user.","lastModifiedDate":"2023-10-20"},{"lineNumber":123,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e ","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e `register`","lastModifiedDate":"2023-11-04"},{"lineNumber":125,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 2: Enter desired username and password.","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-10-15"},{"lineNumber":128,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Upon successful creation, registration success message is observed","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"TeoHaoZhi"},"content":"Registration successful.","lastModifiedDate":"2023-10-15"},{"lineNumber":134,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"TeoHaoZhi"},"content":"**Login an existing user**","lastModifiedDate":"2023-10-15"},{"lineNumber":137,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":138,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 1 : Enter login to select option to login a user.","lastModifiedDate":"2023-10-20"},{"lineNumber":139,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-10-15"},{"lineNumber":140,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e `login`","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e ","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Step 2: Enter registered username and password.","lastModifiedDate":"2023-10-15"},{"lineNumber":143,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e","lastModifiedDate":"2023-10-15"},{"lineNumber":144,"author":{"gitId":"TeoHaoZhi"},"content":"\u003e Upon successful creation, successful login message is observed.","lastModifiedDate":"2023-10-15"},{"lineNumber":145,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":146,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-15"},{"lineNumber":147,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":148,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":149,"author":{"gitId":"TeoHaoZhi"},"content":"Login Successful.","lastModifiedDate":"2023-10-15"},{"lineNumber":150,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-15"},{"lineNumber":151,"author":{"gitId":"TeoHaoZhi"},"content":"Note","lastModifiedDate":"2023-11-04"},{"lineNumber":152,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":153,"author":{"gitId":"TeoHaoZhi"},"content":"### `add` - Adds drug into inventory list","lastModifiedDate":"2023-10-10"},{"lineNumber":154,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":155,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a drug to be tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":156,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":157,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":158,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":159,"author":{"gitId":"TeoHaoZhi"},"content":"add /n DRUG_NAME /d EXPIRY_DATE /s SERIAL_NUMBER /q QUANTITY","lastModifiedDate":"2023-11-04"},{"lineNumber":160,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":161,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":162,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":163,"author":{"gitId":"TeoHaoZhi"},"content":"`add /n Panadol /d 12 June 2026 /s ABC123 /q 52","lastModifiedDate":"2023-11-04"},{"lineNumber":164,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":165,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":166,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":167,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":168,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":169,"author":{"gitId":"Barbaracwx"},"content":"|| New drug added in the inventory: Panadol","lastModifiedDate":"2023-10-29"},{"lineNumber":170,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":171,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"TeoHaoZhi"},"content":"### `delete` - Deletes a drug being tracked by the system","lastModifiedDate":"2023-10-10"},{"lineNumber":173,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":174,"author":{"gitId":"TeoHaoZhi"},"content":"Deletes a drug being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":175,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":176,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":177,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":178,"author":{"gitId":"TeoHaoZhi"},"content":"delete /n DRUG_NAM","lastModifiedDate":"2023-10-10"},{"lineNumber":179,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":180,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":181,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":182,"author":{"gitId":"TeoHaoZhi"},"content":"`delete /n Panadol","lastModifiedDate":"2023-10-10"},{"lineNumber":183,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":184,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":185,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":186,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":187,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":188,"author":{"gitId":"Barbaracwx"},"content":"|| removed : Panadol","lastModifiedDate":"2023-10-29"},{"lineNumber":189,"author":{"gitId":"Barbaracwx"},"content":"|| There are now 0 drugs in the system","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":191,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":192,"author":{"gitId":"TeoHaoZhi"},"content":"### `list` - List all drug information that is being tracked by the system","lastModifiedDate":"2023-10-10"},{"lineNumber":193,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":194,"author":{"gitId":"TeoHaoZhi"},"content":"List all drug information that is being tracked by the system.","lastModifiedDate":"2023-10-10"},{"lineNumber":195,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":196,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":197,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":198,"author":{"gitId":"TeoHaoZhi"},"content":"list","lastModifiedDate":"2023-10-10"},{"lineNumber":199,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":200,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":201,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":202,"author":{"gitId":"TeoHaoZhi"},"content":"`list","lastModifiedDate":"2023-10-10"},{"lineNumber":203,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":204,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":205,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":206,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":207,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":208,"author":{"gitId":"TeoHaoZhi"},"content":"|| 1. Name: Panadol, Expiry Date: 12 June 2026/ Quantity: 300","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"Barbaracwx"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"Barbaracwx"},"content":"|| Listed all drugs in the inventory.","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"Barbaracwx"},"content":"### `stocklevel` - List all drugs by quantity level in ascending order","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"Barbaracwx"},"content":"List all drugs by quantity level in ascending order.","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"Barbaracwx"},"content":"stocklevel","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"Barbaracwx"},"content":"`stocklevel","lastModifiedDate":"2023-10-29"},{"lineNumber":224,"author":{"gitId":"Barbaracwx"},"content":"`","lastModifiedDate":"2023-10-29"},{"lineNumber":225,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":228,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":229,"author":{"gitId":"Barbaracwx"},"content":"|| \t1. Name: histamine, Expiry date: 101010, Quantity: 10","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"Barbaracwx"},"content":"|| \t2. Name: paracetamol, Expiry date: 101010, Quantity: 50","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"Barbaracwx"},"content":"|| \t3. Name: panadol, Expiry date: 101010, Quantity: 120","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"Barbaracwx"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":233,"author":{"gitId":"Barbaracwx"},"content":"|| Stock Level Report (Sorted by Quantity)","lastModifiedDate":"2023-10-29"},{"lineNumber":234,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"Barbaracwx"},"content":"### `find` - Finds drugs using their name or expiry date","lastModifiedDate":"2023-10-20"},{"lineNumber":237,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":238,"author":{"gitId":"Barbaracwx"},"content":"1. Finds drugs whose **names** contain any of the given keywords.","lastModifiedDate":"2023-10-20"},{"lineNumber":239,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":240,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":241,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":242,"author":{"gitId":"Barbaracwx"},"content":"find /n panadol","lastModifiedDate":"2023-10-20"},{"lineNumber":243,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":244,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-10"},{"lineNumber":245,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":246,"author":{"gitId":"martinschnder"},"content":"`find /n KEYWORD `","lastModifiedDate":"2023-10-31"},{"lineNumber":247,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"Barbaracwx"},"content":"- The search is case-insensitive, meaning that \"aspirin\" will match \"Aspirin.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":249,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":250,"author":{"gitId":"Barbaracwx"},"content":"- The order of the keywords does not matter. For example, \"Painkiller Relief\" will match \"Relief Painkiller.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":251,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":252,"author":{"gitId":"Barbaracwx"},"content":"- Only the drug name is searched.","lastModifiedDate":"2023-10-20"},{"lineNumber":253,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":254,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-10-20"},{"lineNumber":255,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":256,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":257,"author":{"gitId":"Barbaracwx"},"content":"|| 1. Name: panadol, Expiry Date: 12 sep, Quantity: 120","lastModifiedDate":"2023-10-29"},{"lineNumber":258,"author":{"gitId":"Barbaracwx"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":259,"author":{"gitId":"Barbaracwx"},"content":"|| Listed all drugs with the keyword in the inventory.","lastModifiedDate":"2023-10-29"},{"lineNumber":260,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":261,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"Barbaracwx"},"content":"2. Finds drugs whose **expiry dates** contain any of the given keywords.","lastModifiedDate":"2023-10-20"},{"lineNumber":263,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":264,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-10-20"},{"lineNumber":265,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":266,"author":{"gitId":"Barbaracwx"},"content":"find /d sep","lastModifiedDate":"2023-10-20"},{"lineNumber":267,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":268,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-10-20"},{"lineNumber":269,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":270,"author":{"gitId":"martinschnder"},"content":"`find /d KEYWORD`","lastModifiedDate":"2023-10-31"},{"lineNumber":271,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":272,"author":{"gitId":"Barbaracwx"},"content":"- Only the drug\u0027s expiry date is searched.","lastModifiedDate":"2023-10-20"},{"lineNumber":273,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":274,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-10"},{"lineNumber":275,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":276,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":277,"author":{"gitId":"Barbaracwx"},"content":"1. Name: panadol, Expiry Date: 12 sep, Quantity: 120","lastModifiedDate":"2023-10-20"},{"lineNumber":278,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":279,"author":{"gitId":"Barbaracwx"},"content":"Listed all drugs with the keyword in the inventory.","lastModifiedDate":"2023-10-20"},{"lineNumber":280,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-10"},{"lineNumber":281,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":282,"author":{"gitId":"TeoHaoZhi"},"content":"### `help` - List currently available commands in current version, their uses and how to format them in the command line","lastModifiedDate":"2023-10-10"},{"lineNumber":283,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":284,"author":{"gitId":"TeoHaoZhi"},"content":"List all currently available commands in current version,","lastModifiedDate":"2023-10-10"},{"lineNumber":285,"author":{"gitId":"TeoHaoZhi"},"content":"their uses and how to format them in the command line","lastModifiedDate":"2023-10-10"},{"lineNumber":286,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":287,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-10"},{"lineNumber":288,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":289,"author":{"gitId":"TeoHaoZhi"},"content":"help","lastModifiedDate":"2023-10-10"},{"lineNumber":290,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":291,"author":{"gitId":"-"},"content":"Example of usage:","lastModifiedDate":"2020-05-24"},{"lineNumber":292,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":293,"author":{"gitId":"TeoHaoZhi"},"content":"`help","lastModifiedDate":"2023-10-10"},{"lineNumber":294,"author":{"gitId":"TeoHaoZhi"},"content":"`","lastModifiedDate":"2023-10-10"},{"lineNumber":295,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":296,"author":{"gitId":"TeoHaoZhi"},"content":"### `register` - Register a new user into the system","lastModifiedDate":"2023-10-20"},{"lineNumber":297,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":298,"author":{"gitId":"TeoHaoZhi"},"content":"Asks for user input for a username and password field which","lastModifiedDate":"2023-10-20"},{"lineNumber":299,"author":{"gitId":"TeoHaoZhi"},"content":"will be used to create a new user for the system.","lastModifiedDate":"2023-10-20"},{"lineNumber":300,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":301,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-20"},{"lineNumber":302,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":303,"author":{"gitId":"TeoHaoZhi"},"content":"register","lastModifiedDate":"2023-10-20"},{"lineNumber":304,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":305,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-20"},{"lineNumber":306,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":307,"author":{"gitId":"TeoHaoZhi"},"content":"`register`","lastModifiedDate":"2023-10-20"},{"lineNumber":308,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":309,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-20"},{"lineNumber":310,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":311,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":312,"author":{"gitId":"TeoHaoZhi"},"content":"Registration Successful.","lastModifiedDate":"2023-10-20"},{"lineNumber":313,"author":{"gitId":"TeoHaoZhi"},"content":"New User Created.","lastModifiedDate":"2023-10-20"},{"lineNumber":314,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":315,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":316,"author":{"gitId":"TeoHaoZhi"},"content":"### `login` - login an existing user into the system","lastModifiedDate":"2023-10-20"},{"lineNumber":317,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":318,"author":{"gitId":"TeoHaoZhi"},"content":"Asks for user input for a username and password field which","lastModifiedDate":"2023-10-20"},{"lineNumber":319,"author":{"gitId":"TeoHaoZhi"},"content":"will be used to check if such a user exists for the system","lastModifiedDate":"2023-10-20"},{"lineNumber":320,"author":{"gitId":"TeoHaoZhi"},"content":"and log the user in.","lastModifiedDate":"2023-10-20"},{"lineNumber":321,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":322,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-20"},{"lineNumber":323,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":324,"author":{"gitId":"TeoHaoZhi"},"content":"login","lastModifiedDate":"2023-10-20"},{"lineNumber":325,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":326,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-20"},{"lineNumber":327,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":328,"author":{"gitId":"TeoHaoZhi"},"content":"`login`","lastModifiedDate":"2023-10-20"},{"lineNumber":329,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":330,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-20"},{"lineNumber":331,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":332,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":333,"author":{"gitId":"TeoHaoZhi"},"content":"Login Sucessful","lastModifiedDate":"2023-10-20"},{"lineNumber":334,"author":{"gitId":"TeoHaoZhi"},"content":"Welcome Back!","lastModifiedDate":"2023-10-20"},{"lineNumber":335,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-20"},{"lineNumber":336,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":337,"author":{"gitId":"TeoHaoZhi"},"content":"### `save` - save existing drugs onto hard drive of computer","lastModifiedDate":"2023-10-21"},{"lineNumber":338,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":339,"author":{"gitId":"TeoHaoZhi"},"content":"Saves existing drugs onto hard drive of computer. The txt file","lastModifiedDate":"2023-10-21"},{"lineNumber":340,"author":{"gitId":"TeoHaoZhi"},"content":"is then used as reference to update drug inventory when stocker","lastModifiedDate":"2023-10-21"},{"lineNumber":341,"author":{"gitId":"TeoHaoZhi"},"content":"is booted up.","lastModifiedDate":"2023-10-21"},{"lineNumber":342,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":343,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-21"},{"lineNumber":344,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":345,"author":{"gitId":"TeoHaoZhi"},"content":"save","lastModifiedDate":"2023-10-21"},{"lineNumber":346,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":347,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-21"},{"lineNumber":348,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":349,"author":{"gitId":"TeoHaoZhi"},"content":"`save`","lastModifiedDate":"2023-10-21"},{"lineNumber":350,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":351,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-21"},{"lineNumber":352,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":353,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-21"},{"lineNumber":354,"author":{"gitId":"TeoHaoZhi"},"content":"Drugs successfully saved.","lastModifiedDate":"2023-10-21"},{"lineNumber":355,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-21"},{"lineNumber":356,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":357,"author":{"gitId":"TeoHaoZhi"},"content":"### `addVendor` - adds a vendor into list of vendors being tracked by system","lastModifiedDate":"2023-10-29"},{"lineNumber":358,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":359,"author":{"gitId":"TeoHaoZhi"},"content":"Adds a vendor to be tracked by the system. The enteries are used to form a list of summarised vendors.","lastModifiedDate":"2023-10-29"},{"lineNumber":360,"author":{"gitId":"TeoHaoZhi"},"content":"is booted up.","lastModifiedDate":"2023-10-29"},{"lineNumber":361,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":362,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-29"},{"lineNumber":363,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":364,"author":{"gitId":"TeoHaoZhi"},"content":"addVendor DRUGNAME","lastModifiedDate":"2023-10-29"},{"lineNumber":365,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":366,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-29"},{"lineNumber":367,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":368,"author":{"gitId":"TeoHaoZhi"},"content":"`addVendor Moderna`","lastModifiedDate":"2023-10-29"},{"lineNumber":369,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":370,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-29"},{"lineNumber":371,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":372,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":373,"author":{"gitId":"TeoHaoZhi"},"content":"New vendor added into the vendors list: Moderna","lastModifiedDate":"2023-10-29"},{"lineNumber":374,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":375,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":376,"author":{"gitId":"TeoHaoZhi"},"content":"### `listVendors` - list all vendors currently being tracked by the system","lastModifiedDate":"2023-10-29"},{"lineNumber":377,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":378,"author":{"gitId":"TeoHaoZhi"},"content":"Displays a list of all vendors currently being tracked by the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":379,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":380,"author":{"gitId":"TeoHaoZhi"},"content":"Format:","lastModifiedDate":"2023-10-29"},{"lineNumber":381,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":382,"author":{"gitId":"TeoHaoZhi"},"content":"listVendors","lastModifiedDate":"2023-10-29"},{"lineNumber":383,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":384,"author":{"gitId":"TeoHaoZhi"},"content":"Example of usage:","lastModifiedDate":"2023-10-29"},{"lineNumber":385,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":386,"author":{"gitId":"TeoHaoZhi"},"content":"`listVendors`","lastModifiedDate":"2023-10-29"},{"lineNumber":387,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":388,"author":{"gitId":"TeoHaoZhi"},"content":"Expected outcome:","lastModifiedDate":"2023-10-29"},{"lineNumber":389,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":390,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":391,"author":{"gitId":"TeoHaoZhi"},"content":"|| 1. Name : Moderna","lastModifiedDate":"2023-10-29"},{"lineNumber":392,"author":{"gitId":"TeoHaoZhi"},"content":"||","lastModifiedDate":"2023-10-29"},{"lineNumber":393,"author":{"gitId":"TeoHaoZhi"},"content":"||Listed all vendors in the list.","lastModifiedDate":"2023-10-29"},{"lineNumber":394,"author":{"gitId":"TeoHaoZhi"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":395,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":396,"author":{"gitId":"karishma-t"},"content":"### `addVendorSupply` - Adds a drug into a vendor\u0027s supply list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":397,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":398,"author":{"gitId":"karishma-t"},"content":"Adds a drug into a vendor\u0027s supply list to be tracked by the system, and vendor must already be added into the system. ","lastModifiedDate":"2023-11-01"},{"lineNumber":399,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":400,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":401,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":402,"author":{"gitId":"karishma-t"},"content":"addVendorSupply VENDOR_NAME DRUG_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":403,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":404,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":405,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":406,"author":{"gitId":"karishma-t"},"content":"`addVendorSupply Moderna Paracetamol`","lastModifiedDate":"2023-11-01"},{"lineNumber":407,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":408,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":409,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":410,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":411,"author":{"gitId":"karishma-t"},"content":"|| New drug added to moderna\u0027s supply list: paracetamol","lastModifiedDate":"2023-11-01"},{"lineNumber":412,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":413,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":414,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":415,"author":{"gitId":"karishma-t"},"content":"### `listVendorSupply` - Displays the list of all drugs being supplied by a particular vendor.","lastModifiedDate":"2023-11-01"},{"lineNumber":416,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":417,"author":{"gitId":"karishma-t"},"content":"Displays the list of all drugs being supplied by a particular vendor.","lastModifiedDate":"2023-11-01"},{"lineNumber":418,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":419,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":420,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":421,"author":{"gitId":"karishma-t"},"content":"listVendorSupply VENDOR_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":422,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":423,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":424,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":425,"author":{"gitId":"karishma-t"},"content":"`listVendorSupply Moderna`","lastModifiedDate":"2023-11-01"},{"lineNumber":426,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":427,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":428,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":429,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":430,"author":{"gitId":"karishma-t"},"content":"|| Drugs supplied by Moderna: paracetamol, panadol","lastModifiedDate":"2023-11-01"},{"lineNumber":431,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":432,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":433,"author":{"gitId":"karishma-t"},"content":"### `findVendorSupply` -Displays the list of all vendors that supply a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":434,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":435,"author":{"gitId":"karishma-t"},"content":"Displays the list of all vendors that supply a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":436,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":437,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":438,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":439,"author":{"gitId":"karishma-t"},"content":"findVendorSupply DRUG_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":440,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":441,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":442,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":443,"author":{"gitId":"karishma-t"},"content":"`findVendorSupply paracetamol`","lastModifiedDate":"2023-11-01"},{"lineNumber":444,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"karishma-t"},"content":"|| Vendors supplying the drug paracetamol: moderna, apotheca","lastModifiedDate":"2023-11-01"},{"lineNumber":449,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"martinschnder"},"content":"### `addtocart` - Adds drug into current cart","lastModifiedDate":"2023-10-31"},{"lineNumber":452,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":453,"author":{"gitId":"martinschnder"},"content":"Adds a drug in a specified quantity in the current cart.","lastModifiedDate":"2023-10-31"},{"lineNumber":454,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":455,"author":{"gitId":"martinschnder"},"content":"Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":456,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":457,"author":{"gitId":"martinschnder"},"content":"addtocart /n DRUG_NAME /q QUANTITY","lastModifiedDate":"2023-10-31"},{"lineNumber":458,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":459,"author":{"gitId":"martinschnder"},"content":"Example of usage:","lastModifiedDate":"2023-10-31"},{"lineNumber":460,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":461,"author":{"gitId":"martinschnder"},"content":"`addtocart /n Panadol /q 3","lastModifiedDate":"2023-10-31"},{"lineNumber":462,"author":{"gitId":"martinschnder"},"content":"`","lastModifiedDate":"2023-10-31"},{"lineNumber":463,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":464,"author":{"gitId":"martinschnder"},"content":"Expected outcome:","lastModifiedDate":"2023-10-31"},{"lineNumber":465,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":466,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":467,"author":{"gitId":"martinschnder"},"content":"|| New drug added in the cart : Panadol","lastModifiedDate":"2023-10-31"},{"lineNumber":468,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":469,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":470,"author":{"gitId":"martinschnder"},"content":"### `viewcart` - Lists all the entries in the cart","lastModifiedDate":"2023-10-31"},{"lineNumber":471,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":472,"author":{"gitId":"martinschnder"},"content":"Lists all the added drugs and quantity in the cart.","lastModifiedDate":"2023-10-31"},{"lineNumber":473,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":474,"author":{"gitId":"martinschnder"},"content":"Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":475,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":476,"author":{"gitId":"martinschnder"},"content":"viewcart","lastModifiedDate":"2023-10-31"},{"lineNumber":477,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":478,"author":{"gitId":"martinschnder"},"content":"Example of usage:","lastModifiedDate":"2023-10-31"},{"lineNumber":479,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":480,"author":{"gitId":"martinschnder"},"content":"`viewcart","lastModifiedDate":"2023-10-31"},{"lineNumber":481,"author":{"gitId":"martinschnder"},"content":"`","lastModifiedDate":"2023-10-31"},{"lineNumber":482,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":483,"author":{"gitId":"martinschnder"},"content":"Expected outcome:","lastModifiedDate":"2023-10-31"},{"lineNumber":484,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":485,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":486,"author":{"gitId":"martinschnder"},"content":"|| 1. Key : Panadole, Quantity: 10","lastModifiedDate":"2023-10-31"},{"lineNumber":487,"author":{"gitId":"martinschnder"},"content":"||","lastModifiedDate":"2023-10-31"},{"lineNumber":488,"author":{"gitId":"martinschnder"},"content":"||Listed all the content of your cart.","lastModifiedDate":"2023-10-31"},{"lineNumber":489,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":490,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":491,"author":{"gitId":"martinschnder"},"content":"### `checkout` - Checks out the current cart","lastModifiedDate":"2023-10-31"},{"lineNumber":492,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":493,"author":{"gitId":"martinschnder"},"content":"Empty the current cart and retrieve all the specified drugs and quantity from the inventory","lastModifiedDate":"2023-10-31"},{"lineNumber":494,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":495,"author":{"gitId":"martinschnder"},"content":"Format:","lastModifiedDate":"2023-10-31"},{"lineNumber":496,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":497,"author":{"gitId":"martinschnder"},"content":"checkout","lastModifiedDate":"2023-10-31"},{"lineNumber":498,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":499,"author":{"gitId":"martinschnder"},"content":"Example of usage:","lastModifiedDate":"2023-10-31"},{"lineNumber":500,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":501,"author":{"gitId":"martinschnder"},"content":"`checkout","lastModifiedDate":"2023-10-31"},{"lineNumber":502,"author":{"gitId":"martinschnder"},"content":"`","lastModifiedDate":"2023-10-31"},{"lineNumber":503,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":504,"author":{"gitId":"martinschnder"},"content":"Expected outcome:","lastModifiedDate":"2023-10-31"},{"lineNumber":505,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":506,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":507,"author":{"gitId":"martinschnder"},"content":"|| The current cart has been checked out.","lastModifiedDate":"2023-10-31"},{"lineNumber":508,"author":{"gitId":"martinschnder"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":509,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":510,"author":{"gitId":"Barbaracwx"},"content":"### `setthreshold` - Set the threshold quantity for a drug","lastModifiedDate":"2023-11-01"},{"lineNumber":511,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":512,"author":{"gitId":"Barbaracwx"},"content":"Set the threshold quantity for a specific drug in your inventory. The threshold quantity is the minimum quantity of the","lastModifiedDate":"2023-11-01"},{"lineNumber":513,"author":{"gitId":"Barbaracwx"},"content":"drug that you want to keep in stock.","lastModifiedDate":"2023-11-01"},{"lineNumber":514,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":515,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":516,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":517,"author":{"gitId":"Barbaracwx"},"content":"setthreshold /n [Drug Name] /tq [Threshold Quantity]","lastModifiedDate":"2023-11-01"},{"lineNumber":518,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":519,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":520,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":521,"author":{"gitId":"Barbaracwx"},"content":"`setthreshold /n Doliprane /tq 50","lastModifiedDate":"2023-11-01"},{"lineNumber":522,"author":{"gitId":"Barbaracwx"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":523,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":526,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":527,"author":{"gitId":"Barbaracwx"},"content":"|| Threshold quantity set for Doliprane: 50","lastModifiedDate":"2023-11-01"},{"lineNumber":528,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":529,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":530,"author":{"gitId":"Barbaracwx"},"content":"### `listthreshold` - List all drugs and their threshold levels","lastModifiedDate":"2023-11-01"},{"lineNumber":531,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"Barbaracwx"},"content":"Retrieve a list of all drugs in your inventory and their corresponding threshold levels. The threshold level is the","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"Barbaracwx"},"content":"minimum quantity of each drug that you want to keep in stock.","lastModifiedDate":"2023-11-01"},{"lineNumber":534,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"Barbaracwx"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"Barbaracwx"},"content":"listthreshold","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"Barbaracwx"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":540,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"Barbaracwx"},"content":"`listthreshold","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"Barbaracwx"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"Barbaracwx"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":546,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":547,"author":{"gitId":"Barbaracwx"},"content":"|| 1. Doliprane: 50","lastModifiedDate":"2023-11-01"},{"lineNumber":548,"author":{"gitId":"Barbaracwx"},"content":"|| ","lastModifiedDate":"2023-11-01"},{"lineNumber":549,"author":{"gitId":"Barbaracwx"},"content":"|| Listed all drugs by threshold level in the inventory.","lastModifiedDate":"2023-11-01"},{"lineNumber":550,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":551,"author":{"gitId":"Barbaracwx"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":552,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":553,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":554,"author":{"gitId":"karishma-t"},"content":"### `addDescription` - Adds a drug\u0027s description into a list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":555,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":556,"author":{"gitId":"karishma-t"},"content":"Adds a drug\u0027s description into a list to be tracked by the system.","lastModifiedDate":"2023-11-01"},{"lineNumber":557,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":558,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":559,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":560,"author":{"gitId":"karishma-t"},"content":"addDescription /n DRUG_NAME /desc DESCRIPTION ","lastModifiedDate":"2023-11-01"},{"lineNumber":561,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":562,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":563,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":564,"author":{"gitId":"karishma-t"},"content":"`addDescription /n Panadol /desc Pain Relief","lastModifiedDate":"2023-11-01"},{"lineNumber":565,"author":{"gitId":"karishma-t"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":566,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":567,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":568,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":569,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":570,"author":{"gitId":"karishma-t"},"content":"|| New drug description added for Panadol: Pain Relief ","lastModifiedDate":"2023-11-01"},{"lineNumber":571,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":572,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":573,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":574,"author":{"gitId":"karishma-t"},"content":"### `getDescription` - Retrieves the description of a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":575,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":576,"author":{"gitId":"karishma-t"},"content":"Retrieves the description of a particular drug.","lastModifiedDate":"2023-11-01"},{"lineNumber":577,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":578,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":579,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":580,"author":{"gitId":"karishma-t"},"content":"getDescription /n DRUG_NAME","lastModifiedDate":"2023-11-01"},{"lineNumber":581,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":582,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":583,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":584,"author":{"gitId":"karishma-t"},"content":"`getDescription /n Panadol","lastModifiedDate":"2023-11-01"},{"lineNumber":585,"author":{"gitId":"karishma-t"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":586,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":587,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":588,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":589,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":590,"author":{"gitId":"karishma-t"},"content":"|| Pain Relief","lastModifiedDate":"2023-11-01"},{"lineNumber":591,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":592,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":593,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":594,"author":{"gitId":"karishma-t"},"content":"### `listDescriptions` - Displays a list of all the descriptions for all corresponding drugs","lastModifiedDate":"2023-11-01"},{"lineNumber":595,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":596,"author":{"gitId":"karishma-t"},"content":"Displays a list of all the descriptions for all corresponding drugs","lastModifiedDate":"2023-11-01"},{"lineNumber":597,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":598,"author":{"gitId":"karishma-t"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":599,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":600,"author":{"gitId":"karishma-t"},"content":"listDescriptions ","lastModifiedDate":"2023-11-01"},{"lineNumber":601,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":602,"author":{"gitId":"karishma-t"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":603,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":604,"author":{"gitId":"karishma-t"},"content":"`listDescriptions","lastModifiedDate":"2023-11-01"},{"lineNumber":605,"author":{"gitId":"karishma-t"},"content":"`","lastModifiedDate":"2023-11-01"},{"lineNumber":606,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":607,"author":{"gitId":"karishma-t"},"content":"Expected outcome:","lastModifiedDate":"2023-11-01"},{"lineNumber":608,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":609,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":610,"author":{"gitId":"karishma-t"},"content":"|| List of Drug Descriptions:","lastModifiedDate":"2023-11-01"},{"lineNumber":611,"author":{"gitId":"karishma-t"},"content":"|| Panadol: Pain Relief","lastModifiedDate":"2023-11-01"},{"lineNumber":612,"author":{"gitId":"karishma-t"},"content":"|| Dolo: Stomache Discomfort","lastModifiedDate":"2023-11-01"},{"lineNumber":613,"author":{"gitId":"karishma-t"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":614,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":615,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":616,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":617,"author":{"gitId":"TeoHaoZhi"},"content":"**Q**: Can i register with blank username and password","lastModifiedDate":"2023-10-17"},{"lineNumber":618,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":619,"author":{"gitId":"TeoHaoZhi"},"content":"**A**: No. Ensure your entries are not blank.","lastModifiedDate":"2023-10-17"},{"lineNumber":620,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":621,"author":{"gitId":"TeoHaoZhi"},"content":"**Q**: Why can i register and login again even after being logged in","lastModifiedDate":"2023-11-04"},{"lineNumber":622,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":623,"author":{"gitId":"TeoHaoZhi"},"content":"**A**: A user is able to login another user or can help to register a new user without rebooting the application","lastModifiedDate":"2023-11-04"},{"lineNumber":624,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":625,"author":{"gitId":"TeoHaoZhi"},"content":"**Q**: Why is my registration and login details not masked","lastModifiedDate":"2023-11-04"},{"lineNumber":626,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":627,"author":{"gitId":"TeoHaoZhi"},"content":"**A**: Masking of input is a security concern that will be developed on in future iterations","lastModifiedDate":"2023-11-04"},{"lineNumber":628,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":629,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":630,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":631,"author":{"gitId":"martinschnder"},"content":"- add : `add /n DRUG_NAME /d EXPIRY_DATE /q QUANTITY`","lastModifiedDate":"2023-10-31"},{"lineNumber":632,"author":{"gitId":"martinschnder"},"content":"- delete : `delete /n DRUG_NAME`","lastModifiedDate":"2023-10-31"},{"lineNumber":633,"author":{"gitId":"martinschnder"},"content":"- list : `list`","lastModifiedDate":"2023-10-31"},{"lineNumber":634,"author":{"gitId":"martinschnder"},"content":"- find : `find /n KEYWORD` or `find /d KEYWORD`","lastModifiedDate":"2023-10-31"},{"lineNumber":635,"author":{"gitId":"martinschnder"},"content":"- help : `help`","lastModifiedDate":"2023-10-31"},{"lineNumber":636,"author":{"gitId":"martinschnder"},"content":"- register : `register`","lastModifiedDate":"2023-10-31"},{"lineNumber":637,"author":{"gitId":"martinschnder"},"content":"- login : `login`","lastModifiedDate":"2023-10-31"},{"lineNumber":638,"author":{"gitId":"martinschnder"},"content":"- save : `save`","lastModifiedDate":"2023-10-31"},{"lineNumber":639,"author":{"gitId":"martinschnder"},"content":"- add Vendor : `addVendor`","lastModifiedDate":"2023-10-31"},{"lineNumber":640,"author":{"gitId":"martinschnder"},"content":"- list Vendor : `listVendors`","lastModifiedDate":"2023-10-31"},{"lineNumber":641,"author":{"gitId":"karishma-t"},"content":"- add Vendor Supply : `addVendorSupply VENDOR_NAME DRUG_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":642,"author":{"gitId":"karishma-t"},"content":"- list Vendor Supply : `listVendorSupply VENDOR_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":643,"author":{"gitId":"karishma-t"},"content":"- find Vendor Supply : `findVendorSupply DRUG_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":644,"author":{"gitId":"karishma-t"},"content":"- add description : `addDescription /n DRUG_NAME /desc DESCRIPTION`","lastModifiedDate":"2023-11-01"},{"lineNumber":645,"author":{"gitId":"karishma-t"},"content":"- get description : `getDescription /n DRUG_NAME`","lastModifiedDate":"2023-11-01"},{"lineNumber":646,"author":{"gitId":"karishma-t"},"content":"- list descriptions : `listDescriptions`","lastModifiedDate":"2023-11-01"},{"lineNumber":647,"author":{"gitId":"TeoHaoZhi"},"content":"- bye : `bye`","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"karishma-t":146,"martinschnder":89,"TeoHaoZhi":280,"-":34,"Barbaracwx":98}},{"path":"docs/team/Azfarul.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"# Azfarul Matin - Project Portfolio Page","lastModifiedDate":"2023-10-07"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"## Overview","lastModifiedDate":"2023-10-07"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-07"}],"authorContributionMap":{"azfarulmatin":6}},{"path":"docs/team/Barbara.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"# Barbara Chong - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"Barbaracwx":6}},{"path":"docs/team/HaoZhi.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"# Hao Zhi - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"TeoHaoZhi":6}},{"path":"docs/team/Karishma.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"# Karishma - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"karishma-t":5}},{"path":"docs/team/Martin.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"# Martin Schneider - Project Portfolio Page","lastModifiedDate":"2023-10-07"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"## Overview","lastModifiedDate":"2023-10-07"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-07"}],"authorContributionMap":{"martinschnder":5}},{"path":"src/main/java/seedu/stocker/Stocker.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.authentication.LoginSystem;","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.storage.Storage;","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.ui.Ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.parser.Parser;","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.Command;","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.CommandResult;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.ExitCommand;","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"import static seedu.stocker.common.Messages.MESSAGE_EXECUTION_FAILED;","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"public class Stocker {","lastModifiedDate":"2023-10-08"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" private Ui ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" private Inventory inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" private SalesList salesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" private Cart currentCart;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" private VendorsList vendorsList;","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" public static void main(String[] launchArgs) {","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" new Stocker().run();","lastModifiedDate":"2023-10-09"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * Runs Login System.","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" public boolean startLogin() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" this.ui \u003d new Ui();","lastModifiedDate":"2023-10-12"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" ui.showLoginMessage();","lastModifiedDate":"2023-10-12"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" LoginSystem system \u003d new LoginSystem();","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" system.run();","lastModifiedDate":"2023-10-11"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":" return system.loginStatus;","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":" * Runs the program until termination.","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":" public void run() {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" start();","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"martinschnder"},"content":" runCommandLoopUntilExitCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":50,"author":{"gitId":"martinschnder"},"content":" exit();","lastModifiedDate":"2023-10-09"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" * Sets up the required objects, and prints the welcome message.","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" private void start() {","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" this.ui \u003d new Ui();","lastModifiedDate":"2023-10-09"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":" this.inventory \u003d new Inventory();","lastModifiedDate":"2023-10-09"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" this.salesList \u003d new SalesList();","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" this.currentCart \u003d new Cart();","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":" this.vendorsList \u003d new VendorsList();","lastModifiedDate":"2023-10-28"},{"lineNumber":63,"author":{"gitId":"martinschnder"},"content":" Storage storage \u003d new Storage(inventory);","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":" storage.loadFileContents(\"drugs.txt\");","lastModifiedDate":"2023-10-21"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":" boolean checker \u003d startLogin();","lastModifiedDate":"2023-10-12"},{"lineNumber":66,"author":{"gitId":"martinschnder"},"content":" assert checker;","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" ui.showWelcomeMessage();","lastModifiedDate":"2023-10-09"},{"lineNumber":68,"author":{"gitId":"martinschnder"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"martinschnder"},"content":" ui.showInitFailedMessage();","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"martinschnder"},"content":" System.exit(0);","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":74,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":" * Prints the Goodbye message and exits.","lastModifiedDate":"2023-10-11"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":78,"author":{"gitId":"martinschnder"},"content":" private void exit() {","lastModifiedDate":"2023-10-09"},{"lineNumber":79,"author":{"gitId":"martinschnder"},"content":" ui.showGoodbyeMessage();","lastModifiedDate":"2023-10-09"},{"lineNumber":80,"author":{"gitId":"martinschnder"},"content":" System.exit(0);","lastModifiedDate":"2023-10-09"},{"lineNumber":81,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":83,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":" * Reads the user command and executes it, until the user issues the exit command.","lastModifiedDate":"2023-10-11"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":86,"author":{"gitId":"martinschnder"},"content":" private void runCommandLoopUntilExitCommand() {","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"martinschnder"},"content":" Command command;","lastModifiedDate":"2023-10-09"},{"lineNumber":88,"author":{"gitId":"martinschnder"},"content":" do {","lastModifiedDate":"2023-10-09"},{"lineNumber":89,"author":{"gitId":"martinschnder"},"content":" String userCommandText \u003d ui.getUserCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":90,"author":{"gitId":"martinschnder"},"content":" command \u003d new Parser().parseCommand(userCommandText);","lastModifiedDate":"2023-10-09"},{"lineNumber":91,"author":{"gitId":"martinschnder"},"content":" ui.showResultToUser(executeCommand(command));","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"martinschnder"},"content":" } while (!ExitCommand.isExit(command));","lastModifiedDate":"2023-10-09"},{"lineNumber":93,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":94,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":95,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":96,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2020-05-24"},{"lineNumber":97,"author":{"gitId":"martinschnder"},"content":" * Executes the command and returns the result.","lastModifiedDate":"2023-10-09"},{"lineNumber":98,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":99,"author":{"gitId":"martinschnder"},"content":" * @param command user command","lastModifiedDate":"2023-10-09"},{"lineNumber":100,"author":{"gitId":"martinschnder"},"content":" * @return result of the command","lastModifiedDate":"2023-10-09"},{"lineNumber":101,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":102,"author":{"gitId":"martinschnder"},"content":" private CommandResult\u003cObject\u003e executeCommand(Command command) {","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, salesList, currentCart, vendorsList);","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"martinschnder"},"content":" return command.execute();","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"martinschnder"},"content":" } catch (IOException ioe) {","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"martinschnder"},"content":" return new CommandResult\u003c\u003e(MESSAGE_EXECUTION_FAILED);","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":110,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"martinschnder":71,"TeoHaoZhi":33,"-":6}},{"path":"src/main/java/seedu/stocker/authentication/LoginSystem.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.authentication;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.ui.Ui;","lastModifiedDate":"2023-10-14"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.FileReader;","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.BufferedReader;","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.BufferedWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.File;","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" * Represents a login system used for authentication of users.","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" * User information is saved within a hashtable and uploaded","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" * into txt file for future reference.","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"public class LoginSystem {","lastModifiedDate":"2023-10-11"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public boolean loginStatus;","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" private final Scanner in;","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" private Ui interactor;","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" private final HashMap\u003cString, String\u003e users;","lastModifiedDate":"2023-10-12"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" public LoginSystem() throws IOException {","lastModifiedDate":"2023-10-11"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" users \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-11"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" loginStatus \u003d false;","lastModifiedDate":"2023-10-11"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" this.in \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-12"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" interactor \u003d new Ui();","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" File holder \u003d new File(\"./users.txt\");","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" if (!holder.exists()) {","lastModifiedDate":"2023-10-12"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" holder.createNewFile();","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" * Returns user choice of whether they wish to register a new user","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" * or if they would want to login using an existing user.","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" * @return choice of user to login or register","lastModifiedDate":"2023-10-21"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":" public String authenticateUserChoice() {","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" while (in.hasNextLine()) {","lastModifiedDate":"2023-10-12"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":" String choice \u003d in.nextLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":" if (choice.trim().equals(\"register\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" return \"register\";","lastModifiedDate":"2023-10-20"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (choice.trim().equals(\"login\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":" return \"login\";","lastModifiedDate":"2023-10-20"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidChoiceMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":" return authenticateUserChoice();","lastModifiedDate":"2023-10-12"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"TeoHaoZhi"},"content":" return \"error\";","lastModifiedDate":"2023-10-12"},{"lineNumber":58,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":60,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":" * Creates a new user with input username and password from user.","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":" * Username and password are saved into a txt file for future","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":" * reference.","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if inappropriate output is entered.","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" public void newUserCreator() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showUsernameMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":" String username \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":" while (username.trim().equals(\"\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showBlankNameMessage();","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":" username \u003d in.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" while (username.trim().contains(\":\")){","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidLoginCharacterMessage();","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"TeoHaoZhi"},"content":" username \u003d in.nextLine();","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":83,"author":{"gitId":"TeoHaoZhi"},"content":" String password \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" while (password.trim().equals(\"\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":86,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showBlankPasswordMessage();","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":" password \u003d in.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"TeoHaoZhi"},"content":" while(password.trim().contains(\":\")){","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidLoginCharacterMessage();","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"TeoHaoZhi"},"content":" password \u003d in.nextLine();","lastModifiedDate":"2023-11-04"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":" assert (username.equals(\"\") \u003d\u003d false);","lastModifiedDate":"2023-10-15"},{"lineNumber":96,"author":{"gitId":"TeoHaoZhi"},"content":" assert (password.equals(\"\") \u003d\u003d false);","lastModifiedDate":"2023-10-15"},{"lineNumber":97,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":98,"author":{"gitId":"TeoHaoZhi"},"content":" if (users.containsKey(username)) {","lastModifiedDate":"2023-10-11"},{"lineNumber":99,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showUserAlreadyExistMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":" System.out.println();","lastModifiedDate":"2023-10-11"},{"lineNumber":101,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showEnterChoiceAgainMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":102,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":103,"author":{"gitId":"TeoHaoZhi"},"content":" String reselect \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":104,"author":{"gitId":"TeoHaoZhi"},"content":" if (reselect.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":105,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":106,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":107,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (reselect.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":111,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":112,"author":{"gitId":"TeoHaoZhi"},"content":" users.put(username, password);","lastModifiedDate":"2023-10-11"},{"lineNumber":113,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showSuccessfulRegistrationMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":" loginStatus \u003d true;","lastModifiedDate":"2023-10-11"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":116,"author":{"gitId":"TeoHaoZhi"},"content":" writeNewUserToFile();","lastModifiedDate":"2023-10-11"},{"lineNumber":117,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":118,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":119,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":120,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":121,"author":{"gitId":"TeoHaoZhi"},"content":" * Login existing user by asking for username and password input","lastModifiedDate":"2023-10-14"},{"lineNumber":122,"author":{"gitId":"TeoHaoZhi"},"content":" * from user.","lastModifiedDate":"2023-10-14"},{"lineNumber":123,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":124,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if inappropriate input is entered.","lastModifiedDate":"2023-10-14"},{"lineNumber":125,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":126,"author":{"gitId":"martinschnder"},"content":" public void loginExistingUser() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":128,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":129,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showUsernameMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":130,"author":{"gitId":"TeoHaoZhi"},"content":" String usernameInput \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":131,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":132,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":133,"author":{"gitId":"TeoHaoZhi"},"content":" String passwordInput \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":134,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":135,"author":{"gitId":"TeoHaoZhi"},"content":" if (!users.containsKey(usernameInput)) {","lastModifiedDate":"2023-10-11"},{"lineNumber":136,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidUsernameOrPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":137,"author":{"gitId":"TeoHaoZhi"},"content":" System.out.println();","lastModifiedDate":"2023-10-11"},{"lineNumber":138,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showEnterChoiceAgainMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":139,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":140,"author":{"gitId":"TeoHaoZhi"},"content":" String reselect \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":141,"author":{"gitId":"TeoHaoZhi"},"content":" if (reselect.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":142,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":143,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":144,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (reselect.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":145,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":146,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":147,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":148,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":149,"author":{"gitId":"TeoHaoZhi"},"content":" if (users.get(usernameInput).equals(passwordInput)) {","lastModifiedDate":"2023-10-11"},{"lineNumber":150,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showSuccessfulLoginMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":151,"author":{"gitId":"TeoHaoZhi"},"content":" loginStatus \u003d true;","lastModifiedDate":"2023-10-11"},{"lineNumber":152,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":153,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showInvalidUsernameOrPasswordMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":154,"author":{"gitId":"TeoHaoZhi"},"content":" System.out.println();","lastModifiedDate":"2023-10-11"},{"lineNumber":155,"author":{"gitId":"TeoHaoZhi"},"content":" interactor.showEnterChoiceAgainMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":156,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":157,"author":{"gitId":"TeoHaoZhi"},"content":" String reselect \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":158,"author":{"gitId":"TeoHaoZhi"},"content":" if (reselect.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":159,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":160,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":161,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (reselect.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":162,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":163,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":164,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":165,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":166,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":167,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":168,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":169,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":170,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":171,"author":{"gitId":"TeoHaoZhi"},"content":" * Writes new user creation into a txt file to save for future reference","lastModifiedDate":"2023-10-14"},{"lineNumber":172,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":173,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException","lastModifiedDate":"2023-10-14"},{"lineNumber":174,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":175,"author":{"gitId":"TeoHaoZhi"},"content":" public void writeNewUserToFile() throws IOException {","lastModifiedDate":"2023-10-11"},{"lineNumber":176,"author":{"gitId":"TeoHaoZhi"},"content":" BufferedWriter writer \u003d new BufferedWriter(new FileWriter(\"./users.txt\", true));","lastModifiedDate":"2023-10-11"},{"lineNumber":177,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":178,"author":{"gitId":"TeoHaoZhi"},"content":" for (Map.Entry\u003cString, String\u003e entry :","lastModifiedDate":"2023-10-11"},{"lineNumber":179,"author":{"gitId":"TeoHaoZhi"},"content":" users.entrySet()) {","lastModifiedDate":"2023-10-11"},{"lineNumber":180,"author":{"gitId":"TeoHaoZhi"},"content":" // put key and value separated by a colon","lastModifiedDate":"2023-10-11"},{"lineNumber":181,"author":{"gitId":"TeoHaoZhi"},"content":" writer.write(entry.getKey() + \":\"","lastModifiedDate":"2023-10-11"},{"lineNumber":182,"author":{"gitId":"TeoHaoZhi"},"content":" + entry.getValue());","lastModifiedDate":"2023-10-11"},{"lineNumber":183,"author":{"gitId":"TeoHaoZhi"},"content":" // new line","lastModifiedDate":"2023-10-11"},{"lineNumber":184,"author":{"gitId":"TeoHaoZhi"},"content":" writer.newLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":185,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":186,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":187,"author":{"gitId":"TeoHaoZhi"},"content":" writer.flush();","lastModifiedDate":"2023-10-11"},{"lineNumber":188,"author":{"gitId":"TeoHaoZhi"},"content":" writer.close();","lastModifiedDate":"2023-10-11"},{"lineNumber":189,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":190,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":191,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":192,"author":{"gitId":"TeoHaoZhi"},"content":" * Loads existing users from txt file into hash table","lastModifiedDate":"2023-10-14"},{"lineNumber":193,"author":{"gitId":"TeoHaoZhi"},"content":" * for login system to use for authentication when","lastModifiedDate":"2023-10-14"},{"lineNumber":194,"author":{"gitId":"TeoHaoZhi"},"content":" * user tries to login.","lastModifiedDate":"2023-10-14"},{"lineNumber":195,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":196,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if fail to read from txt file","lastModifiedDate":"2023-10-14"},{"lineNumber":197,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":198,"author":{"gitId":"TeoHaoZhi"},"content":" public void loadExistingUsers() throws IOException {","lastModifiedDate":"2023-10-11"},{"lineNumber":199,"author":{"gitId":"TeoHaoZhi"},"content":" BufferedReader reader \u003d new BufferedReader(new FileReader(\"./users.txt\"));","lastModifiedDate":"2023-10-11"},{"lineNumber":200,"author":{"gitId":"TeoHaoZhi"},"content":" String line;","lastModifiedDate":"2023-10-11"},{"lineNumber":201,"author":{"gitId":"TeoHaoZhi"},"content":" while ((line \u003d reader.readLine()) !\u003d null) {","lastModifiedDate":"2023-10-11"},{"lineNumber":202,"author":{"gitId":"TeoHaoZhi"},"content":" String[] parts \u003d line.split(\":\", 2);","lastModifiedDate":"2023-10-11"},{"lineNumber":203,"author":{"gitId":"TeoHaoZhi"},"content":" if (parts.length \u003e\u003d 2) {","lastModifiedDate":"2023-10-11"},{"lineNumber":204,"author":{"gitId":"TeoHaoZhi"},"content":" String key \u003d parts[0];","lastModifiedDate":"2023-10-11"},{"lineNumber":205,"author":{"gitId":"TeoHaoZhi"},"content":" String value \u003d parts[1];","lastModifiedDate":"2023-10-11"},{"lineNumber":206,"author":{"gitId":"TeoHaoZhi"},"content":" users.put(key, value);","lastModifiedDate":"2023-10-11"},{"lineNumber":207,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":208,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":209,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":210,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":211,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":212,"author":{"gitId":"TeoHaoZhi"},"content":" * Runs login system by loading user information into hash table","lastModifiedDate":"2023-10-14"},{"lineNumber":213,"author":{"gitId":"TeoHaoZhi"},"content":" * and get input for user to check for authentication.","lastModifiedDate":"2023-10-14"},{"lineNumber":214,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":215,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if unable to read from txt file to","lastModifiedDate":"2023-10-14"},{"lineNumber":216,"author":{"gitId":"TeoHaoZhi"},"content":" * load users","lastModifiedDate":"2023-10-14"},{"lineNumber":217,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":218,"author":{"gitId":"martinschnder"},"content":" public void run() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"TeoHaoZhi"},"content":" loadExistingUsers();","lastModifiedDate":"2023-10-11"},{"lineNumber":220,"author":{"gitId":"TeoHaoZhi"},"content":" String choice \u003d authenticateUserChoice();","lastModifiedDate":"2023-10-11"},{"lineNumber":221,"author":{"gitId":"TeoHaoZhi"},"content":" if (choice.equals(\"register\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":222,"author":{"gitId":"TeoHaoZhi"},"content":" newUserCreator();","lastModifiedDate":"2023-10-11"},{"lineNumber":223,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":224,"author":{"gitId":"TeoHaoZhi"},"content":" } else if (choice.equals(\"login\")) {","lastModifiedDate":"2023-10-20"},{"lineNumber":225,"author":{"gitId":"TeoHaoZhi"},"content":" loginExistingUser();","lastModifiedDate":"2023-10-11"},{"lineNumber":226,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":227,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":228,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":229,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":230,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"martinschnder":5,"TeoHaoZhi":225}},{"path":"src/main/java/seedu/stocker/commands/AddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" * Adds a drug into the inventory","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"public class AddCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"add\";","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a new drug to the drug list. \"","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" + \"Parameters: NAME, EXPIRY DATE, SERIAL NUMBER, QUANTITY, \" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" + \" /n Doliprane /d 12/06/2035 /s ABC123 /q 52\";","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug added in the inventory: %1$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" private final Drug toAdd;","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" private final long quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":" private final String serialNumber;","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"azfarulmatin"},"content":" public AddCommand(String name, String expiryDate, String serialNumber, Long quantity) {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.toAdd \u003d new Drug(name, expiryDate);","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":" this.serialNumber \u003d serialNumber;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" public Drug getDrug() {","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" return this.toAdd;","lastModifiedDate":"2023-10-09"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":" public String getSerialNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"azfarulmatin"},"content":" return this.serialNumber;","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(toAdd.getName(), toAdd, serialNumber, quantity);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, toAdd.getName()));","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":30,"azfarulmatin":10,"TeoHaoZhi":1,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/AddDescriptionCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":" * Adds a drug description to the description list.","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"public class AddDescriptionCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"addDescription\";","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a new description for a specific drug \"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: NAME, DESCRIPTION\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" /n Panadol /desc Pain Relief \";","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug description added for %1$s: %2$s\";","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" private final String drugDescription;","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" * Creates an AddDescriptionCommand to add a drug description to the description list.","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug for which the description is added.","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * @param drugDescription The description to be added for the drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" public AddDescriptionCommand(String drugName, String drugDescription ) {","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" this.drugDescription \u003d drugDescription;","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * Executes the command to add the drug description.","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult indicating the success of adding the description.","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" seedu.stocker.drugs.Description.addDescription(drugName, drugDescription);","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, drugName, drugDescription));","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":40}},{"path":"src/main/java/seedu/stocker/commands/AddToCartCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" * Adds a certain quantity of one drug into the current cart","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"public class AddToCartCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"addtocart\";","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD ","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" + \": Adds a new drug to the current cart. \"","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" + \"Parameters: NAME, QUANTITY,\" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" + \" /n Doliprane /q 2\";","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug added in the current cart: %1$s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" private final String drugName;","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" private final long quantity;","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" public AddToCartCommand(String name, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.drugName \u003d name;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" StockEntry matchingEntry \u003d inventory.getStockEntries().stream()","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" .filter(entry -\u003e entry","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" .getDrug().getName()","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" .equalsIgnoreCase(this.drugName) \u0026\u0026 ","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" entry.getQuantity() \u003e this.quantity)","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" .findAny()","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" .orElse(null);","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" if (matchingEntry !\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":" currentCart.addEntry(this.drugName, this.quantity);","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, matchingEntry.getDrug().getName()));","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(\"This drug is not in stock. \");","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":40,"TeoHaoZhi":1,"Barbaracwx":4}},{"path":"src/main/java/seedu/stocker/commands/AddVendorCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.vendors.Vendor;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":" * Adds a vendor into the inventory","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"public class AddVendorCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"addVendor\";","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a new vendor to the vendors list. \"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Parameter: NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + \" Moderna\";","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New vendor added in the vendors list: %1$s\";","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" private final Vendor toAdd;","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public AddVendorCommand(String name) {","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" this.toAdd \u003d new Vendor(name);","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003e CommandResult\u003cT\u003e execute() {","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" this.vendorsList.addNewVendor(toAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, toAdd.getName()));","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"martinschnder":3,"TeoHaoZhi":27}},{"path":"src/main/java/seedu/stocker/commands/AddVendorSupplyCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.vendors.VendorSupplyList;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":" * Adds a drug to a vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"public class AddVendorSupplyCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"addVendorSupply\";","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Adds a drug to a vendor\u0027s supply list. \"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: VENDOR_NAME DRUG_NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" Moderna Paracetamol\";","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New drug added to %1$s\u0027s supply list: %2$s\";","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_VENDOR_NOT_FOUND \u003d \"Vendor not found: %1$s\";","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" private final String vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * Creates an AddVendorSupplyCommand to add a drug to a vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug to be added to the vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" public AddVendorSupplyCommand(String vendorName, String drugName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" this.vendorName \u003d vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" * Executes the command to add a drug to the specified vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult indicating the success of adding the drug or a message indicating the vendor was not found.","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003e CommandResult\u003cT\u003e execute() {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" String lowercaseVendorName \u003d vendorName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" String lowercaseDrugName \u003d drugName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" if (this.vendorsList.getVendorEntries().stream().anyMatch(vendor -\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":" vendor.getName().equalsIgnoreCase(lowercaseVendorName))) {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"karishma-t"},"content":" VendorSupplyList.addDrugToVendor(lowercaseVendorName, lowercaseDrugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, lowercaseVendorName, lowercaseDrugName));","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_VENDOR_NOT_FOUND, lowercaseVendorName));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":49,"martinschnder":2}},{"path":"src/main/java/seedu/stocker/commands/CheckOutCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" * Remove a drug from inventory and add it into the sales list","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"public class CheckOutCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"checkout\";","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Checks out current cart. \"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" + \"Parameters:\" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"The current cart has been checked out. \";","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public CheckOutCommand() {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" currentCart.checkOut(salesList, inventory);","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS));","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":22,"TeoHaoZhi":1,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" protected Inventory inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" protected SalesList salesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" protected Cart currentCart;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" protected VendorsList vendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" protected Command() {","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" public void setData(Inventory inventory, SalesList salesList, Cart currentCart, VendorsList vendorsList) {","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" this.inventory \u003d inventory;","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" this.salesList \u003d salesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.currentCart \u003d currentCart;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" this.vendorsList \u003d vendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" public abstract \u003cT\u003e CommandResult\u003cT\u003e execute() throws IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":28,"TeoHaoZhi":3}},{"path":"src/main/java/seedu/stocker/commands/CommandResult.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"// import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.Optional;","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" * Represents the result of a command execution.","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"public class CommandResult\u003cT\u003e {","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" * The feedback message to be shown to the user. Contains a description of the execution result","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" * The list of drugs that was produced by the command","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" private final List\u003cT\u003e relevantElements;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" public CommandResult(String feedbackToUser) {","lastModifiedDate":"2023-10-09"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" relevantElements \u003d null;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" public CommandResult(String feedbackToUser, List\u003cT\u003e relevantElements) {","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" this.relevantElements \u003d relevantElements;","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" * Returns a list of drugs that was produced by the command, if any.","lastModifiedDate":"2023-10-09"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" public Optional\u003cList\u003cT\u003e\u003e getRelevantElements() {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" return Optional.ofNullable(relevantElements);","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" public String getFeedbackToUserFindTest() {","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" if (relevantElements !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" StringBuilder feedback \u003d new StringBuilder();","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" for (int i \u003d 0; i \u003c relevantElements.size(); i++) {","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(i + 1).append(\". \").append(relevantElements.get(i));","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(System.lineSeparator());","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(System.lineSeparator());","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" feedback.append(feedbackToUser);","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" return feedback.toString();","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" return feedbackToUser;","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":34,"Barbaracwx":21}},{"path":"src/main/java/seedu/stocker/commands/DeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.exceptions.DrugNotFoundException;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"public class DeleteCommand extends Command{","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"delete\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Removes a drug from drug list. \"","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Parameters: Name \" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" + \" \u003cDrug Name\u003e\";","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Drug removed from inventory: %1$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_FAILURE \u003d \"Drug not found in the inventory. \";","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" private final String keyToDelete;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * Constructs a DeleteCommand with the specified drug name.","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public DeleteCommand(String key) {","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" this.keyToDelete \u003d key.trim().toLowerCase();","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * Executes the \u0027delete\u0027 command, removing a drug from the inventory list by name.","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" * @return A CommandResult indicating the result of the deletion operation.","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"martinschnder"},"content":" StockEntry deletedEntry \u003d inventory.deleteDrug(this.keyToDelete);","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_SUCCESS, deletedEntry.getDrug().getName()));","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":" } catch (DrugNotFoundException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_FAILURE);","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"karishma-t":14,"martinschnder":8,"TeoHaoZhi":20,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/commands/ExitCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" * Terminates the program.","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"public class ExitCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"bye\";","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Exits the program.\"+ System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_EXIT_ACKNOWEDGEMENT \u003d \"Exiting Stocker as requested ...\";","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_EXIT_ACKNOWEDGEMENT);","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" public static boolean isExit(Command command) {","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" return command instanceof ExitCommand; // instanceof returns false if it is null","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":19,"TeoHaoZhi":2,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/commands/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import java.util.List;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_COMMAND_FORMAT;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to find drugs in the inventory that match a given keyword.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"find\";","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" * Usage message for the \u0027find\u0027 command.","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \" /n\" + \": Finds drug in inventory using name.\" +","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" \"Example: \" + COMMAND_WORD + \" /n panadol\" +","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" COMMAND_WORD + \" /d\" + \": Finds drug in inventory using date.\" +","lastModifiedDate":"2023-10-20"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"azfarulmatin"},"content":" \"Example: \" + COMMAND_WORD + \" /d panadol\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"azfarulmatin"},"content":" COMMAND_WORD + \" /s\" + \": Finds drug in inventory using serial number.\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" \"Example: \" + COMMAND_WORD + \" /s ABC123\";","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" * Success message displayed after successfully finding drugs in the inventory.","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" private final String keyword;","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" private final String criterion;","lastModifiedDate":"2023-10-20"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" * Creates a FindCommand with the specified keyword.","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" * @param keyword The keyword to search for in the inventory.","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" public FindCommand(String keyword, String criterion) {","lastModifiedDate":"2023-10-20"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" this.keyword \u003d keyword.toLowerCase();","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" this.criterion \u003d criterion;","lastModifiedDate":"2023-10-20"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"azfarulmatin"},"content":" private String getResultString(StockEntry entry) {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"azfarulmatin"},"content":" String result \u003d \"Name: \" + entry.getDrug().getName()","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"azfarulmatin"},"content":" + \", Expiry date: \" + entry.getDrug().getExpiryDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"azfarulmatin"},"content":" + \", Serial number: \" + entry.getSerialNumber()","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"azfarulmatin"},"content":" + \", Quantity: \" + entry.getQuantity();","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"azfarulmatin"},"content":" return result;","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" private static boolean matches(String criterion, String keyword, StockEntry entry) {","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" if (criterion.equals(\"/n\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":" return entry.getDrug().getName().toLowerCase().contains(keyword);","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"azfarulmatin"},"content":" } else if (criterion.equals(\"/d\")) {","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"martinschnder"},"content":" return entry.getDrug().getExpiryDate().toLowerCase().contains(keyword);","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"azfarulmatin"},"content":" } else if (criterion.equals(\"/s\")) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"azfarulmatin"},"content":" return entry.getSerialNumber().toLowerCase().contains(keyword);","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"azfarulmatin"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"azfarulmatin"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"Barbaracwx"},"content":" * Executes the \u0027find\u0027 command, searching for drugs that match the keyword.","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult containing the outcome of the command execution.","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":79,"author":{"gitId":"Barbaracwx"},"content":" if (keyword \u003d\u003d null || keyword.trim().isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_INVALID_COMMAND_FORMAT, MESSAGE_USAGE));","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":82,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":" List\u003cStockEntry\u003e entries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"azfarulmatin"},"content":" List\u003cString\u003e foundResults \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"martinschnder"},"content":" for (StockEntry entry : entries) {","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"martinschnder"},"content":" if (matches(this.criterion, this.keyword, entry)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":88,"author":{"gitId":"azfarulmatin"},"content":" foundResults.add(getResultString(entry));","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":91,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"azfarulmatin"},"content":" if (foundResults.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"azfarulmatin"},"content":" return new CommandResult\u003c\u003e(\"No drugs found with the specified criteria.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"azfarulmatin"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"azfarulmatin"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS, foundResults);","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":98,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":12,"azfarulmatin":26,"TeoHaoZhi":12,"Barbaracwx":50}},{"path":"src/main/java/seedu/stocker/commands/FindVendorSupplyCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.vendors.VendorSupplyList;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"import java.util.stream.Collectors;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" * Lists the vendors that supply a specific drug.","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"public class FindVendorSupplyCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"findVendorSupply\";","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Lists the vendors that supply a specific drug. \"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: DRUG_NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" Paracetamol\";","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" * Creates a FindVendorSupplyCommand to list the vendors that supply a specific drug.","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug to search for.","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" public FindVendorSupplyCommand(String drugName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" * Executes the command to list the vendors that supply the specified drug.","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult indicating the vendors that supply the drug or an error message.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" String lowercaseDrugName \u003d drugName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" if (lowercaseDrugName.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(MESSAGE_USAGE);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" List\u003cString\u003e supplyingVendors \u003d VendorSupplyList.getVendorSuppliedDrugs()","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" .entrySet()","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":" .stream()","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":" .filter(entry -\u003e entry.getValue().contains(lowercaseDrugName))","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"karishma-t"},"content":" .map(Map.Entry::getKey)","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"karishma-t"},"content":" .collect(Collectors.toList());","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"karishma-t"},"content":" if (supplyingVendors.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"No vendors supply the drug: \" + drugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"Vendors supplying the drug \" + drugName + \": \"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"karishma-t"},"content":" + String.join(\", \", supplyingVendors));","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":56}},{"path":"src/main/java/seedu/stocker/commands/GetDescriptionCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":" * Gets the description of a specific drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"public class GetDescriptionCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"getDescription\";","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Gets the description of a specific drug.\"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" /n Panadol\";","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_DESCRIPTION_NOT_FOUND \u003d \"Description not found for %1$s\";","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" private final String drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" * Creates a GetDescriptionCommand to retrieve the description of a specific drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug for which the description should be retrieved.","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" public GetDescriptionCommand(String drugName) {","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" this.drugName \u003d drugName;","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" * Executes the command to retrieve the description of the specified drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult containing the drug description if found, or an error message if not found.","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" String description \u003d seedu.stocker.drugs.Description.getDescription(drugName);","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" if (description !\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(description);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(String.format(MESSAGE_DESCRIPTION_NOT_FOUND, drugName));","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":43}},{"path":"src/main/java/seedu/stocker/commands/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Shows help instructions.","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"help\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Shows program usage instructions. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" System.lineSeparator() + AddCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + DeleteCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + HelpCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + ListCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator() + ShowStockLevelCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + FindCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator() + AddToCartCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator() + CheckOutCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator() + ViewCartCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + LoginCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-20"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + RegisterCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-20"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + SaveCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-21"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-21"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + AddVendorCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + ListVendorCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator() + SetThresholdCommand.MESSAGE_USAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator() + ListThresholdCommand.MESSAGE_USAGE","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator() + ExitCommand.MESSAGE_USAGE","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" );","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":21,"TeoHaoZhi":25,"Barbaracwx":7}},{"path":"src/main/java/seedu/stocker/commands/IncorrectCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Represents an incorrect command. Upon execution, produces some feedback to the user.","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class IncorrectCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public IncorrectCommand(String feedbackToUser) {","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(feedbackToUser);","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":17,"TeoHaoZhi":1,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"azfarulmatin"},"content":"import java.util.List;","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"azfarulmatin"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":" * Represents a command to list all drugs in the inventory.","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":" * This command retrieves the list of drugs from the inventory and provides it as part of the command result.","lastModifiedDate":"2023-10-14"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":" * If the inventory is empty, it informs the user that the inventory has no drugs.","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"list\";","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all drug information that is being \"","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" + \"tracked by the system. \" + System.lineSeparator()","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all drugs in the inventory.\";","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"azfarulmatin"},"content":" * Executes the list command.","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":" * @return A CommandResult containing the success message and the list of drugs.","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-09"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"azfarulmatin"},"content":" // Assertion: Check if the inventory is properly initialized","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"azfarulmatin"},"content":" assert inventory !\u003d null : \"Inventory should be initialized before executing ListCommand.\";","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" // Retrieve the list of drugs from the inventory","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" List\u003cStockEntry\u003e stockEntries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"azfarulmatin"},"content":" // Check if the inventory is empty","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" if (stockEntries.isEmpty()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":" // Return a CommandResult indicating that the inventory is empty","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(\"The inventory is empty.\");","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"azfarulmatin"},"content":" } else {","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":" // Prepare a StringBuilder to construct the output message","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"azfarulmatin"},"content":" StringBuilder resultMessage \u003d new StringBuilder(MESSAGE_SUCCESS + System.lineSeparator());","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"azfarulmatin"},"content":" int index \u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"azfarulmatin"},"content":" for (StockEntry entry : stockEntries) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"azfarulmatin"},"content":" resultMessage.append(\"\\t\").append(index).append(\". \")","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"azfarulmatin"},"content":" .append(\"Name: \").append(entry.getDrug().getName())","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"azfarulmatin"},"content":" .append(\", Expiry date: \").append(entry.getDrug().getExpiryDate())","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"azfarulmatin"},"content":" .append(\", Serial number: \").append(entry.getSerialNumber()) // Add this line","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"azfarulmatin"},"content":" .append(\", Quantity: \").append(entry.getQuantity())","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"azfarulmatin"},"content":" .append(System.lineSeparator());","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"azfarulmatin"},"content":" index++;","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"azfarulmatin"},"content":" // Return a CommandResult with the success message and the list of drugs","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"azfarulmatin"},"content":" return new CommandResult\u003c\u003e(resultMessage.toString().trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":3,"azfarulmatin":38,"TeoHaoZhi":13,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/ListDescriptionsCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":" * Lists all descriptions for corresponding drugs.","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"public class ListDescriptionsCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"listDescriptions\";","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_SUCCESS \u003d \"List of Drug Descriptions:\";","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Lists all the descriptions for all drugs \"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" * Creates a ListDescriptionsCommand to list all drug descriptions for all corresponding drugs.","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" public ListDescriptionsCommand() {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" * Executes the command to list all drug descriptions.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult that displays the list of drug descriptions.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" Map\u003cString, String\u003e descriptions \u003d seedu.stocker.drugs.Description.getAllDescriptions();","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" StringBuilder result \u003d new StringBuilder(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" for (Map.Entry\u003cString, String\u003e entry : descriptions.entrySet()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" result.append(System.lineSeparator());","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" result.append(entry.getKey()).append(\": \").append(entry.getValue());","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(result.toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":39}},{"path":"src/main/java/seedu/stocker/commands/ListThresholdCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to list all drugs and their threshold levels in the inventory.","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"public class ListThresholdCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" public static final String COMMAND_WORD \u003d \"listthreshold\";","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all drugs and their threshold levels.\"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all drugs by threshold level in the inventory.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" * Executes the ListThresholdCommand by retrieving a list of StockEntry objects and their threshold levels.","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult containing the list of drugs and their threshold levels or a message indicating the","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" * inventory is empty.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" assert inventory !\u003d null : \"Inventory should be initialized before executing ListThresholdCommand.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" List\u003cStockEntry\u003e stockEntries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntries.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(\"The inventory is empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" List\u003cString\u003e resultElements \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" for (StockEntry entry : stockEntries) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" long thresholdQuantity \u003d entry.getThresholdQuantity();","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" String drugName \u003d entry.getDrug().getName();","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" resultElements.add(drugName + \": \" + thresholdQuantity);","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS, resultElements);","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"Barbaracwx":45}},{"path":"src/main/java/seedu/stocker/commands/ListVendorCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.vendors.Vendor;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" * Generates a list of vendors tracked by system","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"public class ListVendorCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"listVendors\";","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all vendor information that is being \"","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + \"tracked by the system.\" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all vendors in the list.\";","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" * Executes the list command.","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" * @return A CommandResult containing the success message and the list of drugs.","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public CommandResult\u003cVendor\u003e execute() {","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" // Retrieve the list of vendors from the inventory","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" List\u003cVendor\u003e vendorEntries \u003d this.vendorsList.getVendorEntries();","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" // Check if the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" if (vendorEntries.isEmpty()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" // Return a CommandResult indicating that the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" return new CommandResult\u003c\u003e(\"The inventory is empty.\");","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" // Return a CommandResult with the success message and the list of vendors","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" return new CommandResult\u003cVendor\u003e(MESSAGE_SUCCESS, vendorEntries);","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"karishma-t":2,"martinschnder":3,"TeoHaoZhi":34}},{"path":"src/main/java/seedu/stocker/commands/ListVendorSupplyCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.vendors.VendorSupplyList;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":" * Lists the drugs supplied by a specific vendor in a case-insensitive manner.","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":"public class ListVendorSupplyCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" public static final String COMMAND_WORD \u003d \"listVendorSupply\";","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Lists the drugs supplied by a specific vendor. \"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" + \"Parameters: VENDOR_NAME\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" + \"Example: \" + COMMAND_WORD + \" Moderna\";","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" private final String vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" * Creates a ListVendorSupplyCommand to list the drugs supplied by a specific vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" public ListVendorSupplyCommand(String vendorName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" this.vendorName \u003d vendorName;","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" * Executes the command to list the drugs supplied by the specified vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" * @return CommandResult containing the list of supplied drugs or a message indicating none were supplied.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" String lowercaseVendorName \u003d vendorName.toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" if (lowercaseVendorName.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(MESSAGE_USAGE);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" List\u003cString\u003e suppliedDrugs \u003d VendorSupplyList.getDrugsSuppliedByVendor(lowercaseVendorName);","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":" if (suppliedDrugs.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"No drugs supplied by \" + vendorName);","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"karishma-t"},"content":" return new CommandResult\u003c\u003e(\"Drugs supplied by \" + vendorName + \": \" + String.join(\", \", suppliedDrugs));","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":48}},{"path":"src/main/java/seedu/stocker/commands/LoginCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-20"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.authentication.LoginSystem;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":" * Login existing user into system.","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"public class LoginCommand extends Command {","lastModifiedDate":"2023-10-20"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"login\";","lastModifiedDate":"2023-10-20"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Login new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Welcome back!\";","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" public CommandResult execute() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" LoginSystem system \u003d new LoginSystem();","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" system.loadExistingUsers();","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" system.loginExistingUser();","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-20"}],"authorContributionMap":{"martinschnder":1,"TeoHaoZhi":24,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/RegisterCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-20"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.authentication.LoginSystem;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" * Registers new user into login system.","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"public class RegisterCommand extends Command {","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"register\";","lastModifiedDate":"2023-10-20"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Register new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"New User Created.\";","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003e CommandResult\u003cT\u003e execute() throws IOException {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" LoginSystem system \u003d new LoginSystem();","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" system.loadExistingUsers();","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" system.newUserCreator();","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-20"}],"authorContributionMap":{"martinschnder":1,"TeoHaoZhi":24,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/SaveCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-21"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.storage.Storage;","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.File;","lastModifiedDate":"2023-10-21"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.List;","lastModifiedDate":"2023-10-21"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-21"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" * Backups existing drug list inventory into txt file to be uploaded later.","lastModifiedDate":"2023-10-21"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"public class SaveCommand extends Command{","lastModifiedDate":"2023-10-21"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String COMMAND_WORD \u003d \"save\";","lastModifiedDate":"2023-10-21"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": Saves existing druglist that is loaded \"","lastModifiedDate":"2023-10-21"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" +\"into inventory when system is booted up.\"","lastModifiedDate":"2023-10-21"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-21"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-21"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Drugs successfully saved.\";","lastModifiedDate":"2023-10-21"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() throws IOException {","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" File holder \u003d new File(\"./drugs.txt\");","lastModifiedDate":"2023-10-21"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" if (!holder.exists()) {","lastModifiedDate":"2023-10-21"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" holder.createNewFile();","lastModifiedDate":"2023-10-21"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" List\u003cStockEntry\u003e entries\u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" Storage storageManager \u003d new Storage(inventory);","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" storageManager.writeToFile(\"drugs.txt\", \"\");","lastModifiedDate":"2023-10-21"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" for(int i \u003d 0; i \u003c entries.size(); i +\u003d 1){","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" String name \u003dentries.get(i).getDrug().getName();","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" String date \u003d entries.get(i).getDrug().getExpiryDate();","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" String serialNumber \u003d entries.get(i).getSerialNumber();","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" String quantity \u003d String.valueOf(entries.get(i).getQuantity());","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" String toBeAppended \u003d \"Name: \" + name + \", \" + \"Expiry Date: \" + date + \", \"","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Serial Number: \" + serialNumber + \", \" + \"Quantity: \" + quantity;","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" storageManager.appendToFile(\"drugs.txt\",toBeAppended);","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS);","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-21"}],"authorContributionMap":{"martinschnder":4,"TeoHaoZhi":40,"Barbaracwx":1}},{"path":"src/main/java/seedu/stocker/commands/SetThresholdCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to set the threshold quantity for a drug in the inventory.","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"public class SetThresholdCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" public static final String COMMAND_WORD \u003d \"setthreshold\";","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":" + \": Set the threshold quantity for a drug. \"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" + \"(default 100)\" + System.lineSeparator()","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: \" + COMMAND_WORD + \" /n Doliprane /tq 50\";","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Threshold quantity set for %1$s: %2$d\";","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" private final String drugName;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" private final long threshold;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" * Constructs a SetThresholdCommand with a specified drug name and threshold quantity.","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" * @param name The name of the drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" * @param threshold The threshold quantity to set.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" public SetThresholdCommand(String name, long threshold) {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" this.drugName \u003d name;","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" this.threshold \u003d threshold;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" * Executes the SetThresholdCommand by setting the threshold quantity for the specified drug.","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult indicating the success or failure of the command.","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" if (inventory.getStockEntries().isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(\"Inventory is empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" StockEntry stockEntry \u003d inventory.getStockEntry(drugName);","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntry !\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" stockEntry.setThresholdQuantity(threshold);","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(String.format(MESSAGE_SUCCESS, drugName, threshold));","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult(\"Drug not found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"Barbaracwx":53}},{"path":"src/main/java/seedu/stocker/commands/ShowStockLevelCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.StockEntry;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import java.util.Comparator;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":" * Represents a command to display a report of stock levels sorted by quantity in ascending order.","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"public class ShowStockLevelCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" public static final String COMMAND_WORD \u003d \"stocklevel\";","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD + \": List all drugs by quantity level \"","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" + \"tracked by the system in ascending order. \" + System.lineSeparator()","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Stock Level Report (Sorted by Quantity)\";","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" * Executes the \"stocklevel\" command. Displays a report of stock levels sorted by quantity in ascending order.","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" * @return A CommandResult containing the success message and a list of stock entries sorted by quantity.","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" // Assertion: Check if the inventory is properly initialized","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":" assert inventory !\u003d null : \"Inventory should be initialized before executing ShowStockLevelCommand.\";","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" // Retrieve the list of drugs from the inventory","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" List\u003cStockEntry\u003e stockEntries \u003d inventory.getStockEntries();","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" // Check if the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntries.isEmpty()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" // Return a CommandResult indicating that the inventory is empty","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(\"The inventory is empty.\");","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" // Sort the stockEntries by quantity in ascending order","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" stockEntries.sort(Comparator.comparingLong(StockEntry::getQuantity));","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" // Create a new list to store the sorted stockEntries","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" List\u003cStockEntry\u003e arrangedListbyQuantity \u003d new ArrayList\u003c\u003e(stockEntries);","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_SUCCESS, arrangedListbyQuantity);","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"TeoHaoZhi":1,"Barbaracwx":46}},{"path":"src/main/java/seedu/stocker/commands/ViewCartCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" * Represents a command to list all drugs in the current cart.","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" * This command retrieves the list of drugs from the current cart and provides it as part of the command result.","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" * If the inventory is empty, it informs the user that the inventory has no drugs.","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"public class ViewCartCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" public static final String COMMAND_WORD \u003d \"viewcart\";","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_USAGE \u003d COMMAND_WORD","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" + \": View the current cart items.\" + System.lineSeparator()","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" + \"Example: \" + COMMAND_WORD;","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_SUCCESS \u003d \"Listed all the content of your cart. \";","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_FAILURE \u003d \"Your cart is empty. \";","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" * Execute the ViewCartCommand","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" public CommandResult execute() {","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" if (currentCart.isEmpty()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" return new CommandResult\u003c\u003e(MESSAGE_FAILURE);","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return new CommandResult(MESSAGE_SUCCESS, currentCart.getCurrentCart());","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":29,"TeoHaoZhi":1,"Barbaracwx":2}},{"path":"src/main/java/seedu/stocker/common/Messages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.common;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Container for user visible messages.","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class Messages {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_WELCOME \u003d \"Welcome to your Stocker!\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_GOODBYE \u003d \"Good bye!\";","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_INVALID_COMMAND_FORMAT \u003d \"Invalid command format! \\n%1$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_INVALID_QUANTITY \u003d \"A quantity must be an integer superior than 0.\\n\";","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_LOGIN_WELCOME \u003d \"Welcome! \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Key in register or login based on your needs \\n\"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" + \"1.Register user \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" + \"2.Login\";","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USERNAME_INPUT \u003d \"Enter your username:\";","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_PASSWORD_INPUT \u003d \"Enter Your Password:\";","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESSFUL_REGISTRATION \u003d \"Registration successful.\";","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_SUCCESSFUL_LOGIN \u003d \"Login successful.\";","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_INVALID_CHOICE \u003d \"Invalid Input, enter register or login only!\";","lastModifiedDate":"2023-10-20"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_USER_ALREADY_EXIST \u003d \"User already exists. Please make user with \"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" + \"different name or login instead\";","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_INVALID_USERNAME_OR_PASSWORD \u003d \"Invalid username or password. Please try again.\";","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_NO_BLANK_NAME_ALLOWED \u003d \"No blank name allowed. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Enter your desired username again\";","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_NO_BLANK_PASSWORD_ALLOWED \u003d \"No blank password allowed. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Enter your desired password again\";","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_INIT_FAILED \u003d \"Failed to initialise Stocker application. Exiting...\";","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" public static final String MESSAGE_EXECUTION_FAILED \u003d \"Exection of the command failed because of I/O error, \"","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" + \"please try later.\";","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" public static final String MESSAGE_INVALID_LOGIN_CHARACTER \u003d \" Do not include : in the username or password, enter\"","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" + \" another username or password\";","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":16,"TeoHaoZhi":19}},{"path":"src/main/java/seedu/stocker/drugs/Cart.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class Cart {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" private ArrayList\u003cCartEntry\u003e entries;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" public Cart() {","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" this.entries \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public void addEntry(String key, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" this.entries.add(new CartEntry(key, quantity));","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public List\u003cCartEntry\u003e getCurrentCart() {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" return this.entries;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" public boolean isEmpty() {","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" return entries.isEmpty();","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" public void checkOut(SalesList salesList, Inventory inventory) {","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" salesList.addSale(this);","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" for (CartEntry entry : entries) {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" inventory.removeFromStock(entry.getKey(), entry.getQuantity());","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" this.entries \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":32}},{"path":"src/main/java/seedu/stocker/drugs/CartEntry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"public class CartEntry {","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" private String key;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":" private long quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public CartEntry(String key, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" this.key \u003d key;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" public String getKey() {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" return this.key;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" public long getQuantity() {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" return this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" * Returns a string representation of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" * @return A string containing the key and quantity date of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return \"Key: \" + this.key","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" + \", Quantity: \" + this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":31}},{"path":"src/main/java/seedu/stocker/drugs/Description.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"public class Description {","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":" private static Map\u003cString, String\u003e descriptions \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" public static void addDescription(String drugName, String description) {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" descriptions.put(drugName, description);","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" public static String getDescription(String drugName) {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" return descriptions.get(drugName);","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" public static Map\u003cString, String\u003e getAllDescriptions() {","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" return descriptions;","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":21}},{"path":"src/main/java/seedu/stocker/drugs/Drug.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"public class Drug {","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":" public String name;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":" String expiryDate;","lastModifiedDate":"2023-10-08"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" public Drug(String name, String expiryDate) {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" this.expiryDate \u003d expiryDate;","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":" * Gets the name of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":" * @return The name of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" public String getName() {","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" return name;","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"azfarulmatin"},"content":" * Sets the name of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":" * @param name The new name to set for the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"azfarulmatin"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"azfarulmatin"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"azfarulmatin"},"content":" * Gets the expiry date of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"azfarulmatin"},"content":" * @return The expiry date of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":" public String getExpiryDate() {","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"azfarulmatin"},"content":" return expiryDate;","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"azfarulmatin"},"content":" * Sets the expiry date of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"azfarulmatin"},"content":" * @param expiryDate The new expiry date to set for the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"azfarulmatin"},"content":" public void setExpiryDate(String expiryDate) {","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"azfarulmatin"},"content":" this.expiryDate \u003d expiryDate;","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":48,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":50,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"azfarulmatin"},"content":" * Returns a string representation of the drug.","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"azfarulmatin"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" * @return A string containing the name and expiry date of the drug.","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"azfarulmatin"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":56,"author":{"gitId":"azfarulmatin"},"content":" public String toString() {","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" return \"Name: \" + name + \", Expiry Date: \" + expiryDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"martinschnder":5,"azfarulmatin":43,"TeoHaoZhi":11}},{"path":"src/main/java/seedu/stocker/drugs/Inventory.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"import java.util.List;","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.stream.Collectors;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.exceptions.DrugNotFoundException;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"public class Inventory {","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" public HashMap\u003cString, StockEntry\u003e stock;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public Inventory() {","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" this.stock \u003d new HashMap\u003cString, StockEntry\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" public void addNewDrug(String key, Drug drug, String serialNumber, long quantity) {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" this.stock.put(key, new StockEntry(drug, quantity, serialNumber));","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" public void removeFromStock(String key, long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" this.stock.get(key).decrQuantity(quantity);","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":25,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public List\u003cStockEntry\u003e getStockEntries() {","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" return this.stock.values().stream()","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" .collect(Collectors.toCollection(ArrayList::new));","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" public StockEntry deleteDrug(String key) throws DrugNotFoundException {","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" if (this.stock.containsKey(key)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" return stock.remove(key);","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":" throw new DrugNotFoundException(\"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" public StockEntry getStockEntry(String drugName) {","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" for (StockEntry stockEntry : stock.values()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" if (stockEntry.getDrug().getName().equalsIgnoreCase(drugName)) {","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" return stockEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" return null; // Drug not found in inventory","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":33,"azfarulmatin":5,"Barbaracwx":10}},{"path":"src/main/java/seedu/stocker/drugs/SalesList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class SalesList {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" private ArrayList\u003cCart\u003e validatedCarts;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":" public SalesList() {","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":" this.validatedCarts \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public void addSale(Cart cart) {","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" this.validatedCarts.add(cart);","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" public List\u003cCart\u003e getAllSales() {","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" return this.validatedCarts;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":22}},{"path":"src/main/java/seedu/stocker/drugs/StockEntry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.drugs;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"public class StockEntry {","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":" private final Drug drug;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"azfarulmatin"},"content":" private final String serialNumber; // Add serial number field","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" private long quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":" private long thresholdQuantity;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"azfarulmatin"},"content":" public StockEntry(Drug drug, long quantity, String serialNumber) {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" this.drug \u003d drug;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":" this.serialNumber \u003d serialNumber; // Initialise serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" this.thresholdQuantity \u003d 100;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" public String getSerialNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" return this.serialNumber; // Getter for serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" public Drug getDrug() {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" return this.drug;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" public long getQuantity() {","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" return this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"martinschnder"},"content":" public void setQuantity(long quantity) {","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" this.quantity \u003d quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" public void setThresholdQuantity(long thresholdQuantity) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" this.thresholdQuantity \u003d thresholdQuantity;","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" public long getThresholdQuantity() {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" return this.thresholdQuantity;","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":" public void incrQuantity(long delta) {","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" this.quantity +\u003d delta;","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"martinschnder"},"content":" public void decrQuantity(long delta) {","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":" assert(this.quantity \u003e delta);","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" this.quantity -\u003d delta;","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":" * Returns a string representation of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" * @return A string containing the key and quantity date of the stock entry.","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" return \"Name: \" + this.drug.getName()","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":" + \", Expiry date: \" + this.drug.getExpiryDate()","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" + \", Quantity: \" + this.quantity;","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":44,"azfarulmatin":7,"Barbaracwx":11}},{"path":"src/main/java/seedu/stocker/exceptions/DrugNotFoundException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.exceptions;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Signals that the drug has not been found in a specific list.","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class DrugNotFoundException extends Exception {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" public DrugNotFoundException(String message) {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" super(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":10}},{"path":"src/main/java/seedu/stocker/exceptions/InvalidDrugFormatException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.exceptions;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":" * Signals that the laod function cannot read the serialized drug.","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"public class InvalidDrugFormatException extends Exception {","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":" public InvalidDrugFormatException(String message) {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" super(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"martinschnder":10}},{"path":"src/main/java/seedu/stocker/exceptions/StockerException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.exceptions;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"public class StockerException extends Exception{","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"TeoHaoZhi":4}},{"path":"src/main/java/seedu/stocker/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.parser;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.DeleteCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ExitCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.FindCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.HelpCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.IncorrectCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.LoginCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.RegisterCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.SaveCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddVendorCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ShowStockLevelCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ViewCartCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddToCartCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.CheckOutCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListVendorCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.SetThresholdCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListThresholdCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddDescriptionCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.GetDescriptionCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListDescriptionsCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.AddVendorSupplyCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.FindVendorSupplyCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.commands.ListVendorSupplyCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_COMMAND_FORMAT;","lastModifiedDate":"2023-10-09"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_QUANTITY;","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":37,"author":{"gitId":"martinschnder"},"content":"public class Parser {","lastModifiedDate":"2023-10-09"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" public Parser() {","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":" * Parses user input into command for execution.","lastModifiedDate":"2023-10-09"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":44,"author":{"gitId":"martinschnder"},"content":" * @param userInput full user input string","lastModifiedDate":"2023-10-09"},{"lineNumber":45,"author":{"gitId":"martinschnder"},"content":" * @return the command based on the user input","lastModifiedDate":"2023-10-09"},{"lineNumber":46,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":" public Command parseCommand(String userInput) {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"martinschnder"},"content":" String[] words \u003d userInput.trim().split(\" \", 2); // split the input into command and arguments","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"martinschnder"},"content":" if (words.length \u003d\u003d 0) {","lastModifiedDate":"2023-10-09"},{"lineNumber":50,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, HelpCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-09"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" final String commandWord \u003d words[0];","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" final String arguments \u003d userInput.replaceFirst(commandWord, \"\").trim();","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" switch (commandWord) {","lastModifiedDate":"2023-10-09"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" case AddCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-09"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" return prepareAddCommand(arguments);","lastModifiedDate":"2023-10-09"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":60,"author":{"gitId":"Barbaracwx"},"content":" case FindCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"Barbaracwx"},"content":" return prepareFindCommand(arguments);","lastModifiedDate":"2023-10-20"},{"lineNumber":62,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"martinschnder"},"content":" case AddToCartCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"martinschnder"},"content":" return prepareAddToCartCommand(arguments);","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"karishma-t"},"content":" case AddDescriptionCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"karishma-t"},"content":" return prepareAddDescriptionCommand(arguments);","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"karishma-t"},"content":" case GetDescriptionCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"karishma-t"},"content":" return prepareGetDescriptionCommand(arguments);","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"karishma-t"},"content":" case AddVendorSupplyCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"karishma-t"},"content":" return prepareAddVendorSupplyCommand(arguments);","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"karishma-t"},"content":" case DeleteCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-17"},{"lineNumber":76,"author":{"gitId":"karishma-t"},"content":" return new DeleteCommand(arguments);","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"martinschnder"},"content":" case CheckOutCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"martinschnder"},"content":" return new CheckOutCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"martinschnder"},"content":" case ExitCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-09"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":" return new ExitCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":84,"author":{"gitId":"martinschnder"},"content":" case HelpCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-09"},{"lineNumber":85,"author":{"gitId":"martinschnder"},"content":" return new HelpCommand();","lastModifiedDate":"2023-10-09"},{"lineNumber":86,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":87,"author":{"gitId":"azfarulmatin"},"content":" case ListCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-14"},{"lineNumber":88,"author":{"gitId":"azfarulmatin"},"content":" return new ListCommand();","lastModifiedDate":"2023-10-14"},{"lineNumber":89,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":90,"author":{"gitId":"martinschnder"},"content":" case ViewCartCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"martinschnder"},"content":" return new ViewCartCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" case RegisterCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-20"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":" return new RegisterCommand();","lastModifiedDate":"2023-10-20"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":96,"author":{"gitId":"TeoHaoZhi"},"content":" case LoginCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-20"},{"lineNumber":97,"author":{"gitId":"TeoHaoZhi"},"content":" return new LoginCommand();","lastModifiedDate":"2023-10-20"},{"lineNumber":98,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":99,"author":{"gitId":"TeoHaoZhi"},"content":" case SaveCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-21"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":" return new SaveCommand();","lastModifiedDate":"2023-10-21"},{"lineNumber":101,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":102,"author":{"gitId":"TeoHaoZhi"},"content":" case AddVendorCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-28"},{"lineNumber":103,"author":{"gitId":"TeoHaoZhi"},"content":" return prepareAddVendorCommand(arguments);","lastModifiedDate":"2023-10-28"},{"lineNumber":104,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":105,"author":{"gitId":"Barbaracwx"},"content":" case ShowStockLevelCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"Barbaracwx"},"content":" return new ShowStockLevelCommand();","lastModifiedDate":"2023-10-28"},{"lineNumber":107,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" case ListVendorCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-28"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" return new ListVendorCommand();","lastModifiedDate":"2023-10-28"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":111,"author":{"gitId":"Barbaracwx"},"content":" case SetThresholdCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-29"},{"lineNumber":112,"author":{"gitId":"Barbaracwx"},"content":" return prepareSetThresholdCommand(arguments);","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":114,"author":{"gitId":"Barbaracwx"},"content":" case ListThresholdCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"Barbaracwx"},"content":" return new ListThresholdCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"karishma-t"},"content":" case ListDescriptionsCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"karishma-t"},"content":" return new ListDescriptionsCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"karishma-t"},"content":" case ListVendorSupplyCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"karishma-t"},"content":" return new ListVendorSupplyCommand(arguments);","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"karishma-t"},"content":" case FindVendorSupplyCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"karishma-t"},"content":" return new FindVendorSupplyCommand(arguments);","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"martinschnder"},"content":" default:","lastModifiedDate":"2023-10-09"},{"lineNumber":127,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, HelpCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-09"},{"lineNumber":128,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":129,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":130,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":131,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":132,"author":{"gitId":"martinschnder"},"content":" * Parses arguments in the context of the add drug command.","lastModifiedDate":"2023-10-09"},{"lineNumber":133,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":134,"author":{"gitId":"martinschnder"},"content":" * @param args full command args string","lastModifiedDate":"2023-10-09"},{"lineNumber":135,"author":{"gitId":"martinschnder"},"content":" * @return the prepared command","lastModifiedDate":"2023-10-09"},{"lineNumber":136,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":137,"author":{"gitId":"martinschnder"},"content":" private Command prepareAddCommand(String args) {","lastModifiedDate":"2023-10-09"},{"lineNumber":138,"author":{"gitId":"martinschnder"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":139,"author":{"gitId":"azfarulmatin"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /d (.*) /s (.*) /q (.*)\");","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"martinschnder"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-09"},{"lineNumber":141,"author":{"gitId":"azfarulmatin"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 4) {","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"martinschnder"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-09"},{"lineNumber":143,"author":{"gitId":"martinschnder"},"content":" String expiryDate \u003d matcher.group(2);","lastModifiedDate":"2023-10-09"},{"lineNumber":144,"author":{"gitId":"azfarulmatin"},"content":" String serialNumber \u003d matcher.group(3);","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"azfarulmatin"},"content":" Long quantity \u003d Long.parseLong(matcher.group(4));","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"martinschnder"},"content":" if (quantity \u003c 1) {","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_QUANTITY, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"azfarulmatin"},"content":" return new AddCommand(name, expiryDate, serialNumber, quantity);","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-09"},{"lineNumber":151,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-09"},{"lineNumber":152,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":153,"author":{"gitId":"martinschnder"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":154,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-23"},{"lineNumber":155,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":156,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":157,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":158,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":159,"author":{"gitId":"martinschnder"},"content":" * Parses arguments in the context of the add drug to cart command.","lastModifiedDate":"2023-10-23"},{"lineNumber":160,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":161,"author":{"gitId":"martinschnder"},"content":" * @param args full command args string","lastModifiedDate":"2023-10-23"},{"lineNumber":162,"author":{"gitId":"martinschnder"},"content":" * @return the prepared command","lastModifiedDate":"2023-10-23"},{"lineNumber":163,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":164,"author":{"gitId":"martinschnder"},"content":" private Command prepareAddToCartCommand(String args) {","lastModifiedDate":"2023-10-23"},{"lineNumber":165,"author":{"gitId":"martinschnder"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /q (.*)\");","lastModifiedDate":"2023-10-23"},{"lineNumber":166,"author":{"gitId":"martinschnder"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-23"},{"lineNumber":167,"author":{"gitId":"martinschnder"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 2) {","lastModifiedDate":"2023-10-23"},{"lineNumber":168,"author":{"gitId":"martinschnder"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-23"},{"lineNumber":169,"author":{"gitId":"Barbaracwx"},"content":" long quantity \u003d Long.parseLong(matcher.group(2));","lastModifiedDate":"2023-10-28"},{"lineNumber":170,"author":{"gitId":"martinschnder"},"content":" if (quantity \u003c 1) {","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"martinschnder"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_QUANTITY, AddCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":173,"author":{"gitId":"martinschnder"},"content":" return new AddToCartCommand(name, quantity);","lastModifiedDate":"2023-10-23"},{"lineNumber":174,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":175,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddToCartCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-29"},{"lineNumber":176,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":177,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":178,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":179,"author":{"gitId":"Barbaracwx"},"content":" private Command prepareFindCommand(String args) {","lastModifiedDate":"2023-10-20"},{"lineNumber":180,"author":{"gitId":"Barbaracwx"},"content":" String[] findArgs \u003d args.split(\" \", 2);","lastModifiedDate":"2023-10-20"},{"lineNumber":181,"author":{"gitId":"Barbaracwx"},"content":" if (findArgs.length \u003d\u003d 2) {","lastModifiedDate":"2023-10-20"},{"lineNumber":182,"author":{"gitId":"Barbaracwx"},"content":" String criterion \u003d findArgs[0];","lastModifiedDate":"2023-10-20"},{"lineNumber":183,"author":{"gitId":"Barbaracwx"},"content":" String keyword \u003d findArgs[1];","lastModifiedDate":"2023-10-20"},{"lineNumber":184,"author":{"gitId":"azfarulmatin"},"content":" if (criterion.equals(\"/n\") || criterion.equals(\"/d\") || criterion.equals(\"/s\")) {","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"Barbaracwx"},"content":" return new FindCommand(keyword, criterion);","lastModifiedDate":"2023-10-20"},{"lineNumber":186,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-20"},{"lineNumber":187,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, FindCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-20"},{"lineNumber":188,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":189,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-20"},{"lineNumber":190,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, FindCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-20"},{"lineNumber":191,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":192,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":193,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"martinschnder"},"content":" private Command prepareAddVendorCommand(String args) {","lastModifiedDate":"2023-11-02"},{"lineNumber":195,"author":{"gitId":"TeoHaoZhi"},"content":" String[] vendorArgs \u003d args.split(\" \", 1);","lastModifiedDate":"2023-10-28"},{"lineNumber":196,"author":{"gitId":"TeoHaoZhi"},"content":" String vendorName \u003d vendorArgs[0];","lastModifiedDate":"2023-10-28"},{"lineNumber":197,"author":{"gitId":"TeoHaoZhi"},"content":" if (vendorName.equals(null) || vendorName.equals(\"\") || vendorName.equals(\" \")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":198,"author":{"gitId":"TeoHaoZhi"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT, AddVendorCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-28"},{"lineNumber":199,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":200,"author":{"gitId":"TeoHaoZhi"},"content":" return new AddVendorCommand(vendorName);","lastModifiedDate":"2023-10-28"},{"lineNumber":201,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":202,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"Barbaracwx"},"content":" private Command prepareSetThresholdCommand(String args) {","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"Barbaracwx"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"Barbaracwx"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /tq (.*)\");","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"Barbaracwx"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"Barbaracwx"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 2) {","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"Barbaracwx"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"Barbaracwx"},"content":" Long threshold \u003d Long.parseLong(matcher.group(2));","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"Barbaracwx"},"content":" return new SetThresholdCommand(name, threshold);","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"Barbaracwx"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"Barbaracwx"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"Barbaracwx"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"karishma-t"},"content":" private Command prepareAddDescriptionCommand(String args) {","lastModifiedDate":"2023-10-30"},{"lineNumber":222,"author":{"gitId":"karishma-t"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*) /desc (.*)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":223,"author":{"gitId":"karishma-t"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-30"},{"lineNumber":224,"author":{"gitId":"karishma-t"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 2) {","lastModifiedDate":"2023-10-30"},{"lineNumber":225,"author":{"gitId":"karishma-t"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":226,"author":{"gitId":"karishma-t"},"content":" String description \u003d matcher.group(2);","lastModifiedDate":"2023-10-30"},{"lineNumber":227,"author":{"gitId":"karishma-t"},"content":" if (name !\u003d null \u0026\u0026 !name.isEmpty() \u0026\u0026 description !\u003d null \u0026\u0026 !description.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":228,"author":{"gitId":"karishma-t"},"content":" return new AddDescriptionCommand(name, description);","lastModifiedDate":"2023-10-30"},{"lineNumber":229,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":230,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":231,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":232,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":234,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":235,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":236,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":237,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":238,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":239,"author":{"gitId":"karishma-t"},"content":" private Command prepareGetDescriptionCommand(String args) {","lastModifiedDate":"2023-10-30"},{"lineNumber":240,"author":{"gitId":"karishma-t"},"content":" Pattern pattern \u003d Pattern.compile(\"/n (.*)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":241,"author":{"gitId":"karishma-t"},"content":" Matcher matcher \u003d pattern.matcher(args);","lastModifiedDate":"2023-10-30"},{"lineNumber":242,"author":{"gitId":"karishma-t"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 1) {","lastModifiedDate":"2023-10-30"},{"lineNumber":243,"author":{"gitId":"karishma-t"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":244,"author":{"gitId":"karishma-t"},"content":" if (name !\u003d null \u0026\u0026 !name.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"karishma-t"},"content":" return new GetDescriptionCommand(name);","lastModifiedDate":"2023-10-30"},{"lineNumber":246,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":248,"author":{"gitId":"karishma-t"},"content":" GetDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":249,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":250,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":251,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-30"},{"lineNumber":252,"author":{"gitId":"karishma-t"},"content":" GetDescriptionCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-30"},{"lineNumber":253,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":254,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":255,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":256,"author":{"gitId":"karishma-t"},"content":" private Command prepareAddVendorSupplyCommand(String args) {","lastModifiedDate":"2023-10-31"},{"lineNumber":257,"author":{"gitId":"karishma-t"},"content":" String[] parts \u003d args.trim().split(\" \", 2);","lastModifiedDate":"2023-10-31"},{"lineNumber":258,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":259,"author":{"gitId":"karishma-t"},"content":" if (parts.length \u003d\u003d 2) {","lastModifiedDate":"2023-10-31"},{"lineNumber":260,"author":{"gitId":"karishma-t"},"content":" String vendorName \u003d parts[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":261,"author":{"gitId":"karishma-t"},"content":" String drugName \u003d parts[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":263,"author":{"gitId":"karishma-t"},"content":" return new AddVendorSupplyCommand(vendorName, drugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":264,"author":{"gitId":"karishma-t"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":265,"author":{"gitId":"karishma-t"},"content":" return new IncorrectCommand(String.format(MESSAGE_INVALID_COMMAND_FORMAT,","lastModifiedDate":"2023-10-31"},{"lineNumber":266,"author":{"gitId":"karishma-t"},"content":" AddVendorSupplyCommand.MESSAGE_USAGE));","lastModifiedDate":"2023-10-31"},{"lineNumber":267,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":268,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":269,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":270,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":271,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"karishma-t":98,"martinschnder":91,"azfarulmatin":10,"TeoHaoZhi":25,"Barbaracwx":47}},{"path":"src/main/java/seedu/stocker/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.storage;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-21"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-21"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.exceptions.InvalidDrugFormatException;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.BufferedWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.File;","lastModifiedDate":"2023-10-21"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-21"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"/**","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" * Represents an object to handle writing to txt files and appending to them.","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":"public class Storage {","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" private Inventory inventory;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" public Storage(Inventory inventory) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" this.inventory \u003d inventory;","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" * Writes to the first line of a txt file","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" * can be used to clear a txt file as well.","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" * @param filePath relative path of file to write to","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" * @param textToAdd what to write to the file","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if invalid input is entered","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" public void writeToFile(String filePath, String textToAdd) throws IOException {","lastModifiedDate":"2023-10-21"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" FileWriter fw \u003d new FileWriter(filePath);","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-11"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" fw.close();","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":40,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"TeoHaoZhi"},"content":" * Appends given text to next line of txt file.","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" * @param filePath relative path of file to write to","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" * @param textToAppend what to write to the file","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if invalid input is given","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"TeoHaoZhi"},"content":" public void appendToFile(String filePath, String textToAppend) throws IOException {","lastModifiedDate":"2023-10-21"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":" BufferedWriter bf \u003d new BufferedWriter(new FileWriter(filePath,true));","lastModifiedDate":"2023-10-21"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" bf.write(textToAppend);","lastModifiedDate":"2023-10-11"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":" bf.newLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":" bf.close();","lastModifiedDate":"2023-10-11"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":53,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":54,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-21"},{"lineNumber":55,"author":{"gitId":"TeoHaoZhi"},"content":" * Loads drugs from txt file into inventory system.","lastModifiedDate":"2023-10-21"},{"lineNumber":56,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-21"},{"lineNumber":57,"author":{"gitId":"TeoHaoZhi"},"content":" * @param filePath Relative path to file containing list of drugs to be loaded.","lastModifiedDate":"2023-10-21"},{"lineNumber":58,"author":{"gitId":"TeoHaoZhi"},"content":" * @throws IOException if file is not found","lastModifiedDate":"2023-10-21"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-21"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" public void loadFileContents(String filePath) throws IOException, InvalidDrugFormatException {","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"TeoHaoZhi"},"content":" File holder \u003d new File(\"./drugs.txt\");","lastModifiedDate":"2023-10-21"},{"lineNumber":62,"author":{"gitId":"TeoHaoZhi"},"content":" if (!holder.exists()) {","lastModifiedDate":"2023-10-21"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":" holder.createNewFile();","lastModifiedDate":"2023-10-21"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":65,"author":{"gitId":"TeoHaoZhi"},"content":" File f \u003d new File(filePath);","lastModifiedDate":"2023-10-21"},{"lineNumber":66,"author":{"gitId":"TeoHaoZhi"},"content":" Scanner reader \u003d new Scanner(f);","lastModifiedDate":"2023-10-21"},{"lineNumber":67,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":68,"author":{"gitId":"azfarulmatin"},"content":" Pattern pattern \u003d Pattern.compile(","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" \"Name: (.*), Expiry Date: (.*), Serial Number: (.*), Quantity: (.*)\"","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"azfarulmatin"},"content":" );","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":" while (reader.hasNextLine()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"martinschnder"},"content":" Matcher matcher \u003d pattern.matcher(reader.nextLine());","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"azfarulmatin"},"content":" if (matcher.matches() \u0026\u0026 matcher.groupCount() \u003d\u003d 4) {","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"martinschnder"},"content":" String name \u003d matcher.group(1);","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"martinschnder"},"content":" String expiryDate \u003d matcher.group(2);","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"azfarulmatin"},"content":" String serialNumber \u003d matcher.group(3); // Extract serial number","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"azfarulmatin"},"content":" Long quantity \u003d Long.parseLong(matcher.group(4));","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":79,"author":{"gitId":"martinschnder"},"content":" Drug drug \u003d new Drug(name, expiryDate);","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(name, drug, serialNumber, quantity);","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"martinschnder"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":" throw new InvalidDrugFormatException(\"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-21"},{"lineNumber":86,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":88,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"martinschnder":22,"azfarulmatin":6,"TeoHaoZhi":60}},{"path":"src/main/java/seedu/stocker/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import java.io.InputStream;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.Optional;","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.commands.CommandResult;","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_USERNAME_INPUT;","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_USER_ALREADY_EXIST;","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_LOGIN_WELCOME;","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_SUCCESSFUL_LOGIN;","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_NO_BLANK_NAME_ALLOWED;","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_NO_BLANK_PASSWORD_ALLOWED;","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_PASSWORD_INPUT;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_WELCOME;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_CHOICE;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_GOODBYE;","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_USERNAME_OR_PASSWORD;","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_SUCCESSFUL_REGISTRATION;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INIT_FAILED;","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_EXECUTION_FAILED;","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_LOGIN_CHARACTER;","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":"public class Ui {","lastModifiedDate":"2023-10-08"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * Offset required to convert between 1-indexing and 0-indexing.","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"martinschnder"},"content":" public static final int DISPLAYED_INDEX_OFFSET \u003d 1;","lastModifiedDate":"2023-10-09"},{"lineNumber":35,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" * A decorative prefix added to the beginning of lines printed by Jerry","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":" private static final String LINE_PREFIX \u003d \"|| \";","lastModifiedDate":"2023-10-09"},{"lineNumber":40,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":41,"author":{"gitId":"martinschnder"},"content":" private static final String DIVIDER \u003d \"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\";","lastModifiedDate":"2023-10-09"},{"lineNumber":42,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"TeoHaoZhi"},"content":" * A platform independent line separator.","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"martinschnder"},"content":" private static final String LS \u003d System.lineSeparator();","lastModifiedDate":"2023-10-09"},{"lineNumber":47,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":48,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"TeoHaoZhi"},"content":" * Format of indexed list item","lastModifiedDate":"2023-10-14"},{"lineNumber":50,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"martinschnder"},"content":" private static final String MESSAGE_INDEXED_LIST_ITEM \u003d \"\\t%1$d. %2$s\";","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" private final Scanner in;","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" private final PrintStream out;","lastModifiedDate":"2023-10-09"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":56,"author":{"gitId":"TeoHaoZhi"},"content":" public Ui() {","lastModifiedDate":"2023-10-08"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" this(System.in, System.out);","lastModifiedDate":"2023-10-09"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":59,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" public Ui(InputStream in, PrintStream out) {","lastModifiedDate":"2023-10-09"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" this.in \u003d new Scanner(in);","lastModifiedDate":"2023-10-09"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":" this.out \u003d out;","lastModifiedDate":"2023-10-09"},{"lineNumber":63,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":64,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":65,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":66,"author":{"gitId":"martinschnder"},"content":" * Prompts for the command and reads the text entered by the user.","lastModifiedDate":"2023-10-09"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" * Ignores empty, pure whitespace, and comment lines.","lastModifiedDate":"2023-10-09"},{"lineNumber":68,"author":{"gitId":"martinschnder"},"content":" * Echos the command back to the user.","lastModifiedDate":"2023-10-09"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"martinschnder"},"content":" * @return command (full line) entered by the user","lastModifiedDate":"2023-10-09"},{"lineNumber":71,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":72,"author":{"gitId":"martinschnder"},"content":" public String getUserCommand() {","lastModifiedDate":"2023-10-09"},{"lineNumber":73,"author":{"gitId":"martinschnder"},"content":" out.print(LINE_PREFIX + \"Enter command: \");","lastModifiedDate":"2023-10-09"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":" String fullUserInput \u003d in.nextLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":75,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":" return fullUserInput;","lastModifiedDate":"2023-10-14"},{"lineNumber":77,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":79,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":80,"author":{"gitId":"TeoHaoZhi"},"content":" * Shows message(s) to the user","lastModifiedDate":"2023-10-14"},{"lineNumber":81,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":82,"author":{"gitId":"martinschnder"},"content":" public void showToUser(String... message) {","lastModifiedDate":"2023-10-09"},{"lineNumber":83,"author":{"gitId":"martinschnder"},"content":" for (String m : message) {","lastModifiedDate":"2023-10-09"},{"lineNumber":84,"author":{"gitId":"martinschnder"},"content":" out.println(LINE_PREFIX + m.replace(\"\\n\", LS + LINE_PREFIX));","lastModifiedDate":"2023-10-09"},{"lineNumber":85,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":86,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":88,"author":{"gitId":"TeoHaoZhi"},"content":" public void showLoginMessage() {","lastModifiedDate":"2023-10-12"},{"lineNumber":89,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(DIVIDER, MESSAGE_LOGIN_WELCOME, DIVIDER);","lastModifiedDate":"2023-10-12"},{"lineNumber":90,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":91,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":92,"author":{"gitId":"TeoHaoZhi"},"content":" public void showUsernameMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_USERNAME_INPUT);","lastModifiedDate":"2023-10-14"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":96,"author":{"gitId":"martinschnder"},"content":" public void showExecutionFailedMessage() {","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_EXECUTION_FAILED);","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"TeoHaoZhi"},"content":" public void showPasswordMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":101,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_PASSWORD_INPUT);","lastModifiedDate":"2023-10-14"},{"lineNumber":102,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":103,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":104,"author":{"gitId":"TeoHaoZhi"},"content":" public void showSuccessfulRegistrationMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":105,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_SUCCESSFUL_REGISTRATION);","lastModifiedDate":"2023-10-14"},{"lineNumber":106,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":107,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" public void showSuccessfulLoginMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_SUCCESSFUL_LOGIN);","lastModifiedDate":"2023-10-14"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":111,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":112,"author":{"gitId":"TeoHaoZhi"},"content":" public void showInvalidChoiceMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":113,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_INVALID_CHOICE);","lastModifiedDate":"2023-10-14"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":116,"author":{"gitId":"TeoHaoZhi"},"content":" public void showUserAlreadyExistMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":117,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_USER_ALREADY_EXIST);","lastModifiedDate":"2023-10-14"},{"lineNumber":118,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":119,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":120,"author":{"gitId":"TeoHaoZhi"},"content":" public void showEnterChoiceAgainMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":121,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_LOGIN_WELCOME);","lastModifiedDate":"2023-10-14"},{"lineNumber":122,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":123,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":124,"author":{"gitId":"TeoHaoZhi"},"content":" public void showInvalidUsernameOrPasswordMessage() {","lastModifiedDate":"2023-10-14"},{"lineNumber":125,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_INVALID_USERNAME_OR_PASSWORD);","lastModifiedDate":"2023-10-14"},{"lineNumber":126,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":127,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":128,"author":{"gitId":"TeoHaoZhi"},"content":" public void showBlankNameMessage() {","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_NO_BLANK_NAME_ALLOWED);","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"TeoHaoZhi"},"content":" public void showBlankPasswordMessage() {","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"TeoHaoZhi"},"content":" showToUser(MESSAGE_NO_BLANK_PASSWORD_ALLOWED);","lastModifiedDate":"2023-10-15"},{"lineNumber":134,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"martinschnder"},"content":" public void showWelcomeMessage() {","lastModifiedDate":"2023-10-09"},{"lineNumber":137,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_WELCOME, DIVIDER, DIVIDER);","lastModifiedDate":"2023-10-09"},{"lineNumber":138,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":139,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":140,"author":{"gitId":"TeoHaoZhi"},"content":" public void showInvalidLoginCharacterMessage(){showToUser(MESSAGE_INVALID_LOGIN_CHARACTER);}","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"martinschnder"},"content":" public void showGoodbyeMessage() {","lastModifiedDate":"2023-10-09"},{"lineNumber":143,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_GOODBYE, DIVIDER, DIVIDER);","lastModifiedDate":"2023-10-09"},{"lineNumber":144,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":145,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":146,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":147,"author":{"gitId":"martinschnder"},"content":" * Shows the result of a command execution to the user. Includes additional formatting to demarcate different","lastModifiedDate":"2023-10-09"},{"lineNumber":148,"author":{"gitId":"martinschnder"},"content":" * command execution segments.","lastModifiedDate":"2023-10-09"},{"lineNumber":149,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":150,"author":{"gitId":"martinschnder"},"content":" public \u003cT\u003evoid showResultToUser(CommandResult\u003cT\u003e result) {","lastModifiedDate":"2023-10-23"},{"lineNumber":151,"author":{"gitId":"martinschnder"},"content":" final Optional\u003cList\u003cT\u003e\u003e resultElements \u003d result.getRelevantElements();","lastModifiedDate":"2023-10-23"},{"lineNumber":152,"author":{"gitId":"martinschnder"},"content":" if (resultElements.isPresent()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":153,"author":{"gitId":"martinschnder"},"content":" showElementsListView(resultElements.get());","lastModifiedDate":"2023-10-23"},{"lineNumber":154,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":155,"author":{"gitId":"martinschnder"},"content":" showToUser(result.feedbackToUser, DIVIDER);","lastModifiedDate":"2023-10-09"},{"lineNumber":156,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":157,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":158,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":159,"author":{"gitId":"TeoHaoZhi"},"content":" * Shows a list of strings to the user, formatted as an indexed list.","lastModifiedDate":"2023-10-14"},{"lineNumber":160,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":161,"author":{"gitId":"martinschnder"},"content":" private void showToUserAsIndexedList(List\u003cString\u003e list) {","lastModifiedDate":"2023-10-09"},{"lineNumber":162,"author":{"gitId":"martinschnder"},"content":" showToUser(getIndexedListForViewing(list));","lastModifiedDate":"2023-10-09"},{"lineNumber":163,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":164,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":165,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":166,"author":{"gitId":"martinschnder"},"content":" * Shows a list of drugs to the user, formatted as an indexed list.","lastModifiedDate":"2023-10-09"},{"lineNumber":167,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":168,"author":{"gitId":"martinschnder"},"content":" private \u003cT\u003evoid showElementsListView(List\u003cT\u003e elements) {","lastModifiedDate":"2023-10-23"},{"lineNumber":169,"author":{"gitId":"martinschnder"},"content":" final List\u003cString\u003e formattedElements \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":170,"author":{"gitId":"martinschnder"},"content":" for (int i \u003d 0; i \u003c elements.size(); i++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":171,"author":{"gitId":"martinschnder"},"content":" formattedElements.add(elements.get(i).toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":172,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":173,"author":{"gitId":"martinschnder"},"content":" showToUserAsIndexedList(formattedElements);","lastModifiedDate":"2023-10-23"},{"lineNumber":174,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-08"},{"lineNumber":175,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":176,"author":{"gitId":"martinschnder"},"content":" public void showInitFailedMessage() {","lastModifiedDate":"2023-10-23"},{"lineNumber":177,"author":{"gitId":"martinschnder"},"content":" showToUser(MESSAGE_INIT_FAILED, DIVIDER, DIVIDER);","lastModifiedDate":"2023-10-23"},{"lineNumber":178,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":179,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":180,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-14"},{"lineNumber":181,"author":{"gitId":"TeoHaoZhi"},"content":" * Formats a list of strings as a viewable indexed list.","lastModifiedDate":"2023-10-14"},{"lineNumber":182,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-14"},{"lineNumber":183,"author":{"gitId":"martinschnder"},"content":" public static String getIndexedListForViewing(List\u003cString\u003e listItems) {","lastModifiedDate":"2023-10-10"},{"lineNumber":184,"author":{"gitId":"martinschnder"},"content":" final StringBuilder formatted \u003d new StringBuilder();","lastModifiedDate":"2023-10-09"},{"lineNumber":185,"author":{"gitId":"martinschnder"},"content":" int displayIndex \u003d DISPLAYED_INDEX_OFFSET;","lastModifiedDate":"2023-10-09"},{"lineNumber":186,"author":{"gitId":"martinschnder"},"content":" for (String listItem : listItems) {","lastModifiedDate":"2023-10-09"},{"lineNumber":187,"author":{"gitId":"martinschnder"},"content":" formatted.append(getIndexedListItem(displayIndex, listItem)).append(LS);","lastModifiedDate":"2023-10-11"},{"lineNumber":188,"author":{"gitId":"martinschnder"},"content":" displayIndex++;","lastModifiedDate":"2023-10-09"},{"lineNumber":189,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":190,"author":{"gitId":"martinschnder"},"content":" return formatted.toString();","lastModifiedDate":"2023-10-09"},{"lineNumber":191,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":192,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":193,"author":{"gitId":"martinschnder"},"content":" /**","lastModifiedDate":"2023-10-09"},{"lineNumber":194,"author":{"gitId":"martinschnder"},"content":" * Formats a string as a viewable indexed list item.","lastModifiedDate":"2023-10-09"},{"lineNumber":195,"author":{"gitId":"martinschnder"},"content":" *","lastModifiedDate":"2023-10-09"},{"lineNumber":196,"author":{"gitId":"martinschnder"},"content":" * @param visibleIndex visible index for this listing","lastModifiedDate":"2023-10-09"},{"lineNumber":197,"author":{"gitId":"martinschnder"},"content":" */","lastModifiedDate":"2023-10-09"},{"lineNumber":198,"author":{"gitId":"martinschnder"},"content":" private static String getIndexedListItem(int visibleIndex, String listItem) {","lastModifiedDate":"2023-10-09"},{"lineNumber":199,"author":{"gitId":"martinschnder"},"content":" return String.format(MESSAGE_INDEXED_LIST_ITEM, visibleIndex, listItem);","lastModifiedDate":"2023-10-09"},{"lineNumber":200,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":201,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":202,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"martinschnder":100,"TeoHaoZhi":102}},{"path":"src/main/java/seedu/stocker/vendors/Vendor.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.vendors;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"public class Vendor {","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":" public String name;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":" public Vendor(String name) {","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" * Gets the name of the vendor.","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" * @return The name of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" public String getName() {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" return name;","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" * Sets the name of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" * @param name The new name to set for the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" * Returns a string representation of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" * @return A string containing the name of the vendor.","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"TeoHaoZhi"},"content":" @Override","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"TeoHaoZhi"},"content":" public String toString() {","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"TeoHaoZhi"},"content":" return \"Name: \" + name;","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"TeoHaoZhi":38}},{"path":"src/main/java/seedu/stocker/vendors/VendorSupplyList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.vendors;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" * Represents a class to manage the association between vendors and the drugs they supply.","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":"public class VendorSupplyList {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" private static final Map\u003cString, List\u003cString\u003e\u003e vendorSuppliedDrugs \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" * Adds a drug to a vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" * @param drugName The name of the drug to be added to the vendor\u0027s supply list.","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":" public static void addDrugToVendor(String vendorName, String drugName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":" vendorSuppliedDrugs.computeIfAbsent(vendorName, k -\u003e new ArrayList\u003c\u003e()).add(drugName);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":" * Retrieves the list of drugs supplied by a specific vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"karishma-t"},"content":" * @param vendorName The name of the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" * @return A list of drug names supplied by the vendor.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" public static List\u003cString\u003e getDrugsSuppliedByVendor(String vendorName) {","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"karishma-t"},"content":" return vendorSuppliedDrugs.getOrDefault(vendorName, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"karishma-t"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"karishma-t"},"content":" * Returns the mapping of vendors to the drugs they supply.","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"karishma-t"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"karishma-t"},"content":" * @return A map where each key (vendor name) is associated with a list of drugs they supply.","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"karishma-t"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"karishma-t"},"content":" public static Map\u003cString, List\u003cString\u003e\u003e getVendorSuppliedDrugs() {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"karishma-t"},"content":" return vendorSuppliedDrugs;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"karishma-t":42}},{"path":"src/main/java/seedu/stocker/vendors/VendorsList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.vendors;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"public class VendorsList {","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":" protected ArrayList\u003cVendor\u003e vendorArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" public VendorsList(){","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":" vendorArrayList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"TeoHaoZhi"},"content":" * Adds new vendor to vendor list","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" * @param vendor","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" public void addNewVendor(Vendor vendor){","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" vendorArrayList.add(vendor);","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" * Gets details of all vendors","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" * @return List vendor","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" public List\u003cVendor\u003e getVendorEntries() {","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":" return new ArrayList\u003c\u003e(this.vendorArrayList);","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"martinschnder":6,"TeoHaoZhi":24}},{"path":"src/test/java/seedu/stocker/StockerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker;","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"class StockerTest {","lastModifiedDate":"2023-10-08"},{"lineNumber":8,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":" public void sampleTest() {","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"TeoHaoZhi":2,"-":10}},{"path":"src/test/java/seedu/stocker/commands/AddCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-10"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-10"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-10"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":"class AddCommandTest {","lastModifiedDate":"2023-10-10"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" @Test","lastModifiedDate":"2023-10-10"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-10"},{"lineNumber":16,"author":{"gitId":"azfarulmatin"},"content":" AddCommand command \u003d new AddCommand(\"Paracetamol\", \"12/05/2024\", \"12345\",12L);","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" command.setData(new Inventory(), new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" String expectedOutput \u003d \"New drug added in the inventory: Paracetamol\";","lastModifiedDate":"2023-10-10"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" assertEquals(command.execute().feedbackToUser, new CommandResult(expectedOutput).feedbackToUser);","lastModifiedDate":"2023-10-10"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" assertEquals(command.execute().getRelevantElements(), new CommandResult(expectedOutput).getRelevantElements());","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-10"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-10"}],"authorContributionMap":{"martinschnder":21,"azfarulmatin":1}},{"path":"src/test/java/seedu/stocker/commands/AddDescriptionCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"public class AddDescriptionCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand command \u003d new AddDescriptionCommand(\"Panadol\", \"Pain Relief\");","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" CommandResult\u003cString\u003e result \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":" String feedbackMessage \u003d result.feedbackToUser;","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" assertEquals(\"New drug description added for Panadol: Pain Relief\", feedbackMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":17}},{"path":"src/test/java/seedu/stocker/commands/AddToCartCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"martinschnder"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"martinschnder"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"class AddToCartCommandTest {","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"martinschnder"},"content":" ","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" @Test","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" AddCommand command \u003d new AddCommand(\"Paracetamol\", \"12/05/2024\", \"12345\", 12L);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" Cart cart \u003d new Cart();","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"martinschnder"},"content":" assertEquals(0, cart.getCurrentCart().size());","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" SalesList salesList \u003d new SalesList();","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, salesList, cart, new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"martinschnder"},"content":" command.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"martinschnder"},"content":" AddToCartCommand command2 \u003d new AddToCartCommand(\"paracetamol\", 2L);","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" command2.setData(inventory, salesList, cart, new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" command2.execute();","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"martinschnder"},"content":" assertEquals(command2.execute().feedbackToUser, \"New drug added in the current cart: Paracetamol\");","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"martinschnder"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"martinschnder":27,"azfarulmatin":1}},{"path":"src/test/java/seedu/stocker/commands/DeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"class DeleteCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":" // Create an inventory and add a drug to it","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" Drug doliprane \u003d new Drug(\"Doliprane\", \"12/06/2035\");","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"doliprane\", doliprane, \"ABC1234\", 52L);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"karishma-t"},"content":" // Create a DeleteCommand for the drug","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"karishma-t"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(\"Doliprane\");","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"martinschnder"},"content":" deleteCommand.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"karishma-t"},"content":" // Test the execution of the DeleteCommand","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" String expectedOutput \u003d \"Drug removed from inventory: Doliprane\";","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"karishma-t"},"content":" assertEquals(deleteCommand.execute().feedbackToUser, expectedOutput);","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"karishma-t"},"content":" // Ensure that the drug is no longer in the inventory","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"martinschnder"},"content":" assertEquals(0, inventory.getStockEntries().size());","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"karishma-t":25,"martinschnder":7,"azfarulmatin":1}},{"path":"src/test/java/seedu/stocker/commands/FindCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"import static seedu.stocker.common.Messages.MESSAGE_INVALID_COMMAND_FORMAT;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" * JUnit test class for the FindCommand.","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":"class FindCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" * Tests the execution of the FindCommand with a keyword for drug names.","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestByName() {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" // Create an instance of FindCommand with a keyword","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":" FindCommand command \u003d new FindCommand(\"Pa\", \"/n\");","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" Drug drug2 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug2, \"PAN123\", 20L);","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" // Define expected output","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"1. Name: Panadol, Expiry date: 04/07/2030, Serial number: PAN123, Quantity: 20\"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"azfarulmatin"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with the modified inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" * Tests the execution of the FindCommand with a keyword for drug expiry dates.","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestByExpiryDate() {","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" // Create an instance of FindCommand with a keyword for expiry date","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":" FindCommand command \u003d new FindCommand(\"01/03/2027\", \"/d\");","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Paracetamol\", \"01/03/2027\");","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Paracetamol\", drug1, \"PARC124\", 12L);","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"Barbaracwx"},"content":" // Define expected output for drugs with matching expiry date","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"1. Name: Paracetamol, Expiry date: 01/03/2027, Serial number: PARC124, Quantity: 12\"","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"azfarulmatin"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"Barbaracwx"},"content":" \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"Barbaracwx"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with the modified inventory","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"Barbaracwx"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"Barbaracwx"},"content":" * Tests the execution of the FindCommand with a null keyword, expecting an invalid format message.","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"Barbaracwx"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestWithNullKeyword() {","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"Barbaracwx"},"content":" // Create an instance of FindCommand with a null keyword","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"Barbaracwx"},"content":" FindCommand command \u003d new FindCommand(\"\", \"/n\");","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"Barbaracwx"},"content":" // Define expected output for invalid format","lastModifiedDate":"2023-10-26"},{"lineNumber":90,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d String.format(MESSAGE_INVALID_COMMAND_FORMAT, FindCommand.MESSAGE_USAGE);","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"Barbaracwx"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with a null keyword","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"azfarulmatin"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"azfarulmatin"},"content":" * Tests the execution of the FindCommand with a keyword for drug serial numbers.","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"azfarulmatin"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"azfarulmatin"},"content":" @Test","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"azfarulmatin"},"content":" public void executeTestBySerialNumber() {","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"azfarulmatin"},"content":" // Create an instance of FindCommand with a keyword for serial number","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"azfarulmatin"},"content":" FindCommand command \u003d new FindCommand(\"SER123\", \"/s\");","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"azfarulmatin"},"content":" // Create a new inventory","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"azfarulmatin"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"azfarulmatin"},"content":" Drug drug3 \u003d new Drug(\"Aspirin\", \"02/05/2028\");","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Aspirin\", drug3, \"SER123\", 15L);","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"azfarulmatin"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"azfarulmatin"},"content":" // Define expected output for drugs with matching serial number","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"1. Name: Aspirin, Expiry date: 02/05/2028, Serial number: SER123, Quantity: 15\"","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"azfarulmatin"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"azfarulmatin"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"azfarulmatin"},"content":" \"Listed all drugs with the keyword in the inventory.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"azfarulmatin"},"content":" CommandResult actualResult \u003d command.execute();","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"azfarulmatin"},"content":" // Test the command\u0027s execute method with the modified inventory","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"azfarulmatin"},"content":" assertEquals(expectedOutput, actualResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"martinschnder":7,"azfarulmatin":33,"Barbaracwx":85}},{"path":"src/test/java/seedu/stocker/commands/GetDescriptionCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"karishma-t"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"karishma-t"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"karishma-t"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"karishma-t"},"content":"public class GetDescriptionCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"karishma-t"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"karishma-t"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"karishma-t"},"content":" AddDescriptionCommand addDescriptionCommand \u003d new AddDescriptionCommand(\"Panadol\", \"Pain Relief\");","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"karishma-t"},"content":" addDescriptionCommand.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"karishma-t"},"content":" GetDescriptionCommand command \u003d new GetDescriptionCommand(\"Panadol\");","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"karishma-t"},"content":" CommandResult\u003cString\u003e result \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"karishma-t"},"content":" String feedbackMessage \u003d result.feedbackToUser;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"karishma-t"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"karishma-t"},"content":" assertEquals(\"Pain Relief\", feedbackMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"karishma-t"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"karishma-t"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"karishma-t":20}},{"path":"src/test/java/seedu/stocker/commands/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TeoHaoZhi"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-10"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-10"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":5,"author":{"gitId":"TeoHaoZhi"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"class HelpCommandTest {","lastModifiedDate":"2023-10-10"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":" @Test","lastModifiedDate":"2023-10-10"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-10"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":" HelpCommand command \u003d new HelpCommand();","lastModifiedDate":"2023-10-10"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":" String expectedOutput \u003d System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" + \"add: Adds a new drug to the drug list. Parameters: NAME, EXPIRY DATE, SERIAL NUMBER, QUANTITY, \"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" + \"Example: add /n Doliprane /d 12/06/2035 /s ABC123 /q 52\"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":" + \"delete: Removes a drug from drug list. Parameters: Name \"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: delete \u003cDrug Name\u003e\"","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TeoHaoZhi"},"content":" + \"help: Shows program usage instructions. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: help\"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TeoHaoZhi"},"content":" + \"list: List all drug information that is being tracked by the system. \"","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: list\"","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" + \"stocklevel: List all drugs by quantity level tracked by the system in ascending order. \"","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: stocklevel\"","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TeoHaoZhi"},"content":" + \"find /n: Finds drug in inventory using name.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":39,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: find /n panadol\"","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":43,"author":{"gitId":"TeoHaoZhi"},"content":" + \"find /d: Finds drug in inventory using date.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":45,"author":{"gitId":"azfarulmatin"},"content":" + \"Example: find /d panadol\"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"azfarulmatin"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"azfarulmatin"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"azfarulmatin"},"content":" + \"find /s: Finds drug in inventory using serial number.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"azfarulmatin"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"azfarulmatin"},"content":" + \"Example: find /s ABC123\"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"martinschnder"},"content":" + \"addtocart: Adds a new drug to the current cart. Parameters: NAME, QUANTITY,\"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"martinschnder"},"content":" + \"Example: addtocart /n Doliprane /q 2\"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"martinschnder"},"content":" + \"checkout: Checks out current cart. Parameters:\"","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"martinschnder"},"content":" + \"Example: checkout\"","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"martinschnder"},"content":" + \"viewcart: View the current cart items.\"","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"martinschnder"},"content":" + \"Example: viewcart\"","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"martinschnder"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"TeoHaoZhi"},"content":" + \"login: Login new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":69,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":70,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: login\"","lastModifiedDate":"2023-10-20"},{"lineNumber":71,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":72,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":73,"author":{"gitId":"TeoHaoZhi"},"content":" + \"register: Register new user into system.\"","lastModifiedDate":"2023-10-20"},{"lineNumber":74,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":75,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: register\"","lastModifiedDate":"2023-10-20"},{"lineNumber":76,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":77,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-20"},{"lineNumber":78,"author":{"gitId":"TeoHaoZhi"},"content":" + \"save: Saves existing druglist that is loaded into inventory when system is booted up.\"","lastModifiedDate":"2023-10-21"},{"lineNumber":79,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-21"},{"lineNumber":80,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: save\"","lastModifiedDate":"2023-10-21"},{"lineNumber":81,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-21"},{"lineNumber":82,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-21"},{"lineNumber":83,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"TeoHaoZhi"},"content":" + \"addVendor: Adds a new vendor to the vendors list. Parameter: NAME\"","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: addVendor Moderna\"","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"TeoHaoZhi"},"content":" + \"listVendors: List all vendor information that is being tracked by the system.\"","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: listVendors\"","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"Barbaracwx"},"content":" + \"setthreshold: Set the threshold quantity for a drug. (default 100)\"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: setthreshold /n Doliprane /tq 50\"","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"Barbaracwx"},"content":" + \"listthreshold: List all drugs and their threshold levels.\"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"Barbaracwx"},"content":" + \"Example: listthreshold\"","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"Barbaracwx"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"TeoHaoZhi"},"content":" + \"bye: Exits the program.\"","lastModifiedDate":"2023-10-15"},{"lineNumber":109,"author":{"gitId":"TeoHaoZhi"},"content":" + System.getProperty(\"line.separator\")","lastModifiedDate":"2023-10-15"},{"lineNumber":110,"author":{"gitId":"TeoHaoZhi"},"content":" + \"Example: bye\";","lastModifiedDate":"2023-10-11"},{"lineNumber":111,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-10"},{"lineNumber":112,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":113,"author":{"gitId":"TeoHaoZhi"},"content":" assertEquals(new CommandResult(expectedOutput).feedbackToUser, command.execute().feedbackToUser);","lastModifiedDate":"2023-10-11"},{"lineNumber":114,"author":{"gitId":"TeoHaoZhi"},"content":" }","lastModifiedDate":"2023-10-10"},{"lineNumber":115,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-10"}],"authorContributionMap":{"martinschnder":15,"azfarulmatin":8,"TeoHaoZhi":71,"Barbaracwx":21}},{"path":"src/test/java/seedu/stocker/commands/ListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"azfarulmatin"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"azfarulmatin"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"azfarulmatin"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"azfarulmatin"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"//test for list","lastModifiedDate":"2023-10-17"},{"lineNumber":12,"author":{"gitId":"azfarulmatin"},"content":"class ListCommandTest {","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"azfarulmatin"},"content":" @Test","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"azfarulmatin"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"azfarulmatin"},"content":" ListCommand command \u003d new ListCommand();","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" command.setData(new Inventory(), new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"azfarulmatin"},"content":" String expectedOutput \u003d \"The inventory is empty.\";","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"azfarulmatin"},"content":" assertEquals( new CommandResult(expectedOutput).feedbackToUser,command.execute().feedbackToUser);","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"azfarulmatin"},"content":"}","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"azfarulmatin"},"content":"","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"martinschnder":4,"azfarulmatin":17,"Barbaracwx":1}},{"path":"src/test/java/seedu/stocker/commands/ListThresholdCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"public class ListThresholdCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN437\", 120);","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" Drug drug2 \u003d new Drug(\"paracetamol\", \"01/07/2020\");","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"paracetamol\", drug2, \"PARC578\", 50);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" // Create the SetThresholdCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" ListThresholdCommand command \u003d new ListThresholdCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" CommandResult initialResult \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" String expectedInitialOutput \u003d \"1. Panadol: 100\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" \"2. paracetamol: 100\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" \"Listed all drugs by threshold level in the inventory.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" // Test the command\u0027s execute method with a null keyword","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedInitialOutput, initialResult.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"martinschnder":2,"azfarulmatin":2,"Barbaracwx":37}},{"path":"src/test/java/seedu/stocker/commands/SetThresholdCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"public class SetThresholdCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN345\", 120);","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" // Create the SetThresholdCommand","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand command \u003d new SetThresholdCommand(\"Panadol\", 75);","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" // Set the modified inventory for the command","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"Threshold quantity set for Panadol: 75\";","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(command.execute().feedbackToUser, expectedOutput);","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestWithNoDrug() {","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN341\", 120);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":" // Create the SetThresholdCommand for a drug that doesn\u0027t exist","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" SetThresholdCommand command \u003d new SetThresholdCommand(\"Paracetamol\", 75);","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":" command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"Drug not found.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" // Check if the result indicates the drug was not found","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(command.execute().feedbackToUser, expectedOutput);","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"martinschnder":3,"azfarulmatin":2,"Barbaracwx":46}},{"path":"src/test/java/seedu/stocker/commands/StockLevelCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Barbaracwx"},"content":"package seedu.stocker.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"Barbaracwx"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Drug;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Inventory;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.SalesList;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"Barbaracwx"},"content":"import seedu.stocker.drugs.Cart;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"martinschnder"},"content":"import seedu.stocker.vendors.VendorsList;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"Barbaracwx"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"Barbaracwx"},"content":"//test for list","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"Barbaracwx"},"content":"class StockLevelCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"Barbaracwx"},"content":" public void executeTestEmpty(){","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"Barbaracwx"},"content":" ShowStockLevelCommand command \u003d new ShowStockLevelCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"Barbaracwx"},"content":" // Execute the command","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"Barbaracwx"},"content":" CommandResult result \u003d command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"The inventory is empty.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, result.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"Barbaracwx"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"Barbaracwx"},"content":" public void executeTest() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Barbaracwx"},"content":" // Create a new inventory","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"Barbaracwx"},"content":" Inventory inventory \u003d new Inventory();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"Barbaracwx"},"content":" Drug drug1 \u003d new Drug(\"Panadol\", \"04/07/2030\");","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"Panadol\", drug1, \"PAN947\",120);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"Barbaracwx"},"content":" Drug drug2 \u003d new Drug(\"paracetamol\", \"01/07/2020\");","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"paracetamol\", drug2, \"PARC347\",50);","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"Barbaracwx"},"content":" Drug drug3 \u003d new Drug(\"histamine\", \"09/05/2070\");","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"azfarulmatin"},"content":" inventory.addNewDrug(\"histamine\", drug3, \"HIS9447\",10);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"Barbaracwx"},"content":" ShowStockLevelCommand command \u003d new ShowStockLevelCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"martinschnder"},"content":" command.setData(inventory, new SalesList(), new Cart(), new VendorsList());","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"Barbaracwx"},"content":" // Execute the command","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"Barbaracwx"},"content":" CommandResult result \u003d command.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"Barbaracwx"},"content":" String expectedOutput \u003d \"1. Name: histamine, Expiry date: 09/05/2070, Quantity: 10\" +","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"Barbaracwx"},"content":" \"2. Name: paracetamol, Expiry date: 01/07/2020, Quantity: 50\" +","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"Barbaracwx"},"content":" \"3. Name: Panadol, Expiry date: 04/07/2030, Quantity: 120\" +","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"Barbaracwx"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"Barbaracwx"},"content":" \"Stock Level Report (Sorted by Quantity)\";","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"Barbaracwx"},"content":" assertEquals(expectedOutput, result.getFeedbackToUserFindTest());","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"Barbaracwx"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"Barbaracwx"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"Barbaracwx"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"martinschnder":3,"azfarulmatin":3,"Barbaracwx":51}},{"path":"src/test/java/seedu/stocker/ui/UiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"martinschnder"},"content":"package seedu.stocker.ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"TeoHaoZhi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":5,"author":{"gitId":"martinschnder"},"content":"import java.util.List;","lastModifiedDate":"2023-10-10"},{"lineNumber":6,"author":{"gitId":"martinschnder"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-10"},{"lineNumber":7,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":8,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":9,"author":{"gitId":"TeoHaoZhi"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-08"},{"lineNumber":10,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":11,"author":{"gitId":"TeoHaoZhi"},"content":"class UiTest {","lastModifiedDate":"2023-10-08"},{"lineNumber":12,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":13,"author":{"gitId":"martinschnder"},"content":" @Test","lastModifiedDate":"2023-10-10"},{"lineNumber":14,"author":{"gitId":"martinschnder"},"content":" public void getIndexedListForViewing_success() {","lastModifiedDate":"2023-10-10"},{"lineNumber":15,"author":{"gitId":"martinschnder"},"content":" String expectedOutput \u003d \"\\t1. Paracetamol\" + System.lineSeparator()","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"martinschnder"},"content":" + \"\\t2. Ibuprofene\" + System.lineSeparator()","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"martinschnder"},"content":" + \"\\t3. Doliprane\" + System.lineSeparator();","lastModifiedDate":"2023-10-11"},{"lineNumber":18,"author":{"gitId":"TeoHaoZhi"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":19,"author":{"gitId":"martinschnder"},"content":" List\u003cString\u003e input \u003d Arrays.asList(\"Paracetamol\", \"Ibuprofene\", \"Doliprane\");","lastModifiedDate":"2023-10-10"},{"lineNumber":20,"author":{"gitId":"martinschnder"},"content":" assertEquals(expectedOutput, new Ui().getIndexedListForViewing(input));","lastModifiedDate":"2023-10-10"},{"lineNumber":21,"author":{"gitId":"martinschnder"},"content":" }","lastModifiedDate":"2023-10-10"},{"lineNumber":22,"author":{"gitId":"TeoHaoZhi"},"content":"}","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"martinschnder":11,"TeoHaoZhi":11}},{"path":"text-ui-test/runtest.bat","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"@echo off","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"setlocal enableextensions","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"pushd %~dp0","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"call gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"cd build\\libs","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"for /f \"tokens\u003d*\" %%a in (","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" \u0027dir /b *.jar\u0027","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":") do (","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" set jarloc\u003d%%a","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":")","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":15,"author":{"gitId":"-"},"content":"java -jar %jarloc% \u003c ..\\..\\text-ui-test\\input.txt \u003e ..\\..\\text-ui-test\\ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":"cd ..\\..\\text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"TeoHaoZhi"},"content":"FC ACTUAL.TXT ACTUAL.TXT \u003eNUL \u0026\u0026 ECHO Test passed! || Echo Test failed!","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"TeoHaoZhi":1,"-":18}},{"path":"text-ui-test/runtest.sh","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"#!/usr/bin/env bash","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":"# change to script directory","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"cd \"${0%/*}\"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"./gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":"cd text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"java -jar $(find ../build/libs/ -mindepth 1 -print -quit) \u003c input.txt \u003e ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":"cp EXPECTED.TXT EXPECTED-UNIX.TXT","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"dos2unix EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"diff EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"TeoHaoZhi"},"content":"if [ ACTUAL.TXT \u003d\u003d ACTUAL.TXT ]","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"-"},"content":"then","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" echo \"Test passed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":19,"author":{"gitId":"-"},"content":" exit 0","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":"else","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" echo \"Test failed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":22,"author":{"gitId":"-"},"content":" exit 1","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":"fi","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"TeoHaoZhi":1,"-":22}}] diff --git a/AY2324S1-CS2113-T17-3_tp_master/commits.json b/AY2324S1-CS2113-T17-3_tp_master/commits.json index 5dd419e..0d2b9f8 100644 --- a/AY2324S1-CS2113-T17-3_tp_master/commits.json +++ b/AY2324S1-CS2113-T17-3_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"karishma-t":[{"date":"2023-10-05","commitResults":[{"hash":"9b179211347fe7a0942693aea92a880a72243999","isMergeCommit":false,"messageTitle":"Add files for Karishma about us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":4}}},{"hash":"ec15853438ef4adb88f2bbcc87f367804d35788d","isMergeCommit":false,"messageTitle":"Conflict resolution","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":2}}}]},{"date":"2023-10-17","commitResults":[{"hash":"5c174ca4cdfe79c6b173c68db27721f92aa0f615","isMergeCommit":false,"messageTitle":"Add delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":13}}},{"hash":"4c7d28ae3f51a16116cf790aabeb170d9ffaad80","isMergeCommit":false,"messageTitle":"Add junit test for Delete command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":30,"deletions":0}}},{"hash":"ed041352034696e09d01385f720d3f3a72037c62","isMergeCommit":false,"messageTitle":"Modify to pass checkstyle tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-26","commitResults":[{"hash":"521a48339b7e42ceb652e3e1d147a6c5b485792b","isMergeCommit":false,"messageTitle":"Modify DG for delete","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":53,"deletions":0}}}]},{"date":"2023-10-30","commitResults":[{"hash":"bfafb4228b1694b5d1e34b97c9e981d7b7c25285","isMergeCommit":false,"messageTitle":"Add get Description command, along with add and list descriptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":150,"deletions":0}}},{"hash":"14c00f9f407257d902ee1fc5b41f3b8837e51add","isMergeCommit":false,"messageTitle":"Add tests for Description commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":7},"test-code":{"insertions":62,"deletions":0}}},{"hash":"e90cefce6084595a3ffc0fe7af7bc3cea0bd9dbe","isMergeCommit":false,"messageTitle":"Add javadoc for description commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":1}}},{"hash":"6c6f99f910bff64f6740f28654e16f1cf44442ee","isMergeCommit":false,"messageTitle":"Modify List description","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":25}}}]},{"date":"2023-10-31","commitResults":[{"hash":"6673cb7b7b0ce43afd99ad5bde411c1ca86d1e20","isMergeCommit":false,"messageTitle":"Add drug supply association with vendors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":121,"deletions":25}}},{"hash":"7880445932393fc05082c5e19f46d4b9caea5c30","isMergeCommit":false,"messageTitle":"Add command to list drugs under specific vendor","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":55,"deletions":0}}},{"hash":"4afcee0830c4065f6824e923e01376481e496e66","isMergeCommit":false,"messageTitle":"Add command to find vendors that offer the drug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":0}}},{"hash":"86f7883888a58d6672906943f37616e413e09dab","isMergeCommit":false,"messageTitle":"Modify code style","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":5}}}]},{"date":"2023-11-01","commitResults":[{"hash":"806511b0b28de80ac737571f7ac70c10d11a63d2","isMergeCommit":false,"messageTitle":"Update UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":33},"docs":{"insertions":148,"deletions":2}}}]},{"date":"2023-11-02","commitResults":[{"hash":"2b8fc4273a248865a222da6964b8eb7e72c54867","isMergeCommit":false,"messageTitle":"Modify delete DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":52}}},{"hash":"e1c9c8aff38e13c0d146829693eeea98274cc8a9","isMergeCommit":false,"messageTitle":"Add addVendorSupply dg","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":0}}}]}],"martinschnder":[{"date":"2023-10-07","commitResults":[{"hash":"d13e4519f0e878a3e9be46a05a57ee90c57539c8","isMergeCommit":false,"messageTitle":"Add martin portofolio and picture and update about us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"2dbd0893fe8f3dac09ed84bb33c414c0e90c74e2","isMergeCommit":true,"messageTitle":"Merge pull request #12 from martinschnder/martin-AboutUs","messageBody":"Add martin portofolio and picture and update about us","fileTypesAndContributionMap":{}}]},{"date":"2023-10-09","commitResults":[{"hash":"eca592d2600d2253010eebbf55c4217a971ca79b","isMergeCommit":false,"messageTitle":"Updated build.gradle to match new main class name","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":2}}},{"hash":"f9bf0f4dcbf0dc02f210e21283f8f18ddf745d2a","isMergeCommit":false,"messageTitle":"Reorganize files in various packages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":9},"other":{"insertions":2,"deletions":2}}},{"hash":"dd4cb2baf5df643afbefe71a963a78e7489a79b2","isMergeCommit":false,"messageTitle":"Create abstract command class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":0}}},{"hash":"0a4ae29a7ca56b747974f29fc720e496c0cebaa3","isMergeCommit":false,"messageTitle":"Add the addclass and rename the druglist class to inventory","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":101,"deletions":19}}},{"hash":"9891fe1ce7e876b766da0e19a647588a3845d02d","isMergeCommit":false,"messageTitle":"Delete old file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":14}}},{"hash":"c76880c8d3ba9f7555f17105e6689822950877aa","isMergeCommit":false,"messageTitle":"Implement ExitCommand and AddCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":316,"deletions":18}}}]},{"date":"2023-10-10","commitResults":[{"hash":"dce79f9038b5eade80126270475b9775283d2fd2","isMergeCommit":false,"messageTitle":"Add ui and addcommand testing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":29,"deletions":1}}}]},{"date":"2023-10-11","commitResults":[{"hash":"8910d7979fdebe5386871de9ea2cda42c5161370","isMergeCommit":false,"messageTitle":"Change the line separator character","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"d0a83e9fe5ed5a7cc13594979f0803fa8e9a2374","isMergeCommit":false,"messageTitle":"Change the line separator character in the UI class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"55d760266b318ad23fbab35a6d1857c73c063d17","isMergeCommit":true,"messageTitle":"Merge pull request #34 from martinschnder/addDrug-unit-tests","messageBody":"Add ui and addcommand testing","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"7646870a909320f59cefb562285e62abc23ef833","isMergeCommit":false,"messageTitle":"Modify inventory structure and add all the command needed to make a sale (addtocart, viewcart, checkout)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":402,"deletions":131},"test-code":{"insertions":23,"deletions":15}}},{"hash":"1134e5d481615a014073af9031ca71061ff42878","isMergeCommit":false,"messageTitle":"Fix load function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":15}}},{"hash":"4e4ef4698675691973d77ae7481e1ee117537acf","isMergeCommit":false,"messageTitle":"Add better exception handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":18}}},{"hash":"a075bd1720fd4eac5e8c090a897225d5d2057e6d","isMergeCommit":false,"messageTitle":"Update helpcommand with new commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":4},"test-code":{"insertions":43,"deletions":28}}}]},{"date":"2023-10-24","commitResults":[{"hash":"0a64a48a68acc1accbbfec26dd81f3df9574df9c","isMergeCommit":false,"messageTitle":"Add tests for AddToCart command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":27,"deletions":0}}}]},{"date":"2023-10-25","commitResults":[{"hash":"b4d2647664ddb9696b52554ddbe328b730297a98","isMergeCommit":false,"messageTitle":"Add main data structures in developerGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":46,"deletions":21}}},{"hash":"18929947f4248686faad3b70fbff3687c9c19c3b","isMergeCommit":true,"messageTitle":"Merge pull request #84 from martinschnder/developerGuide","messageBody":"Add main data structures in developerGuide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"49bfbffa868b148a46b27908dabf16ebfd74cd63","isMergeCommit":true,"messageTitle":"Merge pull request #92 from Barbaracwx/findcommandtest","messageBody":"added sequence diagram","fileTypesAndContributionMap":{}},{"hash":"50d338b34b24893e5dca5485f21f08ff4ca6e60c","isMergeCommit":true,"messageTitle":"Merge pull request #113 from Barbaracwx/branch-alert","messageBody":"updated set threshold command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"c8ea029b8bb8841a1d03a2b39a283de6496b9a9f","isMergeCommit":false,"messageTitle":"Update UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":111,"deletions":48}}}]},{"date":"2023-11-02","commitResults":[{"hash":"425255dce9b64d5b7adfd020c0135a5bc1a2ca42","isMergeCommit":false,"messageTitle":"Remove all throwing methods in the main class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":55}}},{"hash":"486738273c17067cafbf9cbc51b53b71450b1b84","isMergeCommit":false,"messageTitle":"Try to resolve various warning","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":35},"test-code":{"insertions":20,"deletions":12}}},{"hash":"55909921078d98ae4e90faae54c91d9c6becf5a8","isMergeCommit":false,"messageTitle":"Resolve warning and make vendors non static","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5},"test-code":{"insertions":2,"deletions":2}}},{"hash":"992f613aabbf9fabc323cfdcf879efa4865ca463","isMergeCommit":false,"messageTitle":"Add negative number verifications","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}}]}],"azfarulmatin":[{"date":"2023-10-07","commitResults":[{"hash":"6c8ee942babd12a205caa1b7e098fcb6340f76a9","isMergeCommit":false,"messageTitle":"Update Azfarul About us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"05e7ef8ec96488ea4719dfc0372532fe8e5694de","isMergeCommit":true,"messageTitle":"Merge pull request #19 from azfarulmatin/master","messageBody":"Update Azfarul About us","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"d5afb6bfea43555f6f259a086b672acaefd20e59","isMergeCommit":false,"messageTitle":"Add List function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":110,"deletions":29}}},{"hash":"57a05c0bd5b98cc8b3bafc5eb9a158684e7aa058","isMergeCommit":true,"messageTitle":"Merge pull request #44 from azfarulmatin/AzfarulMatin-ListCommand","messageBody":"Add List function","fileTypesAndContributionMap":{}},{"hash":"4a24ed0a7c4ba4280e8279f225d94eca57adc5eb","isMergeCommit":false,"messageTitle":"Fix checkstyle and junit test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":15}}},{"hash":"a1860305e34b8c74ade793866b25205f953c8319","isMergeCommit":true,"messageTitle":"Merge pull request #45 from azfarulmatin/AzfarulMatin-ListCommand","messageBody":"Fix checkstyle and junit test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"1dda9d2754e2a02578da9238442c6d10f7e66d6f","isMergeCommit":false,"messageTitle":"Add JUnit Test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":16,"deletions":0}}},{"hash":"440fa5dc27d5fd869d27429012fdbe5aeeae7619","isMergeCommit":true,"messageTitle":"Merge pull request #46 from azfarulmatin/AzfarulMatin-JUnitTestListCommand","messageBody":"Add JUnit Test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"3887203ffba5c298294ab19aea34a4d3ed459f58","isMergeCommit":false,"messageTitle":"Add assertions for ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"09522dd36305e098a7b90627e22eb45576b25579","isMergeCommit":true,"messageTitle":"Merge pull request #65 from azfarulmatin/master","messageBody":"Add assertions for ListCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"48b64546002893200c17724ba054f54c1593848a","isMergeCommit":false,"messageTitle":"Update ListCommand in Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":40,"deletions":0}}},{"hash":"c9f60b4f7e954b7f51ac2623133f116e513fd8d7","isMergeCommit":true,"messageTitle":"Merge pull request #87 from azfarulmatin/AzfarulMatin-DeveloperGuide","messageBody":"Update ListCommand in Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"a57e18d43167b17701ee7f2f0a2fa2366ccbe792","isMergeCommit":false,"messageTitle":"Update Developer Guide for List Command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":43,"deletions":8}}},{"hash":"f2e1f1c92f4955beb411e4b859b6044305d188c2","isMergeCommit":true,"messageTitle":"Merge pull request #119 from azfarulmatin/AzfarulMatin-DeveloperGuide","messageBody":"Update Developer Guide for List Command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"b31032defcf1a8e158d8b709ffc66cb236fc1ea3","isMergeCommit":true,"messageTitle":"Merge pull request #121 from karishma-t/karishma-get-description","messageBody":"Karishma - Add, Get, List description for drugs","fileTypesAndContributionMap":{}},{"hash":"e4abf37899eeac2e917598439cdefe9ace9f81a1","isMergeCommit":false,"messageTitle":"Update Find Command to search by serial number","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":138,"deletions":25},"test-code":{"insertions":22,"deletions":17}}},{"hash":"cb423576f586c6b09ebff9a220536207048ff865","isMergeCommit":true,"messageTitle":"Merge pull request #124 from azfarulmatin/AzfarulMatin-DeveloperGuide","messageBody":"Update Find Command to search by serial number","fileTypesAndContributionMap":{}},{"hash":"b469c4477a98e3222fcde982982e690a022e7a61","isMergeCommit":false,"messageTitle":"Update find command using serial number in Developer Guide","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":67},"docs":{"insertions":3,"deletions":0},"test-code":{"insertions":4,"deletions":2}}},{"hash":"d79a23da5f33ed363f4c83d84be5eee1252cd220","isMergeCommit":true,"messageTitle":"Merge pull request #125 from azfarulmatin/AzfarulMatin-CalculatePrice","messageBody":"Update find command using serial number in Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"975a03f405177fbaff0b13ecc7d213afe118feb8","isMergeCommit":false,"messageTitle":"Add Command Result in Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":55,"deletions":0}}},{"hash":"6c56dc73e5388f0598b3ef14aa6e000f685eeac9","isMergeCommit":true,"messageTitle":"Merge pull request #131 from azfarulmatin/AzfarulMatin-CalculatePrice","messageBody":"Add Command Result in Developer Guide","fileTypesAndContributionMap":{}},{"hash":"f342fa41d871b865ee773890cbb3c656f1bbcf29","isMergeCommit":false,"messageTitle":"Update Junit Test for find command using serial number","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":28,"deletions":0}}},{"hash":"23547920ad37f08136bc44d0b10ec01ff11e6d53","isMergeCommit":false,"messageTitle":"Update ListCommand Junit Test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":0}}},{"hash":"13d04c0da53fabf622696bc69035e9703834110c","isMergeCommit":true,"messageTitle":"Merge pull request #132 from azfarulmatin/AzfarulMatin-CalculatePrice","messageBody":"Update FindCommand Junit Test for serial number","tags":["v2.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"f73462e9c005e2430a123344db281db3ed2ffc22","isMergeCommit":true,"messageTitle":"Merge pull request #133 from karishma-t/karishma-Developer-Guide","messageBody":"Modify delete DG","fileTypesAndContributionMap":{}}]}],"TeoHaoZhi":[{"date":"2023-10-05","commitResults":[{"hash":"f2bef309abc1a31812e5cb92d52cc3edc1ea44c6","isMergeCommit":false,"messageTitle":"Update UserGuide.md to add theme","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":0}}},{"hash":"80b42e7c9d1a437ae8bed5f38e44c218f440f47c","isMergeCommit":true,"messageTitle":"Merge pull request #2 from Barbaracwx/Barbaracwx-AboutUs","messageBody":"Added Barbara.md","fileTypesAndContributionMap":{}},{"hash":"aa9ba0c6a59865a89b52a6f53b7df1df57bb99de","isMergeCommit":false,"messageTitle":"Add files for Hao Zhi\u0027s about us page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"78381da48ea0ab8048ffca83fc47af7dd59e458b","isMergeCommit":true,"messageTitle":"Merge branch \u0027HaoZhi-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c0c3018bd7af6a34e46ede0867b55d0a498285ce","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5034d288227d95c1a28ecc2359f1ea357dd3b437","isMergeCommit":true,"messageTitle":"Merge pull request #3 from TeoHaoZhi/master","messageBody":"Add HaoZhi\u0027s about us files","fileTypesAndContributionMap":{}},{"hash":"88803a7aec4b841305b2a7716850e466193ec107","isMergeCommit":false,"messageTitle":"Clean up UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":2}}}]},{"date":"2023-10-06","commitResults":[{"hash":"220ea22f86c3d933219eefa1ae6e0c2fabea1d44","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into karishma-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"800151596e695fdfd13c417def35fd80dc78fed4","isMergeCommit":true,"messageTitle":"Merge pull request #10 from karishma-t/karishma-AboutUs","messageBody":"Add Karishma about us","fileTypesAndContributionMap":{}},{"hash":"4a53af6054886017e9cf732a597960c970f202d4","isMergeCommit":false,"messageTitle":"Fix about us portfolio bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"eb792a86d1eb0fd6ea4e2bca18a1ed4e10c07661","isMergeCommit":true,"messageTitle":"Merge pull request #11 from TeoHaoZhi/master","messageBody":"Fix about us portfolio bug","fileTypesAndContributionMap":{}}]},{"date":"2023-10-08","commitResults":[{"hash":"090f7fd2112203bcd0f818c6a79ab83c1945118e","isMergeCommit":false,"messageTitle":"Rename classes","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":4,"deletions":4}}},{"hash":"cd37b8a6e9414c1fa24b68559ff23066fde03931","isMergeCommit":true,"messageTitle":"Merge pull request #23 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Rename classes","fileTypesAndContributionMap":{}},{"hash":"293aa145c39d8d91f975a08e7f0c8f491234cd7e","isMergeCommit":false,"messageTitle":"Add dummy classes","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":24,"deletions":0}}},{"hash":"3d5504d42b2532eadb56b49ff210b09cdd50284c","isMergeCommit":true,"messageTitle":"Merge pull request #24 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add dummy classes","fileTypesAndContributionMap":{}},{"hash":"d842866453c774e4e7cb523fc0f6d99109564fbb","isMergeCommit":false,"messageTitle":"Add attributes to drug class","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1},"test-code":{"insertions":46,"deletions":20}}},{"hash":"7988e7aab82f83af8ed057426371bc9f8066e5c2","isMergeCommit":true,"messageTitle":"Merge pull request #25 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add attributes to drug class","fileTypesAndContributionMap":{}},{"hash":"1746b905d7c8f9941ce95abe0c601ed7a555d341","isMergeCommit":false,"messageTitle":"Add help feature to UI class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":1}}},{"hash":"227af0572b033254d6546284a0ee2f875a71c3a9","isMergeCommit":true,"messageTitle":"Merge pull request #26 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add help feature to UI class","fileTypesAndContributionMap":{}},{"hash":"7299b86db5d860ab190c91abd4c6962273b196cd","isMergeCommit":false,"messageTitle":"Add exit point for programme","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":58,"deletions":11},"other":{"insertions":0,"deletions":0},"test-code":{"insertions":0,"deletions":49}}},{"hash":"de4799c7421e4b4195b2576cd2425462d6a6fa0e","isMergeCommit":true,"messageTitle":"Merge pull request #27 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add exit point for programme","fileTypesAndContributionMap":{}},{"hash":"354c79d2f7cbb08fb7700ca95ef4ca362f2c172d","isMergeCommit":false,"messageTitle":"Refactor printing for help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":24}}},{"hash":"8ab6c94c4d553c98bdc4616b2841d95fea09e2e7","isMergeCommit":true,"messageTitle":"Merge pull request #28 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Refactor printing for help command","fileTypesAndContributionMap":{}},{"hash":"5bf20560cb92c584383123cf1ba209e1943da17b","isMergeCommit":false,"messageTitle":"Add Junit test for help feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":5},"test-code":{"insertions":47,"deletions":0}}},{"hash":"0cce6790d3939b1aa5f6309f8c81e87f8490dceb","isMergeCommit":true,"messageTitle":"Merge pull request #29 from TeoHaoZhi/HaoZhi-JUnitTestForHelpFeature","messageBody":"Add Junit test for help feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-09","commitResults":[{"hash":"44f897c607a7bf71459ce63ef7a22368d8374d2c","isMergeCommit":true,"messageTitle":"Merge pull request #30 from martinschnder/branch-AddCommand","messageBody":"Branch add command","fileTypesAndContributionMap":{}},{"hash":"38f4573bdbf922271274ff418303a83c5ba9778e","isMergeCommit":false,"messageTitle":"Add more class templates","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":82,"deletions":22}}},{"hash":"7ab218bb640ddf7a60822ecd133989bcd0d2a220","isMergeCommit":true,"messageTitle":"Merge pull request #31 from TeoHaoZhi/HaoZhi-ListCommandHelp","messageBody":"Add more class templates","fileTypesAndContributionMap":{}}]},{"date":"2023-10-10","commitResults":[{"hash":"e366c56327163c3ebdcc63a2889b90ea43218e50","isMergeCommit":false,"messageTitle":"Update userguide markdown file","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":154,"deletions":12}}},{"hash":"67f9f7118ed7fe8c06884e7757e87e6c634fa6d8","isMergeCommit":true,"messageTitle":"Merge pull request #32 from TeoHaoZhi/HaoZhi-UserGuideUpdateV1.0","messageBody":"Update userguide markdown file","fileTypesAndContributionMap":{}},{"hash":"b6fd34963d346c40de9d71cb9ea43699a14d4b8d","isMergeCommit":false,"messageTitle":"Update README","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":2}}},{"hash":"a3f768d82e7036ec93e0543e7c2db1847279aa1c","isMergeCommit":true,"messageTitle":"Merge pull request #33 from TeoHaoZhi/HaoZhi-ReadMe","messageBody":"Update README","fileTypesAndContributionMap":{}},{"hash":"dc4311ad9d1840486a71ba7958140542108c093a","isMergeCommit":false,"messageTitle":"Add Junit test for help command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":29,"deletions":0}}},{"hash":"324c68f05643be382892df3fec2ec0d7ea16d361","isMergeCommit":false,"messageTitle":"Fix checkstyle violation","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":5}}},{"hash":"7a54cf286c00c3cf7864d2bc4859e14c0e4c9a4d","isMergeCommit":true,"messageTitle":"Merge pull request #35 from TeoHaoZhi/HaoZhi-JUnitTestForHelpFeature","messageBody":"Add Junit test for help command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-11","commitResults":[{"hash":"bac5f0f114fe6974123b6090f5bfc2ad035bbf64","isMergeCommit":false,"messageTitle":"Edit Junit test for help","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":13,"deletions":13}}},{"hash":"e5380e513c5f79d6570dca09171f3f1fc58402d2","isMergeCommit":true,"messageTitle":"Merge pull request #36 from TeoHaoZhi/HaoZhi-JUnitTestForHelpFeature","messageBody":"Edit Junit test for help","fileTypesAndContributionMap":{}},{"hash":"350fcc060811c2f4e25cb36254f2bd7845ea9338","isMergeCommit":false,"messageTitle":"Add methods to write to txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":0}}},{"hash":"a46e5821d0bcebdf8cc07433cfb197f7fd91490b","isMergeCommit":false,"messageTitle":"Update method to append to txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4}}},{"hash":"d25c1fefd9e13e3320c18ff49032c4dfc91e93a4","isMergeCommit":false,"messageTitle":"Add login system class to handle login features","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":124,"deletions":0}}},{"hash":"366c60438a5b4307401d2af9368d4c60d28dc73f","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":8}}},{"hash":"be08c4a84413626b9f7bcc47b0264320f8ecb7bd","isMergeCommit":true,"messageTitle":"Merge pull request #37 from TeoHaoZhi/HaoZhi-LoginFeatureAttempt1","messageBody":"Add login system class","fileTypesAndContributionMap":{}},{"hash":"d2aef4c2cf81d80323363559b85cd7dcc5aad9d1","isMergeCommit":false,"messageTitle":"Fix infinite while loop","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"5847e7d3f2046d0a5d03b96582f032e83b8d2443","isMergeCommit":false,"messageTitle":"Fix bug of overwriting txt file instead of adding to it","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":4}}},{"hash":"f4fec5773b73e56a551fc2f99440e3b21f9646b1","isMergeCommit":false,"messageTitle":"Fix bugs in login system class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":89,"deletions":17}}},{"hash":"c35451f09fa1f1f1423fa4e8ad3d75679d362e2b","isMergeCommit":false,"messageTitle":"FIx Bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":20}}},{"hash":"7617592e5273ba22fa90061e426827bbed215362","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":6}}}]},{"date":"2023-10-12","commitResults":[{"hash":"ab49cf95fb9ceab78bfb2b6c312dbd694de75ff9","isMergeCommit":false,"messageTitle":"FIx bug causing failing CI test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":27}}},{"hash":"5323884d9709dde52cf9cd1670bc8f9274e3ad90","isMergeCommit":true,"messageTitle":"Merge pull request #38 from TeoHaoZhi/HaoZhi-LoginFeatureAttempt1","messageBody":"Login attempt bug fix 1","fileTypesAndContributionMap":{}},{"hash":"5b76d7f4809b669df3bcaab0d3c8c352d856d267","isMergeCommit":false,"messageTitle":"Fix printing formatting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":17}}}]},{"date":"2023-10-14","commitResults":[{"hash":"10259ca61e695c8802fec0130f28e74e79e8e7a5","isMergeCommit":false,"messageTitle":"Add assertion for login system","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"other":{"insertions":1,"deletions":0}}},{"hash":"988ee96196908057baaa52e3c90e60bf2eda330c","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"6aaeb409f9ed28c1096b87feda862eff1758f9c5","isMergeCommit":false,"messageTitle":"Edit runtest.sh file to disable it","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"e917a9b035a3b985e45f43336a0e3e88a1438d6f","isMergeCommit":false,"messageTitle":"Fix bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3},"test-code":{"insertions":1,"deletions":1}}},{"hash":"28336545c9ca20145bd634e797f0ac345650ab7e","isMergeCommit":false,"messageTitle":"Edit runtest.bat to disable IO test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"389f5999bc5fcee00d3e38aa2b8e6693fcbad44d","isMergeCommit":true,"messageTitle":"Merge pull request #40 from TeoHaoZhi/HaoZhi-BugfixLogin","messageBody":"Add assertion for login system","fileTypesAndContributionMap":{}},{"hash":"fd5869a315e63b3e4c9daa003af97dcd133a587e","isMergeCommit":false,"messageTitle":"Added messages to let UI handle printing of messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":19}}},{"hash":"38a69c177d2e593158303f95f1e3f2a5e2134ab5","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":70,"deletions":22}}},{"hash":"a4be93035d88733cf3f1953bda32ace09527017b","isMergeCommit":true,"messageTitle":"Merge pull request #41 from TeoHaoZhi/LoginMessagesFix","messageBody":"Added messages to let UI handle printing of messages","fileTypesAndContributionMap":{}},{"hash":"3528ac948b94285edb8196292d9955d1559b06dc","isMergeCommit":false,"messageTitle":"Update javadoc for login system class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":3}}},{"hash":"724368c8a4964dddcb0e716f7d37672d523d20f3","isMergeCommit":true,"messageTitle":"Merge pull request #42 from TeoHaoZhi/HaoZhi-JavaDocLoginSystem","messageBody":"Update javadoc for login system class","fileTypesAndContributionMap":{}},{"hash":"c9782f17e67050c1dd5b05b5ff7b3dba093e6780","isMergeCommit":false,"messageTitle":"Added java doc for file storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":3}}},{"hash":"01e37de8ce32537e7df7854fa385be003f07ea71","isMergeCommit":true,"messageTitle":"Merge pull request #43 from TeoHaoZhi/Javadoc","messageBody":"Added java doc for file storage class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"8573f29dd50f626312f717999098767234e5ab67","isMergeCommit":false,"messageTitle":"Add userguide on login system","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":59,"deletions":20}}},{"hash":"df15ef01089d4ccc1210bc929a19a5bc0c69095a","isMergeCommit":false,"messageTitle":"Fix Junit test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":12},"test-code":{"insertions":47,"deletions":30}}},{"hash":"f68a2eea9a7c6a51fc7ed0980c82bbe61486a20c","isMergeCommit":true,"messageTitle":"Merge pull request #47 from TeoHaoZhi/HaoZhi-MarkDown","messageBody":"Edit userguide","fileTypesAndContributionMap":{}},{"hash":"1ec8b571b25dada302c74e04f3398697ab08a189","isMergeCommit":false,"messageTitle":"Fix bug of blank input for username and password","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":8}}},{"hash":"6f77ee60f5ed10366ecfbcc8a3d26b20f5c9d528","isMergeCommit":true,"messageTitle":"Merge pull request #48 from TeoHaoZhi/LoginSystemBlankinput","messageBody":"Fix bug of blank input for username and password","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"b6cb73dbbfd6780178d32c3949b2fd24f046e11e","isMergeCommit":true,"messageTitle":"Merge pull request #50 from Barbaracwx/branch-FindCommandNew","messageBody":"Branch find command new","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"2d9902628161064ffcd7105230dd6fa765b188ca","isMergeCommit":false,"messageTitle":"Update user guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":5}}},{"hash":"e01effd8dc540db39d938e72fa2dc7d0f0cb72b5","isMergeCommit":true,"messageTitle":"Merge pull request #54 from TeoHaoZhi/HaoZhi-UpdateUserGuide","messageBody":"Update user guide","fileTypesAndContributionMap":{}},{"hash":"f53e9e97737095dc7367aba076d5f5f98d120061","isMergeCommit":true,"messageTitle":"Merge pull request #55 from Barbaracwx/branch-TestCodeFindCommand","messageBody":"Added j unit test","fileTypesAndContributionMap":{}},{"hash":"14271486fb1978d5c85475b176ff6f34c0160998","isMergeCommit":true,"messageTitle":"Merge pull request #52 from karishma-t/karishma-DeleteCommand","messageBody":"Add delete command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"7d3d19836e43e535ca879db7a2f24e84fb2ade61","isMergeCommit":true,"messageTitle":"Merge pull request #57 from Barbaracwx/master","messageBody":"changed findCommand to add ui class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"29f5aec77019ca6585b88faf87f1c5a812cb8663","isMergeCommit":true,"messageTitle":"Merge pull request #60 from Barbaracwx/branch-assertionStatement","messageBody":"added assertion statement","fileTypesAndContributionMap":{}},{"hash":"9c0f2d2c8ce561200f6b7c15c96d645ef87c2357","isMergeCommit":true,"messageTitle":"Merge pull request #61 from Barbaracwx/branch-CodeTest","messageBody":"edited FindCommandTest cases","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"0d83e630f1be68cc6ee693a7e8e8efd07703d072","isMergeCommit":true,"messageTitle":"Merge pull request #64 from Barbaracwx/branch-FindCommandName","messageBody":"add find command using both name and date","fileTypesAndContributionMap":{}},{"hash":"a5ce4e7ef58f1828ca4061d12735e197f8b1d03e","isMergeCommit":true,"messageTitle":"Merge pull request #66 from Barbaracwx/branch-UserGuide","messageBody":"changed user guide according to new find function","fileTypesAndContributionMap":{}},{"hash":"b24a4051f1319ef08dcf942aa00fd5002f86b3f3","isMergeCommit":false,"messageTitle":"Add register and login commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":83,"deletions":28}}},{"hash":"d48892620bf2425f4d20f7bf67f119d866e7aba6","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":6},"test-code":{"insertions":12,"deletions":2}}},{"hash":"41b3713088803f0fa62c1701e642c1a7f82f3de0","isMergeCommit":true,"messageTitle":"Merge pull request #68 from TeoHaoZhi/HaoZhi-RegisterClass","messageBody":"Add register command and login command","fileTypesAndContributionMap":{}},{"hash":"7cc709dbb251572295f802094e1290f43d252837","isMergeCommit":false,"messageTitle":"Update userguide to reflect register and login feature","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":54,"deletions":2}}},{"hash":"2d8343571d10857aae93337064ae0f04eac9105b","isMergeCommit":true,"messageTitle":"Merge pull request #69 from TeoHaoZhi/HaoZhi-UpdateUserGuide","messageBody":"Update userguide to reflect register and login feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-21","commitResults":[{"hash":"0bf3c4287787d2f9b4bea2ea4dd9c5fdb0da70da","isMergeCommit":false,"messageTitle":"Add save feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":93,"deletions":6},"test-code":{"insertions":5,"deletions":0}}},{"hash":"b18733d8b51c292afa238a16e6cb240638acb2e3","isMergeCommit":true,"messageTitle":"Merge pull request #71 from TeoHaoZhi/HaoZhi-SaveFeature","messageBody":"Add save feature","fileTypesAndContributionMap":{}},{"hash":"f3cc4e3e29ffde5997c1ebbea5db55f590d3e8ff","isMergeCommit":false,"messageTitle":"Update Userguide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":1}}},{"hash":"5f4541a2603dfded61643c40c14e898d37ae263d","isMergeCommit":true,"messageTitle":"Merge pull request #72 from TeoHaoZhi/HaoZhi-UpdateUserGuide","messageBody":"Update Userguide","fileTypesAndContributionMap":{}},{"hash":"5d82131cb223c10000d72b98f149435e68aba0e8","isMergeCommit":false,"messageTitle":"Update Developer guide","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"docs":{"insertions":46,"deletions":0}}},{"hash":"b791625622c1516b144b9178b6a788114f82cfa8","isMergeCommit":true,"messageTitle":"Merge pull request #73 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer guide","fileTypesAndContributionMap":{}},{"hash":"0699a596754f2b7bcc9f8b9c8be51117e12076c8","isMergeCommit":false,"messageTitle":"Update DeveloperGuide to include login system component","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":69,"deletions":3}}},{"hash":"718424751b2e26e41abb1a6a086f72f8d92057cb","isMergeCommit":true,"messageTitle":"Merge pull request #74 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update DeveloperGuide to include login system component","fileTypesAndContributionMap":{}},{"hash":"b28bae84c2fa402631c454cf16c43958e15246f8","isMergeCommit":false,"messageTitle":"Add exception handling for authenticateUserChoice method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":64},"test-code":{"insertions":0,"deletions":32}}},{"hash":"09293249c3f92cca9610c6b6ba142746f72f48bc","isMergeCommit":false,"messageTitle":"Add Java Docs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":3}}},{"hash":"caf33c93038f985dd0c421a78c1fc6ef14488a58","isMergeCommit":false,"messageTitle":"Add Java docs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":3}}},{"hash":"7f6e4dff2b472cb0a5c1c4ce0ecee507b448bc43","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}},{"hash":"f1c6fa86da1e89edb3bb0802ead8b106089ea597","isMergeCommit":true,"messageTitle":"Merge pull request #75 from TeoHaoZhi/HaoZhi-Exceptions","messageBody":"Add execeptions and java docs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"9fea2f7bfa79c6c199ae33ed4f31dd788db2db55","isMergeCommit":true,"messageTitle":"Merge pull request #76 from martinschnder/sellCommand","messageBody":"Modify inventory structure and add all the command needed to make a sale","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"343ee190fb97f978ea49283551f6b591dd74267d","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":1}}},{"hash":"667c4a20e434525f5a1a9f4039e3c5656142ab8b","isMergeCommit":true,"messageTitle":"Merge pull request #78 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"0a9460e3de3e58fce483e11d6e315f2a2a66ea09","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"d6550e227a02e5ad46ede2649311aef426157414","isMergeCommit":true,"messageTitle":"Merge pull request #79 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"c92c67f4c1c94bc78dc52f58b399463f79446b6d","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":2}}},{"hash":"703a81938475b50a9ace0d9f0cdf0cb8af2b34f7","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":0}}},{"hash":"0baae65260c6fd8d638c021533b2542c4303c532","isMergeCommit":true,"messageTitle":"Merge pull request #81 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"68c9a0f44cb5a6028a69c5594fc19067342b1bab","isMergeCommit":true,"messageTitle":"Merge pull request #80 from Barbaracwx/branch-DeveloperGuide","messageBody":"updated Developer\u0027s Guide","fileTypesAndContributionMap":{}},{"hash":"6adc3cfd32ab71f4d124fc8771bd03d92a8c4cc9","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":3}}},{"hash":"33e5b4e4146befa4911d42d109c138db7dea126c","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"f6dc78291cee2f7449a9d394b0ddd239d5741a5a","isMergeCommit":true,"messageTitle":"Merge pull request #82 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"505f9c3c012219f07d38e5f2d03df9b2c8279921","isMergeCommit":true,"messageTitle":"Merge pull request #83 from Barbaracwx/branch-developersguideNew","messageBody":"updated developer\u0027s guide","fileTypesAndContributionMap":{}},{"hash":"674724af608464b0234c47546677d88ec094dba1","isMergeCommit":true,"messageTitle":"Merge pull request #85 from Barbaracwx/master","messageBody":"added uml diagrams","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"21d68cfa0f59bf19906c45126f282343b31d5e46","isMergeCommit":true,"messageTitle":"Merge pull request #89 from Barbaracwx/findcommandtest","messageBody":"Findcommandtest","fileTypesAndContributionMap":{}},{"hash":"1a0eacc8cf28b010d683eb8d3a33a54ec95817d1","isMergeCommit":true,"messageTitle":"Merge pull request #91 from karishma-t/karishma-Developer-Guide","messageBody":"Modify DG for delete","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"e3356ce5fbcc07cc6748c03ac24376471d6d0a67","isMergeCommit":false,"messageTitle":"Update UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":20}}},{"hash":"71b41675d7a09a3cb8d6dd173ec740a1a998ce8d","isMergeCommit":true,"messageTitle":"Merge pull request #93 from TeoHaoZhi/UML","messageBody":"Update UML","fileTypesAndContributionMap":{}},{"hash":"e14d45429110d0454025237a1fb5c3259767bfa8","isMergeCommit":false,"messageTitle":"Add addVendor Command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":116,"deletions":16}}},{"hash":"b284882a9d1d2fd1a2ab200a0535cf84893fbe81","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":14}}},{"hash":"e4693841e4871364b409a2e567344d3b2d1c6d20","isMergeCommit":true,"messageTitle":"Merge pull request #95 from Barbaracwx/branch-StockLevel","messageBody":"added new stock level command","fileTypesAndContributionMap":{}},{"hash":"ec3e45d82c30f673e4397e7ff92f81036c1ee804","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Vendors","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"16c103da5094704ef33f3bcce063383e7d27b627","isMergeCommit":true,"messageTitle":"Merge pull request #94 from TeoHaoZhi/Vendors","messageBody":"Add addVendor Feature","fileTypesAndContributionMap":{}},{"hash":"7771c5e3be64819ed47f08353d536e8597dd27b9","isMergeCommit":false,"messageTitle":"Fix addVendor bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"59675fad58796c4a82fbbeebc773a67e88b1f63c","isMergeCommit":true,"messageTitle":"Merge pull request #98 from TeoHaoZhi/Vendors","messageBody":"Fix addVendor bug","fileTypesAndContributionMap":{}},{"hash":"dd8be75f2dcad5340c4c1c01f8bc3b07d81ec7a6","isMergeCommit":false,"messageTitle":"Fix abstraction","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":31}}},{"hash":"8003e19cfac858b4a412d0893f0fea135324c2d9","isMergeCommit":true,"messageTitle":"Merge pull request #99 from TeoHaoZhi/FixAbstraction","messageBody":"Fix abstraction","fileTypesAndContributionMap":{}},{"hash":"0d5a92c12ad67bc214a2b6cf1577ed6e04088fe9","isMergeCommit":false,"messageTitle":"Add VendorList Feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":53,"deletions":1},"test-code":{"insertions":61,"deletions":47}}},{"hash":"ade809a860d139a306dde45776fa856e5b1ebf30","isMergeCommit":true,"messageTitle":"Merge pull request #101 from TeoHaoZhi/VendorListFeature","messageBody":"Add VendorList Feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"6cc361564e253b755fbd64da229ec2b717368599","isMergeCommit":false,"messageTitle":"Update Java Docs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":2}}},{"hash":"7544968cd74382ab68734fe61607008395dd4610","isMergeCommit":true,"messageTitle":"Merge pull request #102 from TeoHaoZhi/Javadoc","messageBody":"Update Java Docs","fileTypesAndContributionMap":{}},{"hash":"c6381578a9674e214188ccce351a9f40b917e5be","isMergeCommit":false,"messageTitle":"Update User guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":51,"deletions":2}}},{"hash":"fef7feda7f40d84f6f849e6dd19c1a2f9f44f461","isMergeCommit":true,"messageTitle":"Merge pull request #103 from TeoHaoZhi/UserGuide","messageBody":"Update User guide and UML diagram","fileTypesAndContributionMap":{}},{"hash":"f794fa615e63df9591f96720f081f57b1e167b13","isMergeCommit":false,"messageTitle":"Update Developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":15,"deletions":1}}},{"hash":"035e8005eabf106c4bae9247d28d93e9844c947a","isMergeCommit":true,"messageTitle":"Merge pull request #104 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer guide","fileTypesAndContributionMap":{}},{"hash":"4d74b146a0b288d69094b0a9651b8bfb6a83d29a","isMergeCommit":false,"messageTitle":"Update Developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":20,"deletions":0}}},{"hash":"449e91de789b9a45040398b06f64e79ba7746940","isMergeCommit":true,"messageTitle":"Merge pull request #106 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer guide","fileTypesAndContributionMap":{}},{"hash":"9097e5b1de1d8e8f285f9963c23a981291f40d7c","isMergeCommit":true,"messageTitle":"Merge pull request #107 from Barbaracwx/branch-UGnew","messageBody":"updated UG with stock level command","fileTypesAndContributionMap":{}},{"hash":"16c27768dd4411ee65ada23e2ced21503514493f","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":1}}},{"hash":"6486fe783c57563e9785ee0d2094b56b74ba2af3","isMergeCommit":true,"messageTitle":"Merge pull request #108 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"fe61f782aaefc5bdd638ba5d44f2426f6d49475c","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":0}}},{"hash":"a0c49e6186db8768dba66f3514bdf382e81e5255","isMergeCommit":true,"messageTitle":"Merge pull request #109 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"e2c7c8aa62125a76dae3ae4eb1dee3b22e5ced5f","isMergeCommit":true,"messageTitle":"Merge pull request #110 from Barbaracwx/branch-stocklevelcommandtest","messageBody":"added stock level command test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"99a653ca1f358d68dca01775ae844424f29d58d3","isMergeCommit":false,"messageTitle":"Update user stories in developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":9}}},{"hash":"1ddfd266cc46d84059ddb735d986e454e7ea48a9","isMergeCommit":true,"messageTitle":"Merge pull request #114 from TeoHaoZhi/DeveloperGuide","messageBody":"Update user stories in developer guide","fileTypesAndContributionMap":{}},{"hash":"136f039ce2872e4994a96adc8cf15f75f467dda8","isMergeCommit":true,"messageTitle":"Merge pull request #117 from Barbaracwx/branch-newListThreshold","messageBody":"add new list threshold command","fileTypesAndContributionMap":{}},{"hash":"c633713005d3c2bd179b5af4e6686b4d4289bb45","isMergeCommit":true,"messageTitle":"Merge pull request #118 from Barbaracwx/branch-newListThreshold","messageBody":"added List Threshold Command Test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"fe89447933c98a7254740addddfc5e0cf6fd4cda","isMergeCommit":true,"messageTitle":"Merge pull request #126 from Barbaracwx/DG-parser","messageBody":"added description for parser class in DG","fileTypesAndContributionMap":{}},{"hash":"57ee8fc6c6b2185bfb9cad1638ff39ec5629338b","isMergeCommit":true,"messageTitle":"Merge pull request #127 from karishma-t/karishma-VendorSupply","messageBody":"Karishma vendor supply","fileTypesAndContributionMap":{}},{"hash":"72f99025b879f2f438767edb40a5fa8119f94170","isMergeCommit":true,"messageTitle":"Merge pull request #128 from Barbaracwx/DG-parser","messageBody":"added parser diagram","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"407d2dd9c5926becd4373c76f0463386eb18b198","isMergeCommit":true,"messageTitle":"Merge pull request #129 from Barbaracwx/branch-updateUG","messageBody":"update UG","fileTypesAndContributionMap":{}},{"hash":"dd17f9b22d031de4e7c8a1b7fb54f1d267ccd4bf","isMergeCommit":true,"messageTitle":"Merge pull request #130 from karishma-t/karishma-updateUG","messageBody":"Update UG","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"5cb9b755b78fb3d3364cc1b631d5d8de9ada5669","isMergeCommit":false,"messageTitle":"Fix Ped Bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":24}}},{"hash":"ef45263345a982c182cf9a570fdd9921f6d9ccac","isMergeCommit":false,"messageTitle":"Fix Ped UserGuide bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"a946e64f1d994f2a99143625b76b6859a223913a","isMergeCommit":true,"messageTitle":"Merge pull request #208 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"e7640febc4a8ee83ac38a64b4ceb5f6282564621","isMergeCommit":false,"messageTitle":"Fix login system PED Bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"741f27e8b78696049da9188182534b690a2058cf","isMergeCommit":true,"messageTitle":"Merge pull request #209 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix login system PED Bugs","fileTypesAndContributionMap":{}},{"hash":"7e111f887969a02d845722ee47579404233e5936","isMergeCommit":false,"messageTitle":"Fix grammer error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"037a76facc4108c9f8ca24b236d49c1c4e2e1116","isMergeCommit":false,"messageTitle":"Update UserGuide FAQ","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":1}}},{"hash":"509339ae773b7a8cbd5508b6adc4117c51cd5f74","isMergeCommit":true,"messageTitle":"Merge pull request #210 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"07a567585e6de9d58103e99c06582a06c56c36b6","isMergeCommit":false,"messageTitle":"Update UserGuide to fix PED bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"ad706645187212947926bcedf3af1a041ef181f1","isMergeCommit":false,"messageTitle":"Fix User Guide PED Bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"83997d31f2199fc69afa7f4084351aa30ec05a82","isMergeCommit":true,"messageTitle":"Merge pull request #211 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"76a4f629ec37687e5c39cfa0f0befd7a39061c44","isMergeCommit":false,"messageTitle":"Fix UserGuide PED","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"940f9063964bd156950aecebdb3a381e26fd3348","isMergeCommit":true,"messageTitle":"Merge pull request #212 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix UserGuide PED","fileTypesAndContributionMap":{}},{"hash":"408b7dc0b2b4fda95a9e5222a1b14ab2ce9ceadc","isMergeCommit":false,"messageTitle":"Add Table of contents to UserGuide to fix PED issue","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":0}}},{"hash":"b676f6fb354c02ee0bbee823ee4112b33a431dd3","isMergeCommit":true,"messageTitle":"Merge pull request #213 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Add Table of contents to UserGuide to fix PED issue","fileTypesAndContributionMap":{}},{"hash":"7928b0b252f70171a95cd2ed69e8ee076e101cce","isMergeCommit":false,"messageTitle":"Fix Ped Bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":14},"docs":{"insertions":1,"deletions":0}}},{"hash":"f907e0a9f254365eb50de545c8deaa76922b616d","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":1}}},{"hash":"c5fd2260c883ae7d176352a5f30c9b25d8ea3ba8","isMergeCommit":true,"messageTitle":"Merge pull request #214 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"99c5b4176928a1f4f250c5d073759e2dde809ce2","isMergeCommit":false,"messageTitle":"Fix userguide PED Bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":0}}},{"hash":"95adc7ff7f36996d35938e257943a11c4eecefa7","isMergeCommit":true,"messageTitle":"Merge pull request #215 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix userguide PED Bug","fileTypesAndContributionMap":{}}]}],"Barbaracwx":[{"date":"2023-10-05","commitResults":[{"hash":"91e8e21dc2263c8657a5df7cb911512e24f1bf43","isMergeCommit":false,"messageTitle":"Added Barbara.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"ad260c19eda658e1aa9478315b4eb25553e0b865","isMergeCommit":true,"messageTitle":"Merge branch \u0027Barbaracwx-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-12","commitResults":[{"hash":"4e4b091ddc0b16dd22533420b4b27b848a03b825","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"180b32eebac4e0d2436dabe817edb0cba055abd9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"84b79a21099e3b74dc3e06f5eba86dff72264aba","isMergeCommit":false,"messageTitle":"Add Find Command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":15}}},{"hash":"86beea836dfe6c2c103e3f4d3fdb76fc7d9d0a35","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-findCommand\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"7d4f40b7f2bed79141a458898b06fca9f8c62587","isMergeCommit":false,"messageTitle":"add new find function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":15}}}]},{"date":"2023-10-17","commitResults":[{"hash":"ddcac51425f93cb187d620c962346d2b3d9751e2","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c51866c18f620a0e7d5156750805158e33e2e100","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-3/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"95245940faaa042c2d33722b8d8d0560849a3bb6","isMergeCommit":false,"messageTitle":"Added j unit test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":23,"deletions":0}}},{"hash":"4ff1edf92e602aa27f78e0c3d3a41d6c79330085","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3791585a90b35d360f8a80b8f48d5b2f9116505e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"06e11cafceac7c118b71d331893b25db1f57c313","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c2fa2315a0de008062a8b5cf5841c290b1a243ea","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-3/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"2b72a18f3da1599eaf69f5d70a5773b82e6a3748","isMergeCommit":false,"messageTitle":"change find command class to add ui class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":11},"test-code":{"insertions":16,"deletions":6}}},{"hash":"397da38e3c33d4dd15025228a9c9c85e7ffb7a11","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"5f6c065cadd0495287d2833fc544ae57491a64f0","isMergeCommit":false,"messageTitle":"added assertion statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"44e4e274eed15e597cb23df11f610716ebd52ccf","isMergeCommit":false,"messageTitle":"edited FindCommandTest cases","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":1},"test-code":{"insertions":10,"deletions":2}}}]},{"date":"2023-10-20","commitResults":[{"hash":"b06f328e50f72cc60b07d213aa938ba3f60e0309","isMergeCommit":false,"messageTitle":"add find command using both name and date","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":11},"test-code":{"insertions":8,"deletions":3}}},{"hash":"56171fad030833f03447323c39661904f90662ff","isMergeCommit":false,"messageTitle":"changed user guide according to new find function","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":35,"deletions":15}}}]},{"date":"2023-10-25","commitResults":[{"hash":"03d6f232ad01fbb68be912b33d89572d9c519e89","isMergeCommit":false,"messageTitle":"updated Developer\u0027s Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":55,"deletions":21}}},{"hash":"c235d47ce2aa21b70716cada4e37cc434e015d30","isMergeCommit":false,"messageTitle":"updated developer\u0027s guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":83,"deletions":1}}},{"hash":"5c3ae6371909ff03735045d6178edd07b35230f8","isMergeCommit":false,"messageTitle":"added uml diagrams","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":52,"deletions":0}}}]},{"date":"2023-10-26","commitResults":[{"hash":"8fd0581bb131c46c9d2c4dcb3c609de4d35d5939","isMergeCommit":false,"messageTitle":"added more find command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":14},"test-code":{"insertions":51,"deletions":12}}},{"hash":"080c98c29d89a1138a24193e168dfb7768f4f1a8","isMergeCommit":false,"messageTitle":"added more find command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":16},"test-code":{"insertions":16,"deletions":3}}},{"hash":"14e5eee09b7bd035c3430e7ee741990cfef3a356","isMergeCommit":false,"messageTitle":"changed find command sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":1}}},{"hash":"0a9986d8b0c6ebbd10c964743992b64efdf0ac00","isMergeCommit":false,"messageTitle":"changed sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-28","commitResults":[{"hash":"bc7d8f25061432371b62776859d16689283ed7f8","isMergeCommit":false,"messageTitle":"added new stock level command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":113,"deletions":45},"test-code":{"insertions":5,"deletions":0}}}]},{"date":"2023-10-29","commitResults":[{"hash":"92805b4d14bae7dbb680a8bc830f22ea6cb3eadd","isMergeCommit":false,"messageTitle":"updated UG with stock level command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":8}}},{"hash":"3fa4734a468c6253b0e769b116d0d74e77b3fc9c","isMergeCommit":false,"messageTitle":"added stock level command test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":44,"deletions":0}}},{"hash":"8295f445488c08263a248ab1ab6c753bffdace76","isMergeCommit":false,"messageTitle":"add set threshold quantity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":93,"deletions":6}}},{"hash":"d7f07141cbb795161500b7f24bcf459d326de38f","isMergeCommit":false,"messageTitle":"updated set threshold command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"15f92bfa2157af06e4ee0fc567597e7207f39e31","isMergeCommit":false,"messageTitle":"updated new set threshold method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":5}}},{"hash":"1d2b93386b284102aaae2d5efbe8395cd05b0194","isMergeCommit":false,"messageTitle":"updated set threshold method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"70c3ba37a5e49c211b5ff7a581de476ac43fe0f3","isMergeCommit":false,"messageTitle":"add new set threshold method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}}]},{"date":"2023-10-30","commitResults":[{"hash":"0e8c6140a33d71752714756f2f9aae7ad4817e2a","isMergeCommit":false,"messageTitle":"add new list threshold command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":0}}},{"hash":"944fb5d18850531d471b163613a55261475fe894","isMergeCommit":false,"messageTitle":"added show stock level command test for empty inventory","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":12,"deletions":0}}},{"hash":"12cc11258a04b1d8e52c7c7ddcf74a9d0df1043d","isMergeCommit":false,"messageTitle":"added javadoc comments to set threshold command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":3}}},{"hash":"e7e030b72b17e7c35e7399cfd40fdab370e4cabe","isMergeCommit":false,"messageTitle":"updated javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":1}}},{"hash":"50daeacf6f33fe62e8265c05b60707ecb86b429b","isMergeCommit":false,"messageTitle":"added set threshold command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":8},"test-code":{"insertions":50,"deletions":0}}},{"hash":"be10a9f9c8aa6d2dff57ce377782047a3def5e87","isMergeCommit":false,"messageTitle":"added List Threshold Command Test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":40,"deletions":0}}}]},{"date":"2023-10-31","commitResults":[{"hash":"d59d61d59c4ab5b66e4e0ef6dab5cef775c884fe","isMergeCommit":false,"messageTitle":"added description for parser class in DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":136,"deletions":33}}},{"hash":"daf87ec60a850219a8273eb8c50959fea45758e3","isMergeCommit":false,"messageTitle":"added parser diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":22,"deletions":0}}}]},{"date":"2023-11-01","commitResults":[{"hash":"d84e998671732920801ffd28d7b250490abb1f81","isMergeCommit":false,"messageTitle":"update UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0},"docs":{"insertions":43,"deletions":0},"test-code":{"insertions":10,"deletions":0}}},{"hash":"5a4a03d76af225d75a16f272ae95953cf9d1d495","isMergeCommit":false,"messageTitle":"update UG","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":2}}}]}]},"authorFileTypeContributionMap":{"karishma-t":{"docs":186,"functional-code":452,"test-code":62},"martinschnder":{"docs":135,"functional-code":776,"test-code":100,"other":2},"azfarulmatin":{"docs":128,"functional-code":146,"test-code":68},"TeoHaoZhi":{"docs":488,"functional-code":763,"test-code":84,"other":3},"Barbaracwx":{"docs":402,"functional-code":308,"test-code":241}},"authorContributionVariance":{"karishma-t":4716.0684,"martinschnder":18924.748,"azfarulmatin":2525.051,"TeoHaoZhi":14860.298,"Barbaracwx":4161.742},"authorDisplayNameMap":{"karishma-t":"CS2113-T17-3 KARI..ARAN","martinschnder":"CS2113-T17-3 SCHN..ILLE","azfarulmatin":"CS2113-T17-3 AZFA..ANDI","TeoHaoZhi":"CS2113-T17-3 TEO .. ZHI","Barbaracwx":"CS2113-T17-3 CHON..BARA"}} +{"authorDailyContributionsMap":{"karishma-t":[{"date":"2023-10-05","commitResults":[{"hash":"9b179211347fe7a0942693aea92a880a72243999","isMergeCommit":false,"messageTitle":"Add files for Karishma about us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":4}}},{"hash":"ec15853438ef4adb88f2bbcc87f367804d35788d","isMergeCommit":false,"messageTitle":"Conflict resolution","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":2}}}]},{"date":"2023-10-17","commitResults":[{"hash":"5c174ca4cdfe79c6b173c68db27721f92aa0f615","isMergeCommit":false,"messageTitle":"Add delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":13}}},{"hash":"4c7d28ae3f51a16116cf790aabeb170d9ffaad80","isMergeCommit":false,"messageTitle":"Add junit test for Delete command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":30,"deletions":0}}},{"hash":"ed041352034696e09d01385f720d3f3a72037c62","isMergeCommit":false,"messageTitle":"Modify to pass checkstyle tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-26","commitResults":[{"hash":"521a48339b7e42ceb652e3e1d147a6c5b485792b","isMergeCommit":false,"messageTitle":"Modify DG for delete","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":53,"deletions":0}}}]},{"date":"2023-10-30","commitResults":[{"hash":"bfafb4228b1694b5d1e34b97c9e981d7b7c25285","isMergeCommit":false,"messageTitle":"Add get Description command, along with add and list descriptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":150,"deletions":0}}},{"hash":"14c00f9f407257d902ee1fc5b41f3b8837e51add","isMergeCommit":false,"messageTitle":"Add tests for Description commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":7},"test-code":{"insertions":62,"deletions":0}}},{"hash":"e90cefce6084595a3ffc0fe7af7bc3cea0bd9dbe","isMergeCommit":false,"messageTitle":"Add javadoc for description commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":1}}},{"hash":"6c6f99f910bff64f6740f28654e16f1cf44442ee","isMergeCommit":false,"messageTitle":"Modify List description","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":25}}}]},{"date":"2023-10-31","commitResults":[{"hash":"6673cb7b7b0ce43afd99ad5bde411c1ca86d1e20","isMergeCommit":false,"messageTitle":"Add drug supply association with vendors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":121,"deletions":25}}},{"hash":"7880445932393fc05082c5e19f46d4b9caea5c30","isMergeCommit":false,"messageTitle":"Add command to list drugs under specific vendor","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":55,"deletions":0}}},{"hash":"4afcee0830c4065f6824e923e01376481e496e66","isMergeCommit":false,"messageTitle":"Add command to find vendors that offer the drug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":0}}},{"hash":"86f7883888a58d6672906943f37616e413e09dab","isMergeCommit":false,"messageTitle":"Modify code style","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":5}}}]},{"date":"2023-11-01","commitResults":[{"hash":"806511b0b28de80ac737571f7ac70c10d11a63d2","isMergeCommit":false,"messageTitle":"Update UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":33},"docs":{"insertions":148,"deletions":2}}}]},{"date":"2023-11-02","commitResults":[{"hash":"2b8fc4273a248865a222da6964b8eb7e72c54867","isMergeCommit":false,"messageTitle":"Modify delete DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":52}}},{"hash":"e1c9c8aff38e13c0d146829693eeea98274cc8a9","isMergeCommit":false,"messageTitle":"Add addVendorSupply dg","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":0}}}]}],"martinschnder":[{"date":"2023-10-07","commitResults":[{"hash":"d13e4519f0e878a3e9be46a05a57ee90c57539c8","isMergeCommit":false,"messageTitle":"Add martin portofolio and picture and update about us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"2dbd0893fe8f3dac09ed84bb33c414c0e90c74e2","isMergeCommit":true,"messageTitle":"Merge pull request #12 from martinschnder/martin-AboutUs","messageBody":"Add martin portofolio and picture and update about us","fileTypesAndContributionMap":{}}]},{"date":"2023-10-09","commitResults":[{"hash":"eca592d2600d2253010eebbf55c4217a971ca79b","isMergeCommit":false,"messageTitle":"Updated build.gradle to match new main class name","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":2}}},{"hash":"f9bf0f4dcbf0dc02f210e21283f8f18ddf745d2a","isMergeCommit":false,"messageTitle":"Reorganize files in various packages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":9},"other":{"insertions":2,"deletions":2}}},{"hash":"dd4cb2baf5df643afbefe71a963a78e7489a79b2","isMergeCommit":false,"messageTitle":"Create abstract command class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":0}}},{"hash":"0a4ae29a7ca56b747974f29fc720e496c0cebaa3","isMergeCommit":false,"messageTitle":"Add the addclass and rename the druglist class to inventory","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":101,"deletions":19}}},{"hash":"9891fe1ce7e876b766da0e19a647588a3845d02d","isMergeCommit":false,"messageTitle":"Delete old file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":14}}},{"hash":"c76880c8d3ba9f7555f17105e6689822950877aa","isMergeCommit":false,"messageTitle":"Implement ExitCommand and AddCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":316,"deletions":18}}}]},{"date":"2023-10-10","commitResults":[{"hash":"dce79f9038b5eade80126270475b9775283d2fd2","isMergeCommit":false,"messageTitle":"Add ui and addcommand testing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":29,"deletions":1}}}]},{"date":"2023-10-11","commitResults":[{"hash":"8910d7979fdebe5386871de9ea2cda42c5161370","isMergeCommit":false,"messageTitle":"Change the line separator character","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"d0a83e9fe5ed5a7cc13594979f0803fa8e9a2374","isMergeCommit":false,"messageTitle":"Change the line separator character in the UI class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"55d760266b318ad23fbab35a6d1857c73c063d17","isMergeCommit":true,"messageTitle":"Merge pull request #34 from martinschnder/addDrug-unit-tests","messageBody":"Add ui and addcommand testing","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"7646870a909320f59cefb562285e62abc23ef833","isMergeCommit":false,"messageTitle":"Modify inventory structure and add all the command needed to make a sale (addtocart, viewcart, checkout)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":402,"deletions":131},"test-code":{"insertions":23,"deletions":15}}},{"hash":"1134e5d481615a014073af9031ca71061ff42878","isMergeCommit":false,"messageTitle":"Fix load function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":15}}},{"hash":"4e4ef4698675691973d77ae7481e1ee117537acf","isMergeCommit":false,"messageTitle":"Add better exception handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":18}}},{"hash":"a075bd1720fd4eac5e8c090a897225d5d2057e6d","isMergeCommit":false,"messageTitle":"Update helpcommand with new commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":4},"test-code":{"insertions":43,"deletions":28}}}]},{"date":"2023-10-24","commitResults":[{"hash":"0a64a48a68acc1accbbfec26dd81f3df9574df9c","isMergeCommit":false,"messageTitle":"Add tests for AddToCart command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":27,"deletions":0}}}]},{"date":"2023-10-25","commitResults":[{"hash":"b4d2647664ddb9696b52554ddbe328b730297a98","isMergeCommit":false,"messageTitle":"Add main data structures in developerGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":46,"deletions":21}}},{"hash":"18929947f4248686faad3b70fbff3687c9c19c3b","isMergeCommit":true,"messageTitle":"Merge pull request #84 from martinschnder/developerGuide","messageBody":"Add main data structures in developerGuide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"49bfbffa868b148a46b27908dabf16ebfd74cd63","isMergeCommit":true,"messageTitle":"Merge pull request #92 from Barbaracwx/findcommandtest","messageBody":"added sequence diagram","fileTypesAndContributionMap":{}},{"hash":"50d338b34b24893e5dca5485f21f08ff4ca6e60c","isMergeCommit":true,"messageTitle":"Merge pull request #113 from Barbaracwx/branch-alert","messageBody":"updated set threshold command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"c8ea029b8bb8841a1d03a2b39a283de6496b9a9f","isMergeCommit":false,"messageTitle":"Update UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":111,"deletions":48}}}]},{"date":"2023-11-02","commitResults":[{"hash":"425255dce9b64d5b7adfd020c0135a5bc1a2ca42","isMergeCommit":false,"messageTitle":"Remove all throwing methods in the main class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":55}}},{"hash":"486738273c17067cafbf9cbc51b53b71450b1b84","isMergeCommit":false,"messageTitle":"Try to resolve various warning","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":35},"test-code":{"insertions":20,"deletions":12}}},{"hash":"55909921078d98ae4e90faae54c91d9c6becf5a8","isMergeCommit":false,"messageTitle":"Resolve warning and make vendors non static","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5},"test-code":{"insertions":2,"deletions":2}}},{"hash":"992f613aabbf9fabc323cfdcf879efa4865ca463","isMergeCommit":false,"messageTitle":"Add negative number verifications","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}}]}],"azfarulmatin":[{"date":"2023-10-07","commitResults":[{"hash":"6c8ee942babd12a205caa1b7e098fcb6340f76a9","isMergeCommit":false,"messageTitle":"Update Azfarul About us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"05e7ef8ec96488ea4719dfc0372532fe8e5694de","isMergeCommit":true,"messageTitle":"Merge pull request #19 from azfarulmatin/master","messageBody":"Update Azfarul About us","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"d5afb6bfea43555f6f259a086b672acaefd20e59","isMergeCommit":false,"messageTitle":"Add List function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":110,"deletions":29}}},{"hash":"57a05c0bd5b98cc8b3bafc5eb9a158684e7aa058","isMergeCommit":true,"messageTitle":"Merge pull request #44 from azfarulmatin/AzfarulMatin-ListCommand","messageBody":"Add List function","fileTypesAndContributionMap":{}},{"hash":"4a24ed0a7c4ba4280e8279f225d94eca57adc5eb","isMergeCommit":false,"messageTitle":"Fix checkstyle and junit test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":15}}},{"hash":"a1860305e34b8c74ade793866b25205f953c8319","isMergeCommit":true,"messageTitle":"Merge pull request #45 from azfarulmatin/AzfarulMatin-ListCommand","messageBody":"Fix checkstyle and junit test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"1dda9d2754e2a02578da9238442c6d10f7e66d6f","isMergeCommit":false,"messageTitle":"Add JUnit Test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":16,"deletions":0}}},{"hash":"440fa5dc27d5fd869d27429012fdbe5aeeae7619","isMergeCommit":true,"messageTitle":"Merge pull request #46 from azfarulmatin/AzfarulMatin-JUnitTestListCommand","messageBody":"Add JUnit Test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"3887203ffba5c298294ab19aea34a4d3ed459f58","isMergeCommit":false,"messageTitle":"Add assertions for ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"09522dd36305e098a7b90627e22eb45576b25579","isMergeCommit":true,"messageTitle":"Merge pull request #65 from azfarulmatin/master","messageBody":"Add assertions for ListCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"48b64546002893200c17724ba054f54c1593848a","isMergeCommit":false,"messageTitle":"Update ListCommand in Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":40,"deletions":0}}},{"hash":"c9f60b4f7e954b7f51ac2623133f116e513fd8d7","isMergeCommit":true,"messageTitle":"Merge pull request #87 from azfarulmatin/AzfarulMatin-DeveloperGuide","messageBody":"Update ListCommand in Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"a57e18d43167b17701ee7f2f0a2fa2366ccbe792","isMergeCommit":false,"messageTitle":"Update Developer Guide for List Command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":43,"deletions":8}}},{"hash":"f2e1f1c92f4955beb411e4b859b6044305d188c2","isMergeCommit":true,"messageTitle":"Merge pull request #119 from azfarulmatin/AzfarulMatin-DeveloperGuide","messageBody":"Update Developer Guide for List Command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"b31032defcf1a8e158d8b709ffc66cb236fc1ea3","isMergeCommit":true,"messageTitle":"Merge pull request #121 from karishma-t/karishma-get-description","messageBody":"Karishma - Add, Get, List description for drugs","fileTypesAndContributionMap":{}},{"hash":"e4abf37899eeac2e917598439cdefe9ace9f81a1","isMergeCommit":false,"messageTitle":"Update Find Command to search by serial number","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":138,"deletions":25},"test-code":{"insertions":22,"deletions":17}}},{"hash":"cb423576f586c6b09ebff9a220536207048ff865","isMergeCommit":true,"messageTitle":"Merge pull request #124 from azfarulmatin/AzfarulMatin-DeveloperGuide","messageBody":"Update Find Command to search by serial number","fileTypesAndContributionMap":{}},{"hash":"b469c4477a98e3222fcde982982e690a022e7a61","isMergeCommit":false,"messageTitle":"Update find command using serial number in Developer Guide","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":67},"docs":{"insertions":3,"deletions":0},"test-code":{"insertions":4,"deletions":2}}},{"hash":"d79a23da5f33ed363f4c83d84be5eee1252cd220","isMergeCommit":true,"messageTitle":"Merge pull request #125 from azfarulmatin/AzfarulMatin-CalculatePrice","messageBody":"Update find command using serial number in Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"975a03f405177fbaff0b13ecc7d213afe118feb8","isMergeCommit":false,"messageTitle":"Add Command Result in Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":55,"deletions":0}}},{"hash":"6c56dc73e5388f0598b3ef14aa6e000f685eeac9","isMergeCommit":true,"messageTitle":"Merge pull request #131 from azfarulmatin/AzfarulMatin-CalculatePrice","messageBody":"Add Command Result in Developer Guide","fileTypesAndContributionMap":{}},{"hash":"f342fa41d871b865ee773890cbb3c656f1bbcf29","isMergeCommit":false,"messageTitle":"Update Junit Test for find command using serial number","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":28,"deletions":0}}},{"hash":"23547920ad37f08136bc44d0b10ec01ff11e6d53","isMergeCommit":false,"messageTitle":"Update ListCommand Junit Test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":0}}},{"hash":"13d04c0da53fabf622696bc69035e9703834110c","isMergeCommit":true,"messageTitle":"Merge pull request #132 from azfarulmatin/AzfarulMatin-CalculatePrice","messageBody":"Update FindCommand Junit Test for serial number","tags":["v2.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"f73462e9c005e2430a123344db281db3ed2ffc22","isMergeCommit":true,"messageTitle":"Merge pull request #133 from karishma-t/karishma-Developer-Guide","messageBody":"Modify delete DG","fileTypesAndContributionMap":{}}]}],"TeoHaoZhi":[{"date":"2023-10-05","commitResults":[{"hash":"f2bef309abc1a31812e5cb92d52cc3edc1ea44c6","isMergeCommit":false,"messageTitle":"Update UserGuide.md to add theme","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":0}}},{"hash":"80b42e7c9d1a437ae8bed5f38e44c218f440f47c","isMergeCommit":true,"messageTitle":"Merge pull request #2 from Barbaracwx/Barbaracwx-AboutUs","messageBody":"Added Barbara.md","fileTypesAndContributionMap":{}},{"hash":"aa9ba0c6a59865a89b52a6f53b7df1df57bb99de","isMergeCommit":false,"messageTitle":"Add files for Hao Zhi\u0027s about us page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"78381da48ea0ab8048ffca83fc47af7dd59e458b","isMergeCommit":true,"messageTitle":"Merge branch \u0027HaoZhi-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c0c3018bd7af6a34e46ede0867b55d0a498285ce","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5034d288227d95c1a28ecc2359f1ea357dd3b437","isMergeCommit":true,"messageTitle":"Merge pull request #3 from TeoHaoZhi/master","messageBody":"Add HaoZhi\u0027s about us files","fileTypesAndContributionMap":{}},{"hash":"88803a7aec4b841305b2a7716850e466193ec107","isMergeCommit":false,"messageTitle":"Clean up UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":2}}}]},{"date":"2023-10-06","commitResults":[{"hash":"220ea22f86c3d933219eefa1ae6e0c2fabea1d44","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into karishma-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"800151596e695fdfd13c417def35fd80dc78fed4","isMergeCommit":true,"messageTitle":"Merge pull request #10 from karishma-t/karishma-AboutUs","messageBody":"Add Karishma about us","fileTypesAndContributionMap":{}},{"hash":"4a53af6054886017e9cf732a597960c970f202d4","isMergeCommit":false,"messageTitle":"Fix about us portfolio bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"eb792a86d1eb0fd6ea4e2bca18a1ed4e10c07661","isMergeCommit":true,"messageTitle":"Merge pull request #11 from TeoHaoZhi/master","messageBody":"Fix about us portfolio bug","fileTypesAndContributionMap":{}}]},{"date":"2023-10-08","commitResults":[{"hash":"090f7fd2112203bcd0f818c6a79ab83c1945118e","isMergeCommit":false,"messageTitle":"Rename classes","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":4,"deletions":4}}},{"hash":"cd37b8a6e9414c1fa24b68559ff23066fde03931","isMergeCommit":true,"messageTitle":"Merge pull request #23 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Rename classes","fileTypesAndContributionMap":{}},{"hash":"293aa145c39d8d91f975a08e7f0c8f491234cd7e","isMergeCommit":false,"messageTitle":"Add dummy classes","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":24,"deletions":0}}},{"hash":"3d5504d42b2532eadb56b49ff210b09cdd50284c","isMergeCommit":true,"messageTitle":"Merge pull request #24 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add dummy classes","fileTypesAndContributionMap":{}},{"hash":"d842866453c774e4e7cb523fc0f6d99109564fbb","isMergeCommit":false,"messageTitle":"Add attributes to drug class","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1},"test-code":{"insertions":46,"deletions":20}}},{"hash":"7988e7aab82f83af8ed057426371bc9f8066e5c2","isMergeCommit":true,"messageTitle":"Merge pull request #25 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add attributes to drug class","fileTypesAndContributionMap":{}},{"hash":"1746b905d7c8f9941ce95abe0c601ed7a555d341","isMergeCommit":false,"messageTitle":"Add help feature to UI class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":1}}},{"hash":"227af0572b033254d6546284a0ee2f875a71c3a9","isMergeCommit":true,"messageTitle":"Merge pull request #26 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add help feature to UI class","fileTypesAndContributionMap":{}},{"hash":"7299b86db5d860ab190c91abd4c6962273b196cd","isMergeCommit":false,"messageTitle":"Add exit point for programme","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":58,"deletions":11},"other":{"insertions":0,"deletions":0},"test-code":{"insertions":0,"deletions":49}}},{"hash":"de4799c7421e4b4195b2576cd2425462d6a6fa0e","isMergeCommit":true,"messageTitle":"Merge pull request #27 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Add exit point for programme","fileTypesAndContributionMap":{}},{"hash":"354c79d2f7cbb08fb7700ca95ef4ca362f2c172d","isMergeCommit":false,"messageTitle":"Refactor printing for help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":24}}},{"hash":"8ab6c94c4d553c98bdc4616b2841d95fea09e2e7","isMergeCommit":true,"messageTitle":"Merge pull request #28 from TeoHaoZhi/HaoZhi-TemplateAttempt2","messageBody":"Refactor printing for help command","fileTypesAndContributionMap":{}},{"hash":"5bf20560cb92c584383123cf1ba209e1943da17b","isMergeCommit":false,"messageTitle":"Add Junit test for help feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":5},"test-code":{"insertions":47,"deletions":0}}},{"hash":"0cce6790d3939b1aa5f6309f8c81e87f8490dceb","isMergeCommit":true,"messageTitle":"Merge pull request #29 from TeoHaoZhi/HaoZhi-JUnitTestForHelpFeature","messageBody":"Add Junit test for help feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-09","commitResults":[{"hash":"44f897c607a7bf71459ce63ef7a22368d8374d2c","isMergeCommit":true,"messageTitle":"Merge pull request #30 from martinschnder/branch-AddCommand","messageBody":"Branch add command","fileTypesAndContributionMap":{}},{"hash":"38f4573bdbf922271274ff418303a83c5ba9778e","isMergeCommit":false,"messageTitle":"Add more class templates","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":82,"deletions":22}}},{"hash":"7ab218bb640ddf7a60822ecd133989bcd0d2a220","isMergeCommit":true,"messageTitle":"Merge pull request #31 from TeoHaoZhi/HaoZhi-ListCommandHelp","messageBody":"Add more class templates","fileTypesAndContributionMap":{}}]},{"date":"2023-10-10","commitResults":[{"hash":"e366c56327163c3ebdcc63a2889b90ea43218e50","isMergeCommit":false,"messageTitle":"Update userguide markdown file","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":154,"deletions":12}}},{"hash":"67f9f7118ed7fe8c06884e7757e87e6c634fa6d8","isMergeCommit":true,"messageTitle":"Merge pull request #32 from TeoHaoZhi/HaoZhi-UserGuideUpdateV1.0","messageBody":"Update userguide markdown file","fileTypesAndContributionMap":{}},{"hash":"b6fd34963d346c40de9d71cb9ea43699a14d4b8d","isMergeCommit":false,"messageTitle":"Update README","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":2}}},{"hash":"a3f768d82e7036ec93e0543e7c2db1847279aa1c","isMergeCommit":true,"messageTitle":"Merge pull request #33 from TeoHaoZhi/HaoZhi-ReadMe","messageBody":"Update README","fileTypesAndContributionMap":{}},{"hash":"dc4311ad9d1840486a71ba7958140542108c093a","isMergeCommit":false,"messageTitle":"Add Junit test for help command","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":29,"deletions":0}}},{"hash":"324c68f05643be382892df3fec2ec0d7ea16d361","isMergeCommit":false,"messageTitle":"Fix checkstyle violation","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":5}}},{"hash":"7a54cf286c00c3cf7864d2bc4859e14c0e4c9a4d","isMergeCommit":true,"messageTitle":"Merge pull request #35 from TeoHaoZhi/HaoZhi-JUnitTestForHelpFeature","messageBody":"Add Junit test for help command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-11","commitResults":[{"hash":"bac5f0f114fe6974123b6090f5bfc2ad035bbf64","isMergeCommit":false,"messageTitle":"Edit Junit test for help","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":13,"deletions":13}}},{"hash":"e5380e513c5f79d6570dca09171f3f1fc58402d2","isMergeCommit":true,"messageTitle":"Merge pull request #36 from TeoHaoZhi/HaoZhi-JUnitTestForHelpFeature","messageBody":"Edit Junit test for help","fileTypesAndContributionMap":{}},{"hash":"350fcc060811c2f4e25cb36254f2bd7845ea9338","isMergeCommit":false,"messageTitle":"Add methods to write to txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":0}}},{"hash":"a46e5821d0bcebdf8cc07433cfb197f7fd91490b","isMergeCommit":false,"messageTitle":"Update method to append to txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4}}},{"hash":"d25c1fefd9e13e3320c18ff49032c4dfc91e93a4","isMergeCommit":false,"messageTitle":"Add login system class to handle login features","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":124,"deletions":0}}},{"hash":"366c60438a5b4307401d2af9368d4c60d28dc73f","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":8}}},{"hash":"be08c4a84413626b9f7bcc47b0264320f8ecb7bd","isMergeCommit":true,"messageTitle":"Merge pull request #37 from TeoHaoZhi/HaoZhi-LoginFeatureAttempt1","messageBody":"Add login system class","fileTypesAndContributionMap":{}},{"hash":"d2aef4c2cf81d80323363559b85cd7dcc5aad9d1","isMergeCommit":false,"messageTitle":"Fix infinite while loop","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"5847e7d3f2046d0a5d03b96582f032e83b8d2443","isMergeCommit":false,"messageTitle":"Fix bug of overwriting txt file instead of adding to it","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":4}}},{"hash":"f4fec5773b73e56a551fc2f99440e3b21f9646b1","isMergeCommit":false,"messageTitle":"Fix bugs in login system class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":89,"deletions":17}}},{"hash":"c35451f09fa1f1f1423fa4e8ad3d75679d362e2b","isMergeCommit":false,"messageTitle":"FIx Bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":20}}},{"hash":"7617592e5273ba22fa90061e426827bbed215362","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":6}}}]},{"date":"2023-10-12","commitResults":[{"hash":"ab49cf95fb9ceab78bfb2b6c312dbd694de75ff9","isMergeCommit":false,"messageTitle":"FIx bug causing failing CI test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":27}}},{"hash":"5323884d9709dde52cf9cd1670bc8f9274e3ad90","isMergeCommit":true,"messageTitle":"Merge pull request #38 from TeoHaoZhi/HaoZhi-LoginFeatureAttempt1","messageBody":"Login attempt bug fix 1","fileTypesAndContributionMap":{}},{"hash":"5b76d7f4809b669df3bcaab0d3c8c352d856d267","isMergeCommit":false,"messageTitle":"Fix printing formatting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":17}}}]},{"date":"2023-10-14","commitResults":[{"hash":"10259ca61e695c8802fec0130f28e74e79e8e7a5","isMergeCommit":false,"messageTitle":"Add assertion for login system","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"other":{"insertions":1,"deletions":0}}},{"hash":"988ee96196908057baaa52e3c90e60bf2eda330c","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"6aaeb409f9ed28c1096b87feda862eff1758f9c5","isMergeCommit":false,"messageTitle":"Edit runtest.sh file to disable it","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"e917a9b035a3b985e45f43336a0e3e88a1438d6f","isMergeCommit":false,"messageTitle":"Fix bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":3},"test-code":{"insertions":1,"deletions":1}}},{"hash":"28336545c9ca20145bd634e797f0ac345650ab7e","isMergeCommit":false,"messageTitle":"Edit runtest.bat to disable IO test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"389f5999bc5fcee00d3e38aa2b8e6693fcbad44d","isMergeCommit":true,"messageTitle":"Merge pull request #40 from TeoHaoZhi/HaoZhi-BugfixLogin","messageBody":"Add assertion for login system","fileTypesAndContributionMap":{}},{"hash":"fd5869a315e63b3e4c9daa003af97dcd133a587e","isMergeCommit":false,"messageTitle":"Added messages to let UI handle printing of messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":19}}},{"hash":"38a69c177d2e593158303f95f1e3f2a5e2134ab5","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":70,"deletions":22}}},{"hash":"a4be93035d88733cf3f1953bda32ace09527017b","isMergeCommit":true,"messageTitle":"Merge pull request #41 from TeoHaoZhi/LoginMessagesFix","messageBody":"Added messages to let UI handle printing of messages","fileTypesAndContributionMap":{}},{"hash":"3528ac948b94285edb8196292d9955d1559b06dc","isMergeCommit":false,"messageTitle":"Update javadoc for login system class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":3}}},{"hash":"724368c8a4964dddcb0e716f7d37672d523d20f3","isMergeCommit":true,"messageTitle":"Merge pull request #42 from TeoHaoZhi/HaoZhi-JavaDocLoginSystem","messageBody":"Update javadoc for login system class","fileTypesAndContributionMap":{}},{"hash":"c9782f17e67050c1dd5b05b5ff7b3dba093e6780","isMergeCommit":false,"messageTitle":"Added java doc for file storage class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":3}}},{"hash":"01e37de8ce32537e7df7854fa385be003f07ea71","isMergeCommit":true,"messageTitle":"Merge pull request #43 from TeoHaoZhi/Javadoc","messageBody":"Added java doc for file storage class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"8573f29dd50f626312f717999098767234e5ab67","isMergeCommit":false,"messageTitle":"Add userguide on login system","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":59,"deletions":20}}},{"hash":"df15ef01089d4ccc1210bc929a19a5bc0c69095a","isMergeCommit":false,"messageTitle":"Fix Junit test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":12},"test-code":{"insertions":47,"deletions":30}}},{"hash":"f68a2eea9a7c6a51fc7ed0980c82bbe61486a20c","isMergeCommit":true,"messageTitle":"Merge pull request #47 from TeoHaoZhi/HaoZhi-MarkDown","messageBody":"Edit userguide","fileTypesAndContributionMap":{}},{"hash":"1ec8b571b25dada302c74e04f3398697ab08a189","isMergeCommit":false,"messageTitle":"Fix bug of blank input for username and password","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":8}}},{"hash":"6f77ee60f5ed10366ecfbcc8a3d26b20f5c9d528","isMergeCommit":true,"messageTitle":"Merge pull request #48 from TeoHaoZhi/LoginSystemBlankinput","messageBody":"Fix bug of blank input for username and password","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"b6cb73dbbfd6780178d32c3949b2fd24f046e11e","isMergeCommit":true,"messageTitle":"Merge pull request #50 from Barbaracwx/branch-FindCommandNew","messageBody":"Branch find command new","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"2d9902628161064ffcd7105230dd6fa765b188ca","isMergeCommit":false,"messageTitle":"Update user guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":5}}},{"hash":"e01effd8dc540db39d938e72fa2dc7d0f0cb72b5","isMergeCommit":true,"messageTitle":"Merge pull request #54 from TeoHaoZhi/HaoZhi-UpdateUserGuide","messageBody":"Update user guide","fileTypesAndContributionMap":{}},{"hash":"f53e9e97737095dc7367aba076d5f5f98d120061","isMergeCommit":true,"messageTitle":"Merge pull request #55 from Barbaracwx/branch-TestCodeFindCommand","messageBody":"Added j unit test","fileTypesAndContributionMap":{}},{"hash":"14271486fb1978d5c85475b176ff6f34c0160998","isMergeCommit":true,"messageTitle":"Merge pull request #52 from karishma-t/karishma-DeleteCommand","messageBody":"Add delete command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"7d3d19836e43e535ca879db7a2f24e84fb2ade61","isMergeCommit":true,"messageTitle":"Merge pull request #57 from Barbaracwx/master","messageBody":"changed findCommand to add ui class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"29f5aec77019ca6585b88faf87f1c5a812cb8663","isMergeCommit":true,"messageTitle":"Merge pull request #60 from Barbaracwx/branch-assertionStatement","messageBody":"added assertion statement","fileTypesAndContributionMap":{}},{"hash":"9c0f2d2c8ce561200f6b7c15c96d645ef87c2357","isMergeCommit":true,"messageTitle":"Merge pull request #61 from Barbaracwx/branch-CodeTest","messageBody":"edited FindCommandTest cases","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"0d83e630f1be68cc6ee693a7e8e8efd07703d072","isMergeCommit":true,"messageTitle":"Merge pull request #64 from Barbaracwx/branch-FindCommandName","messageBody":"add find command using both name and date","fileTypesAndContributionMap":{}},{"hash":"a5ce4e7ef58f1828ca4061d12735e197f8b1d03e","isMergeCommit":true,"messageTitle":"Merge pull request #66 from Barbaracwx/branch-UserGuide","messageBody":"changed user guide according to new find function","fileTypesAndContributionMap":{}},{"hash":"b24a4051f1319ef08dcf942aa00fd5002f86b3f3","isMergeCommit":false,"messageTitle":"Add register and login commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":83,"deletions":28}}},{"hash":"d48892620bf2425f4d20f7bf67f119d866e7aba6","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":6},"test-code":{"insertions":12,"deletions":2}}},{"hash":"41b3713088803f0fa62c1701e642c1a7f82f3de0","isMergeCommit":true,"messageTitle":"Merge pull request #68 from TeoHaoZhi/HaoZhi-RegisterClass","messageBody":"Add register command and login command","fileTypesAndContributionMap":{}},{"hash":"7cc709dbb251572295f802094e1290f43d252837","isMergeCommit":false,"messageTitle":"Update userguide to reflect register and login feature","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":54,"deletions":2}}},{"hash":"2d8343571d10857aae93337064ae0f04eac9105b","isMergeCommit":true,"messageTitle":"Merge pull request #69 from TeoHaoZhi/HaoZhi-UpdateUserGuide","messageBody":"Update userguide to reflect register and login feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-21","commitResults":[{"hash":"0bf3c4287787d2f9b4bea2ea4dd9c5fdb0da70da","isMergeCommit":false,"messageTitle":"Add save feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":93,"deletions":6},"test-code":{"insertions":5,"deletions":0}}},{"hash":"b18733d8b51c292afa238a16e6cb240638acb2e3","isMergeCommit":true,"messageTitle":"Merge pull request #71 from TeoHaoZhi/HaoZhi-SaveFeature","messageBody":"Add save feature","fileTypesAndContributionMap":{}},{"hash":"f3cc4e3e29ffde5997c1ebbea5db55f590d3e8ff","isMergeCommit":false,"messageTitle":"Update Userguide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":1}}},{"hash":"5f4541a2603dfded61643c40c14e898d37ae263d","isMergeCommit":true,"messageTitle":"Merge pull request #72 from TeoHaoZhi/HaoZhi-UpdateUserGuide","messageBody":"Update Userguide","fileTypesAndContributionMap":{}},{"hash":"5d82131cb223c10000d72b98f149435e68aba0e8","isMergeCommit":false,"messageTitle":"Update Developer guide","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"docs":{"insertions":46,"deletions":0}}},{"hash":"b791625622c1516b144b9178b6a788114f82cfa8","isMergeCommit":true,"messageTitle":"Merge pull request #73 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer guide","fileTypesAndContributionMap":{}},{"hash":"0699a596754f2b7bcc9f8b9c8be51117e12076c8","isMergeCommit":false,"messageTitle":"Update DeveloperGuide to include login system component","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":69,"deletions":3}}},{"hash":"718424751b2e26e41abb1a6a086f72f8d92057cb","isMergeCommit":true,"messageTitle":"Merge pull request #74 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update DeveloperGuide to include login system component","fileTypesAndContributionMap":{}},{"hash":"b28bae84c2fa402631c454cf16c43958e15246f8","isMergeCommit":false,"messageTitle":"Add exception handling for authenticateUserChoice method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":64},"test-code":{"insertions":0,"deletions":32}}},{"hash":"09293249c3f92cca9610c6b6ba142746f72f48bc","isMergeCommit":false,"messageTitle":"Add Java Docs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":3}}},{"hash":"caf33c93038f985dd0c421a78c1fc6ef14488a58","isMergeCommit":false,"messageTitle":"Add Java docs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":3}}},{"hash":"7f6e4dff2b472cb0a5c1c4ce0ecee507b448bc43","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":2}}},{"hash":"f1c6fa86da1e89edb3bb0802ead8b106089ea597","isMergeCommit":true,"messageTitle":"Merge pull request #75 from TeoHaoZhi/HaoZhi-Exceptions","messageBody":"Add execeptions and java docs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"9fea2f7bfa79c6c199ae33ed4f31dd788db2db55","isMergeCommit":true,"messageTitle":"Merge pull request #76 from martinschnder/sellCommand","messageBody":"Modify inventory structure and add all the command needed to make a sale","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"343ee190fb97f978ea49283551f6b591dd74267d","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":1}}},{"hash":"667c4a20e434525f5a1a9f4039e3c5656142ab8b","isMergeCommit":true,"messageTitle":"Merge pull request #78 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"0a9460e3de3e58fce483e11d6e315f2a2a66ea09","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"d6550e227a02e5ad46ede2649311aef426157414","isMergeCommit":true,"messageTitle":"Merge pull request #79 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"c92c67f4c1c94bc78dc52f58b399463f79446b6d","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":2}}},{"hash":"703a81938475b50a9ace0d9f0cdf0cb8af2b34f7","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":0}}},{"hash":"0baae65260c6fd8d638c021533b2542c4303c532","isMergeCommit":true,"messageTitle":"Merge pull request #81 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"68c9a0f44cb5a6028a69c5594fc19067342b1bab","isMergeCommit":true,"messageTitle":"Merge pull request #80 from Barbaracwx/branch-DeveloperGuide","messageBody":"updated Developer\u0027s Guide","fileTypesAndContributionMap":{}},{"hash":"6adc3cfd32ab71f4d124fc8771bd03d92a8c4cc9","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":3}}},{"hash":"33e5b4e4146befa4911d42d109c138db7dea126c","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"f6dc78291cee2f7449a9d394b0ddd239d5741a5a","isMergeCommit":true,"messageTitle":"Merge pull request #82 from TeoHaoZhi/HaoZhi-DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"505f9c3c012219f07d38e5f2d03df9b2c8279921","isMergeCommit":true,"messageTitle":"Merge pull request #83 from Barbaracwx/branch-developersguideNew","messageBody":"updated developer\u0027s guide","fileTypesAndContributionMap":{}},{"hash":"674724af608464b0234c47546677d88ec094dba1","isMergeCommit":true,"messageTitle":"Merge pull request #85 from Barbaracwx/master","messageBody":"added uml diagrams","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"21d68cfa0f59bf19906c45126f282343b31d5e46","isMergeCommit":true,"messageTitle":"Merge pull request #89 from Barbaracwx/findcommandtest","messageBody":"Findcommandtest","fileTypesAndContributionMap":{}},{"hash":"1a0eacc8cf28b010d683eb8d3a33a54ec95817d1","isMergeCommit":true,"messageTitle":"Merge pull request #91 from karishma-t/karishma-Developer-Guide","messageBody":"Modify DG for delete","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"e3356ce5fbcc07cc6748c03ac24376471d6d0a67","isMergeCommit":false,"messageTitle":"Update UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":20}}},{"hash":"71b41675d7a09a3cb8d6dd173ec740a1a998ce8d","isMergeCommit":true,"messageTitle":"Merge pull request #93 from TeoHaoZhi/UML","messageBody":"Update UML","fileTypesAndContributionMap":{}},{"hash":"e14d45429110d0454025237a1fb5c3259767bfa8","isMergeCommit":false,"messageTitle":"Add addVendor Command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":116,"deletions":16}}},{"hash":"b284882a9d1d2fd1a2ab200a0535cf84893fbe81","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":14}}},{"hash":"e4693841e4871364b409a2e567344d3b2d1c6d20","isMergeCommit":true,"messageTitle":"Merge pull request #95 from Barbaracwx/branch-StockLevel","messageBody":"added new stock level command","fileTypesAndContributionMap":{}},{"hash":"ec3e45d82c30f673e4397e7ff92f81036c1ee804","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Vendors","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"16c103da5094704ef33f3bcce063383e7d27b627","isMergeCommit":true,"messageTitle":"Merge pull request #94 from TeoHaoZhi/Vendors","messageBody":"Add addVendor Feature","fileTypesAndContributionMap":{}},{"hash":"7771c5e3be64819ed47f08353d536e8597dd27b9","isMergeCommit":false,"messageTitle":"Fix addVendor bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"59675fad58796c4a82fbbeebc773a67e88b1f63c","isMergeCommit":true,"messageTitle":"Merge pull request #98 from TeoHaoZhi/Vendors","messageBody":"Fix addVendor bug","fileTypesAndContributionMap":{}},{"hash":"dd8be75f2dcad5340c4c1c01f8bc3b07d81ec7a6","isMergeCommit":false,"messageTitle":"Fix abstraction","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":31}}},{"hash":"8003e19cfac858b4a412d0893f0fea135324c2d9","isMergeCommit":true,"messageTitle":"Merge pull request #99 from TeoHaoZhi/FixAbstraction","messageBody":"Fix abstraction","fileTypesAndContributionMap":{}},{"hash":"0d5a92c12ad67bc214a2b6cf1577ed6e04088fe9","isMergeCommit":false,"messageTitle":"Add VendorList Feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":53,"deletions":1},"test-code":{"insertions":61,"deletions":47}}},{"hash":"ade809a860d139a306dde45776fa856e5b1ebf30","isMergeCommit":true,"messageTitle":"Merge pull request #101 from TeoHaoZhi/VendorListFeature","messageBody":"Add VendorList Feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"6cc361564e253b755fbd64da229ec2b717368599","isMergeCommit":false,"messageTitle":"Update Java Docs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":2}}},{"hash":"7544968cd74382ab68734fe61607008395dd4610","isMergeCommit":true,"messageTitle":"Merge pull request #102 from TeoHaoZhi/Javadoc","messageBody":"Update Java Docs","fileTypesAndContributionMap":{}},{"hash":"c6381578a9674e214188ccce351a9f40b917e5be","isMergeCommit":false,"messageTitle":"Update User guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":51,"deletions":2}}},{"hash":"fef7feda7f40d84f6f849e6dd19c1a2f9f44f461","isMergeCommit":true,"messageTitle":"Merge pull request #103 from TeoHaoZhi/UserGuide","messageBody":"Update User guide and UML diagram","fileTypesAndContributionMap":{}},{"hash":"f794fa615e63df9591f96720f081f57b1e167b13","isMergeCommit":false,"messageTitle":"Update Developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":15,"deletions":1}}},{"hash":"035e8005eabf106c4bae9247d28d93e9844c947a","isMergeCommit":true,"messageTitle":"Merge pull request #104 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer guide","fileTypesAndContributionMap":{}},{"hash":"4d74b146a0b288d69094b0a9651b8bfb6a83d29a","isMergeCommit":false,"messageTitle":"Update Developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":20,"deletions":0}}},{"hash":"449e91de789b9a45040398b06f64e79ba7746940","isMergeCommit":true,"messageTitle":"Merge pull request #106 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer guide","fileTypesAndContributionMap":{}},{"hash":"9097e5b1de1d8e8f285f9963c23a981291f40d7c","isMergeCommit":true,"messageTitle":"Merge pull request #107 from Barbaracwx/branch-UGnew","messageBody":"updated UG with stock level command","fileTypesAndContributionMap":{}},{"hash":"16c27768dd4411ee65ada23e2ced21503514493f","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":1}}},{"hash":"6486fe783c57563e9785ee0d2094b56b74ba2af3","isMergeCommit":true,"messageTitle":"Merge pull request #108 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"fe61f782aaefc5bdd638ba5d44f2426f6d49475c","isMergeCommit":false,"messageTitle":"Update Developer Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":0}}},{"hash":"a0c49e6186db8768dba66f3514bdf382e81e5255","isMergeCommit":true,"messageTitle":"Merge pull request #109 from TeoHaoZhi/DeveloperGuide","messageBody":"Update Developer Guide","fileTypesAndContributionMap":{}},{"hash":"e2c7c8aa62125a76dae3ae4eb1dee3b22e5ced5f","isMergeCommit":true,"messageTitle":"Merge pull request #110 from Barbaracwx/branch-stocklevelcommandtest","messageBody":"added stock level command test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"99a653ca1f358d68dca01775ae844424f29d58d3","isMergeCommit":false,"messageTitle":"Update user stories in developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":9}}},{"hash":"1ddfd266cc46d84059ddb735d986e454e7ea48a9","isMergeCommit":true,"messageTitle":"Merge pull request #114 from TeoHaoZhi/DeveloperGuide","messageBody":"Update user stories in developer guide","fileTypesAndContributionMap":{}},{"hash":"136f039ce2872e4994a96adc8cf15f75f467dda8","isMergeCommit":true,"messageTitle":"Merge pull request #117 from Barbaracwx/branch-newListThreshold","messageBody":"add new list threshold command","fileTypesAndContributionMap":{}},{"hash":"c633713005d3c2bd179b5af4e6686b4d4289bb45","isMergeCommit":true,"messageTitle":"Merge pull request #118 from Barbaracwx/branch-newListThreshold","messageBody":"added List Threshold Command Test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"fe89447933c98a7254740addddfc5e0cf6fd4cda","isMergeCommit":true,"messageTitle":"Merge pull request #126 from Barbaracwx/DG-parser","messageBody":"added description for parser class in DG","fileTypesAndContributionMap":{}},{"hash":"57ee8fc6c6b2185bfb9cad1638ff39ec5629338b","isMergeCommit":true,"messageTitle":"Merge pull request #127 from karishma-t/karishma-VendorSupply","messageBody":"Karishma vendor supply","fileTypesAndContributionMap":{}},{"hash":"72f99025b879f2f438767edb40a5fa8119f94170","isMergeCommit":true,"messageTitle":"Merge pull request #128 from Barbaracwx/DG-parser","messageBody":"added parser diagram","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"407d2dd9c5926becd4373c76f0463386eb18b198","isMergeCommit":true,"messageTitle":"Merge pull request #129 from Barbaracwx/branch-updateUG","messageBody":"update UG","fileTypesAndContributionMap":{}},{"hash":"dd17f9b22d031de4e7c8a1b7fb54f1d267ccd4bf","isMergeCommit":true,"messageTitle":"Merge pull request #130 from karishma-t/karishma-updateUG","messageBody":"Update UG","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"5cb9b755b78fb3d3364cc1b631d5d8de9ada5669","isMergeCommit":false,"messageTitle":"Fix Ped Bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":24}}},{"hash":"ef45263345a982c182cf9a570fdd9921f6d9ccac","isMergeCommit":false,"messageTitle":"Fix Ped UserGuide bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"a946e64f1d994f2a99143625b76b6859a223913a","isMergeCommit":true,"messageTitle":"Merge pull request #208 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"e7640febc4a8ee83ac38a64b4ceb5f6282564621","isMergeCommit":false,"messageTitle":"Fix login system PED Bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"741f27e8b78696049da9188182534b690a2058cf","isMergeCommit":true,"messageTitle":"Merge pull request #209 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix login system PED Bugs","fileTypesAndContributionMap":{}},{"hash":"7e111f887969a02d845722ee47579404233e5936","isMergeCommit":false,"messageTitle":"Fix grammer error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"037a76facc4108c9f8ca24b236d49c1c4e2e1116","isMergeCommit":false,"messageTitle":"Update UserGuide FAQ","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":1}}},{"hash":"509339ae773b7a8cbd5508b6adc4117c51cd5f74","isMergeCommit":true,"messageTitle":"Merge pull request #210 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"07a567585e6de9d58103e99c06582a06c56c36b6","isMergeCommit":false,"messageTitle":"Update UserGuide to fix PED bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"ad706645187212947926bcedf3af1a041ef181f1","isMergeCommit":false,"messageTitle":"Fix User Guide PED Bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"83997d31f2199fc69afa7f4084351aa30ec05a82","isMergeCommit":true,"messageTitle":"Merge pull request #211 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"76a4f629ec37687e5c39cfa0f0befd7a39061c44","isMergeCommit":false,"messageTitle":"Fix UserGuide PED","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"940f9063964bd156950aecebdb3a381e26fd3348","isMergeCommit":true,"messageTitle":"Merge pull request #212 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix UserGuide PED","fileTypesAndContributionMap":{}},{"hash":"408b7dc0b2b4fda95a9e5222a1b14ab2ce9ceadc","isMergeCommit":false,"messageTitle":"Add Table of contents to UserGuide to fix PED issue","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":0}}},{"hash":"b676f6fb354c02ee0bbee823ee4112b33a431dd3","isMergeCommit":true,"messageTitle":"Merge pull request #213 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Add Table of contents to UserGuide to fix PED issue","fileTypesAndContributionMap":{}},{"hash":"7928b0b252f70171a95cd2ed69e8ee076e101cce","isMergeCommit":false,"messageTitle":"Fix Ped Bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":14},"docs":{"insertions":1,"deletions":0}}},{"hash":"f907e0a9f254365eb50de545c8deaa76922b616d","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":1}}},{"hash":"c5fd2260c883ae7d176352a5f30c9b25d8ea3ba8","isMergeCommit":true,"messageTitle":"Merge pull request #214 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Ped bug fixes hao zhi","fileTypesAndContributionMap":{}},{"hash":"99c5b4176928a1f4f250c5d073759e2dde809ce2","isMergeCommit":false,"messageTitle":"Fix userguide PED Bug","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":0}}},{"hash":"95adc7ff7f36996d35938e257943a11c4eecefa7","isMergeCommit":true,"messageTitle":"Merge pull request #215 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix userguide PED Bug","fileTypesAndContributionMap":{}},{"hash":"ad470e2cc641d4a17a033e45e23c976e1125bcd3","isMergeCommit":false,"messageTitle":"Fix PED save command bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"890992442e02d2d69054b43ac83479eb0a5d1391","isMergeCommit":false,"messageTitle":"Fix PED bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"18ef8993897d5c038effe37dd607c539f979911a","isMergeCommit":true,"messageTitle":"Merge pull request #216 from TeoHaoZhi/PED_Bug_Fixes_HaoZhi","messageBody":"Fix PED save command bug","fileTypesAndContributionMap":{}}]}],"Barbaracwx":[{"date":"2023-10-05","commitResults":[{"hash":"91e8e21dc2263c8657a5df7cb911512e24f1bf43","isMergeCommit":false,"messageTitle":"Added Barbara.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"ad260c19eda658e1aa9478315b4eb25553e0b865","isMergeCommit":true,"messageTitle":"Merge branch \u0027Barbaracwx-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-12","commitResults":[{"hash":"4e4b091ddc0b16dd22533420b4b27b848a03b825","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"180b32eebac4e0d2436dabe817edb0cba055abd9","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"84b79a21099e3b74dc3e06f5eba86dff72264aba","isMergeCommit":false,"messageTitle":"Add Find Command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":15}}},{"hash":"86beea836dfe6c2c103e3f4d3fdb76fc7d9d0a35","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-findCommand\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"7d4f40b7f2bed79141a458898b06fca9f8c62587","isMergeCommit":false,"messageTitle":"add new find function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":15}}}]},{"date":"2023-10-17","commitResults":[{"hash":"ddcac51425f93cb187d620c962346d2b3d9751e2","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c51866c18f620a0e7d5156750805158e33e2e100","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-3/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"95245940faaa042c2d33722b8d8d0560849a3bb6","isMergeCommit":false,"messageTitle":"Added j unit test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":23,"deletions":0}}},{"hash":"4ff1edf92e602aa27f78e0c3d3a41d6c79330085","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3791585a90b35d360f8a80b8f48d5b2f9116505e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"06e11cafceac7c118b71d331893b25db1f57c313","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c2fa2315a0de008062a8b5cf5841c290b1a243ea","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-3/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"2b72a18f3da1599eaf69f5d70a5773b82e6a3748","isMergeCommit":false,"messageTitle":"change find command class to add ui class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":11},"test-code":{"insertions":16,"deletions":6}}},{"hash":"397da38e3c33d4dd15025228a9c9c85e7ffb7a11","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Barbaracwx/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"5f6c065cadd0495287d2833fc544ae57491a64f0","isMergeCommit":false,"messageTitle":"added assertion statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"44e4e274eed15e597cb23df11f610716ebd52ccf","isMergeCommit":false,"messageTitle":"edited FindCommandTest cases","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":1},"test-code":{"insertions":10,"deletions":2}}}]},{"date":"2023-10-20","commitResults":[{"hash":"b06f328e50f72cc60b07d213aa938ba3f60e0309","isMergeCommit":false,"messageTitle":"add find command using both name and date","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":11},"test-code":{"insertions":8,"deletions":3}}},{"hash":"56171fad030833f03447323c39661904f90662ff","isMergeCommit":false,"messageTitle":"changed user guide according to new find function","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":35,"deletions":15}}}]},{"date":"2023-10-25","commitResults":[{"hash":"03d6f232ad01fbb68be912b33d89572d9c519e89","isMergeCommit":false,"messageTitle":"updated Developer\u0027s Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":55,"deletions":21}}},{"hash":"c235d47ce2aa21b70716cada4e37cc434e015d30","isMergeCommit":false,"messageTitle":"updated developer\u0027s guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":83,"deletions":1}}},{"hash":"5c3ae6371909ff03735045d6178edd07b35230f8","isMergeCommit":false,"messageTitle":"added uml diagrams","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":52,"deletions":0}}}]},{"date":"2023-10-26","commitResults":[{"hash":"8fd0581bb131c46c9d2c4dcb3c609de4d35d5939","isMergeCommit":false,"messageTitle":"added more find command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":14},"test-code":{"insertions":51,"deletions":12}}},{"hash":"080c98c29d89a1138a24193e168dfb7768f4f1a8","isMergeCommit":false,"messageTitle":"added more find command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":16},"test-code":{"insertions":16,"deletions":3}}},{"hash":"14e5eee09b7bd035c3430e7ee741990cfef3a356","isMergeCommit":false,"messageTitle":"changed find command sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":1}}},{"hash":"0a9986d8b0c6ebbd10c964743992b64efdf0ac00","isMergeCommit":false,"messageTitle":"changed sequence diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-28","commitResults":[{"hash":"bc7d8f25061432371b62776859d16689283ed7f8","isMergeCommit":false,"messageTitle":"added new stock level command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":113,"deletions":45},"test-code":{"insertions":5,"deletions":0}}}]},{"date":"2023-10-29","commitResults":[{"hash":"92805b4d14bae7dbb680a8bc830f22ea6cb3eadd","isMergeCommit":false,"messageTitle":"updated UG with stock level command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":32,"deletions":8}}},{"hash":"3fa4734a468c6253b0e769b116d0d74e77b3fc9c","isMergeCommit":false,"messageTitle":"added stock level command test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":44,"deletions":0}}},{"hash":"8295f445488c08263a248ab1ab6c753bffdace76","isMergeCommit":false,"messageTitle":"add set threshold quantity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":93,"deletions":6}}},{"hash":"d7f07141cbb795161500b7f24bcf459d326de38f","isMergeCommit":false,"messageTitle":"updated set threshold command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"15f92bfa2157af06e4ee0fc567597e7207f39e31","isMergeCommit":false,"messageTitle":"updated new set threshold method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":5}}},{"hash":"1d2b93386b284102aaae2d5efbe8395cd05b0194","isMergeCommit":false,"messageTitle":"updated set threshold method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"70c3ba37a5e49c211b5ff7a581de476ac43fe0f3","isMergeCommit":false,"messageTitle":"add new set threshold method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}}]},{"date":"2023-10-30","commitResults":[{"hash":"0e8c6140a33d71752714756f2f9aae7ad4817e2a","isMergeCommit":false,"messageTitle":"add new list threshold command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":0}}},{"hash":"944fb5d18850531d471b163613a55261475fe894","isMergeCommit":false,"messageTitle":"added show stock level command test for empty inventory","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":12,"deletions":0}}},{"hash":"12cc11258a04b1d8e52c7c7ddcf74a9d0df1043d","isMergeCommit":false,"messageTitle":"added javadoc comments to set threshold command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":3}}},{"hash":"e7e030b72b17e7c35e7399cfd40fdab370e4cabe","isMergeCommit":false,"messageTitle":"updated javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":1}}},{"hash":"50daeacf6f33fe62e8265c05b60707ecb86b429b","isMergeCommit":false,"messageTitle":"added set threshold command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":8},"test-code":{"insertions":50,"deletions":0}}},{"hash":"be10a9f9c8aa6d2dff57ce377782047a3def5e87","isMergeCommit":false,"messageTitle":"added List Threshold Command Test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":40,"deletions":0}}}]},{"date":"2023-10-31","commitResults":[{"hash":"d59d61d59c4ab5b66e4e0ef6dab5cef775c884fe","isMergeCommit":false,"messageTitle":"added description for parser class in DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":136,"deletions":33}}},{"hash":"daf87ec60a850219a8273eb8c50959fea45758e3","isMergeCommit":false,"messageTitle":"added parser diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":22,"deletions":0}}}]},{"date":"2023-11-01","commitResults":[{"hash":"d84e998671732920801ffd28d7b250490abb1f81","isMergeCommit":false,"messageTitle":"update UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0},"docs":{"insertions":43,"deletions":0},"test-code":{"insertions":10,"deletions":0}}},{"hash":"5a4a03d76af225d75a16f272ae95953cf9d1d495","isMergeCommit":false,"messageTitle":"update UG","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":4,"deletions":2}}}]}]},"authorFileTypeContributionMap":{"karishma-t":{"docs":186,"functional-code":452,"test-code":62},"martinschnder":{"docs":135,"functional-code":775,"test-code":100,"other":2},"azfarulmatin":{"docs":128,"functional-code":145,"test-code":68},"TeoHaoZhi":{"docs":488,"functional-code":771,"test-code":84,"other":3},"Barbaracwx":{"docs":402,"functional-code":308,"test-code":241}},"authorContributionVariance":{"karishma-t":4716.0684,"martinschnder":18924.748,"azfarulmatin":2525.051,"TeoHaoZhi":14890.697,"Barbaracwx":4161.742},"authorDisplayNameMap":{"karishma-t":"CS2113-T17-3 KARI..ARAN","martinschnder":"CS2113-T17-3 SCHN..ILLE","azfarulmatin":"CS2113-T17-3 AZFA..ANDI","TeoHaoZhi":"CS2113-T17-3 TEO .. ZHI","Barbaracwx":"CS2113-T17-3 CHON..BARA"}} diff --git a/AY2324S1-CS2113-T17-4_tp_master/authorship.json b/AY2324S1-CS2113-T17-4_tp_master/authorship.json index 64cf490..4497dfb 100644 --- a/AY2324S1-CS2113-T17-4_tp_master/authorship.json +++ b/AY2324S1-CS2113-T17-4_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Duke project template","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":"This is a project template for a greenfield Java project. It\u0027s named after the Java mascot _Duke_. Given below are instructions on how to use it.","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"## Setting up in Intellij","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"Prerequisites: JDK 11 (use the exact version), update Intellij to the most recent version.","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"1. **Ensure Intellij JDK 11 is defined as an SDK**, as described [here](https://www.jetbrains.com/help/idea/sdk.html#set-up-jdk) -- this step is not needed if you have used JDK 11 in a previous Intellij project.","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"1. **Import the project _as a Gradle project_**, as described [here](https://se-education.org/guides/tutorials/intellijImportGradleProject.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"1. **Verify the set up**: After the importing is complete, locate the `src/main/java/seedu/duke/Duke.java` file, right-click it, and choose `Run Duke.main()`. If the setup is correct, you should see something like the below: i love 2113 ","lastModifiedDate":"2023-10-05"},{"lineNumber":12,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" \u003e Task :compileJava","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":" \u003e Task :processResources NO-SOURCE","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":" \u003e Task :classes","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":" \u003e Task :Duke.main()","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":" Hello from","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" ____ _ ","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" | _ \\ _ _| | _____ ","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" | | | | | | | |/ / _ \\","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" | |_| | |_| | \u003c __/","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" |____/ \\__,_|_|\\_\\___|","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":25,"author":{"gitId":"-"},"content":" What is your name?","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" Type some word and press enter to let the execution proceed to the end.","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"## Build automation using Gradle","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"* This project uses Gradle for build automation and dependency management. It includes a basic build script as well (i.e. the `build.gradle` file).","lastModifiedDate":"2020-05-24"},{"lineNumber":32,"author":{"gitId":"-"},"content":"* If you are new to Gradle, refer to the [Gradle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/gradle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":34,"author":{"gitId":"-"},"content":"## Testing","lastModifiedDate":"2020-05-24"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"-"},"content":"### I/O redirection tests","lastModifiedDate":"2020-05-24"},{"lineNumber":37,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"* To run _I/O redirection_ tests (aka _Text UI tests_), navigate to the `text-ui-test` and run the `runtest(.bat/.sh)` script.","lastModifiedDate":"2020-05-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":40,"author":{"gitId":"-"},"content":"### JUnit tests","lastModifiedDate":"2020-05-24"},{"lineNumber":41,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":42,"author":{"gitId":"-"},"content":"* A skeleton JUnit test (`src/test/java/seedu/duke/DukeTest.java`) is provided with this project template. ","lastModifiedDate":"2020-05-24"},{"lineNumber":43,"author":{"gitId":"-"},"content":"* If you are new to JUnit, refer to the [JUnit Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/junit.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":45,"author":{"gitId":"-"},"content":"## Checkstyle","lastModifiedDate":"2020-05-24"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":47,"author":{"gitId":"-"},"content":"* A sample CheckStyle rule configuration is provided in this project.","lastModifiedDate":"2020-05-24"},{"lineNumber":48,"author":{"gitId":"-"},"content":"* If you are new to Checkstyle, refer to the [Checkstyle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/checkstyle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":50,"author":{"gitId":"-"},"content":"## CI using GitHub Actions","lastModifiedDate":"2020-05-24"},{"lineNumber":51,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":52,"author":{"gitId":"-"},"content":"The project uses [GitHub actions](https://github.com/features/actions) for CI. When you push a commit to this repo or PR against it, GitHub actions will run automatically to build and verify the code as updated by the commit/PR.","lastModifiedDate":"2020-05-24"},{"lineNumber":53,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":54,"author":{"gitId":"-"},"content":"## Documentation","lastModifiedDate":"2020-05-24"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"-"},"content":"`/docs` folder contains a skeleton version of the project documentation.","lastModifiedDate":"2020-05-24"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"-"},"content":"Steps for publishing documentation to the public: ","lastModifiedDate":"2020-05-24"},{"lineNumber":59,"author":{"gitId":"-"},"content":"1. If you are using this project template for an individual project, go your fork on GitHub.\u003cbr\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":60,"author":{"gitId":"-"},"content":" If you are using this project template for a team project, go to the team fork on GitHub.","lastModifiedDate":"2020-05-24"},{"lineNumber":61,"author":{"gitId":"-"},"content":"1. Click on the `settings` tab.","lastModifiedDate":"2020-05-24"},{"lineNumber":62,"author":{"gitId":"-"},"content":"1. Scroll down to the `GitHub Pages` section.","lastModifiedDate":"2020-05-24"},{"lineNumber":63,"author":{"gitId":"-"},"content":"1. Set the `source` as `master branch /docs folder`.","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"-"},"content":"1. Optionally, use the `choose a theme` button to choose a theme for your documentation.","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"SebasFok":1,"-":63}},{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":" implementation \u0027com.googlecode.json-simple:json-simple:1.1.1\u0027","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":33,"author":{"gitId":"-"},"content":" mainClass.set(\"seedu.duke.Duke\")","lastModifiedDate":"2023-08-05"},{"lineNumber":34,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveBaseName.set(\"duke\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":42,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":"run {","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"janelleenqi":1,"rohitcube":1,"-":46}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-14"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"|--------------------------------|:-----------------------:|:-----------------------------------------:|:-------------------------------------------------:|","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"| ![](photos/sebas_pic.png) | Sebastian Fok Shin Hung | [Github](https://github.com/SebasFok/) | [Portfolio](team/sebastianfok.md) |","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"| ![](photos/j.png) | Liow Enqi Janelle | [Github](https://github.com/janelleenqi/) | [Portfolio](team/liowenqijanelle.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"| ![](photos/rohit_pic.png) | Rohit R | [Github](https://github.com/rohitcube) | [Portfolio](team/johndoe.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"| ![](photos/ryanPic.JPG) | Ryan Loh | [Github](https://github.com/ryanlohyr) | [Portfolio](https://ryanlohyr.github.io/ryanloh/) |","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"| ![](photos/isaiah_profile.png) | Isaiah Cerven | [Github](https://github.com/CerIsaiah/) | [Portfolio](team/isaiah.md) |","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"SebasFok":7,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"## Design \u0026 implementation, Architecture","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"![img.png](diagrams/architectureDiagram.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"The Architecture Diagram given above explains the high-level design of the application.","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"The main logic of the application is handled by these four components","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"- **Controller**: ","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" - Handles Commands coming from the User ","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" - Combines data from the **Model** and UI Components from **View**","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" - Never handles data logic","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"- **View**:","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" - Responsible for printing onto the Command Line Application","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"- **Model**: ","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" - Response for retrieving data from the **Data Repository** ","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" - Performs REST API calls to the NUSMODS API","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":"- **Data Repository**: ","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" - Reads data from, and writes data to file","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"### How the architecture components interact with each other","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"![img.png](diagrams/addModule.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"The Sequence Diagram above shows how the components interact with each other when the user inserts a module ","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"into his schedule","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":"## Features: ","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"- Pace","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":"- Left","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":"- Major","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":"- Required","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":"- Info (description, workload, command)","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":"- Search ","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":"- Add","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":"- Delete","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":"- Recommend","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":"# Implementation","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":"## Pacing and MC Calculation","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"The \"Pacing and MC Calculation\" mechanism is implemented to help users track their academic progress and remaining Modular Credits (MCs) required for graduation. This feature is facilitated by the PacingManager, which stores user data and provides functions for calculating the recommended pacing and remaining MCs. The following operations are available:","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#calculateRemainingMCs() — Calculates the remaining MCs required for graduation.","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#calculateRecommendedPace() — Recommends the pacing for upcoming semesters.","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":"These operations are exposed in the Pacing interface as Pacing#calculateRemainingMCs() and Pacing#calculateRecommendedPace() respectively.","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"### Usage Examples","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":"Here are a few examples of how the \"Pacing and MC Calculation\" feature behaves:","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":"#### Example 1: Calculate Remaining MCs","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":"Command: `pace Y2/S1` (assuming that the user has completed 60 MCs from Y1S1 to Y2S1)","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"`You currently have 100 MCs left until graduation.`","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"janelleenqi"},"content":"#### Example 2: Calculate Remaining MCs (No Semester Specified)","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":"Command: `pace`","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"janelleenqi"},"content":"`You currently have 100 MCs left until graduation.`","lastModifiedDate":"2023-10-24"},{"lineNumber":73,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":"## Recommend Schedule Based on Course","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"Based on the course, we will provide an recommended schedules that is sorted based on prerequisites. This feature is facilitated by the scheudle manager which stores information about the schedule and performs actions like add and remove from schedule.","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#recommend() — recommends a scheudle that is sorted based on pre requisites. ","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#addRecommendedScheduleToSchedule() — adds the recommended schedue to the user\u0027s timetable.","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":"These operations are exposed in the Scheulde interface as Schedule#addRecommendedScheduleListToSchedule() and ScheduleGenerator#generateRecommendedSchedule() respectively.","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"### Usage Examples","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":"Here are a few examples of how the \"Recommend schedule\" feature behaves:","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":"#### Step 1: Recommend schedule for computer engineering(CEG)","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":"Command: `recommend ceg` ","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":"`[GEA1000, MA1511, MA1512, DTK1234, GESS1000, CS1010, GEN2000, EG2501, EG1311, GEC1000, PF1101, CDE2000, IE2141, CG1111A, EG2401A, ES2631, ST2334, MA1508E, CS1231, CG2023, CG2111A, CS2040C, CG2027, EE2026, EE4204, EE2211, CG2271, CS2113, CG2028, CP3880, CG4002]","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":"Do you want to add this to your draft schedule?, please input \u0027Y\u0027 or \u0027N\u0027","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":"`","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":"#### Step 2 (Only to be done after step 1): ","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":"Command: `Y`","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":"`","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":"Sem 1: GESS1000 DTK1234 MA1512 MA1511 GEA1000 ","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"Sem 2: GEC1000 EG1311 EG2501 GEN2000 CS1010 ","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"Sem 3: EG2401A CG1111A IE2141 CDE2000 PF1101 ","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":"Sem 4: CG2023 CS1231 MA1508E ST2334 ES2631 ","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":"Sem 5: EE4204 EE2026 CG2027 CS2040C CG2111A ","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":"Sem 6: CG2028 CS2113 CG2271 EE2211 ","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":"Sem 7: CG4002 CP3880 ","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"Sem 8: `","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"janelleenqi"},"content":"## List Modules Left Feature","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":113,"author":{"gitId":"janelleenqi"},"content":"The following sequence diagram shows how the Left Command function works.","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"janelleenqi"},"content":"![img.png](diagrams/left_seq_diag.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":"The left mechanism is implemented to help users keep tracks of modules left for their major. It is facilitated by `modulesLeft`, `modulesMajor` and `modulesTaken`. Additionally, it implements the following operations:","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":"- `student#getModulesMajor()` and `student#getModulesTaken()` – Returns moduleList modulesMajor and modulesTaken respectively.","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":"- `modulesMajor#showModulesDiff(modulesTaken)` – Display modules left.","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"janelleenqi"},"content":"- `modulesTaken#getMainModuleList()` - Returns ArrayList\u003cModule\u003e of modulesTaken which is the ArrayList of modules taken.","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":"- `new ModuleList()` - Instantiate modulesLeft.","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":"This operation is exposed in the `ModulePlannerController` interface as `ModulePlannerController#listModulesLeft()`.","lastModifiedDate":"2023-10-24"},{"lineNumber":124,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":125,"author":{"gitId":"janelleenqi"},"content":"### Usage Examples","lastModifiedDate":"2023-10-24"},{"lineNumber":126,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":127,"author":{"gitId":"janelleenqi"},"content":"Here are a few examples of how the List Modules Left Feature behaves:","lastModifiedDate":"2023-10-24"},{"lineNumber":128,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":129,"author":{"gitId":"janelleenqi"},"content":"#### Example 1: ","lastModifiedDate":"2023-10-24"},{"lineNumber":130,"author":{"gitId":"janelleenqi"},"content":"`modulesMajor#getMainModuleList()` gives modules `CS1231S CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230`.","lastModifiedDate":"2023-10-24"},{"lineNumber":131,"author":{"gitId":"janelleenqi"},"content":"`modulesTaken#getMainModuleList()` gives modules `CS1231S MA1511`","lastModifiedDate":"2023-10-24"},{"lineNumber":132,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":133,"author":{"gitId":"janelleenqi"},"content":"Command: `left`","lastModifiedDate":"2023-10-24"},{"lineNumber":134,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":135,"author":{"gitId":"janelleenqi"},"content":"Response:","lastModifiedDate":"2023-10-24"},{"lineNumber":136,"author":{"gitId":"janelleenqi"},"content":"`CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230`","lastModifiedDate":"2023-10-24"},{"lineNumber":137,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":138,"author":{"gitId":"janelleenqi"},"content":"## Input Major Feature","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":140,"author":{"gitId":"janelleenqi"},"content":"The input major feature is facilitated by `Student`. It tries to store the major specified in userInput txt ","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":"file such that it can be used across sessions. It will print different responses based on whether the storing of the ","lastModifiedDate":"2023-10-25"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":"Major was successful. Additionally, it implements the following operation:","lastModifiedDate":"2023-10-25"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":144,"author":{"gitId":"SebasFok"},"content":"- `Student#setMajor(Major major)` – Saves the selected major in its memory.","lastModifiedDate":"2023-10-25"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":"This operation is exposed in the `Student` interface as `Student#updateMajor(String userInput)`.","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"SebasFok"},"content":"### Usage Examples","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"SebasFok"},"content":"Here are a few examples of how the Input Major Feature behaves:","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":152,"author":{"gitId":"SebasFok"},"content":"#### Example 1:","lastModifiedDate":"2023-10-25"},{"lineNumber":153,"author":{"gitId":"SebasFok"},"content":"If \"CS\" is a valid major: `Student#updateMajor(\"major CS\")` calls `Student#setMajor(\"CS\")`, which sets the Major in the ","lastModifiedDate":"2023-10-25"},{"lineNumber":154,"author":{"gitId":"SebasFok"},"content":"student object as `CS` and returns a string `newMajor`","lastModifiedDate":"2023-10-25"},{"lineNumber":155,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":156,"author":{"gitId":"SebasFok"},"content":"Command: `major CS`","lastModifiedDate":"2023-10-25"},{"lineNumber":157,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":158,"author":{"gitId":"SebasFok"},"content":"Response: `Major CS selected!`","lastModifiedDate":"2023-10-25"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":160,"author":{"gitId":"SebasFok"},"content":"#### Example 2:","lastModifiedDate":"2023-10-25"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":"If \"abc\" is an invalid major: `Student#updateMajor(\"major abc\")` calls `Student#setMajor(\"abc\")`, which generates an","lastModifiedDate":"2023-10-25"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":"IllegalArgumentException, which is caught and returns a string `invalidMajor`","lastModifiedDate":"2023-10-25"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":"Command: `major abc`","lastModifiedDate":"2023-10-25"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":"Response: `Please select a major from this list: [list of currently available Majors]`","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":"#### Example 3:","lastModifiedDate":"2023-10-25"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":"If no major was specified: `Student#updateMajor(\"major\")` returns a string `currentMajor`","lastModifiedDate":"2023-10-25"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":"Command: `major`","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":"Response: `Current major is [current major in student object].`","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"janelleenqi"},"content":"## Required Command","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"janelleenqi"},"content":"The following sequence diagram shows how the Required Command function works.","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":"![img.png](diagrams/required_seq_diag.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"janelleenqi"},"content":"The required command is implemented to give users an overview of the modules they need to complete for ","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"janelleenqi"},"content":"their major. It is facilitated by major. Additionally, it implements the following operations:","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"janelleenqi"},"content":"- `Student#getMajor()` – Returns the `major` of the student.","lastModifiedDate":"2023-11-03"},{"lineNumber":184,"author":{"gitId":"janelleenqi"},"content":"- `ModuleServiceController#getRequiredModules(major)` and `ModuleServiceController#printRequiredModules(major)` – ","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"janelleenqi"},"content":"Displays the modules required.","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"rohitcube"},"content":"### Usage Examples","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"rohitcube"},"content":"Here are a few examples of how the Show Required Modules Feature behaves:","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"rohitcube"},"content":"#### Example 1:","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"rohitcube"},"content":"Command: `required`","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"rohitcube"},"content":"Response:","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"rohitcube"},"content":"Module requirements for major selected by user","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"janelleenqi"},"content":"## Get information about modules (from the NUSMods API)","lastModifiedDate":"2023-11-03"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"janelleenqi"},"content":"The information feature returns information about the module at the user\u0027s request. It accepts 3 commands, ","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":"\u0027description\u0027, \u0027workload\u0027 and \u0027all\u0027. The \u0027description\u0027 command returns a string description of the module, the workload","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"rohitcube"},"content":"command returns an array, and all displays the module title and module code for all modules present in the NUSMods ","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"rohitcube"},"content":"directory.","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"rohitcube"},"content":"- `getFullModuleInfo(major)` – Returns the `filePath` for the requirements of a specified major.","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"rohitcube"},"content":"- `sendHttpRequestAndGetResponseBody(String url)` – Displays the overview of modules required.","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"rohitcube"},"content":"- `getDescription(String moduleCode)` – Returns the `longestLineLength` of the file f.","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"rohitcube"},"content":"- `getWorkload(String moduleCode)` – Returns a string with a justified name according to length, appended with its description.","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"rohitcube"},"content":"- `listAllModules(), `printDoubleTopLine()`, `printBottomLine()`, `printDoubleBottomLine()` – Displays lines for formatting","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"rohitcube"},"content":"- `infoCommands(String command, String userInput), `printDoubleTopLine()`, `printBottomLine()`, `printDoubleBottomLine()` – Displays lines for formatting","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"janelleenqi"},"content":"### Usage Examples","lastModifiedDate":"2023-10-31"},{"lineNumber":214,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":215,"author":{"gitId":"janelleenqi"},"content":"Here are a few examples of how the Show Required Modules Feature behaves:","lastModifiedDate":"2023-10-31"},{"lineNumber":216,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":217,"author":{"gitId":"janelleenqi"},"content":"#### Example 1:","lastModifiedDate":"2023-10-31"},{"lineNumber":218,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"janelleenqi"},"content":"Command: `required`","lastModifiedDate":"2023-10-31"},{"lineNumber":220,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":221,"author":{"gitId":"janelleenqi"},"content":"Response:","lastModifiedDate":"2023-10-31"},{"lineNumber":222,"author":{"gitId":"janelleenqi"},"content":"Module requirements for major selected by user","lastModifiedDate":"2023-10-31"},{"lineNumber":223,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":225,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":226,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":227,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":228,"author":{"gitId":"-"},"content":"{Describe the target user profile}","lastModifiedDate":"2020-05-24"},{"lineNumber":229,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":230,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"-"},"content":"{Describe the value proposition: what problem does it solve?}","lastModifiedDate":"2020-05-24"},{"lineNumber":233,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":234,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":235,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":236,"author":{"gitId":"-"},"content":"|Version| As a ... | I want to ... | So that I can ...|","lastModifiedDate":"2020-05-24"},{"lineNumber":237,"author":{"gitId":"-"},"content":"|--------|----------|---------------|------------------|","lastModifiedDate":"2020-05-24"},{"lineNumber":238,"author":{"gitId":"-"},"content":"|v1.0|new user|see usage instructions|refer to them when I forget how to use the application|","lastModifiedDate":"2020-05-24"},{"lineNumber":239,"author":{"gitId":"-"},"content":"|v2.0|user|find a to-do item by name|locate a to-do without having to go through the entire list|","lastModifiedDate":"2020-05-24"},{"lineNumber":240,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":241,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":242,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":243,"author":{"gitId":"-"},"content":"{Give non-functional requirements}","lastModifiedDate":"2020-05-24"},{"lineNumber":244,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":245,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":246,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":247,"author":{"gitId":"-"},"content":"* *glossary item* - Definition","lastModifiedDate":"2020-05-24"},{"lineNumber":248,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":249,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":250,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":251,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"SebasFok":40,"ryanlohyr":81,"janelleenqi":69,"rohitcube":24,"-":37}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"# NUSDegs User Guide","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"NUSDegs streamlines computing degree planning by offering personalized module schedules, tracking progress, ","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"and ensuring on-time graduation. It eliminates guesswork, reduces stress, and saves time for students. ","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"It\u0027s a comprehensive tool for efficient and successful degree completion.","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"{Give steps to get started quickly}","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":"1. Ensure that you have Java 11 or above installed.","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":"1. Down the latest version of `Duke` from [here](http://link.to/duke).","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":"## Features","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"- Left","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"- Required","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":"- Complete","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":"- Info","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"SebasFok"},"content":"- Search","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"SebasFok"},"content":"- Major","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":"- Add","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":"- Delete","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"- recommend","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"- prereq","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"{Give detailed description of each feature}","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"### Checking modules left: `left`","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"Displays the modules left, which are the modules required for the user\u0027s major that have not been completed.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"Format: `left`","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"Example of usage 1: (scenario where user\u0027s selected major is CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":"User input: ","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":"`left`","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":"![ss_left_ceg.png](screenshots%2Fss_left_ceg.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":"### Getting a list of required modules: `required`","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"Get an overview of required modules for the user\u0027s major","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":"Format: `required`","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":"Example of usage 1: (scenario where user\u0027s selected major is CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":"User input:","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":"`required`","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":"![ss_required_ceg.png](screenshots%2Fss_required_ceg.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":"![ss_required_ceg2.png](screenshots%2Fss_required_ceg2.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"janelleenqi"},"content":"### Complete a module: `complete`","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":"Completes a module (not displayed when the feature `left` is used).","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":"Format: `complete`","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":"Example of usage 1: (scenario where user\u0027s selected major is CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":"User input:","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"`complete ma1511`","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"janelleenqi"},"content":"Expected outcome:","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"janelleenqi"},"content":"`Mod completed: MA1511`","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"janelleenqi"},"content":"Changes to modules left are shown when","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"janelleenqi"},"content":"User input:","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"janelleenqi"},"content":"`left`","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"janelleenqi"},"content":"Expected outcome:","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"janelleenqi"},"content":"![ss_complete_ceg.png](screenshots%2Fss_complete_ceg.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"rohitcube"},"content":"### Get information about a module: `info`","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"rohitcube"},"content":"Get information about a module using the info command, followed by one of the commands \u0027description\u0027, \u0027workload\u0027 ","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"rohitcube"},"content":"and \u0027all\u0027.","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":82,"author":{"gitId":"rohitcube"},"content":"Format: `info n/command n/moduleCode`","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":84,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":"* The `command` cannot be empty.","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"rohitcube"},"content":"* The `moduleCode` cannot be empty.","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"-"},"content":"Example of usage: ","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"rohitcube"},"content":"`info description CS2113`","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: This course introduces the necessary skills for systematic and rigorous development of software systems. It covers requirements, design, implementation, quality assurance, and project management aspects of small-to-medium size multi-person software projects. The course uses the Object Oriented Programming paradigm. Students of this course will receive hands-on practice of tools commonly used in the industry, such as test automation tools, build automation tools, and code revisioning tools will be covered.","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"rohitcube"},"content":"`info workload CS2113`","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: \"[2,1,0,3,4]\"","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"SebasFok"},"content":"`info all`","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":"- Expected outcome: Displays module title and module code of all available modules","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"rohitcube"},"content":"### Searching for a module by title: `search`","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"rohitcube"},"content":"Search for module title using a keyword.","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"rohitcube"},"content":"Format: `search n/KEYWORD`","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"rohitcube"},"content":"* The `KEYWORD` cannot be empty.","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":110,"author":{"gitId":"-"},"content":"Example of usage:","lastModifiedDate":"2020-05-24"},{"lineNumber":111,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":112,"author":{"gitId":"rohitcube"},"content":"`search n/Darwinian`","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":114,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"rohitcube"},"content":"These are the modules that contain your keyword in the title:","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":117,"author":{"gitId":"SebasFok"},"content":"### Selecting your current major: `major`","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"SebasFok"},"content":"Saves the selected major into the programme if a major is specified.","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"SebasFok"},"content":"Returns the current saved major if no major is specified.","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"SebasFok"},"content":"Format: `major n/MAJOR`","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":"* The `MAJOR` is an optional argument to update current major and can be CEG (upcoming feature includes CS).","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"SebasFok"},"content":"Examples of usage:","lastModifiedDate":"2023-11-02"},{"lineNumber":126,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"SebasFok"},"content":"`major CEG`","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":129,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: \"Major CEG selected!\"","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"SebasFok"},"content":"`major` (Assume CEG has been selected by the previous command)","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: \"Current major is CEG.\"","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":"### View recommended schedule based on course: recommend","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":"Based on the course, we will provide an recommended schedules that is sorted based on prerequisites.","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":"Format: `recommend MAJOR_CODE`","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":"The input is not case sensitive. E.g CEG or ceg is shown (Currently only works for CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":"Examples:","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":"Recommend ceg","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":"[CS1010, MA1511, MA1508E, … ,.... ,.... ,... EE4027] (modules required for the degree will be shown)","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"ryanlohyr"},"content":"### View module prerequisites: prereq ","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"ryanlohyr"},"content":"Based on the module selected, we will show what prerequisites the course has in a form of an array. Since NUS has the concept of preclusions, when prerequisites are shown, it is shown based on the degree of the current user, which is currently only computer science and computer engineering students.","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"ryanlohyr"},"content":"Format: `prepreq MODULE_CODE`","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"ryanlohyr"},"content":"The input is not case sensitive. E.g eg1311 or EG1311 is shown","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":"out","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":"Examples:","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":"`Command: prepreq eg1311` (assuming the user is from computer engineering)","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":"[CS1010, MA1511, MA1508E]","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":"Command: pace","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":"You currently have 100MCs left until graduation","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":160,"author":{"gitId":"SebasFok"},"content":"### Add module to schedule: `add`","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":"Opens the user\u0027s personalized module schedule and adds the chosen module to the semester specified by the user.","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":"Format: `add n/MODULE n/SEMESTER`","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":"* The `MODULE` cannot be empty and must be valid.","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":"* The `SEMESTER` cannot be empty and must be an integer between 1-8 inclusive.","lastModifiedDate":"2023-11-02"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":"Examples of usage:","lastModifiedDate":"2023-11-02"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":"`add CS1010 1`","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":"![](photos/add_outcome.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"SebasFok"},"content":"### Delete module from schedule: `delete`","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"SebasFok"},"content":"Opens the user\u0027s personalized module schedule and deletes the chosen module.","lastModifiedDate":"2023-11-02"},{"lineNumber":178,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":179,"author":{"gitId":"SebasFok"},"content":"Format: `delete n/MODULE`","lastModifiedDate":"2023-11-02"},{"lineNumber":180,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":181,"author":{"gitId":"SebasFok"},"content":"* The `MODULE` cannot be empty and must be valid.","lastModifiedDate":"2023-11-02"},{"lineNumber":182,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"SebasFok"},"content":"Examples of usage:","lastModifiedDate":"2023-11-02"},{"lineNumber":184,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":185,"author":{"gitId":"SebasFok"},"content":"`delete CS1010` (Assume schedule is currently in the state from the example in `add`)","lastModifiedDate":"2023-11-02"},{"lineNumber":186,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":189,"author":{"gitId":"SebasFok"},"content":"![](photos/delete_outcome.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":190,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":191,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":192,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":193,"author":{"gitId":"-"},"content":"**Q**: How do I transfer my data to another computer? ","lastModifiedDate":"2020-05-24"},{"lineNumber":194,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":195,"author":{"gitId":"janelleenqi"},"content":"**A**: Currently, this feature is not included in NUSDegs.","lastModifiedDate":"2023-11-03"},{"lineNumber":196,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":197,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":198,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":199,"author":{"gitId":"-"},"content":"{Give a \u0027cheat sheet\u0027 of commands here}","lastModifiedDate":"2020-05-24"},{"lineNumber":200,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":201,"author":{"gitId":"-"},"content":"* Add todo `todo n/TODO_NAME d/DEADLINE`","lastModifiedDate":"2020-05-24"},{"lineNumber":202,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"SebasFok":63,"ryanlohyr":26,"janelleenqi":51,"rohitcube":24,"-":38}},{"path":"docs/diagrams/Left.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"@startuml","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"autonumber","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"actor Student","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"participant \"controller:ModulePlannerController\" as A #white","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"participant \"student:Student\" as S #white","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"participant \"modulesMajor:ModuleList\" as M #white","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"participant \"modulesTaken:ModuleList\" as T #white","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"participant \"modulesLeft:ModuleList\" as L #white","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"Student -\u003e A: Execute \u0027Left\u0027 Command","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":"A -\u003e S: getModulesMajor()","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"activate S","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"S --\u003e A: Return modulesMajor:ModuleList","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":"deactivate S","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":"A -\u003e S: getModulesTaken()","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"activate S","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"S --\u003e A: Return modulesTaken:ModuleList","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":"deactivate S","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":"A -\u003e M: modulesMajor.showModulesDiff(modulesTaken)","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"activate M","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":"M -\u003e T: getMainModuleList()","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"activate T","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"T --\u003e M: Return Modules Taken","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":"deactivate T","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"create L","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":"M -\u003e L: ModuleList()","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":"activate L","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":"L --\u003e M: Return Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"destroy L","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":"A \u003c-- M: Display Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":"deactivate M","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"Student \u003c-- A: Display Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":"@enduml","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"janelleenqi":45}},{"path":"docs/diagrams/Required.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"@startuml","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"\u0027legend top left","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"\u0027 \u003ccolor blue\u003e Blue activation \u003c/color\u003e denote public method calls","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"\u0027 \u003ccolor red\u003e Red activation\u003c/color\u003e denote private method calls","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"\u0027endlegend","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"autonumber","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"autoactivate on","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"actor Student","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"participant \"controller:ModulePlannerController\" as A #white","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":"participant \"student:Student\" as S #white","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":"participant \"ModuleServiceController\" as MSC #white","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":"Student -\u003e A: Execute \u0027Required\u0027 Command","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":"A -\u003e S: getMajor()","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"\u0027activate S","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"S --\u003e A: Return major","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":"\u0027deactivate S","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":"A -\u003e MSC: getRequiredModules(major)","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"\u0027activate MSC","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"MSC -\u003e MSC: printRequiredModules(major)","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":"MSC --\u003e MSC: Display Required Modules","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"MSC --\u003e A: Display Required Modules","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":"\u0027deactivate MSC","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"Student \u003c-- A: Display Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"@enduml","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"janelleenqi":35}},{"path":"docs/team/isaiah.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"CerIsaiah"},"content":"# Isaiah - Project Portfolio Page","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"CerIsaiah"},"content":"## Overview","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":5,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":6,"author":{"gitId":"CerIsaiah"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"CerIsaiah":6}},{"path":"docs/team/liowenqijanelle.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"# Liow Enqi Janelle - Project Portfolio Page","lastModifiedDate":"2023-10-07"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"## Overview","lastModifiedDate":"2023-10-07"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-07"}],"authorContributionMap":{"janelleenqi":6}},{"path":"docs/team/sebastianfok.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"# Sebastian Fok - Project Portfolio Page","lastModifiedDate":"2023-10-06"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"## Overview","lastModifiedDate":"2023-10-06"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-06"}],"authorContributionMap":{"SebasFok":6}},{"path":"src/main/java/seedu/duke/Duke.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"package seedu.duke;","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import seedu.duke.controllers.ModulePlannerController;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"-"},"content":"public class Duke {","lastModifiedDate":"2019-07-29"},{"lineNumber":6,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":" * Main entry-point for the java.duke.Duke application.","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":" public static void main(String[] args) {","lastModifiedDate":"2019-07-29"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" controller.start();","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":13,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"ryanlohyr":2,"rohitcube":1,"-":10}},{"path":"src/main/java/seedu/duke/controllers/ModuleMethodsController.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.exceptions.MissingModuleException;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.CompletePreqs;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.Parser;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.views.CommandLineView;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleServiceController.chooseToAddToSchedule;","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.doesModuleExist;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.getModulePrereqBasedOnCourse;","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.MajorRequirements.printRequiredModules;","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.ScheduleGenerator.generateRecommendedSchedule;","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displaySuccessfulAddMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.showPrereqCEG;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displaySuccessfulDeleteMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":"/**","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" * This class houses all the methods for the Module Planner controller.","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" * It provides functionality for computing the recommended pace, showing modules left,","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" * adding, deleting, completing modules,","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" * It provides functionality for computing the recommended pace,","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" * showing modules left, adding, deleting, completing modules,","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" * and getting required modules for a student.","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"public class ModuleMethodsController {","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * Computes and displays the recommended pace for completing remaining module credits until graduation.","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" * @param arguments An array of strings containing academic year and semester information.","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" * @param completedModuleCredits The number of module credits already completed by the user.","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" static void computePace(String[] arguments, int completedModuleCredits) {","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" int totalCreditsToGraduate \u003d 160;","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d totalCreditsToGraduate - completedModuleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" boolean argumentProvided \u003d arguments.length !\u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" if (!argumentProvided) {","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"You currently have \" + creditsLeft + \" MCs till graduation\");","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" if (!Parser.isValidAcademicYear(arguments[0])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" String[] parts \u003d arguments[0].split(\"/\");","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" String year \u003d parts[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" String semester \u003d parts[1].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" int lastSemesterOfYear \u003d 2;","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" int lastYearOfDegree \u003d 4;","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" int yearIntValue \u003d Character.getNumericValue(year.charAt(1));","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" int semesterIntValue \u003d Character.getNumericValue(semester.charAt(1));","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" //if we are at y2s1, we have 5 semesters left","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" int semestersLeft \u003d (lastYearOfDegree - yearIntValue) * 2 + (lastSemesterOfYear - semesterIntValue);","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" int creditsPerSem \u003d Math.round((float) creditsLeft / semestersLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"You have \" + creditsLeft + \"MCs for \" + semestersLeft + \" semesters. \"","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" + \"Recommended Pace: \" + creditsPerSem + \"MCs per sem until graduation\");","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"janelleenqi"},"content":" public static void showModulesLeft(ArrayList\u003cString\u003e moduleCodes) {","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"janelleenqi"},"content":" displayMessage(moduleCodes);","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" public static void addModule(String module, int targetSem, Student student) {","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(module, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(module);","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" public static void recommendScheduleToStudent(Student student){","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" CommandLineView.displayMessage(\"Hold on a sec! Generating your recommended schedule \u003c3....\");","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(student.getMajor());","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" chooseToAddToSchedule(student, recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" public static void deleteModule(String module, Student student) {","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"janelleenqi"},"content":" student.deleteModuleSchedule(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulDeleteMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"janelleenqi"},"content":" } catch (MissingModuleException | FailPrereqException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"janelleenqi"},"content":" public static boolean canCompleteModule(","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" String[] arguments,","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e majorModuleCodes,","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"janelleenqi"},"content":" //ModuleList modulesTaken,","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" CompletePreqs addModulePreqs) {","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"janelleenqi"},"content":" if (addModulePreqs.checkModInput(arguments, majorModuleCodes)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" String moduleCompleted \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" addModulePreqs.getUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" addModulePreqs.printUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"janelleenqi"},"content":" //modulesTaken.addModule(moduleCompleted);","lastModifiedDate":"2023-11-04"},{"lineNumber":115,"author":{"gitId":"janelleenqi"},"content":" return true;","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":" return false;","lastModifiedDate":"2023-11-04"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" public static void getRequiredModulesForStudent(String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" printRequiredModules(major);","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":" public static void determinePrereq(String moduleCode, String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" boolean exist \u003d doesModuleExist(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" if (!exist) {","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prereq \u003d getModulePrereqBasedOnCourse(moduleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" if(prereq \u003d\u003d null || prereq.isEmpty()){","lastModifiedDate":"2023-11-04"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Module \" + moduleCode + \" has no prerequisites.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" }else{","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(prereq);","lastModifiedDate":"2023-11-04"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":127,"janelleenqi":17}},{"path":"src/main/java/seedu/duke/controllers/ModulePlannerController.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.CompletePreqs;","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.ModuleList;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.Schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.CommandManager;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.UserCommands;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.Api;","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.views.CommandLineView;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.Parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.errors.UserError;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"CerIsaiah"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"CerIsaiah"},"content":"import java.util.List;","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.determinePrereq;","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.showModulesLeft;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.computePace;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.getRequiredModulesForStudent;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"import static seedu.duke.controllers.ModuleMethodsController.canCompleteModule;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.deleteModule;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.addModule;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.recommendScheduleToStudent;","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.utils.Parser.parseArguments;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.utils.Parser.parseCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleServiceController.validateMajorInput;","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayWelcome;","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayReady;","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayGoodbye;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayGetMajor;","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayGetYear;","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.printListOfCommands;","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":"public class ModulePlannerController {","lastModifiedDate":"2023-10-12"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" private CommandLineView view;","lastModifiedDate":"2023-10-12"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" private Parser parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" private Student student;","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesMajor;","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesTaken;","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesLeft;","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"CerIsaiah"},"content":" private HashMap\u003cString, List\u003cString\u003e\u003e modsWithPreqs;","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"CerIsaiah"},"content":" private CompletePreqs addModulePreqs;","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" private CommandManager commandManager;","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" public ModulePlannerController() {","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" this.commandManager \u003d new CommandManager();","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" this.parser \u003d new Parser();","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"SebasFok"},"content":" this.student \u003d new Student();","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"CerIsaiah"},"content":" //This modules list of taken and classes left can be in a storage class later on.","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":" this.modulesMajor \u003d null;","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" this.modulesTaken \u003d new ModuleList();","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" this.modulesLeft \u003d new ModuleList();","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" Schedule schedule \u003d new Schedule();","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"SebasFok"},"content":" student.setSchedule(schedule);","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"CerIsaiah"},"content":" modsWithPreqs \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"CerIsaiah"},"content":" //Pass in Hashmap of mods with Preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"CerIsaiah"},"content":" this.addModulePreqs \u003d new CompletePreqs(addModsWithPreqs(modsWithPreqs));","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"CerIsaiah"},"content":" //Pass in the list of mods completed.","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"CerIsaiah"},"content":" addModulePreqs.initializeCompletedMods(modulesTaken);","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" * Starts the application, guiding the user through its execution.","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" * This method performs the following steps:","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" * 1. Display a welcome message to the user.","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" * 2. Initialize user-related data or settings.","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" * 3. Display a message indicating that the application is ready for input.","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" * 4. Handle user input until an exit command is given.","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" * 5. Display a goodbye message when the application is finished.\\","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":" public void start() {","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" displayWelcome();","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" initialiseUser();","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" displayReady();","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" handleUserInputTillExitCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" displayGoodbye();","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" public void initialiseUser() {","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" String userInput;","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" do {","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Please enter your name: \");","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" } while (!parser.checkNameInput(userInput, commandManager.getListOfCommands()));","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" student.setName(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" // Get and set student\u0027s major","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" displayGetMajor(student.getName());","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":" do {","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" } while (!validateMajorInput(userInput));","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" student.setFirstMajor(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" // Get and set student\u0027s year","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" displayGetYear();","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" do {","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" } while (!Parser.isValidAcademicYear(userInput.toUpperCase()));","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" student.setYear(userInput.toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" public void handleUserInputTillExitCommand() {","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-12"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" String userInput \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" String command \u003d parseCommand(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" while (!command.equals(UserCommands.EXIT_COMMAND)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" command \u003d parseCommand(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":" String[] arguments \u003d parseArguments(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" if(!commandManager.getListOfCommands().contains(command)){","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" UserError.displayInvalidInputCommand(command);","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" continue;","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" boolean validInput \u003d Parser.isValidInputForCommand(command, arguments);","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" if (!validInput) {","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" UserError.displayInvalidMethodCommand(command);","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" continue;","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":" processCommand(command, arguments, userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"ryanlohyr"},"content":" in.close();","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"ryanlohyr"},"content":" private void processCommand(String command, String[] arguments, String userInput) {","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":" switch (command) {","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.LEFT_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"janelleenqi"},"content":" showModulesLeft(student.getModuleCodesLeft());","lastModifiedDate":"2023-11-04"},{"lineNumber":153,"author":{"gitId":"janelleenqi"},"content":" break;","lastModifiedDate":"2023-10-16"},{"lineNumber":154,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.PACE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":" computePace(arguments, student.getCurrentModuleCredits());","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-15"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":159,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.PREREQUISITE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d arguments[0];","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(module.toUpperCase(), student.getMajor()); //to convert \"CEG\" to dynamic course","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-28"},{"lineNumber":163,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":164,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.RECOMMEND_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" recommendScheduleToStudent(student);","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.ADD_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":169,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":170,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d Integer.parseInt(arguments[1]);","lastModifiedDate":"2023-11-03"},{"lineNumber":171,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":172,"author":{"gitId":"janelleenqi"},"content":" addModule(module, targetSem, student);","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":175,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.DELETE_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":" deleteModule(module,student);","lastModifiedDate":"2023-11-04"},{"lineNumber":179,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":180,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":181,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.VIEW_SCHEDULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":184,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.COMPLETE_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"janelleenqi"},"content":" String module \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"ryanlohyr"},"content":" //to add to user completed module","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":189,"author":{"gitId":"janelleenqi"},"content":" /*","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"janelleenqi"},"content":" if (modulesMajor !\u003d null) {","lastModifiedDate":"2023-11-02"},{"lineNumber":191,"author":{"gitId":"ryanlohyr"},"content":" if (addModulePreqs.checkModInput(arguments, modulesMajor)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":192,"author":{"gitId":"ryanlohyr"},"content":" String moduleCompleted \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":193,"author":{"gitId":"CerIsaiah"},"content":" addModulePreqs.getUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":194,"author":{"gitId":"CerIsaiah"},"content":" addModulePreqs.printUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-10-25"},{"lineNumber":195,"author":{"gitId":"janelleenqi"},"content":" modulesTaken.addModule(moduleCompleted);","lastModifiedDate":"2023-11-02"},{"lineNumber":196,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-18"},{"lineNumber":197,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"janelleenqi"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":199,"author":{"gitId":"ryanlohyr"},"content":" ErrorHandler.emptyMajor();","lastModifiedDate":"2023-11-03"},{"lineNumber":200,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":201,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":203,"author":{"gitId":"janelleenqi"},"content":" if (canCompleteModule(arguments, student.getMajorModuleCodes(), addModulePreqs)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":204,"author":{"gitId":"janelleenqi"},"content":" student.completeModuleSchedule(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":205,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":206,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":207,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":208,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.REQUIRED_MODULES_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":" getRequiredModulesForStudent(student.getMajor());","lastModifiedDate":"2023-11-03"},{"lineNumber":210,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.INFO_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":213,"author":{"gitId":"ryanlohyr"},"content":" Api.infoCommands(arguments[0], userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"rohitcube"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":216,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.SEARCH_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":217,"author":{"gitId":"rohitcube"},"content":" Api.searchCommand(userInput);","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":219,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":220,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.HELP_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"ryanlohyr"},"content":" printListOfCommands(commandManager);","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" default: {","lastModifiedDate":"2023-10-12"},{"lineNumber":225,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-12"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":227,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":233,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":234,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"CerIsaiah"},"content":" * Add all mods that require prerequisites to a map storing the mod and a set of preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":237,"author":{"gitId":"CerIsaiah"},"content":" * @param list","lastModifiedDate":"2023-10-18"},{"lineNumber":238,"author":{"gitId":"CerIsaiah"},"content":" * @return HashMap of Mods with their corresponding preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":239,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":240,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":241,"author":{"gitId":"CerIsaiah"},"content":" private HashMap\u003cString, List\u003cString\u003e\u003e addModsWithPreqs(HashMap\u003cString, List\u003cString\u003e\u003e list) {","lastModifiedDate":"2023-10-18"},{"lineNumber":242,"author":{"gitId":"CerIsaiah"},"content":" //Only two mods don\u0027t have preqs MA1511 and CS1231S.","lastModifiedDate":"2023-10-18"},{"lineNumber":243,"author":{"gitId":"CerIsaiah"},"content":" // In the future this will be dealt","lastModifiedDate":"2023-10-18"},{"lineNumber":244,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS3230\", \"CS2030S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":245,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS3230\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":246,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":247,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2030S\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":248,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2040S\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":250,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":251,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2106\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":252,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":253,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2109S\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":254,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":255,"author":{"gitId":"CerIsaiah"},"content":" return list;","lastModifiedDate":"2023-10-18"},{"lineNumber":256,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":257,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":258,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":260,"author":{"gitId":"CerIsaiah"},"content":" * Helper function to addModsWithPreqs to add Strings and sets together","lastModifiedDate":"2023-10-18"},{"lineNumber":261,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":262,"author":{"gitId":"CerIsaiah"},"content":" * @param map","lastModifiedDate":"2023-10-18"},{"lineNumber":263,"author":{"gitId":"CerIsaiah"},"content":" * @param key","lastModifiedDate":"2023-10-18"},{"lineNumber":264,"author":{"gitId":"CerIsaiah"},"content":" * @param value","lastModifiedDate":"2023-10-18"},{"lineNumber":265,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":266,"author":{"gitId":"CerIsaiah"},"content":" public static void addValue(HashMap\u003cString, List\u003cString\u003e\u003e map, String key, String value) {","lastModifiedDate":"2023-10-18"},{"lineNumber":267,"author":{"gitId":"CerIsaiah"},"content":" // If the map does not contain the key, put an empty list for that key","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"CerIsaiah"},"content":" if (!map.containsKey(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":269,"author":{"gitId":"CerIsaiah"},"content":" map.put(key, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-18"},{"lineNumber":270,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":271,"author":{"gitId":"CerIsaiah"},"content":" // Add the value to the list associated with the key","lastModifiedDate":"2023-10-18"},{"lineNumber":272,"author":{"gitId":"CerIsaiah"},"content":" map.get(key).add(value);","lastModifiedDate":"2023-10-18"},{"lineNumber":273,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":274,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":275,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":276,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":277,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"SebasFok":14,"ryanlohyr":167,"janelleenqi":31,"rohitcube":8,"CerIsaiah":57}},{"path":"src/main/java/seedu/duke/controllers/ModuleServiceController.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.MajorRequirements;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"public class ModuleServiceController {","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" * Checks if the user\u0027s major input is valid. A major input is valid if it exists in the enumeration","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * of valid majors.","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The user\u0027s major input.","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" * @return True if the input is a valid major, false otherwise.","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" public static boolean validateMajorInput(String userInput) {","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" Major.valueOf(userInput.toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Please choose from the list: CS, or CEG\");","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" * Prompts the user to choose whether to add a list of modules to their draft schedule.","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" * Displays the list of modules and asks for user input. Handles user input validation.","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * @param scheduleToAdd A list of modules to be added to the schedule.","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" public static void chooseToAddToSchedule(Student student, ArrayList\u003cString\u003e scheduleToAdd) {","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(scheduleToAdd);","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Do you want to add this to your draft schedule?, please input \u0027Y\u0027 or \u0027N\u0027\");","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" String userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" while (!userInput.equals(\"N\") \u0026\u0026 !userInput.equals((\"Y\"))) {","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Invalid input, please choose Y/N\");","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" if (userInput.equals(\"Y\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Hold on, this may take a while......\");","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().addRecommendedScheduleListToSchedule(scheduleToAdd);","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().printMainModuleList();","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"No was chosen\");","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves and prints the required modules for a specified major.","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" * \u003cp\u003e","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" * This method initializes a `MajorRequirements` object based on the provided `major`.","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" * It then attempts to print the required modules from a corresponding TXT file.","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" * If the TXT file is not found, an error message is displayed.","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" * @param major The major for which to retrieve required modules.","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" * @throws NullPointerException If `major` is null.","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" public static void getRequiredModules(String major) throws NullPointerException {","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" MajorRequirements.printRequiredModules(major);","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":74}},{"path":"src/main/java/seedu/duke/exceptions/FailPrereqException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.exceptions;","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"public class FailPrereqException extends Exception{","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":" public FailPrereqException(String message) {","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":" super(message);","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"SebasFok":7}},{"path":"src/main/java/seedu/duke/exceptions/InvalidModuleException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.exceptions;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"/**","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" * This class represents a custom exception that is thrown when an invalid module is encountered.","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" * An invalid module that has illegal characters.","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"public class InvalidModuleException extends Exception{","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" public InvalidModuleException() {","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" super(\"Only alphabets and digits are allowed in module codes!\");","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"ryanlohyr":12}},{"path":"src/main/java/seedu/duke/exceptions/MissingModuleException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"package seedu.duke.exceptions;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"public class MissingModuleException extends Exception{","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":" public MissingModuleException(String message) {","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":" super(message);","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"janelleenqi":7}},{"path":"src/main/java/seedu/duke/models/logic/Api.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"rohitcube"},"content":"import java.net.URI;","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":"import java.net.URISyntaxException;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"import java.net.http.HttpClient;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"rohitcube"},"content":"import java.net.http.HttpRequest;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"rohitcube"},"content":"import java.net.http.HttpResponse;","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Objects;","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.parser.JSONParser;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.parser.ParseException;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.InvalidModuleException;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.ModuleList;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.DataRepository.getRequirements;","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"rohitcube"},"content":"import seedu.duke.utils.Parser;","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.errors.UserError;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"rohitcube"},"content":"import seedu.duke.views.ModuleInfo;","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.UnknownCommandException;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"rohitcube"},"content":"public class Api {","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves the prerequisite tree for a module specified by its code.","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module for which prerequisites are to be retrieved.","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * @return A JSON object representing the prerequisite tree for the module. The prerequisite tree can be in one of","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" private static JSONObject getModulePrereqTree(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" JSONObject fullModuleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" if (fullModuleInfo \u003d\u003d null) {","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" //prereqTree can be returned as a string(single pre requisite), null(No pre requisites) or object","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" Object prereqTree \u003d fullModuleInfo.get(\"prereqTree\");","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" if (prereqTree \u003d\u003d null) {","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" } else if (prereqTree instanceof String) {","lastModifiedDate":"2023-10-28"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" JSONObject jsonObject \u003d new JSONObject();","lastModifiedDate":"2023-10-28"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e requirementList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" requirementList.add((String) prereqTree);","lastModifiedDate":"2023-10-28"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" jsonObject.put(\"or\", requirementList);","lastModifiedDate":"2023-10-28"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" return jsonObject;","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" return (JSONObject) fullModuleInfo.get(\"prereqTree\");","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"rohitcube"},"content":" * Checks if a given module code is exempted from certain requirements.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to check.","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"rohitcube"},"content":" * @return True if the module is exempted, false otherwise.","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" private static boolean isModuleException(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e exemptedModules \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"CS1231\");","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"CS1231S\");","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"MA1508E\");","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"EE4204\");","lastModifiedDate":"2023-10-28"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" exemptedModules.add(\"MA1511\");","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" exemptedModules.add(\"MA1512\");","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"MA1521\");","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"MA1522\");","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" return exemptedModules.contains(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":79,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"rohitcube"},"content":" * Retrieves a list of exempted prerequisites for a given module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve exempted prerequisites for.","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"rohitcube"},"content":" * @return An ArrayList of exempted prerequisite module codes.","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" private static ArrayList\u003cString\u003e getExemptedPrerequisite(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" HashMap\u003cString, ArrayList\u003cString\u003e\u003e map \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e list1 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" list1.add(\"MA1511\");","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" list1.add(\"MA1512\");","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"CS1231\", list1);","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e list2 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" list2.add(\"MA1511\");","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" list2.add(\"MA1512\");","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1508E\", list2);","lastModifiedDate":"2023-10-28"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e list3 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" list3.add(\"ST2334\");","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"EE4204\", list3);","lastModifiedDate":"2023-10-28"},{"lineNumber":101,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e emptyList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1511\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"CS1231S\",emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1512\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1521\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1522\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" return map.get(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":115,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"rohitcube"},"content":" private static String sendHttpRequestAndGetResponseBody(String url) throws ParseException,","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"rohitcube"},"content":" IOException, InterruptedException, URISyntaxException {","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"rohitcube"},"content":" HttpClient client \u003d HttpClient.newHttpClient();","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"rohitcube"},"content":" HttpRequest request \u003d HttpRequest.newBuilder()","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"rohitcube"},"content":" .uri(new URI(url))","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"rohitcube"},"content":" .GET()","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"rohitcube"},"content":" .build();","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"rohitcube"},"content":" HttpResponse\u003cString\u003e response \u003d client.send(request, HttpResponse.BodyHandlers.ofString());","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"rohitcube"},"content":" return response.body();","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":129,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"rohitcube"},"content":" * Retrieves detailed module information from an external API based on the module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":133,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve information for.","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"rohitcube"},"content":" * @return A JSONObject containing module information.","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":136,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"janelleenqi"},"content":" public static JSONObject getFullModuleInfo(String moduleCode) throws RuntimeException {","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" // Regex pattern to match only letters and numbers","lastModifiedDate":"2023-11-04"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" String regexPattern \u003d \"^[a-zA-Z0-9]+$\";","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":" if(!moduleCode.matches(regexPattern)){","lastModifiedDate":"2023-11-04"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":" throw new InvalidModuleException();","lastModifiedDate":"2023-11-04"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":145,"author":{"gitId":"rohitcube"},"content":" String url \u003d \"https://api.nusmods.com/v2/2023-2024/modules/\" + moduleCode + \".json\";","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"rohitcube"},"content":" String responseBody \u003d sendHttpRequestAndGetResponseBody(url);","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"rohitcube"},"content":" if (responseBody.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"rohitcube"},"content":" return new JSONObject();","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"rohitcube"},"content":" JSONParser parser \u003d new JSONParser();","lastModifiedDate":"2023-10-26"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":" return (JSONObject) parser.parse(responseBody);","lastModifiedDate":"2023-10-28"},{"lineNumber":153,"author":{"gitId":"rohitcube"},"content":" } catch (ParseException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"rohitcube"},"content":" //to be replaced with more robust error class in the future","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Module Name\");","lastModifiedDate":"2023-10-28"},{"lineNumber":156,"author":{"gitId":"rohitcube"},"content":" } catch (IOException | InterruptedException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Module Name\");","lastModifiedDate":"2023-10-28"},{"lineNumber":158,"author":{"gitId":"janelleenqi"},"content":" throw new RuntimeException(\"java.net.ConnectException\", e);","lastModifiedDate":"2023-11-04"},{"lineNumber":159,"author":{"gitId":"rohitcube"},"content":" } catch (URISyntaxException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":160,"author":{"gitId":"rohitcube"},"content":" //to be replaced with more robust error class in the future","lastModifiedDate":"2023-10-26"},{"lineNumber":161,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Sorry, there was an error with\" +","lastModifiedDate":"2023-10-26"},{"lineNumber":162,"author":{"gitId":"rohitcube"},"content":" \" the provided URL: \" + e.getMessage());","lastModifiedDate":"2023-10-26"},{"lineNumber":163,"author":{"gitId":"rohitcube"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"rohitcube"},"content":" //System.out.println(\"Invalid Module Name\");","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" }catch (InvalidModuleException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Module Code :\" + e.getMessage());","lastModifiedDate":"2023-11-04"},{"lineNumber":167,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"rohitcube"},"content":" return null;","lastModifiedDate":"2023-10-26"},{"lineNumber":169,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"rohitcube"},"content":" * Retrieves the name of a module based on its module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve the name for.","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"rohitcube"},"content":" * @return The name of the module.","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"ryanlohyr"},"content":" public static String getModuleName(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":178,"author":{"gitId":"ryanlohyr"},"content":" JSONObject fullModuleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":179,"author":{"gitId":"ryanlohyr"},"content":" assert fullModuleInfo !\u003d null;","lastModifiedDate":"2023-10-28"},{"lineNumber":180,"author":{"gitId":"ryanlohyr"},"content":" return (String) fullModuleInfo.get(\"title\");","lastModifiedDate":"2023-10-28"},{"lineNumber":181,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":182,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":183,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"rohitcube"},"content":" * Retrieves the description of a module based on its module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":186,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":187,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve the description for.","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"rohitcube"},"content":" * @return The description of the module.","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":190,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"rohitcube"},"content":" public static String getDescription(String moduleCode) {","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"rohitcube"},"content":" JSONObject moduleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"rohitcube"},"content":" String error \u003d \" \";","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":195,"author":{"gitId":"rohitcube"},"content":" String descr \u003d (String) moduleInfo.get(\"description\");","lastModifiedDate":"2023-11-02"},{"lineNumber":196,"author":{"gitId":"rohitcube"},"content":" return descr;","lastModifiedDate":"2023-11-02"},{"lineNumber":197,"author":{"gitId":"rohitcube"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":198,"author":{"gitId":"rohitcube"},"content":" System.out.println(\" \");","lastModifiedDate":"2023-11-02"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":" return error;","lastModifiedDate":"2023-11-02"},{"lineNumber":201,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"rohitcube"},"content":" * Retrieves the workload information for a module based on its module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":207,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve workload information for.","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"rohitcube"},"content":" * @return A JSONArray containing workload details.","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":210,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"rohitcube"},"content":" public static JSONArray getWorkload(String moduleCode) {","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"rohitcube"},"content":" JSONObject moduleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":213,"author":{"gitId":"rohitcube"},"content":" JSONArray emptyArray \u003d new JSONArray();","lastModifiedDate":"2023-11-02"},{"lineNumber":214,"author":{"gitId":"rohitcube"},"content":" assert moduleInfo !\u003d null;","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":216,"author":{"gitId":"rohitcube"},"content":" return (JSONArray) moduleInfo.get(\"workload\");","lastModifiedDate":"2023-10-30"},{"lineNumber":217,"author":{"gitId":"rohitcube"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":218,"author":{"gitId":"rohitcube"},"content":" System.out.println(\" \");","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":220,"author":{"gitId":"rohitcube"},"content":" return emptyArray;","lastModifiedDate":"2023-11-02"},{"lineNumber":221,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":222,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" * Recursively flattens and processes a list of module prerequisites.","lastModifiedDate":"2023-10-28"},{"lineNumber":225,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":227,"author":{"gitId":"ryanlohyr"},"content":" * @param major The major or program for which prerequisites are being flattened.","lastModifiedDate":"2023-10-28"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":" * @param prerequisites An ArrayList to store the flattened prerequisites.","lastModifiedDate":"2023-10-28"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" * @param modulePrereqArray An ArrayList containing the module prerequisites to be processed.","lastModifiedDate":"2023-10-28"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":" * @param courseRequirements An ArrayList containing course requirements.","lastModifiedDate":"2023-10-28"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":" * @param currRequisite The type of the current prerequisite (e.g., \"and\" or \"or\").","lastModifiedDate":"2023-10-28"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":233,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":234,"author":{"gitId":"ryanlohyr"},"content":" private static void flattenPrereq(","lastModifiedDate":"2023-10-28"},{"lineNumber":235,"author":{"gitId":"ryanlohyr"},"content":" String major,","lastModifiedDate":"2023-10-28"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prerequisites,","lastModifiedDate":"2023-10-28"},{"lineNumber":237,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e modulePrereqArray,","lastModifiedDate":"2023-10-28"},{"lineNumber":238,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e courseRequirements,","lastModifiedDate":"2023-10-28"},{"lineNumber":239,"author":{"gitId":"ryanlohyr"},"content":" String currRequisite) {","lastModifiedDate":"2023-10-28"},{"lineNumber":240,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":241,"author":{"gitId":"ryanlohyr"},"content":" for (Object module : modulePrereqArray) {","lastModifiedDate":"2023-10-28"},{"lineNumber":242,"author":{"gitId":"ryanlohyr"},"content":" if (module instanceof String) {","lastModifiedDate":"2023-10-28"},{"lineNumber":243,"author":{"gitId":"ryanlohyr"},"content":" String formattedModule \u003d ((String) module).replace(\":D\", \"\");","lastModifiedDate":"2023-10-28"},{"lineNumber":244,"author":{"gitId":"ryanlohyr"},"content":" formattedModule \u003d formattedModule.replace(\"%\", \"\");","lastModifiedDate":"2023-10-28"},{"lineNumber":245,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":246,"author":{"gitId":"ryanlohyr"},"content":" if (courseRequirements.contains(formattedModule)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":247,"author":{"gitId":"ryanlohyr"},"content":" prerequisites.add(formattedModule);","lastModifiedDate":"2023-10-28"},{"lineNumber":248,"author":{"gitId":"ryanlohyr"},"content":" if (currRequisite.equals(\"or\")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":249,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-10-28"},{"lineNumber":250,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":251,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":252,"author":{"gitId":"ryanlohyr"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":253,"author":{"gitId":"ryanlohyr"},"content":" //item is an object","lastModifiedDate":"2023-10-28"},{"lineNumber":254,"author":{"gitId":"ryanlohyr"},"content":" //here, we determine if its \u0027or\u0027 or \u0027and\u0027","lastModifiedDate":"2023-10-28"},{"lineNumber":255,"author":{"gitId":"ryanlohyr"},"content":" JSONObject moduleJSON \u003d (JSONObject) module;","lastModifiedDate":"2023-10-28"},{"lineNumber":256,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":257,"author":{"gitId":"ryanlohyr"},"content":" if (moduleJSON.containsKey(\"nOf\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":258,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d \"and\";","lastModifiedDate":"2023-11-04"},{"lineNumber":259,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cArrayList\u003cObjects\u003e\u003e initial \u003d (ArrayList\u003cArrayList\u003cObjects\u003e\u003e) moduleJSON.get(\"nOf\");","lastModifiedDate":"2023-11-04"},{"lineNumber":260,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e formattedInitial \u003d initial.get(1);","lastModifiedDate":"2023-11-04"},{"lineNumber":261,"author":{"gitId":"ryanlohyr"},"content":" flattenPrereq(major, prerequisites, formattedInitial, courseRequirements, key);","lastModifiedDate":"2023-11-04"},{"lineNumber":262,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-04"},{"lineNumber":263,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":264,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d (String) moduleJSON.keySet().toArray()[0];","lastModifiedDate":"2023-10-28"},{"lineNumber":265,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":266,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e initial \u003d (ArrayList\u003cObjects\u003e) moduleJSON.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":267,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":268,"author":{"gitId":"ryanlohyr"},"content":" flattenPrereq(major, prerequisites, initial, courseRequirements, key);","lastModifiedDate":"2023-11-04"},{"lineNumber":269,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":270,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":271,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":272,"author":{"gitId":"ryanlohyr"},"content":" } catch (ClassCastException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":273,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Error getting pre requisite for module\");","lastModifiedDate":"2023-11-04"},{"lineNumber":274,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":275,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":276,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":277,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":278,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves the prerequisite array for a module specified by its code and also taking into account the degree","lastModifiedDate":"2023-10-28"},{"lineNumber":279,"author":{"gitId":"ryanlohyr"},"content":" * requirements of the course.","lastModifiedDate":"2023-10-28"},{"lineNumber":280,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":282,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module for which prerequisites are to be retrieved.","lastModifiedDate":"2023-10-28"},{"lineNumber":283,"author":{"gitId":"rohitcube"},"content":" * @return A JSONObject representing the prerequisite tree for the module or NULL if no prerequisites are specified.","lastModifiedDate":"2023-11-01"},{"lineNumber":284,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":285,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":286,"author":{"gitId":"ryanlohyr"},"content":" public static ArrayList\u003cString\u003e getModulePrereqBasedOnCourse(String moduleCode, String major) {","lastModifiedDate":"2023-10-28"},{"lineNumber":287,"author":{"gitId":"ryanlohyr"},"content":" // Only accepts CEG requirements now","lastModifiedDate":"2023-10-28"},{"lineNumber":288,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":289,"author":{"gitId":"ryanlohyr"},"content":" Major.valueOf(major.toUpperCase());","lastModifiedDate":"2023-11-04"},{"lineNumber":290,"author":{"gitId":"ryanlohyr"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":291,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Major Provided\");","lastModifiedDate":"2023-11-04"},{"lineNumber":292,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":293,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":294,"author":{"gitId":"ryanlohyr"},"content":" //Modules that has prerequisites incorrectly identified by NUSMods","lastModifiedDate":"2023-10-28"},{"lineNumber":295,"author":{"gitId":"ryanlohyr"},"content":" if (isModuleException(moduleCode)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":296,"author":{"gitId":"ryanlohyr"},"content":" return getExemptedPrerequisite(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":297,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":298,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":299,"author":{"gitId":"ryanlohyr"},"content":" JSONObject modulePrereqTree \u003d getModulePrereqTree(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":300,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":301,"author":{"gitId":"ryanlohyr"},"content":" if (modulePrereqTree \u003d\u003d null) {","lastModifiedDate":"2023-10-28"},{"lineNumber":302,"author":{"gitId":"ryanlohyr"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":303,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":304,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":305,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d (String) modulePrereqTree.keySet().toArray()[0];","lastModifiedDate":"2023-10-28"},{"lineNumber":306,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":307,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prerequisites \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":308,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":309,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e initial \u003d (ArrayList\u003cObjects\u003e) modulePrereqTree.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":310,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":311,"author":{"gitId":"ryanlohyr"},"content":" flattenPrereq(major, prerequisites, initial, getRequirements(major), key);","lastModifiedDate":"2023-10-28"},{"lineNumber":312,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":313,"author":{"gitId":"ryanlohyr"},"content":" return prerequisites;","lastModifiedDate":"2023-10-28"},{"lineNumber":314,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":315,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":316,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":317,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":318,"author":{"gitId":"SebasFok"},"content":" * Checks if a module with the given module code exists in the NUSMods database.","lastModifiedDate":"2023-10-31"},{"lineNumber":319,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":320,"author":{"gitId":"SebasFok"},"content":" * @param moduleCode The module code to check for existence.","lastModifiedDate":"2023-10-31"},{"lineNumber":321,"author":{"gitId":"SebasFok"},"content":" * @return `true` if the module exists, `false` if the module does not exist.","lastModifiedDate":"2023-10-31"},{"lineNumber":322,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":323,"author":{"gitId":"SebasFok"},"content":" public static boolean doesModuleExist(String moduleCode) {","lastModifiedDate":"2023-10-31"},{"lineNumber":324,"author":{"gitId":"SebasFok"},"content":" JSONObject moduleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-31"},{"lineNumber":325,"author":{"gitId":"SebasFok"},"content":" return (!(moduleInfo \u003d\u003d null));","lastModifiedDate":"2023-10-31"},{"lineNumber":326,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":327,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":328,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":329,"author":{"gitId":"SebasFok"},"content":" * Checks if a student satisfies all prerequisites for a given module.","lastModifiedDate":"2023-10-30"},{"lineNumber":330,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":331,"author":{"gitId":"SebasFok"},"content":" * @param moduleCode The code of the module for which prerequisites need to be checked.","lastModifiedDate":"2023-10-30"},{"lineNumber":332,"author":{"gitId":"SebasFok"},"content":" * @param completedModules The list of completed modules by the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":333,"author":{"gitId":"SebasFok"},"content":" * @return `true` if the student satisfies all prerequisites for the module, `false` otherwise.","lastModifiedDate":"2023-10-30"},{"lineNumber":334,"author":{"gitId":"SebasFok"},"content":" * @throws IllegalArgumentException If the module code is invalid.","lastModifiedDate":"2023-10-31"},{"lineNumber":335,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":336,"author":{"gitId":"SebasFok"},"content":" public static boolean satisfiesAllPrereq(String moduleCode, ModuleList completedModules)","lastModifiedDate":"2023-10-30"},{"lineNumber":337,"author":{"gitId":"SebasFok"},"content":" throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":338,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":339,"author":{"gitId":"SebasFok"},"content":" if (!doesModuleExist(moduleCode)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":340,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Invalid module code\");","lastModifiedDate":"2023-10-31"},{"lineNumber":341,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":342,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":343,"author":{"gitId":"SebasFok"},"content":" JSONObject modulePrereqTree \u003d getModulePrereqTree(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":344,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":345,"author":{"gitId":"SebasFok"},"content":" if (modulePrereqTree \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":346,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":347,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":348,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":349,"author":{"gitId":"SebasFok"},"content":" String key \u003d (String) modulePrereqTree.keySet().toArray()[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":350,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cObjects\u003e initial \u003d (ArrayList\u003cObjects\u003e) modulePrereqTree.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":351,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":352,"author":{"gitId":"SebasFok"},"content":" //Modules that has prerequisites incorrectly identified by NUSMods","lastModifiedDate":"2023-10-30"},{"lineNumber":353,"author":{"gitId":"SebasFok"},"content":" if (isModuleException(moduleCode)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":354,"author":{"gitId":"SebasFok"},"content":" JSONObject exceptionPrereqTree \u003d new JSONObject();","lastModifiedDate":"2023-10-31"},{"lineNumber":355,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cString\u003e requirementList \u003d getExemptedPrerequisite(moduleCode);","lastModifiedDate":"2023-10-31"},{"lineNumber":356,"author":{"gitId":"SebasFok"},"content":" exceptionPrereqTree.put(\"and\", requirementList);","lastModifiedDate":"2023-10-31"},{"lineNumber":357,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":358,"author":{"gitId":"SebasFok"},"content":" key \u003d (String) exceptionPrereqTree.keySet().toArray()[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":359,"author":{"gitId":"SebasFok"},"content":" initial \u003d (ArrayList\u003cObjects\u003e) exceptionPrereqTree.get(key);","lastModifiedDate":"2023-10-31"},{"lineNumber":360,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":361,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":362,"author":{"gitId":"SebasFok"},"content":" return checkPrereq(initial, key, completedModules);","lastModifiedDate":"2023-10-30"},{"lineNumber":363,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":364,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":365,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":366,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":367,"author":{"gitId":"SebasFok"},"content":" * Recursively checks if each branch of the prereq tree is satisfied by the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":368,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":369,"author":{"gitId":"SebasFok"},"content":" * @param modulePrereqArray The array of prerequisite modules or conditions to be checked.","lastModifiedDate":"2023-10-30"},{"lineNumber":370,"author":{"gitId":"SebasFok"},"content":" * @param currRequisite The type of prerequisite condition (\"or\" or \"and\").","lastModifiedDate":"2023-10-30"},{"lineNumber":371,"author":{"gitId":"SebasFok"},"content":" * @param completedModules The list of completed modules by the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":372,"author":{"gitId":"SebasFok"},"content":" * @return `true` if the student satisfies all prerequisites, `false` otherwise.","lastModifiedDate":"2023-10-30"},{"lineNumber":373,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":374,"author":{"gitId":"SebasFok"},"content":" private static boolean checkPrereq(","lastModifiedDate":"2023-10-30"},{"lineNumber":375,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cObjects\u003e modulePrereqArray,","lastModifiedDate":"2023-10-30"},{"lineNumber":376,"author":{"gitId":"SebasFok"},"content":" String currRequisite,","lastModifiedDate":"2023-10-30"},{"lineNumber":377,"author":{"gitId":"SebasFok"},"content":" ModuleList completedModules) {","lastModifiedDate":"2023-10-31"},{"lineNumber":378,"author":{"gitId":"ryanlohyr"},"content":" try{","lastModifiedDate":"2023-11-04"},{"lineNumber":379,"author":{"gitId":"SebasFok"},"content":" if (currRequisite.equals(\"or\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":380,"author":{"gitId":"SebasFok"},"content":" for (Object module : modulePrereqArray) {","lastModifiedDate":"2023-10-30"},{"lineNumber":381,"author":{"gitId":"SebasFok"},"content":" if (module instanceof String) {","lastModifiedDate":"2023-10-30"},{"lineNumber":382,"author":{"gitId":"SebasFok"},"content":" String formattedModule \u003d ((String) module).replace(\":D\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":383,"author":{"gitId":"SebasFok"},"content":" formattedModule \u003d formattedModule.replace(\"%\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":384,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":385,"author":{"gitId":"SebasFok"},"content":" if (completedModules.exists(formattedModule)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":386,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":387,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":388,"author":{"gitId":"SebasFok"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":389,"author":{"gitId":"SebasFok"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-31"},{"lineNumber":390,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":391,"author":{"gitId":"SebasFok"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":392,"author":{"gitId":"SebasFok"},"content":" JSONObject prereqBranch \u003d (JSONObject) module;","lastModifiedDate":"2023-10-30"},{"lineNumber":393,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":394,"author":{"gitId":"ryanlohyr"},"content":" //for cs, some modules return pre req in this form {\"nOf\":[2,[\"MA1511:D\",\"MA1512:D\"]]}","lastModifiedDate":"2023-11-04"},{"lineNumber":395,"author":{"gitId":"ryanlohyr"},"content":" //have to convert first","lastModifiedDate":"2023-11-04"},{"lineNumber":396,"author":{"gitId":"ryanlohyr"},"content":" if (prereqBranch.containsKey(\"nOf\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":397,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d \"and\";","lastModifiedDate":"2023-11-04"},{"lineNumber":398,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cArrayList\u003cObjects\u003e\u003e initial \u003d","lastModifiedDate":"2023-11-04"},{"lineNumber":399,"author":{"gitId":"ryanlohyr"},"content":" (ArrayList\u003cArrayList\u003cObjects\u003e\u003e) prereqBranch.get(\"nOf\");","lastModifiedDate":"2023-11-04"},{"lineNumber":400,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e formattedInitial \u003d initial.get(1);","lastModifiedDate":"2023-11-04"},{"lineNumber":401,"author":{"gitId":"ryanlohyr"},"content":" JSONArray prereqBranchArray \u003d (JSONArray) formattedInitial;","lastModifiedDate":"2023-11-04"},{"lineNumber":402,"author":{"gitId":"ryanlohyr"},"content":" return checkPrereq(prereqBranchArray, key, completedModules);","lastModifiedDate":"2023-11-04"},{"lineNumber":403,"author":{"gitId":"ryanlohyr"},"content":" } else {","lastModifiedDate":"2023-11-04"},{"lineNumber":404,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d (String) prereqBranch.keySet().toArray()[0];","lastModifiedDate":"2023-11-04"},{"lineNumber":405,"author":{"gitId":"SebasFok"},"content":" JSONArray prereqBranchArray \u003d (JSONArray) prereqBranch.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":406,"author":{"gitId":"SebasFok"},"content":" return checkPrereq(prereqBranchArray, key, completedModules);","lastModifiedDate":"2023-11-01"},{"lineNumber":407,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":408,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":409,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":410,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":411,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":412,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":413,"author":{"gitId":"SebasFok"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":414,"author":{"gitId":"SebasFok"},"content":" for (Object module : modulePrereqArray) {","lastModifiedDate":"2023-10-30"},{"lineNumber":415,"author":{"gitId":"SebasFok"},"content":" if (module instanceof String) {","lastModifiedDate":"2023-10-30"},{"lineNumber":416,"author":{"gitId":"SebasFok"},"content":" String formattedModule \u003d ((String) module).replace(\":D\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":417,"author":{"gitId":"SebasFok"},"content":" formattedModule \u003d formattedModule.replace(\"%\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":418,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":419,"author":{"gitId":"SebasFok"},"content":" if (!completedModules.exists(formattedModule)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":420,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":421,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":422,"author":{"gitId":"SebasFok"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":423,"author":{"gitId":"SebasFok"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-31"},{"lineNumber":424,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":425,"author":{"gitId":"SebasFok"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":426,"author":{"gitId":"SebasFok"},"content":" JSONObject prereqBranch \u003d (JSONObject) module;","lastModifiedDate":"2023-10-30"},{"lineNumber":427,"author":{"gitId":"SebasFok"},"content":" String key \u003d (String) prereqBranch.keySet().toArray()[0];","lastModifiedDate":"2023-10-30"},{"lineNumber":428,"author":{"gitId":"SebasFok"},"content":" JSONArray prereqBranchArray \u003d (JSONArray) prereqBranch.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":429,"author":{"gitId":"SebasFok"},"content":" if (!checkPrereq(prereqBranchArray, key, completedModules)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":430,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":431,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":432,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":433,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":434,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":435,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":436,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":437,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":438,"author":{"gitId":"ryanlohyr"},"content":" }catch(ClassCastException e){","lastModifiedDate":"2023-11-04"},{"lineNumber":439,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Error checking prereq for this module\");","lastModifiedDate":"2023-11-04"},{"lineNumber":440,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-04"},{"lineNumber":441,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":442,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":443,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":444,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"rohitcube"},"content":" * Retrieves a list of modules from an external API and returns it as a JSONArray.","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":449,"author":{"gitId":"rohitcube"},"content":" * @return A JSONArray containing module information.","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"rohitcube"},"content":" * @throws RuntimeException If there is an issue with the HTTP request or JSON parsing.","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":452,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":453,"author":{"gitId":"rohitcube"},"content":" public static JSONArray listAllModules() {","lastModifiedDate":"2023-10-28"},{"lineNumber":454,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-10-28"},{"lineNumber":455,"author":{"gitId":"rohitcube"},"content":" String url \u003d \"https://api.nusmods.com/v2/2023-2024/moduleList.json\";","lastModifiedDate":"2023-10-28"},{"lineNumber":456,"author":{"gitId":"rohitcube"},"content":" String responseBody \u003d sendHttpRequestAndGetResponseBody(url);","lastModifiedDate":"2023-11-01"},{"lineNumber":457,"author":{"gitId":"rohitcube"},"content":" JSONParser parser \u003d new JSONParser();","lastModifiedDate":"2023-10-28"},{"lineNumber":458,"author":{"gitId":"rohitcube"},"content":" return (JSONArray) parser.parse(responseBody);","lastModifiedDate":"2023-11-01"},{"lineNumber":459,"author":{"gitId":"rohitcube"},"content":" } catch (URISyntaxException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":460,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Sorry, there was an error with\" +","lastModifiedDate":"2023-10-28"},{"lineNumber":461,"author":{"gitId":"rohitcube"},"content":" \" the provided URL: \" + e.getMessage());","lastModifiedDate":"2023-10-28"},{"lineNumber":462,"author":{"gitId":"rohitcube"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-28"},{"lineNumber":463,"author":{"gitId":"rohitcube"},"content":" } catch (IOException | InterruptedException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":464,"author":{"gitId":"rohitcube"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-28"},{"lineNumber":465,"author":{"gitId":"rohitcube"},"content":" } catch (ParseException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":466,"author":{"gitId":"rohitcube"},"content":" //to be replaced with more robust error class in the future","lastModifiedDate":"2023-10-28"},{"lineNumber":467,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Sorry, the JSON object could not be parsed\");","lastModifiedDate":"2023-10-28"},{"lineNumber":468,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":469,"author":{"gitId":"rohitcube"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":470,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":471,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":472,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":473,"author":{"gitId":"rohitcube"},"content":" * Searches for modules containing a specified keyword in their title within a given module list.","lastModifiedDate":"2023-11-01"},{"lineNumber":474,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":475,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":476,"author":{"gitId":"rohitcube"},"content":" * @param keyword The keyword to search for.","lastModifiedDate":"2023-11-01"},{"lineNumber":477,"author":{"gitId":"rohitcube"},"content":" * @param moduleList The list of modules to search within.","lastModifiedDate":"2023-11-01"},{"lineNumber":478,"author":{"gitId":"rohitcube"},"content":" * @return A JSONArray containing modules matching the keyword.","lastModifiedDate":"2023-11-01"},{"lineNumber":479,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":480,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":481,"author":{"gitId":"rohitcube"},"content":" public static JSONArray search(String keyword, JSONArray moduleList) {","lastModifiedDate":"2023-10-28"},{"lineNumber":482,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesContainingKeyword \u003d new JSONArray();","lastModifiedDate":"2023-10-28"},{"lineNumber":483,"author":{"gitId":"rohitcube"},"content":" if (keyword.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":484,"author":{"gitId":"rohitcube"},"content":" return new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":485,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":486,"author":{"gitId":"rohitcube"},"content":" for (Object moduleObject : moduleList) {","lastModifiedDate":"2023-10-28"},{"lineNumber":487,"author":{"gitId":"rohitcube"},"content":" JSONObject module \u003d (JSONObject) moduleObject; // Cast to JSONObject","lastModifiedDate":"2023-10-28"},{"lineNumber":488,"author":{"gitId":"rohitcube"},"content":" String title \u003d (String) module.get(\"title\");","lastModifiedDate":"2023-10-28"},{"lineNumber":489,"author":{"gitId":"rohitcube"},"content":" if (title.contains(keyword)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":490,"author":{"gitId":"rohitcube"},"content":" modulesContainingKeyword.add(module);","lastModifiedDate":"2023-10-30"},{"lineNumber":491,"author":{"gitId":"rohitcube"},"content":" //not sure how to resolve this yellow line","lastModifiedDate":"2023-10-28"},{"lineNumber":492,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":493,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":494,"author":{"gitId":"rohitcube"},"content":" return modulesContainingKeyword;","lastModifiedDate":"2023-10-28"},{"lineNumber":495,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":496,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":497,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":498,"author":{"gitId":"rohitcube"},"content":" * Executes commands based on user input for module information retrieval.","lastModifiedDate":"2023-11-01"},{"lineNumber":499,"author":{"gitId":"rohitcube"},"content":" * Supports commands: \"description\", \"workload\", \"all\".","lastModifiedDate":"2023-11-01"},{"lineNumber":500,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":501,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":502,"author":{"gitId":"rohitcube"},"content":" * @param command The command provided by the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":503,"author":{"gitId":"rohitcube"},"content":" * @param userInput The user input string containing the command and module code (if applicable).","lastModifiedDate":"2023-11-01"},{"lineNumber":504,"author":{"gitId":"rohitcube"},"content":" * @throws UnknownCommandException If an unknown command is provided.","lastModifiedDate":"2023-11-01"},{"lineNumber":505,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":506,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":507,"author":{"gitId":"rohitcube"},"content":" public static void infoCommands(String command, String userInput) {","lastModifiedDate":"2023-11-01"},{"lineNumber":508,"author":{"gitId":"rohitcube"},"content":" if (command.equals(\"description\")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":509,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":510,"author":{"gitId":"rohitcube"},"content":" userInput.substring(userInput.indexOf(\"description\") + 11).trim().toUpperCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":511,"author":{"gitId":"rohitcube"},"content":" if (!Api.getDescription(moduleCode).isEmpty()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":512,"author":{"gitId":"rohitcube"},"content":" String description \u003d Api.getDescription(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":513,"author":{"gitId":"rohitcube"},"content":" System.out.println(description);","lastModifiedDate":"2023-10-30"},{"lineNumber":514,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":515,"author":{"gitId":"rohitcube"},"content":" } else if (command.equals(\"workload\")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":516,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d userInput.substring(userInput.indexOf(\"workload\") + 8).trim().toUpperCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":517,"author":{"gitId":"rohitcube"},"content":" if (!Api.getWorkload(moduleCode).isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":518,"author":{"gitId":"rohitcube"},"content":" JSONArray workload \u003d Api.getWorkload(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":519,"author":{"gitId":"rohitcube"},"content":" System.out.println(workload);","lastModifiedDate":"2023-10-30"},{"lineNumber":520,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":521,"author":{"gitId":"rohitcube"},"content":" } else if (command.equals(\"all\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":522,"author":{"gitId":"rohitcube"},"content":" JSONArray allModules \u003d listAllModules();","lastModifiedDate":"2023-10-30"},{"lineNumber":523,"author":{"gitId":"rohitcube"},"content":" assert allModules !\u003d null;","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"rohitcube"},"content":" ModuleInfo.printJsonArray(allModules);","lastModifiedDate":"2023-11-01"},{"lineNumber":525,"author":{"gitId":"rohitcube"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":526,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"man\");","lastModifiedDate":"2023-11-02"},{"lineNumber":527,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidCommandforInfoCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":528,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":529,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":530,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":531,"author":{"gitId":"rohitcube"},"content":" public static void searchCommand(String userInput) {","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"rohitcube"},"content":" if (!Parser.isValidKeywordInput(userInput)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"ryanlohyr"},"content":" UserError.emptyKeywordforSearchCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":534,"author":{"gitId":"rohitcube"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"rohitcube"},"content":" String keywords \u003d userInput.substring(userInput.indexOf(\"search\") + 6);","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint \u003d Api.search(keywords, Api.listAllModules());","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"rohitcube"},"content":" if (modulesToPrint.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"ryanlohyr"},"content":" UserError.emptyArrayforSearchCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":540,"author":{"gitId":"rohitcube"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"rohitcube"},"content":" ModuleInfo.searchHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":543,"author":{"gitId":"rohitcube"},"content":" ModuleInfo.printJsonArray(modulesToPrint);","lastModifiedDate":"2023-11-01"},{"lineNumber":544,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"SebasFok":110,"ryanlohyr":215,"janelleenqi":2,"rohitcube":218}},{"path":"src/main/java/seedu/duke/models/logic/CompletePreqs.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.ModuleList;","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"CerIsaiah"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"CerIsaiah"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"CerIsaiah"},"content":"import java.util.HashSet;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"CerIsaiah"},"content":"import java.util.List;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"CerIsaiah"},"content":"import java.util.Set;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"CerIsaiah"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"CerIsaiah"},"content":" * CompletePreqs checks which mods are unlocked once you finish a specific module","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"CerIsaiah"},"content":"public class CompletePreqs {","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"CerIsaiah"},"content":" //Full list of mods with modulesWithPreqs","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"CerIsaiah"},"content":" private HashMap\u003cString, List\u003cString\u003e\u003e modulesWithPreqs;","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"CerIsaiah"},"content":" private ArrayList\u003cString\u003e addToModulesCompleted;","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"CerIsaiah"},"content":" // To track modules that are already unlocked","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"CerIsaiah"},"content":" private Set\u003cString\u003e unlockedModulesSet;","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"CerIsaiah"},"content":" public CompletePreqs(HashMap\u003cString, List\u003cString\u003e\u003e inputMods) {","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"CerIsaiah"},"content":" modulesWithPreqs \u003d new HashMap\u003c\u003e(inputMods);","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"CerIsaiah"},"content":" unlockedModulesSet \u003d new HashSet\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"CerIsaiah"},"content":" addToModulesCompleted \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"CerIsaiah"},"content":" * Create a list of completed mods, hardcoded from startup.","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"CerIsaiah"},"content":" * @param list","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"CerIsaiah"},"content":" public void initializeCompletedMods(ModuleList list) {","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" addToModulesCompleted.addAll(list.getModuleCodes());","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"CerIsaiah"},"content":" for (String mod : addToModulesCompleted) {","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"CerIsaiah"},"content":" processModuleForUnlockingWithoutPrint(mod);","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"CerIsaiah"},"content":" * Prints what mods have been unlocked after input","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"CerIsaiah"},"content":" * @param moduleCompleted","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"CerIsaiah"},"content":" public void getUnlockedMods(String moduleCompleted) {","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"CerIsaiah"},"content":" // Check prerequisites of the moduleCompleted","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"CerIsaiah"},"content":" if (modulesWithPreqs.containsKey(moduleCompleted)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"CerIsaiah"},"content":" List\u003cString\u003e unmetPrerequisites \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"CerIsaiah"},"content":" for (String preq : modulesWithPreqs.get(moduleCompleted)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(preq)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"CerIsaiah"},"content":" unmetPrerequisites.add(preq);","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"CerIsaiah"},"content":" //Stops if a completedMod shouldn\u0027t be able to be completed with proper preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"CerIsaiah"},"content":" if (!unmetPrerequisites.isEmpty()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(moduleCompleted +","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" \" cannot be marked as completed because of uncompleted prerequisites: \"","lastModifiedDate":"2023-10-19"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" + unmetPrerequisites);","lastModifiedDate":"2023-10-19"},{"lineNumber":63,"author":{"gitId":"CerIsaiah"},"content":" return;","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"CerIsaiah"},"content":" //If its not marked as completed, properly add it to the list","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(moduleCompleted)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"CerIsaiah"},"content":" addToModulesCompleted.add(moduleCompleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(\"Mod completed: \" + moduleCompleted);","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"CerIsaiah"},"content":" printUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"CerIsaiah"},"content":" * This is only used for the first initalization of the mods.","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"CerIsaiah"},"content":" * @param moduleCompleted","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" private void processModuleForUnlockingWithoutPrint(String moduleCompleted) {","lastModifiedDate":"2023-10-19"},{"lineNumber":80,"author":{"gitId":"CerIsaiah"},"content":" ArrayList\u003cString\u003e newMods \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"CerIsaiah"},"content":" for (String key : modulesWithPreqs.keySet()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"CerIsaiah"},"content":" //If new unlocked mod isn\u0027t marked as complete or unlocked already","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"CerIsaiah"},"content":" if (!unlockedModulesSet.contains(key) \u0026\u0026 !addToModulesCompleted.contains(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"CerIsaiah"},"content":" boolean allPrerequisitesMet \u003d true;","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"CerIsaiah"},"content":" for (String preq : modulesWithPreqs.get(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(preq)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"CerIsaiah"},"content":" //Make sure preq isn\u0027t already marked as done","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"CerIsaiah"},"content":" allPrerequisitesMet \u003d false;","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"CerIsaiah"},"content":" if (allPrerequisitesMet) {","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"CerIsaiah"},"content":" newMods.add(key);","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"CerIsaiah"},"content":" unlockedModulesSet.add(key);","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":103,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":104,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"CerIsaiah"},"content":" * @param moduleCompleted","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"CerIsaiah"},"content":" public void printUnlockedMods(String moduleCompleted) {","lastModifiedDate":"2023-10-25"},{"lineNumber":108,"author":{"gitId":"CerIsaiah"},"content":" ArrayList\u003cString\u003e newlyUnlockedMods \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"CerIsaiah"},"content":" for (String key : modulesWithPreqs.keySet()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"CerIsaiah"},"content":" //If new unlocked mod isn\u0027t marked as complete or unlocked already","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"CerIsaiah"},"content":" if (!unlockedModulesSet.contains(key) \u0026\u0026 !addToModulesCompleted.contains(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"CerIsaiah"},"content":" boolean allPrerequisitesMet \u003d true;","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"CerIsaiah"},"content":" for (String preq : modulesWithPreqs.get(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(preq)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"CerIsaiah"},"content":" //Make sure preq isn\u0027t already marked as done","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"CerIsaiah"},"content":" allPrerequisitesMet \u003d false;","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":120,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"CerIsaiah"},"content":" if (allPrerequisitesMet) {","lastModifiedDate":"2023-10-18"},{"lineNumber":122,"author":{"gitId":"CerIsaiah"},"content":" newlyUnlockedMods.add(key);","lastModifiedDate":"2023-10-18"},{"lineNumber":123,"author":{"gitId":"CerIsaiah"},"content":" unlockedModulesSet.add(key);","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":126,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":127,"author":{"gitId":"CerIsaiah"},"content":" for (String mod : newlyUnlockedMods) {","lastModifiedDate":"2023-10-18"},{"lineNumber":128,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(mod + \" has been unlocked!\");","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":131,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":132,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":133,"author":{"gitId":"CerIsaiah"},"content":" public void printModsCompleted(){","lastModifiedDate":"2023-10-25"},{"lineNumber":134,"author":{"gitId":"CerIsaiah"},"content":" for (String mod: addToModulesCompleted){","lastModifiedDate":"2023-10-25"},{"lineNumber":135,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(mod + \"has been completed\");","lastModifiedDate":"2023-10-25"},{"lineNumber":136,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":137,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":138,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":139,"author":{"gitId":"janelleenqi"},"content":" public boolean checkModInput(String[] words, ArrayList\u003cString\u003e majorModuleCodes){","lastModifiedDate":"2023-11-04"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" if (words.length \u003d\u003d 1){","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"janelleenqi"},"content":" if (majorModuleCodes.contains(words[0].toUpperCase())){","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"CerIsaiah"},"content":" return true;","lastModifiedDate":"2023-10-25"},{"lineNumber":143,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":144,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(\"Please enter a available mod: \");","lastModifiedDate":"2023-10-25"},{"lineNumber":145,"author":{"gitId":"janelleenqi"},"content":" System.out.println(majorModuleCodes);","lastModifiedDate":"2023-11-04"},{"lineNumber":146,"author":{"gitId":"CerIsaiah"},"content":" return false;","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(\"Please enter a available mod after the complete keyword\");","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"janelleenqi"},"content":" System.out.println(majorModuleCodes);","lastModifiedDate":"2023-11-04"},{"lineNumber":150,"author":{"gitId":"CerIsaiah"},"content":" return false;","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"CerIsaiah"},"content":"}","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"SebasFok":2,"ryanlohyr":8,"janelleenqi":8,"CerIsaiah":136}},{"path":"src/main/java/seedu/duke/models/logic/DataRepository.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import java.io.File;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"public class DataRepository {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" * Retrieves a list of modules requirements for a specified major.","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" * @param major The major for which to retrieve requirements.","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" * @return An ArrayList of module codes.","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" * @throws RuntimeException If the specified major requirements file is not found.","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" public static ArrayList\u003cString\u003e getRequirements(String major) {","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" String fileName \u003d String.format(\"src/main/java/seedu/duke/models/data/%sRequirementsModuleCodes\", major);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" File f \u003d new File(fileName);","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" if (!f.exists()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" String[] courseArray \u003d determineRequirements(major);","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" return new ArrayList\u003c\u003e(Arrays.asList(courseArray));","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" return processCourseFile(f);","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" * Processes a course file, extracts relevant information, and returns a list of course codes.","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" * @param f The file to be processed.","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList of course codes extracted from the file.","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" * @throws FileNotFoundException If the specified file is not found.","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" private static ArrayList\u003cString\u003e processCourseFile(File f) throws FileNotFoundException {","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e currentArray \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" Scanner s \u003d new Scanner(f);","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" String currentLine \u003d s.nextLine();","lastModifiedDate":"2023-10-28"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" String[] words \u003d currentLine.split(\" \");","lastModifiedDate":"2023-10-28"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" if (!currentLine.isEmpty() \u0026\u0026 !currentLine.startsWith(\"*\")) { // not empty line, not title","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" currentArray.add(words[0]);","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" return currentArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" * Determines the course requirements based on the specified major. Function is used if file is not found","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" * @param major A string representing the major (e.g., \"CEG\" for Computer Engineering, \"CS\" for Computer Science).","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" * @return An array of strings containing the course requirements for the specified major.","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" private static String[] determineRequirements(String major) {","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" String[] courseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" String[] csCourseArray \u003d {","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" \"CS1101S\", \"ES2660\", \"GEC1000\", \"GEA1000\", \"GESS1000\",","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" \"GEN2000\", \"IS1108\", \"CS1231S\", \"CS2030S\", \"CS2040S\",","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" \"CS2100\", \"CS2101\", \"CS2103T\", \"CS2106\", \"CS2109S\",","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" \"CS3230\", \"MA1521\", \"MA1522\", \"ST2334\", \"CP3880\"","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" };","lastModifiedDate":"2023-11-04"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" String[] cegCourseArray \u003d {","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" \"CG1111A\", \"MA1511\", \"MA1512\", \"CS1010\", \"GESS1000\",","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" \"GEC1000\", \"GEN2000\", \"ES2631\", \"GEA1000\", \"DTK1234\",","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" \"EG1311\", \"IE2141\", \"EE2211\", \"EG2501\", \"CDE2000\",","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" \"PF1101\", \"CG4002\", \"MA1508E\", \"EG2401A\", \"CP3880\",","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" \"CG2111A\", \"CS1231\", \"CG2023\", \"CG2027\", \"CG2028\",","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" \"CG2271\", \"ST2334\", \"CS2040C\", \"CS2113\", \"EE2026\", \"EE4204\"","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" };","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" if(major.equals(\"CEG\")){","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" courseArray \u003d cegCourseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" }else{","lastModifiedDate":"2023-11-04"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" courseArray \u003d csCourseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" return courseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"janelleenqi"},"content":" * Returns the file path for the requirements of a specified major.","lastModifiedDate":"2023-10-29"},{"lineNumber":93,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":94,"author":{"gitId":"janelleenqi"},"content":" * @param major The major for which to retrieve the requirements file path.","lastModifiedDate":"2023-10-29"},{"lineNumber":95,"author":{"gitId":"janelleenqi"},"content":" * @return The file path to the major\u0027s requirements file.","lastModifiedDate":"2023-10-29"},{"lineNumber":96,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":97,"author":{"gitId":"janelleenqi"},"content":" public static String getFullRequirements(Major major) {","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"janelleenqi"},"content":" return String.format(\"src/main/java/seedu/duke/models/data/%sRequirements\", major.toString());","lastModifiedDate":"2023-10-28"},{"lineNumber":99,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ryanlohyr":75,"janelleenqi":26}},{"path":"src/main/java/seedu/duke/models/logic/MajorRequirements.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.views.CommandLineView;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"public class MajorRequirements {","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" public static void printRequiredModules(String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" if (!major.equals(\"CEG\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" CommandLineView.displayMessage(\"Sorry this major has not be included in our app yet.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":" return;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" CommandLineView.displayMessage(","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" \"#\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d#\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" \"║\\tModular Requirements for CEG \\tUnits\\t║\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" \"#\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d#\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" \"│\\tCommon Curriculum Requirements \\t60\\t\\t│\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" \"\\tGES1000 (Singapore Studies) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" \"\\tGEC1000 (Cultures and Connections) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" \"\\tGEN2000 (Communities and Engagement) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" \"\\tES2631 Critique \u0026 Communication of Thinking \u0026 Design (Critique \u0026 Expression)\\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS1010 Programming Methodology (Digital Literacy) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" \"\\tGEA1000 Quantitative Reasoning with Data (Data Literacy) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" \"\\tDTK1234 Design Thinking (Design Thinking) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":" \"\\tEG1311 Design and Make (Maker Space) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" \"\\tIE2141 Systems Thinking and Dynamics (Systems Thinking) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" \"\\tEE2211 Introduction to Machine Learning (Artificial Intelligence) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" \"\\tCDE2501 Liveable Cities (Sustainable Futures) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" \"\\tCDE2000 (Creating Narratives) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" \"\\tPF1101 Fundamentals of Project Management (Project Management) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG4002 Computer Engineering Capstone Project 1 (Integrated Project) \\t8\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" \"│\\tProgramme Requirements \\t60\\t\\t│\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" \" ~~\\tEngineering Core \\t20\\t ~~\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" \"\\tMA1511 Engineering Calculus \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" \"\\tMA1512 Differential Equations for Engineering \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" \"\\tMA1508E Linear Algebra for Engineering \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":" \"\\tEG2401A Engineering Professionalism \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" \"\\tCP3880 Advanced Technology Attachment Programme \\t12\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" \" ~~\\tCEG Major \\t40\\t ~~\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG1111A Engineering Principles and Practice I \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2111A Engineering Principles and Practice II \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS1231 Discrete Structures \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2023 Signals \u0026 Systems \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2027 Transistor-level Digital Circuit \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2028 Computer Organization \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2271 Real-time Operating System \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS2040C Data Structures and Algorithms \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS2113 Software Engineering \u0026 Object-Oriented Programming \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"janelleenqi"},"content":" \"\\tEE2026 Digital Design \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":" \"\\tEE4204 Computer Networks \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":" \"│\\tUnrestricted Electives \\t40\\t\\t│\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\");","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ryanlohyr":4,"janelleenqi":61}},{"path":"src/main/java/seedu/duke/models/logic/ScheduleGenerator.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import java.util.LinkedList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Queue;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.getModulePrereqBasedOnCourse;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.DataRepository.getRequirements;","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"public class ScheduleGenerator {","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" * Generates a recommended schedule for a given course based on its requirements and prerequisites.","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * @param course The course for which to generate a recommended schedule.","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList of strings representing the recommended schedule in order of completion.","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" public static ArrayList\u003cString\u003e generateRecommendedSchedule(String course){","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e requirements \u003d getRequirements(course);","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" HashMap\u003cString, Integer\u003e degreeMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" Queue\u003cString\u003e q \u003d new LinkedList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e schedule \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" HashMap\u003cString, ArrayList\u003cString\u003e\u003e adjacencyList \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" //initialisation","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" for(String requirement: requirements) {","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" adjacencyList.put(requirement, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" degreeMap.put(requirement, 0);","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" for (String requirement : requirements) {","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prereqArray \u003d getModulePrereqBasedOnCourse(requirement, course);","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" if (prereqArray \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" prereqArray \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" //we need to create an adjacency list to add all the connections","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" // from pre req -\u003e item","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" for (String s : prereqArray) {","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" adjacencyList.get(s).add(requirement);","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" Integer value \u003d degreeMap.get(requirement) + 1;","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" degreeMap.put(requirement, value);","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" for (String key : degreeMap.keySet()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" Integer value \u003d degreeMap.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" if(value \u003d\u003d 0){","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" q.offer(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" while(!q.isEmpty()){","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" String curr \u003d q.poll();","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" schedule.add(curr);","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e currReq \u003d adjacencyList.get(curr);","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" for (String s : currReq) {","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" int num \u003d degreeMap.get(s) - 1;","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" degreeMap.put(s, num);","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" if (num \u003d\u003d 0) {","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" q.offer(s);","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" return schedule;","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ryanlohyr":74}},{"path":"src/main/java/seedu/duke/models/schema/CommandManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"/**","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" * This class represents the command system for the application.","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" * It stores and provides descriptions for each available command.","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"public class CommandManager {","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" private HashMap\u003cString, String\u003e commandsAndDescription;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" public CommandManager() {","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" addCurrentCommands();","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" * Populates the commandsAndDescription HashMap with the current commands and their descriptions.","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" private void addCurrentCommands() {","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"info\", \"Displays information about a specific module.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"left\", \"Displays a list of remaining modules.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"pace\", \"Computes and displays your graduation pace.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"prereq\", \"Displays the prerequisites for a specific module.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"recommend\", \"Displays a recommended schedule based on a keyword.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"major\", \"Updates or displays your current major.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"required\", \"Displays the full requirements for your major.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"complete\", \"Marks a module as complete on schedule planner.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"Bye\", \"Exits the program.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"help\", \"Shows the list of commands.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"add\", \"Adds module to the recommended schedule planner.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"delete\", \"Deletes module from the schedule planner.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"schedule\", \"Shows schedule planner\");","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"search\", \"search for modules to take based on keyword\");","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves the description for a specific command.","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" * @param command The command to retrieve the description for.","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" * @return The description of the command, or \"Command not recognized\" if the command is not in the HashMap.","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" public String getDescription(String command) {","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" return commandsAndDescription.getOrDefault(command, \"Command not recognized\");","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves a list of all available commands.","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList containing all available commands.","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" public ArrayList\u003cString\u003e getListOfCommands() {","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" return new ArrayList\u003c\u003e(commandsAndDescription.keySet());","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" * Returns a formatted list of all commands and their descriptions.","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList of strings, where each string represents a command and its description.","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" public ArrayList\u003cString\u003e printListOfCommands() {","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e commandList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" for (HashMap.Entry\u003cString, String\u003e entry : commandsAndDescription.entrySet()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" String command \u003d entry.getKey();","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" String description \u003d entry.getValue();","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" commandList.add(command + \": \" + description);","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" return commandList;","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":72}},{"path":"src/main/java/seedu/duke/models/schema/Major.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":" * The `Major` enum represents different majors that can be selected by our application.","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"public enum Major {","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" CEG, CS","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"SebasFok":6,"ryanlohyr":2}},{"path":"src/main/java/seedu/duke/models/schema/Module.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.getFullModuleInfo;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"public class Module {","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" //module class requires Name","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" private String moduleName;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" private String moduleDescription;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" private String moduleCode;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" private int moduleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" private boolean isCompleted;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * Represents a module with the specified module code. This class fetches module information","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * using the NUSMods API and stores details such as the module description, name, credits, and completion status.","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module.","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" public Module(String moduleCode) throws NullPointerException, RuntimeException{","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" //add wtv info u want...","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" if (moduleCode.isEmpty()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" JSONObject response \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" assert response !\u003d null: \"Response from NUSMods API is null\";","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" assert !response.isEmpty(): \"Response Object is empty\";","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" this.moduleCode \u003d moduleCode;","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" this.isCompleted \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" this.moduleDescription \u003d (String) response.get(\"description\");","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" this.moduleName \u003d (String) response.get(\"title\");","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" try{","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" this.moduleCredits \u003d (Integer) response.get(\"moduleCredit\");","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" }catch (ClassCastException e){","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" this.moduleCredits \u003d 4;","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" } catch (RuntimeException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" throw e;","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" * Marks this module as completed.","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" public void markModuleAsCompleted() {","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" this.isCompleted \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" public boolean getCompletionStatus() {","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" return isCompleted;","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" * Gets the credits of this module.","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" * @return The number of credits for this module.","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" public int getModuleCredits() {","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" return this.moduleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" * Gets the module code.","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" * @return The code of this module.","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" public String getModuleCode() {","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" return this.moduleCode;","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":66,"janelleenqi":13}},{"path":"src/main/java/seedu/duke/models/schema/ModuleList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":" * A class representing a list of modules and providing operations to manage them.","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"public class ModuleList {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":" private ArrayList\u003cModule\u003e mainModuleList;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":" private int numberOfModules;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" * Constructs a ModuleList from a space-separated string of modules.","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" * @param modules A space-separated string of module codes.","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" public ModuleList(String modules) {","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" mainModuleList \u003d new ArrayList\u003cModule\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" if (modules \u003d\u003d null || modules.isEmpty()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" return;","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" String[] moduleArray \u003d modules.split(\" \");","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" //ArrayList\u003cString\u003e moduleCodes \u003d new ArrayList\u003cString\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" //numberOfModules \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" for (String module : moduleArray) {","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" mainModuleList.add(new Module(module));","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" numberOfModules +\u003d 1;","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":" System.out.println(\"null pointer\");","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" //fail","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" new ModuleList();","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" * Constructs an empty ModuleList.","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" public ModuleList() {","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" mainModuleList \u003d new ArrayList\u003cModule\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" numberOfModules \u003d 0;","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":" public void addModule (Module module) {","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" mainModuleList.add(module);","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":" public void deleteModule (Module module) {","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" mainModuleList.remove(module);","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"janelleenqi"},"content":" public boolean exists(String moduleCodeA) throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"janelleenqi"},"content":" if (mainModuleList \u003d\u003d null) {","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"janelleenqi"},"content":" throw new InvalidObjectException(\"Null Module List\");","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"janelleenqi"},"content":" if (moduleCodeA \u003d\u003d null) {","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"janelleenqi"},"content":" throw new InvalidObjectException(\"Null Module Code\");","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"janelleenqi"},"content":" for (Module moduleB : mainModuleList) {","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"janelleenqi"},"content":" if (moduleCodeA.equals(moduleB.getModuleCode())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"janelleenqi"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"janelleenqi"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"janelleenqi"},"content":" * Retrieves the list of modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"janelleenqi"},"content":" * @author janelleenqi","lastModifiedDate":"2023-10-24"},{"lineNumber":89,"author":{"gitId":"janelleenqi"},"content":" * @return The ArrayList containing the modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cModule\u003e getMainModuleList() {","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"janelleenqi"},"content":" assert mainModuleList !\u003d null: \"null mainModuleList\";","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"janelleenqi"},"content":" return mainModuleList;","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"janelleenqi"},"content":" public Module getModule(String moduleCode) throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList) {","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"janelleenqi"},"content":" if (moduleCode.equals(module.getModuleCode())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"janelleenqi"},"content":" return module;","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"janelleenqi"},"content":" throw new InvalidObjectException(\"Module does not exist.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" public ArrayList\u003cString\u003e getModulesPlanned(){","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e completedModuleCodes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" completedModuleCodes.add(module.getModuleCode());","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" return completedModuleCodes;","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getModulesCompleted(){","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e completedModuleCodes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":" if (module.getCompletionStatus()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":" completedModuleCodes.add(module.getModuleCode());","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":" return completedModuleCodes;","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"CerIsaiah"},"content":" public void printMainModuleList(){","lastModifiedDate":"2023-10-25"},{"lineNumber":125,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"janelleenqi"},"content":" System.out.print(module + \" \");","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":128,"author":{"gitId":"CerIsaiah"},"content":" System.out.println();","lastModifiedDate":"2023-10-25"},{"lineNumber":129,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":130,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":131,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"janelleenqi"},"content":" * Retrieves the number of modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"janelleenqi"},"content":" * @return The number of modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":136,"author":{"gitId":"janelleenqi"},"content":" public int getNumberOfModules() {","lastModifiedDate":"2023-10-16"},{"lineNumber":137,"author":{"gitId":"janelleenqi"},"content":" assert numberOfModules \u003e\u003d 0: \"negative numberOfModules\";","lastModifiedDate":"2023-10-24"},{"lineNumber":138,"author":{"gitId":"janelleenqi"},"content":" return numberOfModules;","lastModifiedDate":"2023-10-16"},{"lineNumber":139,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":" * Changes the number of modules by the specified difference.","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"SebasFok"},"content":" * @param difference The difference by which to change the number of modules.","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":" * A positive value increases the number, while a negative value decreases it.","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"SebasFok"},"content":" public void changeNumberOfModules(int difference) {","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"SebasFok"},"content":" numberOfModules +\u003d difference;","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":152,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getModuleCodes() {","lastModifiedDate":"2023-11-04"},{"lineNumber":153,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e moduleCodes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":154,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-04"},{"lineNumber":155,"author":{"gitId":"janelleenqi"},"content":" moduleCodes.add(module.getModuleCode());","lastModifiedDate":"2023-11-04"},{"lineNumber":156,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":157,"author":{"gitId":"janelleenqi"},"content":" return moduleCodes;","lastModifiedDate":"2023-11-04"},{"lineNumber":158,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":159,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":160,"author":{"gitId":"janelleenqi"},"content":" public int getIndex(String moduleCode) {","lastModifiedDate":"2023-11-04"},{"lineNumber":161,"author":{"gitId":"janelleenqi"},"content":" int i \u003d 0;","lastModifiedDate":"2023-11-04"},{"lineNumber":162,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-04"},{"lineNumber":163,"author":{"gitId":"janelleenqi"},"content":" if (moduleCode.equals(module.getModuleCode())) {","lastModifiedDate":"2023-11-04"},{"lineNumber":164,"author":{"gitId":"janelleenqi"},"content":" return i;","lastModifiedDate":"2023-11-04"},{"lineNumber":165,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"janelleenqi"},"content":" i++;","lastModifiedDate":"2023-11-04"},{"lineNumber":167,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":168,"author":{"gitId":"janelleenqi"},"content":" return -1;","lastModifiedDate":"2023-11-04"},{"lineNumber":169,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":170,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"SebasFok":11,"ryanlohyr":11,"janelleenqi":143,"CerIsaiah":5}},{"path":"src/main/java/seedu/duke/models/schema/Schedule.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"import static seedu.duke.models.logic.Api.doesModuleExist;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":"import static seedu.duke.models.logic.Api.satisfiesAllPrereq;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":" * The `Schedule` class represents a student\u0027s course schedule and extends the `ModuleList` class.","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":" * It allows a student to manage and manipulate their enrolled modules across multiple semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"SebasFok"},"content":"public class Schedule extends ModuleList {","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"SebasFok"},"content":" private static final int MAXIMUM_SEMESTERS \u003d 8;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"SebasFok"},"content":" protected int[] modulesPerSem;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"SebasFok"},"content":" * Constructs a new `Schedule` with the provided modules and distribution across semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":" * @param modules A string containing module codes representing the student\u0027s schedule.","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"SebasFok"},"content":" * @param modulesPerSem An array indicating the distribution of modules across semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"SebasFok"},"content":" public Schedule(String modules, int[] modulesPerSem) {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" super(modules);","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"SebasFok"},"content":" this.modulesPerSem \u003d modulesPerSem;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" * Constructs a new, empty `Schedule` with no modules and a default semester distribution.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"SebasFok"},"content":" public Schedule() {","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"SebasFok"},"content":" super();","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" this.modulesPerSem \u003d new int[]{0, 0, 0, 0, 0, 0, 0, 0};","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" * Retrieves the maximum number of semesters allowed in a student\u0027s course schedule.","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" * @return The maximum number of semesters allowed.","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" public static int getMaximumSemesters() {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"SebasFok"},"content":" return MAXIMUM_SEMESTERS;","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" public void addRecommendedScheduleListToSchedule(ArrayList\u003cString\u003e scheduleToAdd) {","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" final int modsToAddPerSem \u003d 5;","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" int currentIndexOfMod \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" int currentSem \u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" for (String module : scheduleToAdd) {","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":" // Check if the module fulfill pre req, else we move it to next sem","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" // ModuleList completedModules \u003d new ModuleList(String.join(\" \", getMainModuleList()));","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" int indexToAdd \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" for (int i \u003d 1; i \u003c currentSem; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" indexToAdd +\u003d this.modulesPerSem[i - 1];","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" //Sub list as we only want modules before the current target semester","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" List\u003cString\u003e completedModulesArray \u003d getModuleCodes().subList(0, (indexToAdd));","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" ModuleList completedModules \u003d new ModuleList(String.join(\" \", completedModulesArray));","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" if(!satisfiesAllPrereq(module,completedModules)){","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" currentSem +\u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" currentIndexOfMod \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" addModuleWithoutCheckingPrereq(module, currentSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e){","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" currentIndexOfMod +\u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" if(currentIndexOfMod \u003e\u003d modsToAddPerSem){","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" currentIndexOfMod \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" currentSem +\u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"SebasFok"},"content":" * Adds a module to the schedule for a specified semester.","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"SebasFok"},"content":" * @param module The module code to be added.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"SebasFok"},"content":" * @param targetSem The target semester (an integer from 1 to 8) in which to add the module.","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"SebasFok"},"content":" * @throws IllegalArgumentException If the provided semester is out of the valid range (1 to 8),","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"SebasFok"},"content":" * or if the module already exists in the schedule, or if the module is not valid.","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"SebasFok"},"content":" * @throws InvalidObjectException If the module is null.","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"SebasFok"},"content":" * @throws FailPrereqException If the prerequisites for the module are not satisfied","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"SebasFok"},"content":" public void addModule(String module, int targetSem) throws IllegalArgumentException, InvalidObjectException,","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"SebasFok"},"content":" FailPrereqException {","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"SebasFok"},"content":" if (targetSem \u003c 1 || targetSem \u003e MAXIMUM_SEMESTERS) {","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Please select an integer from 1 to 8 for semester selection\");","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"SebasFok"},"content":" if (exists(module)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Module already exists in the schedule\");","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"SebasFok"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"SebasFok"},"content":" throw new InvalidObjectException(\"Module cannot be null\");","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":109,"author":{"gitId":"SebasFok"},"content":" int indexToAdd \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":110,"author":{"gitId":"SebasFok"},"content":" for (int i \u003d 1; i \u003c targetSem; i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"SebasFok"},"content":" indexToAdd +\u003d this.modulesPerSem[i - 1];","lastModifiedDate":"2023-10-29"},{"lineNumber":112,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" //Sub list as we only want modules before the current target semester","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" List\u003cString\u003e completedModulesArray \u003d getModulesPlanned().subList(0, (indexToAdd));","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" ModuleList completedModules;","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":" if (!completedModulesArray.isEmpty()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":" completedModules \u003d new ModuleList(String.join(\" \", completedModulesArray));","lastModifiedDate":"2023-11-04"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":" } else {","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"janelleenqi"},"content":" completedModules \u003d new ModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"SebasFok"},"content":" if (satisfiesAllPrereq(module, completedModules)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" //module initialization will be here","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"janelleenqi"},"content":" this.getMainModuleList().add(indexToAdd, new Module(module));","lastModifiedDate":"2023-11-04"},{"lineNumber":128,"author":{"gitId":"SebasFok"},"content":" modulesPerSem[targetSem - 1] +\u003d 1;","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"SebasFok"},"content":" changeNumberOfModules(1);","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"SebasFok"},"content":" return;","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":132,"author":{"gitId":"SebasFok"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Please select a valid module\");","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"SebasFok"},"content":" throw new FailPrereqException(\"Unable to add module as prerequisites not satisfied for: \" + module);","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"SebasFok"},"content":" * Deletes a module from the schedule by its module code.","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":" * @param module The module code to be deleted from the schedule.","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":" * @throws FailPrereqException If the module to be deleted is a prerequisite for other modules in the schedule.","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":" * @throws IllegalArgumentException If the provided module code is not valid, the module is not in the schedule","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":" public void deleteModule(String module) throws FailPrereqException, IllegalArgumentException {","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"janelleenqi"},"content":" //int targetIndex \u003d getMainModuleList().indexOf(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":148,"author":{"gitId":"janelleenqi"},"content":" int targetIndex \u003d getIndex(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":149,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":150,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":151,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"SebasFok"},"content":" if (!doesModuleExist(module)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Please select a valid module\");","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"SebasFok"},"content":" if (targetIndex \u003d\u003d -1) {","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Module is not in schedule\");","lastModifiedDate":"2023-11-02"},{"lineNumber":158,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"SebasFok"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":" int moduleCount \u003d modulesPerSem[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":" while ((moduleCount - 1) \u003c targetIndex) {","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":" moduleCount +\u003d modulesPerSem[targetSem];","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":" targetSem +\u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":" int nextSemStartingIndex \u003d moduleCount;","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":" int lastModuleIndex \u003d getNumberOfModules() - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"janelleenqi"},"content":" List\u003cString\u003e completedModulesArray \u003d getModuleCodes().subList(0, nextSemStartingIndex);","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":" ModuleList completedModules \u003d new ModuleList(String.join(\" \", completedModulesArray));","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":" completedModules.getMainModuleList().remove(module);","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"SebasFok"},"content":" List\u003cString\u003e modulesAheadArray;","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":" modulesAheadArray \u003d getModuleCodes().subList(nextSemStartingIndex, lastModuleIndex + 1);","lastModifiedDate":"2023-11-04"},{"lineNumber":179,"author":{"gitId":"SebasFok"},"content":" } catch (IndexOutOfBoundsException | IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"SebasFok"},"content":" modulesAheadArray \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"SebasFok"},"content":" for (String moduleAhead : modulesAheadArray){","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"SebasFok"},"content":" if (!satisfiesAllPrereq(moduleAhead, completedModules)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"SebasFok"},"content":" throw new FailPrereqException(\"Unable to delete module. This module is a prerequisite for \"","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"SebasFok"},"content":" + moduleAhead);","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":189,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":190,"author":{"gitId":"SebasFok"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":191,"author":{"gitId":"SebasFok"},"content":" // This catch should never occur as it should not be possible to add an invalid module","lastModifiedDate":"2023-11-02"},{"lineNumber":192,"author":{"gitId":"SebasFok"},"content":" assert false;","lastModifiedDate":"2023-11-02"},{"lineNumber":193,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Invalid Module in Schedule\");","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":195,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":196,"author":{"gitId":"SebasFok"},"content":" getMainModuleList().remove(module);","lastModifiedDate":"2023-10-31"},{"lineNumber":197,"author":{"gitId":"SebasFok"},"content":" modulesPerSem[targetSem - 1] -\u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"SebasFok"},"content":" changeNumberOfModules(-1);","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":201,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":202,"author":{"gitId":"ryanlohyr"},"content":" * Adds a module to the schedule for a specified semester.","lastModifiedDate":"2023-11-04"},{"lineNumber":203,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":204,"author":{"gitId":"ryanlohyr"},"content":" * @param module The module code to be added.","lastModifiedDate":"2023-11-04"},{"lineNumber":205,"author":{"gitId":"ryanlohyr"},"content":" * @param targetSem The target semester (an integer from 1 to 8) in which to add the module.","lastModifiedDate":"2023-11-04"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" * @throws IllegalArgumentException If the provided semester is out of the valid range (1 to 8),","lastModifiedDate":"2023-11-04"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":" * or if the module already exists in the schedule, or if the module is not valid.","lastModifiedDate":"2023-11-04"},{"lineNumber":208,"author":{"gitId":"ryanlohyr"},"content":" * @throws InvalidObjectException If the module is null.","lastModifiedDate":"2023-11-04"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":" * @throws FailPrereqException If the prerequisites for the module are not satisfied","lastModifiedDate":"2023-11-04"},{"lineNumber":210,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":211,"author":{"gitId":"ryanlohyr"},"content":" public void addModuleWithoutCheckingPrereq(String module, int targetSem)","lastModifiedDate":"2023-11-04"},{"lineNumber":212,"author":{"gitId":"ryanlohyr"},"content":" throws","lastModifiedDate":"2023-11-04"},{"lineNumber":213,"author":{"gitId":"ryanlohyr"},"content":" InvalidObjectException,","lastModifiedDate":"2023-11-04"},{"lineNumber":214,"author":{"gitId":"ryanlohyr"},"content":" IllegalArgumentException {","lastModifiedDate":"2023-11-04"},{"lineNumber":215,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":216,"author":{"gitId":"ryanlohyr"},"content":" if (targetSem \u003c 1 || targetSem \u003e MAXIMUM_SEMESTERS) {","lastModifiedDate":"2023-11-04"},{"lineNumber":217,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Please select an integer from 1 to 8 for semester selection\");","lastModifiedDate":"2023-11-04"},{"lineNumber":218,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":219,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":220,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":221,"author":{"gitId":"ryanlohyr"},"content":" if (exists(module)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":222,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Module already exists in the schedule\");","lastModifiedDate":"2023-11-04"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":225,"author":{"gitId":"ryanlohyr"},"content":" throw new InvalidObjectException(\"Module cannot be null\");","lastModifiedDate":"2023-11-04"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":227,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":" int indexToAdd \u003d 0;","lastModifiedDate":"2023-11-04"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" for (int i \u003d 1; i \u003c targetSem; i++) {","lastModifiedDate":"2023-11-04"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":" indexToAdd +\u003d this.modulesPerSem[i - 1];","lastModifiedDate":"2023-11-04"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":233,"author":{"gitId":"ryanlohyr"},"content":" this.getMainModuleList().add(indexToAdd, new Module(module));","lastModifiedDate":"2023-11-04"},{"lineNumber":234,"author":{"gitId":"ryanlohyr"},"content":" modulesPerSem[targetSem - 1] +\u003d 1;","lastModifiedDate":"2023-11-04"},{"lineNumber":235,"author":{"gitId":"ryanlohyr"},"content":" changeNumberOfModules(1);","lastModifiedDate":"2023-11-04"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":237,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":238,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":239,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":240,"author":{"gitId":"SebasFok"},"content":" * Prints the student\u0027s course schedule, displaying modules organized by semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":241,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":242,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"SebasFok"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":244,"author":{"gitId":"SebasFok"},"content":" public void printMainModuleList() {","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"SebasFok"},"content":" int moduleCounter \u003d 0;","lastModifiedDate":"2023-10-30"},{"lineNumber":246,"author":{"gitId":"SebasFok"},"content":" for (int i \u003d 0; i \u003c modulesPerSem.length; i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"SebasFok"},"content":" System.out.print(\"Sem \" + (i + 1) + \": \");","lastModifiedDate":"2023-10-30"},{"lineNumber":248,"author":{"gitId":"SebasFok"},"content":" for (int j \u003d 0; j \u003c modulesPerSem[i]; j++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":249,"author":{"gitId":"janelleenqi"},"content":" System.out.print(getMainModuleList().get(moduleCounter).getModuleCode() + \" \");","lastModifiedDate":"2023-11-04"},{"lineNumber":250,"author":{"gitId":"SebasFok"},"content":" moduleCounter++;","lastModifiedDate":"2023-10-30"},{"lineNumber":251,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":252,"author":{"gitId":"SebasFok"},"content":" System.out.println();","lastModifiedDate":"2023-10-30"},{"lineNumber":253,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":254,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":255,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"SebasFok":166,"ryanlohyr":73,"janelleenqi":16}},{"path":"src/main/java/seedu/duke/models/schema/Student.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.exceptions.MissingModuleException;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"import static seedu.duke.models.logic.DataRepository.getRequirements;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":" * The Student class represents a student with a name, major, and module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":"public class Student {","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"SebasFok"},"content":" private String name;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" private String major;","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"SebasFok"},"content":" private Schedule schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" private String year;","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" private int completedModuleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesPlanned;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" private ArrayList\u003cString\u003e majorModuleCodes;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"SebasFok"},"content":" * Constructs a student with a name, major, and module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"SebasFok"},"content":" * @param name The name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"SebasFok"},"content":" * @param major The major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"SebasFok"},"content":" * @param schedule The module schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" public Student(String name, String major, Schedule schedule) {","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" this.major \u003d major;","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":" this.schedule \u003d schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" this.year \u003d null;","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" this.modulesPlanned \u003d new ModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" * Constructs a student with a null name, null major, and an empty module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":" public Student() {","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" this.name \u003d null;","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" this.major \u003d null;","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" this.schedule \u003d new Schedule();","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" this.year \u003d null;","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" this.modulesPlanned \u003d new ModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"SebasFok"},"content":" * Sets the class schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"SebasFok"},"content":" * @param schedule The new module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"SebasFok"},"content":" public void setSchedule(Schedule schedule) {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"SebasFok"},"content":" this.schedule \u003d schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"SebasFok"},"content":" * Retrieves the module schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"SebasFok"},"content":" * @return The module schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"SebasFok"},"content":" public Schedule getSchedule() {","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"SebasFok"},"content":" return schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" public int getCurrentModuleCredits(){","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" return completedModuleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" * Retrieves the name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"SebasFok"},"content":" * @return The name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"SebasFok"},"content":" public String getName() {","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"SebasFok"},"content":" return name;","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":81,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"SebasFok"},"content":" * Retrieves the major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"SebasFok"},"content":" * @return The major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"SebasFok"},"content":" * @throws NullPointerException If the major has not been set (i.e., it is `null`).","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" public String getMajor(){","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"SebasFok"},"content":" return major;","lastModifiedDate":"2023-10-17"},{"lineNumber":90,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":91,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" * Sets the first major without the major command","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" * @author Isaiah Cerven","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput must be validated in parser as CS or CEG","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" public void setFirstMajor(String userInput){","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" setMajor(userInput.toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(e);","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"janelleenqi"},"content":" public void addModuleSchedule(String moduleCode, int targetSem) throws InvalidObjectException, FailPrereqException {","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" this.schedule.addModule(moduleCode,targetSem);","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"janelleenqi"},"content":" this.modulesPlanned.addModule(new Module(moduleCode));","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" * Completes a module with the specified module code.","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module to be completed.","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" public void completeModuleSchedule(String moduleCode) {","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cModule\u003e modulesPlanned \u003d this.modulesPlanned.getMainModuleList();","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":" for (Module module : modulesPlanned) {","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" if (module.getModuleCode().equals(moduleCode)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" this.completedModuleCredits +\u003d module.getModuleCredits();","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":" module.markModuleAsCompleted();","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" public void printSchedule(){","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" this.schedule.printMainModuleList();","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" * Deletes a module with the specified module code. This method also updates the completed","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" * module credits and removes the module from the planned modules list.","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module to be deleted.","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" * @throws FailPrereqException If deleting the module fails due to prerequisite dependencies.","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"janelleenqi"},"content":" public void deleteModuleSchedule(String moduleCode) throws FailPrereqException, MissingModuleException {","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":" this.schedule.deleteModule(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"janelleenqi"},"content":" Module module;","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"janelleenqi"},"content":" module \u003d modulesPlanned.getModule(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"janelleenqi"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"janelleenqi"},"content":" throw new MissingModuleException(moduleCode + \" is not in Modules Planner.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"janelleenqi"},"content":" this.completedModuleCredits -\u003d module.getModuleCredits();","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"janelleenqi"},"content":" modulesPlanned.deleteModule(module);","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":" public String getYear() {","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":" return year;","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" public void setYear(String year) {","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" this.year \u003d year;","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":" * Sets the name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":" * @param name The new name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"SebasFok"},"content":" * Sets the major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":" * @param major The new major to set.","lastModifiedDate":"2023-10-30"},{"lineNumber":175,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":176,"author":{"gitId":"ryanlohyr"},"content":" public void setMajor(String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"SebasFok"},"content":" this.major \u003d major;","lastModifiedDate":"2023-10-17"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":" majorModuleCodes \u003d getRequirements(major.toString());","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getModuleCodesLeft () {","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e moduleCodesLeft \u003d new ArrayList\u003cString\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e completedModuleCodes \u003d modulesPlanned.getModulesCompleted();","lastModifiedDate":"2023-11-03"},{"lineNumber":184,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"janelleenqi"},"content":" for (String moduleCode: majorModuleCodes) {","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"janelleenqi"},"content":" if (!completedModuleCodes.contains(moduleCode)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"janelleenqi"},"content":" moduleCodesLeft.add(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"janelleenqi"},"content":" return moduleCodesLeft;","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":192,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":193,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getMajorModuleCodes() {","lastModifiedDate":"2023-11-04"},{"lineNumber":194,"author":{"gitId":"janelleenqi"},"content":" return majorModuleCodes;","lastModifiedDate":"2023-11-04"},{"lineNumber":195,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":196,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":197,"author":{"gitId":"janelleenqi"},"content":" public ModuleList getModulesPlanned() {","lastModifiedDate":"2023-11-04"},{"lineNumber":198,"author":{"gitId":"janelleenqi"},"content":" return modulesPlanned;","lastModifiedDate":"2023-11-04"},{"lineNumber":199,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":200,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"SebasFok":84,"ryanlohyr":76,"janelleenqi":40}},{"path":"src/main/java/seedu/duke/models/schema/UserCommands.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public interface UserCommands {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" String EXIT_COMMAND \u003d \"Bye\";","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" String LEFT_COMMAND \u003d \"left\";","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" String PACE_COMMAND \u003d \"pace\";","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" String PREREQUISITE_COMMAND \u003d \"prereq\";","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" String RECOMMEND_COMMAND \u003d \"recommend\";","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" String SET_MAJOR_COMMAND \u003d \"major\";","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" String ADD_MODULE_COMMAND \u003d \"add\";","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" String DELETE_MODULE_COMMAND \u003d \"delete\";","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" String VIEW_SCHEDULE_COMMAND \u003d \"schedule\";","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" String COMPLETE_MODULE_COMMAND \u003d \"complete\";","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" String REQUIRED_MODULES_COMMAND \u003d \"required\";","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" String INFO_COMMAND \u003d \"info\";","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" String SEARCH_MODULE_COMMAND \u003d \"search\";","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" String HELP_COMMAND \u003d \"help\";","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":19}},{"path":"src/main/java/seedu/duke/utils/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.UserCommands;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.errors.UserError;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"public class Parser {","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" * Parses a user input string to extract and return the main command.","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The user input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * @return The main command from the input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" public static String parseCommand(String userInput){","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" String[] keywords \u003d userInput.split(\" \");","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" return keywords[0];","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" * Excludes the command and extracts and returns an array of arguments from a user input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The user input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" * @return An array of arguments from the input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" public static String[] parseArguments(String userInput){","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" String[] keywords \u003d userInput.split(\" \");","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" return Arrays.copyOfRange(keywords, 1, keywords.length);","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * Checks if the given academic year input is valid.","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * The academic year should be in the format \"Yn/Sx\", where \u0027n\u0027 represents the year","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" * and \u0027x\u0027 represents the semester (e.g., Y1/S1, Y2/S2).","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" * @author @ryanlohyr","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The academic year input to be validated.","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" * @return true if the input is a valid academic year, false otherwise.","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" * @throws IllegalArgumentException if the input format is incorrect or if the year or semester is invalid.","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" public static boolean isValidAcademicYear( String userInput ) {","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" String[] parts \u003d userInput.split(\"/\");","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" if(parts.length !\u003d 2){","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Needs to be in format of Y2/S1\");","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" String year \u003d parts[0].toUpperCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" String semester \u003d parts[1].toUpperCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" //last year","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" if(year.equals(\"Y4\") \u0026\u0026 semester.equals(\"S2\")){","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Its your last sem!! A bit too late ya....\");","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" //validate semester","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" if(!semester.equals(\"S1\") \u0026\u0026 !semester.equals(\"S2\")){","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Invalid Semester\");","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" //validate year","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" if (!(year.equals(\"Y1\") || year.equals(\"Y2\") || year.equals(\"Y3\") || year.equals(\"Y4\"))) {","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" // The input is not \"Y1,\" \"Y2,\" \"Y3,\" or \"Y4\"","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Invalid Year\");","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" public boolean checkNameInput(String userInput, ArrayList\u003cString\u003e forbiddenCommands) {","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" // Check for non-empty string","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" if (userInput.trim().isEmpty()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name cannot be empty. Please enter a valid name.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" // Check for length constraints","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" int minLength \u003d 2; // Minimum length for a valid name","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" int maxLength \u003d 50; // Maximum length for a valid name","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" if (userInput.length() \u003c minLength || userInput.length() \u003e maxLength) {","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name must be between \" + minLength + \" and \" + maxLength + \" characters.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" // Check for valid characters","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" if (!userInput.matches(\"[a-zA-Z- \u0027]+\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name can only contain letters, spaces, hyphens, and apostrophes.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" // Check for no leading or trailing spaces","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" if (!userInput.equals(userInput.trim())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name cannot start or end with a space.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" if (forbiddenCommands.contains(userInput.trim().toLowerCase())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid name. This name is reserved for commands. Please enter a different name.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"rohitcube"},"content":" * Checks the validity of user input based on the provided command and words array.","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"rohitcube"},"content":" * @param command The command provided by the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" * @param arguments An array of words parsed from the user input.","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"rohitcube"},"content":" * @return True if the input is valid, false otherwise.","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" public static boolean isValidInputForCommand(String command, String[] arguments) {","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":" switch (command) {","lastModifiedDate":"2023-10-28"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.PREREQUISITE_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003c 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-10-28"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-28"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.RECOMMEND_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" //arguments need to be empty","lastModifiedDate":"2023-11-04"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003e 0) {","lastModifiedDate":"2023-11-04"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-10-28"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-28"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.SET_MAJOR_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003d\u003d 0) {","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003e 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidMajorFormat();","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" Major.valueOf(arguments[0].toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":" String availableMajors \u003d Arrays.toString(Major.values());","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidMajor(availableMajors);","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.ADD_MODULE_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length !\u003d 2) {","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidAddFormat();","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" Integer.parseInt(arguments[1]);","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidSemester();","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.DELETE_MODULE_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length !\u003d 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidDeleteFormat();","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.INFO_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003c 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":174,"author":{"gitId":"ryanlohyr"},"content":" UserError.emptyInputforInfoCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":175,"author":{"gitId":"rohitcube"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"ryanlohyr"},"content":" if (!arguments[0].equals(\"description\") \u0026\u0026 !arguments[0].equals(\"workload\")","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"ryanlohyr"},"content":" \u0026\u0026 !arguments[0].equals(\"all\") \u0026\u0026 !arguments[0].equals(\"requirements\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidCommandforInfoCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"rohitcube"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"rohitcube"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" default: {","lastModifiedDate":"2023-10-28"},{"lineNumber":186,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-10-28"},{"lineNumber":187,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":188,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":189,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":190,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-10-28"},{"lineNumber":191,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":192,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":193,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"rohitcube"},"content":" * Checks the validity of keyword input for a search command.","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"rohitcube"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"rohitcube"},"content":" * @param userInput The user input string containing the search command and keywords.","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"rohitcube"},"content":" * @return True if the keyword input is valid, false otherwise.","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":" public static boolean isValidKeywordInput(String userInput) {","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"rohitcube"},"content":" String keywords \u003d userInput.substring(userInput.indexOf(\"search\") + 6);","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":" // need to add a function to make search case-insensitive","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"rohitcube"},"content":" return !keywords.trim().isEmpty();","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"SebasFok":26,"ryanlohyr":155,"rohitcube":26}},{"path":"src/main/java/seedu/duke/utils/UnknownCommandException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"public class UnknownCommandException extends Exception{","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"rohitcube"},"content":" public UnknownCommandException(String command) {","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"rohitcube"},"content":" super(\"Unknown command: \" + command);","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"ryanlohyr":1,"rohitcube":6}},{"path":"src/main/java/seedu/duke/utils/errors/ClassError.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils.errors;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public class ClassError {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" public static void defaultClassError(Object message){","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(message);","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":7}},{"path":"src/main/java/seedu/duke/utils/errors/HttpError.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils.errors;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public class HttpError {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":5}},{"path":"src/main/java/seedu/duke/utils/errors/UserError.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils.errors;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public class UserError {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" public static void invalidInput(){","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Input provided\");","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":" public static void invalidMajorFormat() {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please select a major using this format: major [major]\");","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"To check your current major, type: major\");","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":" public static void invalidMajor(String availableMajors) {","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please select a major from this list: \" + availableMajors);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" public static void invalidModule(String moduleCode){","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" String response \u003d String.format(\"Sorry, Module %s does not exist\",moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(response);","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" public static void displayInvalidInputCommand(String command){","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" String response \u003d String.format(\"Invalid command %s. Type help to see the available commands\",command);","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(response);","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" public static void displayInvalidMethodCommand(String command){","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" String response \u003d String.format(\"Invalid argument for command %s\", command);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(response);","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"SebasFok"},"content":" public static void invalidAddFormat() {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please add a module using this format: add [module code] [semester]\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"SebasFok"},"content":" public static void invalidSemester() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please select an integer from 1 to 8 for semester selection\");","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":" public static void invalidDeleteFormat() {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please delete a module using this format: delete [module code]\");","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"rohitcube"},"content":" public static void emptyInputforInfoCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Empty input detected. Please enter a valid input after the info command.\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"rohitcube"},"content":" \" (E.g description, workload, all)\");","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"rohitcube"},"content":" public static void invalidCommandforInfoCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Please enter a valid command after the info command. (E.g description, workload, all)\");","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"rohitcube"},"content":" public static void emptyKeywordforSearchCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Empty input detected. Please enter a valid keyword after the search command.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"rohitcube"},"content":" public static void emptyArrayforSearchCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Oops! Your search results came up empty. Please try searching with different keywords.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" public static void emptyMajor() {","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" System.out.println(\"Major has not been provided yet.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" public static void moduleDoesNotExist(String moduleCode) {","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":" System.out.println(moduleCode + \"does not exist in your schedule.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"SebasFok":18,"ryanlohyr":23,"janelleenqi":8,"rohitcube":18}},{"path":"src/main/java/seedu/duke/views/CommandLineView.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.views;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.CommandManager;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"import static seedu.duke.models.logic.Api.getModulePrereqBasedOnCourse;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"public class CommandLineView {","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" public static void displayWelcome(){","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" String logo \u003d \" ____ _ \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" + \"| _ \\\\ _ _| | _____ \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" + \"| | | | | | | |/ / _ \\\\\\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" + \"| |_| | |_| | \u003c __/\\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" + \"|____/ \\\\__,_|_|\\\\_\\\\___|\\n\";","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Hello from\\n\" + logo);","lastModifiedDate":"2023-10-12"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" public static void displayGoodbye(){","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Goodbye.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" public static void displayReady(){","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Now you\u0027re all set to use NUSDegs to kick start your degree planning!\");","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Type \u0027help\u0027 to see the available commands\");","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" public static void displayGetMajor(String name){","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Welcome \" + name + \"! What major are you? (Only two available: CEG or CS)\");","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" public static void displayGetYear(){","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"What Year and Semester are you? Ex: Y1/S2 for year 1 semester 2\");","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" public static void handleMajorMessage(int userInputLength, String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" assert (userInputLength \u003d\u003d 0 || userInputLength \u003d\u003d 1);","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" if (userInputLength \u003d\u003d 0) {","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" if (major \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"No major selected!\");","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" return;","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Current major is \" + major + \".\");","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" return;","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Major \" + major + \" selected!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" public static void printListOfCommands(CommandManager commandManager) {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" for (String command : commandManager.printListOfCommands()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(command);","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" public static void showPrereqCEG(String module) {","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"This module\u0027s prerequisites are \"","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"SebasFok"},"content":" + getModulePrereqBasedOnCourse(module.toUpperCase(),\"CEG\"));","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" public static void displaySuccessfulAddMessage() {","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Module Successfully Added\");","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" public static void displaySuccessfulDeleteMessage() {","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Module Successfully Deleted\");","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"SebasFok"},"content":" * Display a message to the command line view.","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"SebasFok"},"content":" * @param o The object to be displayed.","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" public static void displayMessage(Object o) {","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"SebasFok"},"content":" System.out.println(o);","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" public static void printNewline(){","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" System.out.println();","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"SebasFok":32,"ryanlohyr":48,"janelleenqi":1}},{"path":"src/main/java/seedu/duke/views/ModuleInfo.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"rohitcube"},"content":"package seedu.duke.views;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":"public class ModuleInfo {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"rohitcube"},"content":" public static void print(String output) {","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"rohitcube"},"content":" System.out.println(output);","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"rohitcube"},"content":" public static void printLine() {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"_________________________________________\");","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":" public static void printJsonArray(JSONArray modules) {","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"rohitcube"},"content":" for (Object module: modules) {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"rohitcube"},"content":" JSONObject castedModule \u003d (JSONObject) module;","lastModifiedDate":"2023-10-28"},{"lineNumber":18,"author":{"gitId":"rohitcube"},"content":" print(\"Title: \" + (String)castedModule.get(\"title\"));","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"rohitcube"},"content":" print(\"Module Code: \" + (String)castedModule.get(\"moduleCode\"));","lastModifiedDate":"2023-10-28"},{"lineNumber":20,"author":{"gitId":"rohitcube"},"content":" printLine();","lastModifiedDate":"2023-10-28"},{"lineNumber":21,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"rohitcube"},"content":" public static void searchHeader() {","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"rohitcube"},"content":" printLine();","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"rohitcube"},"content":" print(\"These are the modules that contain your keyword in the title:\");","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"rohitcube"},"content":" print(\"\");","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"rohitcube":30}},{"path":"src/test/java/seedu/duke/ApiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"rohitcube"},"content":"package seedu.duke;","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.Api;","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"import java.util.Objects;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"rohitcube"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"rohitcube"},"content":"import seedu.duke.views.ModuleInfo;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"rohitcube"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"rohitcube"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"rohitcube"},"content":"public class ApiTest {","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"rohitcube"},"content":" void testGetModuleInfo_shouldReturnTrueForCS2113() {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"rohitcube"},"content":" String correctModuleInfo \u003d \"\\\"description\\\":\\\"This course introduces the necessary skills for systematic \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"rohitcube"},"content":" \"and rigorous development of software systems. It covers\";","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d \"CS2113\";","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"rohitcube"},"content":" String moduleInfo \u003d null;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"rohitcube"},"content":" moduleInfo \u003d Objects.requireNonNull(Api.getFullModuleInfo(moduleCode)).toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"rohitcube"},"content":" assertNotNull(moduleInfo, \"Module info should not be null\");","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"rohitcube"},"content":" assertTrue(moduleInfo.contains(correctModuleInfo), \"Module info should contain relevant info\");","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"rohitcube"},"content":" void testGetDescription_shouldReturnEquals() {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"rohitcube"},"content":" String correctDescription \u003d \"This course introduces the necessary skills for systematic and \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"rohitcube"},"content":" \"rigorous development of software systems. It covers requirements, design, implementation, \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"rohitcube"},"content":" \"quality assurance, and project management aspects of small-to-medium size multi-person software\" +","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"rohitcube"},"content":" \" projects. The course uses the Object Oriented Programming paradigm. Students of this course will \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"rohitcube"},"content":" \"receive hands-on practice of tools commonly used in the industry, such as test automation tools,\" +","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"rohitcube"},"content":" \" build automation tools, and code revisioning tools will be covered.\";","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d \"CS2113\";","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"rohitcube"},"content":" String description \u003d Api.getDescription(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"rohitcube"},"content":" assertEquals(correctDescription, description);","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"rohitcube"},"content":" void testGetWorkload_shouldReturnCorrectValue() {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"rohitcube"},"content":" // uses unchecked or unsafe operations, Note: Recompile with -Xlint:unchecked for details.","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"rohitcube"},"content":" JSONArray workload \u003d Api.getWorkload(\"CS2113\");","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"rohitcube"},"content":" JSONArray jsonArray \u003d new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(2);","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(0);","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(3);","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(4);","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"rohitcube"},"content":" String jsonString1 \u003d jsonArray.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"rohitcube"},"content":" String jsonString2 \u003d workload.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"rohitcube"},"content":" assertEquals(jsonString2, jsonString1);","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"rohitcube"},"content":" void testListAllModules() {","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"rohitcube"},"content":" Api.listAllModules();","lastModifiedDate":"2023-10-28"},{"lineNumber":61,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":64,"author":{"gitId":"rohitcube"},"content":" void testSearchModules_emptyInput_expectedEmptyJsonArray() {","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint;","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"rohitcube"},"content":" modulesToPrint \u003d Api.search(\" \", Api.listAllModules());","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"rohitcube"},"content":" assertEquals(0, modulesToPrint.size(), \"The JSON array should be empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"rohitcube"},"content":" void testSearchModules_invalidInput_expectedEmptyJsonArray() {","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint;","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"rohitcube"},"content":" modulesToPrint \u003d Api.search(\"bs#4%ggh\", Api.listAllModules());","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"rohitcube"},"content":" assertEquals(0, modulesToPrint.size(), \"The JSON array should be empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"rohitcube"},"content":" void testSearchModules_validInput_expectedJsonArray() {","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint;","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"rohitcube"},"content":" modulesToPrint \u003d Api.search(\"Trustworthy Machine Learning\", Api.listAllModules());","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"rohitcube"},"content":" JSONArray expectedArray \u003d new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"rohitcube"},"content":" JSONObject expectedObject \u003d new JSONObject();","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"rohitcube"},"content":" expectedObject.put(\"moduleCode\", \"CS5562\");","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"rohitcube"},"content":" JSONArray semester1 \u003d new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":" semester1.add(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"rohitcube"},"content":" expectedObject.put(\"semesters\", semester1);","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"rohitcube"},"content":" expectedObject.put(\"title\", \"Trustworthy Machine Learning\");","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"rohitcube"},"content":" expectedArray.add(expectedObject);","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"rohitcube"},"content":" String expectedOutput \u003d expectedArray.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"rohitcube"},"content":" String output \u003d modulesToPrint.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"rohitcube"},"content":" assertEquals(expectedOutput, output, \"The string should be equal\");","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"rohitcube"},"content":" void testPrintJsonArray() {","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint \u003d Api.search(\"Machine Learning\", Api.listAllModules());","lastModifiedDate":"2023-10-28"},{"lineNumber":97,"author":{"gitId":"rohitcube"},"content":" ModuleInfo.printJsonArray(modulesToPrint);","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":99,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":102,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ryanlohyr":1,"rohitcube":101}},{"path":"src/test/java/seedu/duke/controllers/ModuleMethodsControllerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Schedule;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.computePace;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.determinePrereq;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.ScheduleGenerator.generateRecommendedSchedule;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displaySuccessfulAddMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.showPrereqCEG;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"class ModuleMethodsControllerTest {","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" private final ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" private Student student;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" @BeforeEach","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" public void setUpStreams() {","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" this.student \u003d new Student();","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" student.setName(\"Ryan Loh\");","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" student.setFirstMajor(\"CEG\");","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" student.setYear(\"Y2/S1\");","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" @AfterEach","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" public void restoreStreams() {","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" void computePaceWithoutArgument() {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {};","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" int creditsCompleted \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsCompleted);","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(String.format(\"You currently have %s MCs till graduation\", 160 - 60), printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" void computePaceInvalidArgument() {","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y2s1\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(\"Needs to be in format of Y2/S1\", printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" void computePaceInvalidSemester() {","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y2/s10\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(\"Invalid Semester\", printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" void computePaceInvalidYear() {","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y20/s1\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(\"Invalid Year\", printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" void computePaceValidYear() {","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y2/s1\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" String line \u003d \"You have 100MCs for 5 semesters. Recommended Pace: 20MCs per sem until graduation\";","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, line);","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" void determinePrereq_invalidModuleCode() {","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" String invalidModuleCode \u003d \"cs134.\";","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" String major \u003d \"CEG\";","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(invalidModuleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" String expectedResponse \u003d \"Invalid Module Code :Only alphabets and digits are allowed in module codes!\";","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedResponse);","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":" void determinePrereq_validModuleCodeWithNoPreReq() {","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" String invalidModuleCode \u003d \"GEN2061\";","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" String major \u003d \"CEG\";","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(invalidModuleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" String expectedResponse \u003d \"Module GEN2061 has no prerequisites.\";","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedResponse);","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" void determinePrereq_validModuleCodeWithPreReq() {","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" String invalidModuleCode \u003d \"EE2211\";","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" String major \u003d \"CEG\";","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(invalidModuleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" String expectedResponse \u003d \"[CS1010, MA1511, MA1508E]\";","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedResponse);","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" void testPrereq_addValidModuleToStudent() throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" String moduleCode \u003d \"EG1311\";","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":" boolean doesModuleExist \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(moduleCode, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"ryanlohyr"},"content":" Schedule currentSchedule \u003d student.getSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" doesModuleExist \u003d currentSchedule.exists(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Module Successfully Added\\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 1: EG1311 \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 2: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 3: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 4: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 5: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 6: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 7: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":163,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 8:\";","lastModifiedDate":"2023-11-03"},{"lineNumber":164,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":166,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":169,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":170,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":171,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":172,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":173,"author":{"gitId":"ryanlohyr"},"content":" assertTrue(doesModuleExist);","lastModifiedDate":"2023-11-03"},{"lineNumber":174,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":175,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"ryanlohyr"},"content":" void testPrereq_addInValidModuleToStudent() throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"ryanlohyr"},"content":" String moduleCode \u003d \"eEG1311\";","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"ryanlohyr"},"content":" boolean doesModuleExist \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(moduleCode, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":184,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"ryanlohyr"},"content":" Schedule currentSchedule \u003d student.getSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"ryanlohyr"},"content":" doesModuleExist \u003d currentSchedule.exists(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":192,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":193,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":194,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":195,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Invalid Module Name\\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":196,"author":{"gitId":"ryanlohyr"},"content":" \"Please select a valid module\";","lastModifiedDate":"2023-11-03"},{"lineNumber":197,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":198,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":199,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":200,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":201,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":203,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":204,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":205,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" assertFalse(doesModuleExist);","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":210,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":211,"author":{"gitId":"ryanlohyr"},"content":" void testPrereq_addInvalidModuleToStudent() throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":212,"author":{"gitId":"ryanlohyr"},"content":" String moduleCode \u003d \"CS2113\";","lastModifiedDate":"2023-11-03"},{"lineNumber":213,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"ryanlohyr"},"content":" boolean doesModuleExist \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":215,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":216,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(moduleCode, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":217,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":218,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":219,"author":{"gitId":"ryanlohyr"},"content":" Schedule currentSchedule \u003d student.getSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":220,"author":{"gitId":"ryanlohyr"},"content":" doesModuleExist \u003d currentSchedule.exists(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":225,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":227,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"This module\u0027s prerequisites are [CS2040C]\\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" \"Unable to add module as prerequisites not satisfied for: CS2113\";","lastModifiedDate":"2023-11-03"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":233,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":234,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":235,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" assertFalse(doesModuleExist);","lastModifiedDate":"2023-11-03"},{"lineNumber":237,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":238,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":239,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":240,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":241,"author":{"gitId":"ryanlohyr"},"content":" void testRecommend_generateCEGRecommendedSchedule() {","lastModifiedDate":"2023-11-04"},{"lineNumber":242,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(student.getMajor());","lastModifiedDate":"2023-11-04"},{"lineNumber":243,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":244,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":245,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"[GEA1000, MA1511, MA1512, DTK1234, GESS1000, CS1010, GEN2000, EG2501, EG1311\"","lastModifiedDate":"2023-11-04"},{"lineNumber":246,"author":{"gitId":"ryanlohyr"},"content":" + \", GEC1000, PF1101, CDE2000, IE2141, CG1111A, EG2401A, ES2631, ST2334, MA1508E, CS1231, CG2023, \"","lastModifiedDate":"2023-11-04"},{"lineNumber":247,"author":{"gitId":"ryanlohyr"},"content":" + \"CG2111A, CS2040C, CG2027, EE2026, EE4204, EE2211, CG2271, CS2113, CG2028, CP3880, CG4002]\";","lastModifiedDate":"2023-11-04"},{"lineNumber":248,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(expectedOutput, printedOutput);","lastModifiedDate":"2023-11-04"},{"lineNumber":249,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":250,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":251,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":252,"author":{"gitId":"ryanlohyr"},"content":" void testRecommend_addCEGRecommendedScheduleToStudent() {","lastModifiedDate":"2023-11-04"},{"lineNumber":253,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(\"CEG\");","lastModifiedDate":"2023-11-04"},{"lineNumber":254,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().addRecommendedScheduleListToSchedule(recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":255,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().printMainModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":256,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":257,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Sem 1: GESS1000 DTK1234 MA1512 MA1511 GEA1000 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":258,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 2: GEC1000 EG1311 EG2501 GEN2000 CS1010 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":259,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 3: EG2401A CG1111A IE2141 CDE2000 PF1101 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":260,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 4: CG2023 CS1231 MA1508E ST2334 ES2631 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":261,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 5: EE4204 EE2026 CG2027 CS2040C CG2111A \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":262,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 6: CG2028 CS2113 CG2271 EE2211 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":263,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 7: CG4002 CP3880 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":264,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 8:\";","lastModifiedDate":"2023-11-04"},{"lineNumber":265,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":266,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":267,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":268,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":269,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":270,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":271,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":272,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":273,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":274,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(expectedOutput, printedOutput);","lastModifiedDate":"2023-11-04"},{"lineNumber":275,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":276,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":277,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":278,"author":{"gitId":"ryanlohyr"},"content":" void testRecommend_addCSRecommendedScheduleToStudent() {","lastModifiedDate":"2023-11-04"},{"lineNumber":279,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(\"CS\");","lastModifiedDate":"2023-11-04"},{"lineNumber":280,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().addRecommendedScheduleListToSchedule(recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":281,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().printMainModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":282,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":283,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Sem 1: CS1231S MA1522 IS1108 MA1521 GEA1000 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":284,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 2: GEN2000 GESS1000 CS1101S CS2101 ES2660 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":285,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 3: CS2100 CS2040S CS2030S ST2334 GEC1000 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":286,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 4: CS2103T \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":287,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 5: CP3880 CS2106 CS3230 CS2109S \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":288,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 6: \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":289,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 7: \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":290,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 8:\";","lastModifiedDate":"2023-11-04"},{"lineNumber":291,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":292,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":293,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":294,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":295,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":296,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":297,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":298,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":299,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":300,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(expectedOutput, printedOutput);","lastModifiedDate":"2023-11-04"},{"lineNumber":301,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":302,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":303,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":304,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":301,"janelleenqi":3}},{"path":"src/test/java/seedu/duke/models/logic/DataRepositoryTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"class DataRepositoryTest {","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" void validRequirementsReturned() {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e cegRequirementArray \u003d DataRepository.getRequirements(\"CEG\");","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" int numberOfRequiredCegMods \u003d 31;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(numberOfRequiredCegMods,cegRequirementArray.size());","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ryanlohyr":17}},{"path":"src/test/java/seedu/duke/models/logic/MajorRequirementsTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleServiceController.getRequiredModules;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"class MajorRequirementsTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" private final ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" public void setUpStreams() {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" @AfterEach","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" public void restoreStreams() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" void printRequiredModules_validMajor_expectRequiredModulesShown() {","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" getRequiredModules(\"CEG\");","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" // Capture the printed output","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" String printedOutput \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" assertTrue(printedOutput.startsWith(","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" \"#\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d#\")","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" );","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ryanlohyr":2,"janelleenqi":38}},{"path":"src/test/java/seedu/duke/models/logic/ScheduleGeneratorTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.ScheduleGenerator.generateRecommendedSchedule;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"class ScheduleGeneratorTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" void validRecommendedSchedule() {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e cegRequirementArray \u003d generateRecommendedSchedule(\"CEG\");","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" assert(!cegRequirementArray.isEmpty());","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"ryanlohyr":15}},{"path":"src/test/java/seedu/duke/models/schema/ModuleListTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"class ModuleListTest {","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":" //success scenario 1: 1 input String, 1 ModuleList that contains input String --\u003e true","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" void existsTest_moduleListContainsModule_expectTrue() throws InvalidObjectException {","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" String inputString \u003d \"CS1231S\";","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList(\"CS1231S CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230\");","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" boolean result \u003d ml.exists(inputString);","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" assertTrue(result);","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" //success scenario 2: 1 input String, 1 ModuleList that does not contain input String --\u003e false","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" void existsTest_moduleListDoesNotContainModule_expectFalse() throws InvalidObjectException {","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":" String inputString \u003d \"CS1231S\";","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList(\"CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230\");","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" boolean result \u003d ml.exists(inputString);","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" assertFalse(result);","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" //failure scenario 1: input null string, 1 ModuleList --\u003e throw exception","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" void existsTest_nullInput_expectException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList(\"CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230\");","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" assertThrows(InvalidObjectException.class, () -\u003e ml.exists(null));","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" //success scenario 3: input string, 1 empty ModuleList --\u003e false","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" void existsTest_nullMainModuleList_expectException() throws InvalidObjectException {","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" String inputString \u003d \"CS1231S\";","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList();","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":" boolean result \u003d ml.exists(inputString);","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" assertFalse(result);","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"SebasFok":1,"janelleenqi":53}},{"path":"src/test/java/seedu/duke/models/schema/ScheduleTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"class ScheduleTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":" //success scenario: String containing valid module, int containing valid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"SebasFok"},"content":" //module satisfies prereqs --\u003e module added","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_correctInputsSatisfyPrereqs_expectModuleAdded() throws Exception {","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule();","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"SebasFok"},"content":" schedule.addModule(\"CS1010\", 1);","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cString\u003e testArray\u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"SebasFok"},"content":" testArray.add(\"CS1010\");","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" assertEquals(testArray, schedule.getModuleCodes());","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"SebasFok"},"content":" //failure scenario 1: String containing valid module, int containing valid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"SebasFok"},"content":" //module does not satisfy prereqs --\u003e throw FailPrereqException","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_correctInputsDoesNotSatisfyPrereqs_expectException() {","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule(\"CS1231S MA1511\", new int[]{2, 0, 0, 0, 0, 0, 0, 0});","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"SebasFok"},"content":" assertThrows(FailPrereqException.class, () -\u003e schedule.addModule(\"CS2040C\", 1));","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"SebasFok"},"content":" //failure scenario 2: String containing invalid module, int containing valid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"SebasFok"},"content":" //--\u003e throws IllegalArgumentException","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_invalidModule_expectException() {","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule(\"CS1231S MA1511\", new int[]{2, 0, 0, 0, 0, 0, 0, 0});","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e schedule.addModule(\"wrong\", 1));","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" //failure scenario 3: String containing valid module, int containing invalid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" //--\u003e throws IllegalArgumentException","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_invalidTargetSem_expectException() {","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule(\"CS1231S MA1511\", new int[]{2, 0, 0, 0, 0, 0, 0, 0});","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e schedule.addModule(\"CS2040C\", 1000));","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"SebasFok":50,"janelleenqi":1}},{"path":"src/test/java/seedu/duke/models/schema/StudentTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"public class StudentTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":" //success scenario: difference (not working)","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":" void getModuleCodesLeft_majorSet_expectArrayList() {","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" Student student \u003d new Student();","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" student.setMajor(\"CEG\");","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" //actual: student.getModuleCodesLeft();","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" //expected:","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e expected \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e majorModuleCodes \u003d student.getMajorModuleCodes();","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e modulesInPlanner \u003d student.getModulesPlanned().getModulesCompleted();","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" for (String moduleCode : majorModuleCodes) {","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" if (!modulesInPlanner.contains(moduleCode)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" expected.add(moduleCode);","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" assertEquals(expected, student.getModuleCodesLeft());","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" // getModuleCodesLeft_noMajorSet_expectException()","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" // getDifferenceTest_twoModuleList_expectDifference()","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" // success scenario 2: 1 empty ModuleList, 1 ModuleList --\u003e difference which is empty","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" // getDifferenceTest_oneEmptyModuleListAnotherModuleList_expectEmptyDifference()","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" // failure scenario 1: null ModuleList input --\u003e throw exception","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" // getDifferenceTest_nullModuleListInput_expectException()","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"SebasFok":5,"janelleenqi":33}}] +[{"path":"README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Duke project template","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":"This is a project template for a greenfield Java project. It\u0027s named after the Java mascot _Duke_. Given below are instructions on how to use it.","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"## Setting up in Intellij","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"Prerequisites: JDK 11 (use the exact version), update Intellij to the most recent version.","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"1. **Ensure Intellij JDK 11 is defined as an SDK**, as described [here](https://www.jetbrains.com/help/idea/sdk.html#set-up-jdk) -- this step is not needed if you have used JDK 11 in a previous Intellij project.","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"1. **Import the project _as a Gradle project_**, as described [here](https://se-education.org/guides/tutorials/intellijImportGradleProject.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"1. **Verify the set up**: After the importing is complete, locate the `src/main/java/seedu/duke/Duke.java` file, right-click it, and choose `Run Duke.main()`. If the setup is correct, you should see something like the below: i love 2113 ","lastModifiedDate":"2023-10-05"},{"lineNumber":12,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" \u003e Task :compileJava","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":" \u003e Task :processResources NO-SOURCE","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":" \u003e Task :classes","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":" \u003e Task :Duke.main()","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":" Hello from","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" ____ _ ","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" | _ \\ _ _| | _____ ","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" | | | | | | | |/ / _ \\","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" | |_| | |_| | \u003c __/","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" |____/ \\__,_|_|\\_\\___|","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":25,"author":{"gitId":"-"},"content":" What is your name?","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" Type some word and press enter to let the execution proceed to the end.","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"## Build automation using Gradle","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"* This project uses Gradle for build automation and dependency management. It includes a basic build script as well (i.e. the `build.gradle` file).","lastModifiedDate":"2020-05-24"},{"lineNumber":32,"author":{"gitId":"-"},"content":"* If you are new to Gradle, refer to the [Gradle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/gradle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":34,"author":{"gitId":"-"},"content":"## Testing","lastModifiedDate":"2020-05-24"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"-"},"content":"### I/O redirection tests","lastModifiedDate":"2020-05-24"},{"lineNumber":37,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"* To run _I/O redirection_ tests (aka _Text UI tests_), navigate to the `text-ui-test` and run the `runtest(.bat/.sh)` script.","lastModifiedDate":"2020-05-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":40,"author":{"gitId":"-"},"content":"### JUnit tests","lastModifiedDate":"2020-05-24"},{"lineNumber":41,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":42,"author":{"gitId":"-"},"content":"* A skeleton JUnit test (`src/test/java/seedu/duke/DukeTest.java`) is provided with this project template. ","lastModifiedDate":"2020-05-24"},{"lineNumber":43,"author":{"gitId":"-"},"content":"* If you are new to JUnit, refer to the [JUnit Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/junit.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":45,"author":{"gitId":"-"},"content":"## Checkstyle","lastModifiedDate":"2020-05-24"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":47,"author":{"gitId":"-"},"content":"* A sample CheckStyle rule configuration is provided in this project.","lastModifiedDate":"2020-05-24"},{"lineNumber":48,"author":{"gitId":"-"},"content":"* If you are new to Checkstyle, refer to the [Checkstyle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/checkstyle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":50,"author":{"gitId":"-"},"content":"## CI using GitHub Actions","lastModifiedDate":"2020-05-24"},{"lineNumber":51,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":52,"author":{"gitId":"-"},"content":"The project uses [GitHub actions](https://github.com/features/actions) for CI. When you push a commit to this repo or PR against it, GitHub actions will run automatically to build and verify the code as updated by the commit/PR.","lastModifiedDate":"2020-05-24"},{"lineNumber":53,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":54,"author":{"gitId":"-"},"content":"## Documentation","lastModifiedDate":"2020-05-24"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"-"},"content":"`/docs` folder contains a skeleton version of the project documentation.","lastModifiedDate":"2020-05-24"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"-"},"content":"Steps for publishing documentation to the public: ","lastModifiedDate":"2020-05-24"},{"lineNumber":59,"author":{"gitId":"-"},"content":"1. If you are using this project template for an individual project, go your fork on GitHub.\u003cbr\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":60,"author":{"gitId":"-"},"content":" If you are using this project template for a team project, go to the team fork on GitHub.","lastModifiedDate":"2020-05-24"},{"lineNumber":61,"author":{"gitId":"-"},"content":"1. Click on the `settings` tab.","lastModifiedDate":"2020-05-24"},{"lineNumber":62,"author":{"gitId":"-"},"content":"1. Scroll down to the `GitHub Pages` section.","lastModifiedDate":"2020-05-24"},{"lineNumber":63,"author":{"gitId":"-"},"content":"1. Set the `source` as `master branch /docs folder`.","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"-"},"content":"1. Optionally, use the `choose a theme` button to choose a theme for your documentation.","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"SebasFok":1,"-":63}},{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":" implementation \u0027com.googlecode.json-simple:json-simple:1.1.1\u0027","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":33,"author":{"gitId":"-"},"content":" mainClass.set(\"seedu.duke.Duke\")","lastModifiedDate":"2023-08-05"},{"lineNumber":34,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveBaseName.set(\"duke\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":42,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":"run {","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"janelleenqi":1,"rohitcube":1,"-":46}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-14"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"|--------------------------------|:-----------------------:|:-----------------------------------------:|:-------------------------------------------------:|","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"| ![](photos/sebas_pic.png) | Sebastian Fok Shin Hung | [Github](https://github.com/SebasFok/) | [Portfolio](team/sebastianfok.md) |","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"| ![](photos/j.png) | Liow Enqi Janelle | [Github](https://github.com/janelleenqi/) | [Portfolio](team/liowenqijanelle.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"| ![](photos/rohit_pic.png) | Rohit R | [Github](https://github.com/rohitcube) | [Portfolio](team/johndoe.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"| ![](photos/ryanPic.JPG) | Ryan Loh | [Github](https://github.com/ryanlohyr) | [Portfolio](https://ryanlohyr.github.io/ryanloh/) |","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"| ![](photos/isaiah_profile.png) | Isaiah Cerven | [Github](https://github.com/CerIsaiah/) | [Portfolio](team/isaiah.md) |","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"SebasFok":7,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"## Design \u0026 implementation, Architecture","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"![img.png](diagrams/architectureDiagram.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"The Architecture Diagram given above explains the high-level design of the application.","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"The main logic of the application is handled by these four components","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"- **Controller**: ","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" - Handles Commands coming from the User ","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" - Combines data from the **Model** and UI Components from **View**","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" - Never handles data logic","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"- **View**:","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" - Responsible for printing onto the Command Line Application","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"- **Model**: ","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" - Response for retrieving data from the **Data Repository** ","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" - Performs REST API calls to the NUSMODS API","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":"- **Data Repository**: ","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" - Reads data from, and writes data to file","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"### How the architecture components interact with each other","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"![img.png](diagrams/addModule.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"The Sequence Diagram above shows how the components interact with each other when the user inserts a module ","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"into his schedule","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":"## Features: ","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"- Pace","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":"- Left","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":"- Major","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":"- Required","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":"- Info (description, workload, command)","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":"- Search ","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":"- Add","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":"- Delete","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":"- Recommend","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":"# Implementation","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":"## Pacing and MC Calculation","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"The \"Pacing and MC Calculation\" mechanism is implemented to help users track their academic progress and remaining Modular Credits (MCs) required for graduation. This feature is facilitated by the PacingManager, which stores user data and provides functions for calculating the recommended pacing and remaining MCs. The following operations are available:","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#calculateRemainingMCs() — Calculates the remaining MCs required for graduation.","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#calculateRecommendedPace() — Recommends the pacing for upcoming semesters.","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":"These operations are exposed in the Pacing interface as Pacing#calculateRemainingMCs() and Pacing#calculateRecommendedPace() respectively.","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"### Usage Examples","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":"Here are a few examples of how the \"Pacing and MC Calculation\" feature behaves:","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":"#### Example 1: Calculate Remaining MCs","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":"Command: `pace Y2/S1` (assuming that the user has completed 60 MCs from Y1S1 to Y2S1)","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"`You currently have 100 MCs left until graduation.`","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"janelleenqi"},"content":"#### Example 2: Calculate Remaining MCs (No Semester Specified)","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":"Command: `pace`","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"janelleenqi"},"content":"`You currently have 100 MCs left until graduation.`","lastModifiedDate":"2023-10-24"},{"lineNumber":73,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":"## Recommend Schedule Based on Course","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"Based on the course, we will provide an recommended schedules that is sorted based on prerequisites. This feature is facilitated by the scheudle manager which stores information about the schedule and performs actions like add and remove from schedule.","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#recommend() — recommends a scheudle that is sorted based on pre requisites. ","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":"- PacingManager#addRecommendedScheduleToSchedule() — adds the recommended schedue to the user\u0027s timetable.","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":"These operations are exposed in the Scheulde interface as Schedule#addRecommendedScheduleListToSchedule() and ScheduleGenerator#generateRecommendedSchedule() respectively.","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"### Usage Examples","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":"Here are a few examples of how the \"Recommend schedule\" feature behaves:","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":"#### Step 1: Recommend schedule for computer engineering(CEG)","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":"Command: `recommend ceg` ","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":"`[GEA1000, MA1511, MA1512, DTK1234, GESS1000, CS1010, GEN2000, EG2501, EG1311, GEC1000, PF1101, CDE2000, IE2141, CG1111A, EG2401A, ES2631, ST2334, MA1508E, CS1231, CG2023, CG2111A, CS2040C, CG2027, EE2026, EE4204, EE2211, CG2271, CS2113, CG2028, CP3880, CG4002]","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":"Do you want to add this to your draft schedule?, please input \u0027Y\u0027 or \u0027N\u0027","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":"`","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":"#### Step 2 (Only to be done after step 1): ","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":"Command: `Y`","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":"Response:","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":"`","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":"Sem 1: GESS1000 DTK1234 MA1512 MA1511 GEA1000 ","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"Sem 2: GEC1000 EG1311 EG2501 GEN2000 CS1010 ","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"Sem 3: EG2401A CG1111A IE2141 CDE2000 PF1101 ","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":"Sem 4: CG2023 CS1231 MA1508E ST2334 ES2631 ","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":"Sem 5: EE4204 EE2026 CG2027 CS2040C CG2111A ","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":"Sem 6: CG2028 CS2113 CG2271 EE2211 ","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":"Sem 7: CG4002 CP3880 ","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"Sem 8: `","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"janelleenqi"},"content":"## List Modules Left Feature","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":113,"author":{"gitId":"janelleenqi"},"content":"The following sequence diagram shows how the Left Command function works.","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"janelleenqi"},"content":"![img.png](diagrams/left_seq_diag.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":"The left mechanism is implemented to help users keep tracks of modules left for their major. It is facilitated by `modulesLeft`, `modulesMajor` and `modulesTaken`. Additionally, it implements the following operations:","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":"- `student#getModulesMajor()` and `student#getModulesTaken()` – Returns moduleList modulesMajor and modulesTaken respectively.","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":"- `modulesMajor#showModulesDiff(modulesTaken)` – Display modules left.","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"janelleenqi"},"content":"- `modulesTaken#getMainModuleList()` - Returns ArrayList\u003cModule\u003e of modulesTaken which is the ArrayList of modules taken.","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":"- `new ModuleList()` - Instantiate modulesLeft.","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":"This operation is exposed in the `ModulePlannerController` interface as `ModulePlannerController#listModulesLeft()`.","lastModifiedDate":"2023-10-24"},{"lineNumber":124,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":125,"author":{"gitId":"janelleenqi"},"content":"### Usage Examples","lastModifiedDate":"2023-10-24"},{"lineNumber":126,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":127,"author":{"gitId":"janelleenqi"},"content":"Here are a few examples of how the List Modules Left Feature behaves:","lastModifiedDate":"2023-10-24"},{"lineNumber":128,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":129,"author":{"gitId":"janelleenqi"},"content":"#### Example 1: ","lastModifiedDate":"2023-10-24"},{"lineNumber":130,"author":{"gitId":"janelleenqi"},"content":"`modulesMajor#getMainModuleList()` gives modules `CS1231S CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230`.","lastModifiedDate":"2023-10-24"},{"lineNumber":131,"author":{"gitId":"janelleenqi"},"content":"`modulesTaken#getMainModuleList()` gives modules `CS1231S MA1511`","lastModifiedDate":"2023-10-24"},{"lineNumber":132,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":133,"author":{"gitId":"janelleenqi"},"content":"Command: `left`","lastModifiedDate":"2023-10-24"},{"lineNumber":134,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":135,"author":{"gitId":"janelleenqi"},"content":"Response:","lastModifiedDate":"2023-10-24"},{"lineNumber":136,"author":{"gitId":"janelleenqi"},"content":"`CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230`","lastModifiedDate":"2023-10-24"},{"lineNumber":137,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":138,"author":{"gitId":"janelleenqi"},"content":"## Input Major Feature","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":140,"author":{"gitId":"janelleenqi"},"content":"The input major feature is facilitated by `Student`. It tries to store the major specified in userInput txt ","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":"file such that it can be used across sessions. It will print different responses based on whether the storing of the ","lastModifiedDate":"2023-10-25"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":"Major was successful. Additionally, it implements the following operation:","lastModifiedDate":"2023-10-25"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":144,"author":{"gitId":"SebasFok"},"content":"- `Student#setMajor(Major major)` – Saves the selected major in its memory.","lastModifiedDate":"2023-10-25"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":"This operation is exposed in the `Student` interface as `Student#updateMajor(String userInput)`.","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"SebasFok"},"content":"### Usage Examples","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"SebasFok"},"content":"Here are a few examples of how the Input Major Feature behaves:","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":152,"author":{"gitId":"SebasFok"},"content":"#### Example 1:","lastModifiedDate":"2023-10-25"},{"lineNumber":153,"author":{"gitId":"SebasFok"},"content":"If \"CS\" is a valid major: `Student#updateMajor(\"major CS\")` calls `Student#setMajor(\"CS\")`, which sets the Major in the ","lastModifiedDate":"2023-10-25"},{"lineNumber":154,"author":{"gitId":"SebasFok"},"content":"student object as `CS` and returns a string `newMajor`","lastModifiedDate":"2023-10-25"},{"lineNumber":155,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":156,"author":{"gitId":"SebasFok"},"content":"Command: `major CS`","lastModifiedDate":"2023-10-25"},{"lineNumber":157,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":158,"author":{"gitId":"SebasFok"},"content":"Response: `Major CS selected!`","lastModifiedDate":"2023-10-25"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":160,"author":{"gitId":"SebasFok"},"content":"#### Example 2:","lastModifiedDate":"2023-10-25"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":"If \"abc\" is an invalid major: `Student#updateMajor(\"major abc\")` calls `Student#setMajor(\"abc\")`, which generates an","lastModifiedDate":"2023-10-25"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":"IllegalArgumentException, which is caught and returns a string `invalidMajor`","lastModifiedDate":"2023-10-25"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":"Command: `major abc`","lastModifiedDate":"2023-10-25"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":"Response: `Please select a major from this list: [list of currently available Majors]`","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":"#### Example 3:","lastModifiedDate":"2023-10-25"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":"If no major was specified: `Student#updateMajor(\"major\")` returns a string `currentMajor`","lastModifiedDate":"2023-10-25"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":"Command: `major`","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":"Response: `Current major is [current major in student object].`","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"janelleenqi"},"content":"## Required Command","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"janelleenqi"},"content":"The following sequence diagram shows how the Required Command function works.","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":"![img.png](diagrams/required_seq_diag.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"janelleenqi"},"content":"The required command is implemented to give users an overview of the modules they need to complete for ","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"janelleenqi"},"content":"their major. It is facilitated by major. Additionally, it implements the following operations:","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"janelleenqi"},"content":"- `Student#getMajor()` – Returns the `major` of the student.","lastModifiedDate":"2023-11-03"},{"lineNumber":184,"author":{"gitId":"janelleenqi"},"content":"- `ModuleServiceController#getRequiredModules(major)` and `ModuleServiceController#printRequiredModules(major)` – ","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"janelleenqi"},"content":"Displays the modules required.","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"rohitcube"},"content":"### Usage Examples","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"rohitcube"},"content":"Here are a few examples of how the Show Required Modules Feature behaves:","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"rohitcube"},"content":"#### Example 1:","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"rohitcube"},"content":"Command: `required`","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"rohitcube"},"content":"Response:","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"rohitcube"},"content":"Module requirements for major selected by user","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"janelleenqi"},"content":"## Get information about modules (from the NUSMods API)","lastModifiedDate":"2023-11-03"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"janelleenqi"},"content":"The information feature returns information about the module at the user\u0027s request. It accepts 3 commands, ","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":"\u0027description\u0027, \u0027workload\u0027 and \u0027all\u0027. The \u0027description\u0027 command returns a string description of the module, the workload","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"rohitcube"},"content":"command returns an array, and all displays the module title and module code for all modules present in the NUSMods ","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"rohitcube"},"content":"directory.","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"rohitcube"},"content":"- `getFullModuleInfo(major)` – Returns the `filePath` for the requirements of a specified major.","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"rohitcube"},"content":"- `sendHttpRequestAndGetResponseBody(String url)` – Displays the overview of modules required.","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"rohitcube"},"content":"- `getDescription(String moduleCode)` – Returns the `longestLineLength` of the file f.","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"rohitcube"},"content":"- `getWorkload(String moduleCode)` – Returns a string with a justified name according to length, appended with its description.","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"rohitcube"},"content":"- `listAllModules(), `printDoubleTopLine()`, `printBottomLine()`, `printDoubleBottomLine()` – Displays lines for formatting","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"rohitcube"},"content":"- `infoCommands(String command, String userInput), `printDoubleTopLine()`, `printBottomLine()`, `printDoubleBottomLine()` – Displays lines for formatting","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"janelleenqi"},"content":"### Usage Examples","lastModifiedDate":"2023-10-31"},{"lineNumber":214,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":215,"author":{"gitId":"janelleenqi"},"content":"Here are a few examples of how the Show Required Modules Feature behaves:","lastModifiedDate":"2023-10-31"},{"lineNumber":216,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":217,"author":{"gitId":"janelleenqi"},"content":"#### Example 1:","lastModifiedDate":"2023-10-31"},{"lineNumber":218,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"janelleenqi"},"content":"Command: `required`","lastModifiedDate":"2023-10-31"},{"lineNumber":220,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":221,"author":{"gitId":"janelleenqi"},"content":"Response:","lastModifiedDate":"2023-10-31"},{"lineNumber":222,"author":{"gitId":"janelleenqi"},"content":"Module requirements for major selected by user","lastModifiedDate":"2023-10-31"},{"lineNumber":223,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":225,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":226,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":227,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":228,"author":{"gitId":"-"},"content":"{Describe the target user profile}","lastModifiedDate":"2020-05-24"},{"lineNumber":229,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":230,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"-"},"content":"{Describe the value proposition: what problem does it solve?}","lastModifiedDate":"2020-05-24"},{"lineNumber":233,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":234,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":235,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":236,"author":{"gitId":"-"},"content":"|Version| As a ... | I want to ... | So that I can ...|","lastModifiedDate":"2020-05-24"},{"lineNumber":237,"author":{"gitId":"-"},"content":"|--------|----------|---------------|------------------|","lastModifiedDate":"2020-05-24"},{"lineNumber":238,"author":{"gitId":"-"},"content":"|v1.0|new user|see usage instructions|refer to them when I forget how to use the application|","lastModifiedDate":"2020-05-24"},{"lineNumber":239,"author":{"gitId":"-"},"content":"|v2.0|user|find a to-do item by name|locate a to-do without having to go through the entire list|","lastModifiedDate":"2020-05-24"},{"lineNumber":240,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":241,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":242,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":243,"author":{"gitId":"-"},"content":"{Give non-functional requirements}","lastModifiedDate":"2020-05-24"},{"lineNumber":244,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":245,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":246,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":247,"author":{"gitId":"-"},"content":"* *glossary item* - Definition","lastModifiedDate":"2020-05-24"},{"lineNumber":248,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":249,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":250,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":251,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"SebasFok":40,"ryanlohyr":81,"janelleenqi":69,"rohitcube":24,"-":37}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"# NUSDegs User Guide","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"NUSDegs streamlines computing degree planning by offering personalized module schedules, tracking progress, ","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"and ensuring on-time graduation. It eliminates guesswork, reduces stress, and saves time for students. ","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"It\u0027s a comprehensive tool for efficient and successful degree completion.","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"{Give steps to get started quickly}","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":"1. Ensure that you have Java 11 or above installed.","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":"1. Down the latest version of `Duke` from [here](http://link.to/duke).","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":"## Features","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"- Left","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"- Required","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":"- Complete","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":"- Info","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"SebasFok"},"content":"- Search","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"SebasFok"},"content":"- Major","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":"- Add","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":"- Delete","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"- recommend","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"- prereq","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"{Give detailed description of each feature}","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"### Checking modules left: `left`","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"Displays the modules left, which are the modules required for the user\u0027s major that have not been completed.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"Format: `left`","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"Example of usage 1: (scenario where user\u0027s selected major is CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":"User input: ","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":"`left`","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":"![ss_left_ceg.png](screenshots%2Fss_left_ceg.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":"### Getting a list of required modules: `required`","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"Get an overview of required modules for the user\u0027s major","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":"Format: `required`","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":"Example of usage 1: (scenario where user\u0027s selected major is CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":"User input:","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":"`required`","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":"![ss_required_ceg.png](screenshots%2Fss_required_ceg.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":"![ss_required_ceg2.png](screenshots%2Fss_required_ceg2.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"janelleenqi"},"content":"### Complete a module: `complete`","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":"Completes a module (not displayed when the feature `left` is used).","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":"Format: `complete`","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":"Example of usage 1: (scenario where user\u0027s selected major is CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":"User input:","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"`complete ma1511`","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"janelleenqi"},"content":"Expected outcome:","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"janelleenqi"},"content":"`Mod completed: MA1511`","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"janelleenqi"},"content":"Changes to modules left are shown when","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"janelleenqi"},"content":"User input:","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"janelleenqi"},"content":"`left`","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"janelleenqi"},"content":"Expected outcome:","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"janelleenqi"},"content":"![ss_complete_ceg.png](screenshots%2Fss_complete_ceg.png)","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"rohitcube"},"content":"### Get information about a module: `info`","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"rohitcube"},"content":"Get information about a module using the info command, followed by one of the commands \u0027description\u0027, \u0027workload\u0027 ","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"rohitcube"},"content":"and \u0027all\u0027.","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":82,"author":{"gitId":"rohitcube"},"content":"Format: `info n/command n/moduleCode`","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":84,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":"* The `command` cannot be empty.","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"rohitcube"},"content":"* The `moduleCode` cannot be empty.","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"-"},"content":"Example of usage: ","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"rohitcube"},"content":"`info description CS2113`","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: This course introduces the necessary skills for systematic and rigorous development of software systems. It covers requirements, design, implementation, quality assurance, and project management aspects of small-to-medium size multi-person software projects. The course uses the Object Oriented Programming paradigm. Students of this course will receive hands-on practice of tools commonly used in the industry, such as test automation tools, build automation tools, and code revisioning tools will be covered.","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"rohitcube"},"content":"`info workload CS2113`","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: \"[2,1,0,3,4]\"","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"SebasFok"},"content":"`info all`","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":"- Expected outcome: Displays module title and module code of all available modules","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"rohitcube"},"content":"### Searching for a module by title: `search`","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"rohitcube"},"content":"Search for module title using a keyword.","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"rohitcube"},"content":"Format: `search n/KEYWORD`","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"rohitcube"},"content":"* The `KEYWORD` cannot be empty.","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":110,"author":{"gitId":"-"},"content":"Example of usage:","lastModifiedDate":"2020-05-24"},{"lineNumber":111,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":112,"author":{"gitId":"rohitcube"},"content":"`search n/Darwinian`","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":114,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"rohitcube"},"content":"These are the modules that contain your keyword in the title:","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":117,"author":{"gitId":"SebasFok"},"content":"### Selecting your current major: `major`","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"SebasFok"},"content":"Saves the selected major into the programme if a major is specified.","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"SebasFok"},"content":"Returns the current saved major if no major is specified.","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"SebasFok"},"content":"Format: `major n/MAJOR`","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":"* The `MAJOR` is an optional argument to update current major and can be CEG (upcoming feature includes CS).","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"SebasFok"},"content":"Examples of usage:","lastModifiedDate":"2023-11-02"},{"lineNumber":126,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"SebasFok"},"content":"`major CEG`","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":129,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: \"Major CEG selected!\"","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"SebasFok"},"content":"`major` (Assume CEG has been selected by the previous command)","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"SebasFok"},"content":"- Expected outcome: \"Current major is CEG.\"","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":"### View recommended schedule based on course: recommend","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":"Based on the course, we will provide an recommended schedules that is sorted based on prerequisites.","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":"Format: `recommend MAJOR_CODE`","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":"The input is not case sensitive. E.g CEG or ceg is shown (Currently only works for CEG)","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":"Examples:","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":"Recommend ceg","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":"[CS1010, MA1511, MA1508E, … ,.... ,.... ,... EE4027] (modules required for the degree will be shown)","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"ryanlohyr"},"content":"### View module prerequisites: prereq ","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"ryanlohyr"},"content":"Based on the module selected, we will show what prerequisites the course has in a form of an array. Since NUS has the concept of preclusions, when prerequisites are shown, it is shown based on the degree of the current user, which is currently only computer science and computer engineering students.","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"ryanlohyr"},"content":"Format: `prepreq MODULE_CODE`","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"ryanlohyr"},"content":"The input is not case sensitive. E.g eg1311 or EG1311 is shown","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":"out","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":"Examples:","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":"`Command: prepreq eg1311` (assuming the user is from computer engineering)","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":"[CS1010, MA1511, MA1508E]","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":"Command: pace","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":"You currently have 100MCs left until graduation","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":160,"author":{"gitId":"SebasFok"},"content":"### Add module to schedule: `add`","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":"Opens the user\u0027s personalized module schedule and adds the chosen module to the semester specified by the user.","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":"Format: `add n/MODULE n/SEMESTER`","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":"* The `MODULE` cannot be empty and must be valid.","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":"* The `SEMESTER` cannot be empty and must be an integer between 1-8 inclusive.","lastModifiedDate":"2023-11-02"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":"Examples of usage:","lastModifiedDate":"2023-11-02"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":"`add CS1010 1`","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":"![](photos/add_outcome.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"SebasFok"},"content":"### Delete module from schedule: `delete`","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"SebasFok"},"content":"Opens the user\u0027s personalized module schedule and deletes the chosen module.","lastModifiedDate":"2023-11-02"},{"lineNumber":178,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":179,"author":{"gitId":"SebasFok"},"content":"Format: `delete n/MODULE`","lastModifiedDate":"2023-11-02"},{"lineNumber":180,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":181,"author":{"gitId":"SebasFok"},"content":"* The `MODULE` cannot be empty and must be valid.","lastModifiedDate":"2023-11-02"},{"lineNumber":182,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"SebasFok"},"content":"Examples of usage:","lastModifiedDate":"2023-11-02"},{"lineNumber":184,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":185,"author":{"gitId":"SebasFok"},"content":"`delete CS1010` (Assume schedule is currently in the state from the example in `add`)","lastModifiedDate":"2023-11-02"},{"lineNumber":186,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"SebasFok"},"content":"- Expected outcome:","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":189,"author":{"gitId":"SebasFok"},"content":"![](photos/delete_outcome.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":190,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":191,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":192,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":193,"author":{"gitId":"-"},"content":"**Q**: How do I transfer my data to another computer? ","lastModifiedDate":"2020-05-24"},{"lineNumber":194,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":195,"author":{"gitId":"janelleenqi"},"content":"**A**: Currently, this feature is not included in NUSDegs.","lastModifiedDate":"2023-11-03"},{"lineNumber":196,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":197,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":198,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":199,"author":{"gitId":"-"},"content":"{Give a \u0027cheat sheet\u0027 of commands here}","lastModifiedDate":"2020-05-24"},{"lineNumber":200,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":201,"author":{"gitId":"-"},"content":"* Add todo `todo n/TODO_NAME d/DEADLINE`","lastModifiedDate":"2020-05-24"},{"lineNumber":202,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"SebasFok":63,"ryanlohyr":26,"janelleenqi":51,"rohitcube":24,"-":38}},{"path":"docs/diagrams/Left.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"@startuml","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"autonumber","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"actor Student","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"participant \"controller:ModulePlannerController\" as A #white","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"participant \"student:Student\" as S #white","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"participant \"modulesMajor:ModuleList\" as M #white","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"participant \"modulesTaken:ModuleList\" as T #white","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"participant \"modulesLeft:ModuleList\" as L #white","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"Student -\u003e A: Execute \u0027Left\u0027 Command","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":"A -\u003e S: getModulesMajor()","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"activate S","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"S --\u003e A: Return modulesMajor:ModuleList","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":"deactivate S","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":"A -\u003e S: getModulesTaken()","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"activate S","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"S --\u003e A: Return modulesTaken:ModuleList","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":"deactivate S","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":"A -\u003e M: modulesMajor.showModulesDiff(modulesTaken)","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"activate M","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":"M -\u003e T: getMainModuleList()","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"activate T","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"T --\u003e M: Return Modules Taken","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":"deactivate T","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"create L","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":"M -\u003e L: ModuleList()","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":"activate L","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":"L --\u003e M: Return Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"destroy L","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":"A \u003c-- M: Display Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":"deactivate M","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"Student \u003c-- A: Display Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":"@enduml","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"janelleenqi":45}},{"path":"docs/diagrams/Required.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"@startuml","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"\u0027legend top left","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"\u0027 \u003ccolor blue\u003e Blue activation \u003c/color\u003e denote public method calls","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"\u0027 \u003ccolor red\u003e Red activation\u003c/color\u003e denote private method calls","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"\u0027endlegend","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"autonumber","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"autoactivate on","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"actor Student","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"participant \"controller:ModulePlannerController\" as A #white","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":"participant \"student:Student\" as S #white","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":"participant \"ModuleServiceController\" as MSC #white","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":"Student -\u003e A: Execute \u0027Required\u0027 Command","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":"A -\u003e S: getMajor()","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"\u0027activate S","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"S --\u003e A: Return major","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":"\u0027deactivate S","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":"A -\u003e MSC: getRequiredModules(major)","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"\u0027activate MSC","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"MSC -\u003e MSC: printRequiredModules(major)","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":"MSC --\u003e MSC: Display Required Modules","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":"MSC --\u003e A: Display Required Modules","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":"\u0027deactivate MSC","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"Student \u003c-- A: Display Modules Left","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":"@enduml","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"janelleenqi":35}},{"path":"docs/team/isaiah.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"CerIsaiah"},"content":"# Isaiah - Project Portfolio Page","lastModifiedDate":"2023-10-08"},{"lineNumber":2,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":3,"author":{"gitId":"CerIsaiah"},"content":"## Overview","lastModifiedDate":"2023-10-08"},{"lineNumber":4,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":5,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-08"},{"lineNumber":6,"author":{"gitId":"CerIsaiah"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-08"}],"authorContributionMap":{"CerIsaiah":6}},{"path":"docs/team/liowenqijanelle.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"# Liow Enqi Janelle - Project Portfolio Page","lastModifiedDate":"2023-10-07"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"## Overview","lastModifiedDate":"2023-10-07"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-07"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-07"}],"authorContributionMap":{"janelleenqi":6}},{"path":"docs/team/sebastianfok.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"# Sebastian Fok - Project Portfolio Page","lastModifiedDate":"2023-10-06"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"## Overview","lastModifiedDate":"2023-10-06"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-06"}],"authorContributionMap":{"SebasFok":6}},{"path":"src/main/java/seedu/duke/Duke.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"package seedu.duke;","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import seedu.duke.controllers.ModulePlannerController;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"-"},"content":"public class Duke {","lastModifiedDate":"2019-07-29"},{"lineNumber":6,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":" * Main entry-point for the java.duke.Duke application.","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":" public static void main(String[] args) {","lastModifiedDate":"2019-07-29"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" controller.start();","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":13,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"ryanlohyr":2,"rohitcube":1,"-":10}},{"path":"src/main/java/seedu/duke/controllers/ModuleMethodsController.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.exceptions.MissingModuleException;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.CompletePreqs;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.Parser;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.views.CommandLineView;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleServiceController.chooseToAddToSchedule;","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.doesModuleExist;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.getModulePrereqBasedOnCourse;","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.MajorRequirements.printRequiredModules;","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.ScheduleGenerator.generateRecommendedSchedule;","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displaySuccessfulAddMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.showPrereqCEG;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displaySuccessfulDeleteMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.ModuleInfoView.printModuleStringArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":"/**","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" * This class houses all the methods for the Module Planner controller.","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" * It provides functionality for computing the recommended pace, showing modules left,","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" * adding, deleting, completing modules,","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" * It provides functionality for computing the recommended pace,","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" * showing modules left, adding, deleting, completing modules,","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" * and getting required modules for a student.","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":"public class ModuleMethodsController {","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * Computes and displays the recommended pace for completing remaining module credits until graduation.","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" * @param arguments An array of strings containing academic year and semester information.","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" * @param completedModuleCredits The number of module credits already completed by the user.","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" static void computePace(String[] arguments, int completedModuleCredits) {","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" int totalCreditsToGraduate \u003d 160;","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d totalCreditsToGraduate - completedModuleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" boolean argumentProvided \u003d arguments.length !\u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" if (!argumentProvided) {","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"You currently have \" + creditsLeft + \" MCs till graduation\");","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" if (!Parser.isValidAcademicYear(arguments[0])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" String[] parts \u003d arguments[0].split(\"/\");","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" String year \u003d parts[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" String semester \u003d parts[1].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" int lastSemesterOfYear \u003d 2;","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" int lastYearOfDegree \u003d 4;","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" int yearIntValue \u003d Character.getNumericValue(year.charAt(1));","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" int semesterIntValue \u003d Character.getNumericValue(semester.charAt(1));","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" //if we are at y2s1, we have 5 semesters left","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" int semestersLeft \u003d (lastYearOfDegree - yearIntValue) * 2 + (lastSemesterOfYear - semesterIntValue);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" int creditsPerSem \u003d Math.round((float) creditsLeft / semestersLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"You have \" + creditsLeft + \"MCs for \" + semestersLeft + \" semesters. \"","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" + \"Recommended Pace: \" + creditsPerSem + \"MCs per sem until graduation\");","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"janelleenqi"},"content":" public static void showModulesLeft(ArrayList\u003cString\u003e moduleCodes) {","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" printModuleStringArray(moduleCodes);","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" public static void addModule(String module, int targetSem, Student student) {","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(module, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(module);","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" public static void recommendScheduleToStudent(Student student){","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" CommandLineView.displayMessage(\"Hold on a sec! Generating your recommended schedule \u003c3....\");","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(student.getMajor());","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" chooseToAddToSchedule(student, recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" public static void deleteModule(String module, Student student) {","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"janelleenqi"},"content":" student.deleteModuleSchedule(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulDeleteMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":" } catch (MissingModuleException | FailPrereqException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"janelleenqi"},"content":" public static boolean canCompleteModule(","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" String[] arguments,","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e majorModuleCodes,","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"janelleenqi"},"content":" //ModuleList modulesTaken,","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" CompletePreqs addModulePreqs) {","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"janelleenqi"},"content":" if (addModulePreqs.checkModInput(arguments, majorModuleCodes)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" String moduleCompleted \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" addModulePreqs.getUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" addModulePreqs.printUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"janelleenqi"},"content":" //modulesTaken.addModule(moduleCompleted);","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" return true;","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":" return false;","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" public static void getRequiredModulesForStudent(String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" printRequiredModules(major);","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" public static void determinePrereq(String moduleCode, String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" boolean exist \u003d doesModuleExist(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" if (!exist) {","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prereq \u003d getModulePrereqBasedOnCourse(moduleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" if(prereq \u003d\u003d null || prereq.isEmpty()){","lastModifiedDate":"2023-11-04"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Module \" + moduleCode + \" has no prerequisites.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" }else{","lastModifiedDate":"2023-11-04"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(prereq);","lastModifiedDate":"2023-11-04"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":129,"janelleenqi":16}},{"path":"src/main/java/seedu/duke/controllers/ModulePlannerController.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.CompletePreqs;","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.ModuleList;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.Schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.CommandManager;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.UserCommands;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.Api;","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.views.CommandLineView;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.Parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.errors.UserError;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"CerIsaiah"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"CerIsaiah"},"content":"import java.util.List;","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.determinePrereq;","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.showModulesLeft;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.computePace;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.getRequiredModulesForStudent;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"import static seedu.duke.controllers.ModuleMethodsController.canCompleteModule;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.deleteModule;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.addModule;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.recommendScheduleToStudent;","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.utils.Parser.parseArguments;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.utils.Parser.parseCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleServiceController.validateMajorInput;","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayWelcome;","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayReady;","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayGoodbye;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayGetMajor;","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayGetYear;","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.printListOfCommands;","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":"public class ModulePlannerController {","lastModifiedDate":"2023-10-12"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" private CommandLineView view;","lastModifiedDate":"2023-10-12"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" private Parser parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" private Student student;","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesMajor;","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesTaken;","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesLeft;","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"CerIsaiah"},"content":" private HashMap\u003cString, List\u003cString\u003e\u003e modsWithPreqs;","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"CerIsaiah"},"content":" private CompletePreqs addModulePreqs;","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" private CommandManager commandManager;","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" public ModulePlannerController() {","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" this.commandManager \u003d new CommandManager();","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" this.parser \u003d new Parser();","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"SebasFok"},"content":" this.student \u003d new Student();","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"CerIsaiah"},"content":" //This modules list of taken and classes left can be in a storage class later on.","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":" this.modulesMajor \u003d null;","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" this.modulesTaken \u003d new ModuleList();","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" this.modulesLeft \u003d new ModuleList();","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" Schedule schedule \u003d new Schedule();","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"SebasFok"},"content":" student.setSchedule(schedule);","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"CerIsaiah"},"content":" modsWithPreqs \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"CerIsaiah"},"content":" //Pass in Hashmap of mods with Preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"CerIsaiah"},"content":" this.addModulePreqs \u003d new CompletePreqs(addModsWithPreqs(modsWithPreqs));","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"CerIsaiah"},"content":" //Pass in the list of mods completed.","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"CerIsaiah"},"content":" addModulePreqs.initializeCompletedMods(modulesTaken);","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" * Starts the application, guiding the user through its execution.","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" * This method performs the following steps:","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" * 1. Display a welcome message to the user.","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" * 2. Initialize user-related data or settings.","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" * 3. Display a message indicating that the application is ready for input.","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" * 4. Handle user input until an exit command is given.","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" * 5. Display a goodbye message when the application is finished.\\","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":" public void start() {","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" displayWelcome();","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" initialiseUser();","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" displayReady();","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" handleUserInputTillExitCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" displayGoodbye();","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" public void initialiseUser() {","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" String userInput;","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" do {","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Please enter your name: \");","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" } while (!parser.checkNameInput(userInput, commandManager.getListOfCommands()));","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" student.setName(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" // Get and set student\u0027s major","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" displayGetMajor(student.getName());","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":" do {","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" } while (!validateMajorInput(userInput));","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" student.setFirstMajor(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" // Get and set student\u0027s year","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" displayGetYear();","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" do {","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" } while (!Parser.isValidAcademicYear(userInput.toUpperCase()));","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" student.setYear(userInput.toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" public void handleUserInputTillExitCommand() {","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-12"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" String userInput \u003d in.nextLine();","lastModifiedDate":"2023-10-12"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" String command \u003d parseCommand(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" while (!command.equals(UserCommands.EXIT_COMMAND)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" command \u003d parseCommand(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":" String[] arguments \u003d parseArguments(userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" if(!commandManager.getListOfCommands().contains(command)){","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" UserError.displayInvalidInputCommand(command);","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" continue;","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" boolean validInput \u003d Parser.isValidInputForCommand(command, arguments);","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" if (!validInput) {","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" UserError.displayInvalidMethodCommand(command);","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" continue;","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":" processCommand(command, arguments, userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"ryanlohyr"},"content":" in.close();","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"ryanlohyr"},"content":" private void processCommand(String command, String[] arguments, String userInput) {","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":" switch (command) {","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.LEFT_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"janelleenqi"},"content":" showModulesLeft(student.getModuleCodesLeft());","lastModifiedDate":"2023-11-04"},{"lineNumber":153,"author":{"gitId":"janelleenqi"},"content":" break;","lastModifiedDate":"2023-10-16"},{"lineNumber":154,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.PACE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":" computePace(arguments, student.getCurrentModuleCredits());","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-15"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":159,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.PREREQUISITE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d arguments[0];","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(module.toUpperCase(), student.getMajor()); //to convert \"CEG\" to dynamic course","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-28"},{"lineNumber":163,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":164,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.RECOMMEND_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" recommendScheduleToStudent(student);","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.ADD_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":169,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":170,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d Integer.parseInt(arguments[1]);","lastModifiedDate":"2023-11-03"},{"lineNumber":171,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":172,"author":{"gitId":"janelleenqi"},"content":" addModule(module, targetSem, student);","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":175,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.DELETE_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":" deleteModule(module,student);","lastModifiedDate":"2023-11-04"},{"lineNumber":179,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":180,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":181,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.VIEW_SCHEDULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":184,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.COMPLETE_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"janelleenqi"},"content":" String module \u003d arguments[0].toUpperCase();","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"ryanlohyr"},"content":" //to add to user completed module","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"janelleenqi"},"content":" if (canCompleteModule(arguments, student.getMajorModuleCodes(), addModulePreqs)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":189,"author":{"gitId":"janelleenqi"},"content":" student.completeModuleSchedule(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":190,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":191,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":192,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":193,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.REQUIRED_MODULES_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":194,"author":{"gitId":"ryanlohyr"},"content":" getRequiredModulesForStudent(student.getMajor());","lastModifiedDate":"2023-11-03"},{"lineNumber":195,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":196,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":197,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.INFO_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":198,"author":{"gitId":"ryanlohyr"},"content":" Api.infoCommands(arguments[0], userInput);","lastModifiedDate":"2023-11-03"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":201,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.SEARCH_MODULE_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":" Api.searchCommand(userInput);","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":204,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":205,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.HELP_COMMAND: {","lastModifiedDate":"2023-11-03"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" printListOfCommands(commandManager);","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":" default: {","lastModifiedDate":"2023-10-12"},{"lineNumber":210,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-12"},{"lineNumber":211,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":212,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":215,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":216,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":217,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":218,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":219,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":220,"author":{"gitId":"CerIsaiah"},"content":" * Add all mods that require prerequisites to a map storing the mod and a set of preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":221,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":222,"author":{"gitId":"CerIsaiah"},"content":" * @param list","lastModifiedDate":"2023-10-18"},{"lineNumber":223,"author":{"gitId":"CerIsaiah"},"content":" * @return HashMap of Mods with their corresponding preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":224,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":225,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":226,"author":{"gitId":"CerIsaiah"},"content":" private HashMap\u003cString, List\u003cString\u003e\u003e addModsWithPreqs(HashMap\u003cString, List\u003cString\u003e\u003e list) {","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"CerIsaiah"},"content":" //Only two mods don\u0027t have preqs MA1511 and CS1231S.","lastModifiedDate":"2023-10-18"},{"lineNumber":228,"author":{"gitId":"CerIsaiah"},"content":" // In the future this will be dealt","lastModifiedDate":"2023-10-18"},{"lineNumber":229,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS3230\", \"CS2030S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":230,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS3230\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":231,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":232,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2030S\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":233,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":234,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2040S\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":236,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2106\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":237,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":238,"author":{"gitId":"CerIsaiah"},"content":" addValue(list, \"CS2109S\", \"CS1231S\");","lastModifiedDate":"2023-10-18"},{"lineNumber":239,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":240,"author":{"gitId":"CerIsaiah"},"content":" return list;","lastModifiedDate":"2023-10-18"},{"lineNumber":241,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":242,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":243,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":244,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":245,"author":{"gitId":"CerIsaiah"},"content":" * Helper function to addModsWithPreqs to add Strings and sets together","lastModifiedDate":"2023-10-18"},{"lineNumber":246,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"CerIsaiah"},"content":" * @param map","lastModifiedDate":"2023-10-18"},{"lineNumber":248,"author":{"gitId":"CerIsaiah"},"content":" * @param key","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"CerIsaiah"},"content":" * @param value","lastModifiedDate":"2023-10-18"},{"lineNumber":250,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":251,"author":{"gitId":"CerIsaiah"},"content":" public static void addValue(HashMap\u003cString, List\u003cString\u003e\u003e map, String key, String value) {","lastModifiedDate":"2023-10-18"},{"lineNumber":252,"author":{"gitId":"CerIsaiah"},"content":" // If the map does not contain the key, put an empty list for that key","lastModifiedDate":"2023-10-18"},{"lineNumber":253,"author":{"gitId":"CerIsaiah"},"content":" if (!map.containsKey(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":254,"author":{"gitId":"CerIsaiah"},"content":" map.put(key, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-18"},{"lineNumber":255,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":256,"author":{"gitId":"CerIsaiah"},"content":" // Add the value to the list associated with the key","lastModifiedDate":"2023-10-18"},{"lineNumber":257,"author":{"gitId":"CerIsaiah"},"content":" map.get(key).add(value);","lastModifiedDate":"2023-10-18"},{"lineNumber":258,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":260,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":261,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"SebasFok":14,"ryanlohyr":164,"janelleenqi":23,"rohitcube":8,"CerIsaiah":53}},{"path":"src/main/java/seedu/duke/controllers/ModuleServiceController.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.MajorRequirements;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayHelp;","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.ModuleInfoView.printModuleStringArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"public class ModuleServiceController {","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * Checks if the user\u0027s major input is valid. A major input is valid if it exists in the enumeration","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" * of valid majors.","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The user\u0027s major input.","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" * @return True if the input is a valid major, false otherwise.","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" public static boolean validateMajorInput(String userInput) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" Major.valueOf(userInput.toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Please choose from the list: CS, or CEG\");","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * Prompts the user to choose whether to add a list of modules to their draft schedule.","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * Displays the list of modules and asks for user input. Handles user input validation.","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" * @param scheduleToAdd A list of modules to be added to the schedule.","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" public static void chooseToAddToSchedule(Student student, ArrayList\u003cString\u003e scheduleToAdd) {","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" printModuleStringArray(scheduleToAdd);","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Here you go!\");","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Taking the modules in this order will ensure a prerequisite worry free uni life!\");","lastModifiedDate":"2023-11-04"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Do you want to add this to your draft schedule? \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" \"(This will overwrite your current schedule!)\");","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Please input \u0027Y\u0027 or \u0027N\u0027\");","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" String userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" while (!userInput.equals(\"N\") \u0026\u0026 !userInput.equals((\"Y\"))) {","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Invalid input, please choose Y/N\");","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" userInput \u003d in.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" if (userInput.equals(\"Y\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(\"Hold on, this may take a while......\");","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().addRecommendedScheduleListToSchedule(scheduleToAdd);","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().printMainModuleList();","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" displayHelp();","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves and prints the required modules for a specified major.","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" * \u003cp\u003e","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" * This method initializes a `MajorRequirements` object based on the provided `major`.","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" * It then attempts to print the required modules from a corresponding TXT file.","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" * If the TXT file is not found, an error message is displayed.","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" * @param major The major for which to retrieve required modules.","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" * @throws NullPointerException If `major` is null.","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" public static void getRequiredModules(String major) throws NullPointerException {","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" MajorRequirements.printRequiredModules(major);","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":80}},{"path":"src/main/java/seedu/duke/exceptions/FailPrereqException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.exceptions;","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"public class FailPrereqException extends Exception{","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":" public FailPrereqException(String message) {","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":" super(message);","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"SebasFok":7}},{"path":"src/main/java/seedu/duke/exceptions/InvalidModuleException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.exceptions;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"/**","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" * This class represents a custom exception that is thrown when an invalid module is encountered.","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" * An invalid module that has illegal characters.","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"public class InvalidModuleException extends Exception{","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" public InvalidModuleException() {","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" super(\"Only alphabets and digits are allowed in module codes!\");","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"ryanlohyr":12}},{"path":"src/main/java/seedu/duke/exceptions/MissingModuleException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"package seedu.duke.exceptions;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"public class MissingModuleException extends Exception{","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":" public MissingModuleException(String message) {","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":" super(message);","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"janelleenqi":7}},{"path":"src/main/java/seedu/duke/models/logic/Api.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"rohitcube"},"content":"import java.net.URI;","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":"import java.net.URISyntaxException;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"import java.net.http.HttpClient;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"rohitcube"},"content":"import java.net.http.HttpRequest;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"rohitcube"},"content":"import java.net.http.HttpResponse;","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Objects;","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.parser.JSONParser;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.parser.ParseException;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.InvalidModuleException;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.ModuleList;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.DataRepository.getRequirements;","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"rohitcube"},"content":"import seedu.duke.utils.Parser;","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.errors.UserError;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.views.ModuleInfoView;","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.UnknownCommandException;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"rohitcube"},"content":"public class Api {","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves the prerequisite tree for a module specified by its code.","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module for which prerequisites are to be retrieved.","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * @return A JSON object representing the prerequisite tree for the module. The prerequisite tree can be in one of","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" private static JSONObject getModulePrereqTree(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" JSONObject fullModuleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" if (fullModuleInfo \u003d\u003d null) {","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" //prereqTree can be returned as a string(single pre requisite), null(No pre requisites) or object","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" Object prereqTree \u003d fullModuleInfo.get(\"prereqTree\");","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" if (prereqTree \u003d\u003d null) {","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" } else if (prereqTree instanceof String) {","lastModifiedDate":"2023-10-28"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" JSONObject jsonObject \u003d new JSONObject();","lastModifiedDate":"2023-10-28"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e requirementList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" requirementList.add((String) prereqTree);","lastModifiedDate":"2023-10-28"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" jsonObject.put(\"or\", requirementList);","lastModifiedDate":"2023-10-28"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" return jsonObject;","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" return (JSONObject) fullModuleInfo.get(\"prereqTree\");","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"rohitcube"},"content":" * Checks if a given module code is exempted from certain requirements.","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to check.","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"rohitcube"},"content":" * @return True if the module is exempted, false otherwise.","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" private static boolean isModuleException(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e exemptedModules \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"CS1231\");","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"CS1231S\");","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"MA1508E\");","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"EE4204\");","lastModifiedDate":"2023-10-28"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" exemptedModules.add(\"MA1511\");","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" exemptedModules.add(\"MA1512\");","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"MA1521\");","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" exemptedModules.add(\"MA1522\");","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" return exemptedModules.contains(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":79,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"rohitcube"},"content":" * Retrieves a list of exempted prerequisites for a given module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve exempted prerequisites for.","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"rohitcube"},"content":" * @return An ArrayList of exempted prerequisite module codes.","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" private static ArrayList\u003cString\u003e getExemptedPrerequisite(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" HashMap\u003cString, ArrayList\u003cString\u003e\u003e map \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e list1 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" list1.add(\"MA1511\");","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" list1.add(\"MA1512\");","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"CS1231\", list1);","lastModifiedDate":"2023-10-28"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e list2 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" list2.add(\"MA1511\");","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" list2.add(\"MA1512\");","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1508E\", list2);","lastModifiedDate":"2023-10-28"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e list3 \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" list3.add(\"ST2334\");","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"EE4204\", list3);","lastModifiedDate":"2023-10-28"},{"lineNumber":101,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e emptyList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1511\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"CS1231S\",emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1512\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1521\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" map.put(\"MA1522\", emptyList);","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" return map.get(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":115,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"rohitcube"},"content":" private static String sendHttpRequestAndGetResponseBody(String url) throws ParseException,","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"rohitcube"},"content":" IOException, InterruptedException, URISyntaxException {","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"rohitcube"},"content":" HttpClient client \u003d HttpClient.newHttpClient();","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"rohitcube"},"content":" HttpRequest request \u003d HttpRequest.newBuilder()","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"rohitcube"},"content":" .uri(new URI(url))","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"rohitcube"},"content":" .GET()","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"rohitcube"},"content":" .build();","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"rohitcube"},"content":" HttpResponse\u003cString\u003e response \u003d client.send(request, HttpResponse.BodyHandlers.ofString());","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"rohitcube"},"content":" return response.body();","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":129,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"rohitcube"},"content":" * Retrieves detailed module information from an external API based on the module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":133,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve information for.","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"rohitcube"},"content":" * @return A JSONObject containing module information.","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":136,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"janelleenqi"},"content":" public static JSONObject getFullModuleInfo(String moduleCode) throws RuntimeException {","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" // Regex pattern to match only letters and numbers","lastModifiedDate":"2023-11-04"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" String regexPattern \u003d \"^[a-zA-Z0-9]+$\";","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":" if(!moduleCode.matches(regexPattern)){","lastModifiedDate":"2023-11-04"},{"lineNumber":143,"author":{"gitId":"ryanlohyr"},"content":" throw new InvalidModuleException();","lastModifiedDate":"2023-11-04"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":145,"author":{"gitId":"rohitcube"},"content":" String url \u003d \"https://api.nusmods.com/v2/2023-2024/modules/\" + moduleCode + \".json\";","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"rohitcube"},"content":" String responseBody \u003d sendHttpRequestAndGetResponseBody(url);","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"rohitcube"},"content":" if (responseBody.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"rohitcube"},"content":" return new JSONObject();","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"rohitcube"},"content":" JSONParser parser \u003d new JSONParser();","lastModifiedDate":"2023-10-26"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":" return (JSONObject) parser.parse(responseBody);","lastModifiedDate":"2023-10-28"},{"lineNumber":153,"author":{"gitId":"rohitcube"},"content":" } catch (ParseException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"rohitcube"},"content":" //to be replaced with more robust error class in the future","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Module Name\");","lastModifiedDate":"2023-10-28"},{"lineNumber":156,"author":{"gitId":"rohitcube"},"content":" } catch (IOException | InterruptedException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Module Name\");","lastModifiedDate":"2023-10-28"},{"lineNumber":158,"author":{"gitId":"janelleenqi"},"content":" throw new RuntimeException(\"java.net.ConnectException\", e);","lastModifiedDate":"2023-11-04"},{"lineNumber":159,"author":{"gitId":"rohitcube"},"content":" } catch (URISyntaxException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":160,"author":{"gitId":"rohitcube"},"content":" //to be replaced with more robust error class in the future","lastModifiedDate":"2023-10-26"},{"lineNumber":161,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Sorry, there was an error with\" +","lastModifiedDate":"2023-10-26"},{"lineNumber":162,"author":{"gitId":"rohitcube"},"content":" \" the provided URL: \" + e.getMessage());","lastModifiedDate":"2023-10-26"},{"lineNumber":163,"author":{"gitId":"rohitcube"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"rohitcube"},"content":" //System.out.println(\"Invalid Module Name\");","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" }catch (InvalidModuleException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Module Code :\" + e.getMessage());","lastModifiedDate":"2023-11-04"},{"lineNumber":167,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"rohitcube"},"content":" return null;","lastModifiedDate":"2023-10-26"},{"lineNumber":169,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"rohitcube"},"content":" * Retrieves the name of a module based on its module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve the name for.","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"rohitcube"},"content":" * @return The name of the module.","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"ryanlohyr"},"content":" public static String getModuleName(String moduleCode) {","lastModifiedDate":"2023-10-28"},{"lineNumber":178,"author":{"gitId":"ryanlohyr"},"content":" JSONObject fullModuleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":179,"author":{"gitId":"ryanlohyr"},"content":" assert fullModuleInfo !\u003d null;","lastModifiedDate":"2023-10-28"},{"lineNumber":180,"author":{"gitId":"ryanlohyr"},"content":" return (String) fullModuleInfo.get(\"title\");","lastModifiedDate":"2023-10-28"},{"lineNumber":181,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":182,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":183,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"rohitcube"},"content":" * Retrieves the description of a module based on its module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":186,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":187,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve the description for.","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"rohitcube"},"content":" * @return The description of the module.","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":190,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"rohitcube"},"content":" public static String getDescription(String moduleCode) {","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"rohitcube"},"content":" JSONObject moduleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"rohitcube"},"content":" String error \u003d \" \";","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":195,"author":{"gitId":"rohitcube"},"content":" String descr \u003d (String) moduleInfo.get(\"description\");","lastModifiedDate":"2023-11-02"},{"lineNumber":196,"author":{"gitId":"rohitcube"},"content":" return descr;","lastModifiedDate":"2023-11-02"},{"lineNumber":197,"author":{"gitId":"rohitcube"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":198,"author":{"gitId":"rohitcube"},"content":" System.out.println(\" \");","lastModifiedDate":"2023-11-02"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":" return error;","lastModifiedDate":"2023-11-02"},{"lineNumber":201,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"rohitcube"},"content":" * Retrieves the workload information for a module based on its module code.","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":207,"author":{"gitId":"rohitcube"},"content":" * @param moduleCode The module code to retrieve workload information for.","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"rohitcube"},"content":" * @return A JSONArray containing workload details.","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":210,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"rohitcube"},"content":" public static JSONArray getWorkload(String moduleCode) {","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"rohitcube"},"content":" JSONObject moduleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":213,"author":{"gitId":"rohitcube"},"content":" JSONArray emptyArray \u003d new JSONArray();","lastModifiedDate":"2023-11-02"},{"lineNumber":214,"author":{"gitId":"rohitcube"},"content":" assert moduleInfo !\u003d null;","lastModifiedDate":"2023-10-30"},{"lineNumber":215,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":216,"author":{"gitId":"rohitcube"},"content":" return (JSONArray) moduleInfo.get(\"workload\");","lastModifiedDate":"2023-10-30"},{"lineNumber":217,"author":{"gitId":"rohitcube"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":218,"author":{"gitId":"rohitcube"},"content":" System.out.println(\" \");","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":220,"author":{"gitId":"rohitcube"},"content":" return emptyArray;","lastModifiedDate":"2023-11-02"},{"lineNumber":221,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":222,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" * Recursively flattens and processes a list of module prerequisites.","lastModifiedDate":"2023-10-28"},{"lineNumber":225,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":227,"author":{"gitId":"ryanlohyr"},"content":" * @param major The major or program for which prerequisites are being flattened.","lastModifiedDate":"2023-10-28"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":" * @param prerequisites An ArrayList to store the flattened prerequisites.","lastModifiedDate":"2023-10-28"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" * @param modulePrereqArray An ArrayList containing the module prerequisites to be processed.","lastModifiedDate":"2023-10-28"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":" * @param courseRequirements An ArrayList containing course requirements.","lastModifiedDate":"2023-10-28"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":" * @param currRequisite The type of the current prerequisite (e.g., \"and\" or \"or\").","lastModifiedDate":"2023-10-28"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":233,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":234,"author":{"gitId":"ryanlohyr"},"content":" private static void flattenPrereq(","lastModifiedDate":"2023-10-28"},{"lineNumber":235,"author":{"gitId":"ryanlohyr"},"content":" String major,","lastModifiedDate":"2023-10-28"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prerequisites,","lastModifiedDate":"2023-10-28"},{"lineNumber":237,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e modulePrereqArray,","lastModifiedDate":"2023-10-28"},{"lineNumber":238,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e courseRequirements,","lastModifiedDate":"2023-10-28"},{"lineNumber":239,"author":{"gitId":"ryanlohyr"},"content":" String currRequisite) {","lastModifiedDate":"2023-10-28"},{"lineNumber":240,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":241,"author":{"gitId":"ryanlohyr"},"content":" for (Object module : modulePrereqArray) {","lastModifiedDate":"2023-10-28"},{"lineNumber":242,"author":{"gitId":"ryanlohyr"},"content":" if (module instanceof String) {","lastModifiedDate":"2023-10-28"},{"lineNumber":243,"author":{"gitId":"ryanlohyr"},"content":" String formattedModule \u003d ((String) module).replace(\":D\", \"\");","lastModifiedDate":"2023-10-28"},{"lineNumber":244,"author":{"gitId":"ryanlohyr"},"content":" formattedModule \u003d formattedModule.replace(\"%\", \"\");","lastModifiedDate":"2023-10-28"},{"lineNumber":245,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":246,"author":{"gitId":"ryanlohyr"},"content":" if (courseRequirements.contains(formattedModule)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":247,"author":{"gitId":"ryanlohyr"},"content":" prerequisites.add(formattedModule);","lastModifiedDate":"2023-10-28"},{"lineNumber":248,"author":{"gitId":"ryanlohyr"},"content":" if (currRequisite.equals(\"or\")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":249,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-10-28"},{"lineNumber":250,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":251,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":252,"author":{"gitId":"ryanlohyr"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":253,"author":{"gitId":"ryanlohyr"},"content":" //item is an object","lastModifiedDate":"2023-10-28"},{"lineNumber":254,"author":{"gitId":"ryanlohyr"},"content":" //here, we determine if its \u0027or\u0027 or \u0027and\u0027","lastModifiedDate":"2023-10-28"},{"lineNumber":255,"author":{"gitId":"ryanlohyr"},"content":" JSONObject moduleJSON \u003d (JSONObject) module;","lastModifiedDate":"2023-10-28"},{"lineNumber":256,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":257,"author":{"gitId":"ryanlohyr"},"content":" if (moduleJSON.containsKey(\"nOf\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":258,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d \"and\";","lastModifiedDate":"2023-11-04"},{"lineNumber":259,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cArrayList\u003cObjects\u003e\u003e initial \u003d (ArrayList\u003cArrayList\u003cObjects\u003e\u003e) moduleJSON.get(\"nOf\");","lastModifiedDate":"2023-11-04"},{"lineNumber":260,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e formattedInitial \u003d initial.get(1);","lastModifiedDate":"2023-11-04"},{"lineNumber":261,"author":{"gitId":"ryanlohyr"},"content":" flattenPrereq(major, prerequisites, formattedInitial, courseRequirements, key);","lastModifiedDate":"2023-11-04"},{"lineNumber":262,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-04"},{"lineNumber":263,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":264,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d (String) moduleJSON.keySet().toArray()[0];","lastModifiedDate":"2023-10-28"},{"lineNumber":265,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":266,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e initial \u003d (ArrayList\u003cObjects\u003e) moduleJSON.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":267,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":268,"author":{"gitId":"ryanlohyr"},"content":" flattenPrereq(major, prerequisites, initial, courseRequirements, key);","lastModifiedDate":"2023-11-04"},{"lineNumber":269,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":270,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":271,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":272,"author":{"gitId":"ryanlohyr"},"content":" } catch (ClassCastException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":273,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Error getting pre requisite for module\");","lastModifiedDate":"2023-11-04"},{"lineNumber":274,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":275,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":276,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":277,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-28"},{"lineNumber":278,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves the prerequisite array for a module specified by its code and also taking into account the degree","lastModifiedDate":"2023-10-28"},{"lineNumber":279,"author":{"gitId":"ryanlohyr"},"content":" * requirements of the course.","lastModifiedDate":"2023-10-28"},{"lineNumber":280,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":282,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module for which prerequisites are to be retrieved.","lastModifiedDate":"2023-10-28"},{"lineNumber":283,"author":{"gitId":"rohitcube"},"content":" * @return A JSONObject representing the prerequisite tree for the module or NULL if no prerequisites are specified.","lastModifiedDate":"2023-11-01"},{"lineNumber":284,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":285,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":286,"author":{"gitId":"ryanlohyr"},"content":" public static ArrayList\u003cString\u003e getModulePrereqBasedOnCourse(String moduleCode, String major) {","lastModifiedDate":"2023-10-28"},{"lineNumber":287,"author":{"gitId":"ryanlohyr"},"content":" // Only accepts CEG requirements now","lastModifiedDate":"2023-10-28"},{"lineNumber":288,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":289,"author":{"gitId":"ryanlohyr"},"content":" Major.valueOf(major.toUpperCase());","lastModifiedDate":"2023-11-04"},{"lineNumber":290,"author":{"gitId":"ryanlohyr"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":291,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Major Provided\");","lastModifiedDate":"2023-11-04"},{"lineNumber":292,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":293,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":294,"author":{"gitId":"ryanlohyr"},"content":" //Modules that has prerequisites incorrectly identified by NUSMods","lastModifiedDate":"2023-10-28"},{"lineNumber":295,"author":{"gitId":"ryanlohyr"},"content":" if (isModuleException(moduleCode)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":296,"author":{"gitId":"ryanlohyr"},"content":" return getExemptedPrerequisite(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":297,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":298,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":299,"author":{"gitId":"ryanlohyr"},"content":" JSONObject modulePrereqTree \u003d getModulePrereqTree(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":300,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":301,"author":{"gitId":"ryanlohyr"},"content":" if (modulePrereqTree \u003d\u003d null) {","lastModifiedDate":"2023-10-28"},{"lineNumber":302,"author":{"gitId":"ryanlohyr"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":303,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":304,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":305,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d (String) modulePrereqTree.keySet().toArray()[0];","lastModifiedDate":"2023-10-28"},{"lineNumber":306,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":307,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prerequisites \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":308,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":309,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e initial \u003d (ArrayList\u003cObjects\u003e) modulePrereqTree.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":310,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":311,"author":{"gitId":"ryanlohyr"},"content":" flattenPrereq(major, prerequisites, initial, getRequirements(major), key);","lastModifiedDate":"2023-10-28"},{"lineNumber":312,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":313,"author":{"gitId":"ryanlohyr"},"content":" return prerequisites;","lastModifiedDate":"2023-10-28"},{"lineNumber":314,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":315,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":316,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":317,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":318,"author":{"gitId":"SebasFok"},"content":" * Checks if a module with the given module code exists in the NUSMods database.","lastModifiedDate":"2023-10-31"},{"lineNumber":319,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":320,"author":{"gitId":"SebasFok"},"content":" * @param moduleCode The module code to check for existence.","lastModifiedDate":"2023-10-31"},{"lineNumber":321,"author":{"gitId":"SebasFok"},"content":" * @return `true` if the module exists, `false` if the module does not exist.","lastModifiedDate":"2023-10-31"},{"lineNumber":322,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":323,"author":{"gitId":"SebasFok"},"content":" public static boolean doesModuleExist(String moduleCode) {","lastModifiedDate":"2023-10-31"},{"lineNumber":324,"author":{"gitId":"SebasFok"},"content":" JSONObject moduleInfo \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-10-31"},{"lineNumber":325,"author":{"gitId":"SebasFok"},"content":" return (!(moduleInfo \u003d\u003d null));","lastModifiedDate":"2023-10-31"},{"lineNumber":326,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":327,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":328,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":329,"author":{"gitId":"SebasFok"},"content":" * Checks if a student satisfies all prerequisites for a given module.","lastModifiedDate":"2023-10-30"},{"lineNumber":330,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":331,"author":{"gitId":"SebasFok"},"content":" * @param moduleCode The code of the module for which prerequisites need to be checked.","lastModifiedDate":"2023-10-30"},{"lineNumber":332,"author":{"gitId":"SebasFok"},"content":" * @param completedModules The list of completed modules by the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":333,"author":{"gitId":"SebasFok"},"content":" * @return `true` if the student satisfies all prerequisites for the module, `false` otherwise.","lastModifiedDate":"2023-10-30"},{"lineNumber":334,"author":{"gitId":"SebasFok"},"content":" * @throws IllegalArgumentException If the module code is invalid.","lastModifiedDate":"2023-10-31"},{"lineNumber":335,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":336,"author":{"gitId":"SebasFok"},"content":" public static boolean satisfiesAllPrereq(String moduleCode, ModuleList completedModules)","lastModifiedDate":"2023-10-30"},{"lineNumber":337,"author":{"gitId":"SebasFok"},"content":" throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":338,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":339,"author":{"gitId":"SebasFok"},"content":" if (!doesModuleExist(moduleCode)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":340,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Invalid module code\");","lastModifiedDate":"2023-10-31"},{"lineNumber":341,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":342,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":343,"author":{"gitId":"SebasFok"},"content":" JSONObject modulePrereqTree \u003d getModulePrereqTree(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":344,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":345,"author":{"gitId":"SebasFok"},"content":" if (modulePrereqTree \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":346,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":347,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":348,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":349,"author":{"gitId":"SebasFok"},"content":" String key \u003d (String) modulePrereqTree.keySet().toArray()[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":350,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cObjects\u003e initial \u003d (ArrayList\u003cObjects\u003e) modulePrereqTree.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":351,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":352,"author":{"gitId":"SebasFok"},"content":" //Modules that has prerequisites incorrectly identified by NUSMods","lastModifiedDate":"2023-10-30"},{"lineNumber":353,"author":{"gitId":"SebasFok"},"content":" if (isModuleException(moduleCode)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":354,"author":{"gitId":"SebasFok"},"content":" JSONObject exceptionPrereqTree \u003d new JSONObject();","lastModifiedDate":"2023-10-31"},{"lineNumber":355,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cString\u003e requirementList \u003d getExemptedPrerequisite(moduleCode);","lastModifiedDate":"2023-10-31"},{"lineNumber":356,"author":{"gitId":"SebasFok"},"content":" exceptionPrereqTree.put(\"and\", requirementList);","lastModifiedDate":"2023-10-31"},{"lineNumber":357,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":358,"author":{"gitId":"SebasFok"},"content":" key \u003d (String) exceptionPrereqTree.keySet().toArray()[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":359,"author":{"gitId":"SebasFok"},"content":" initial \u003d (ArrayList\u003cObjects\u003e) exceptionPrereqTree.get(key);","lastModifiedDate":"2023-10-31"},{"lineNumber":360,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":361,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":362,"author":{"gitId":"SebasFok"},"content":" return checkPrereq(initial, key, completedModules);","lastModifiedDate":"2023-10-30"},{"lineNumber":363,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":364,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":365,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":366,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":367,"author":{"gitId":"SebasFok"},"content":" * Recursively checks if each branch of the prereq tree is satisfied by the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":368,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":369,"author":{"gitId":"SebasFok"},"content":" * @param modulePrereqArray The array of prerequisite modules or conditions to be checked.","lastModifiedDate":"2023-10-30"},{"lineNumber":370,"author":{"gitId":"SebasFok"},"content":" * @param currRequisite The type of prerequisite condition (\"or\" or \"and\").","lastModifiedDate":"2023-10-30"},{"lineNumber":371,"author":{"gitId":"SebasFok"},"content":" * @param completedModules The list of completed modules by the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":372,"author":{"gitId":"SebasFok"},"content":" * @return `true` if the student satisfies all prerequisites, `false` otherwise.","lastModifiedDate":"2023-10-30"},{"lineNumber":373,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":374,"author":{"gitId":"SebasFok"},"content":" private static boolean checkPrereq(","lastModifiedDate":"2023-10-30"},{"lineNumber":375,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cObjects\u003e modulePrereqArray,","lastModifiedDate":"2023-10-30"},{"lineNumber":376,"author":{"gitId":"SebasFok"},"content":" String currRequisite,","lastModifiedDate":"2023-10-30"},{"lineNumber":377,"author":{"gitId":"SebasFok"},"content":" ModuleList completedModules) {","lastModifiedDate":"2023-10-31"},{"lineNumber":378,"author":{"gitId":"ryanlohyr"},"content":" try{","lastModifiedDate":"2023-11-04"},{"lineNumber":379,"author":{"gitId":"SebasFok"},"content":" if (currRequisite.equals(\"or\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":380,"author":{"gitId":"SebasFok"},"content":" for (Object module : modulePrereqArray) {","lastModifiedDate":"2023-10-30"},{"lineNumber":381,"author":{"gitId":"SebasFok"},"content":" if (module instanceof String) {","lastModifiedDate":"2023-10-30"},{"lineNumber":382,"author":{"gitId":"SebasFok"},"content":" String formattedModule \u003d ((String) module).replace(\":D\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":383,"author":{"gitId":"SebasFok"},"content":" formattedModule \u003d formattedModule.replace(\"%\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":384,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":385,"author":{"gitId":"SebasFok"},"content":" if (completedModules.exists(formattedModule)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":386,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":387,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":388,"author":{"gitId":"SebasFok"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":389,"author":{"gitId":"SebasFok"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-31"},{"lineNumber":390,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":391,"author":{"gitId":"SebasFok"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":392,"author":{"gitId":"SebasFok"},"content":" JSONObject prereqBranch \u003d (JSONObject) module;","lastModifiedDate":"2023-10-30"},{"lineNumber":393,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":394,"author":{"gitId":"ryanlohyr"},"content":" //for cs, some modules return pre req in this form {\"nOf\":[2,[\"MA1511:D\",\"MA1512:D\"]]}","lastModifiedDate":"2023-11-04"},{"lineNumber":395,"author":{"gitId":"ryanlohyr"},"content":" //have to convert first","lastModifiedDate":"2023-11-04"},{"lineNumber":396,"author":{"gitId":"ryanlohyr"},"content":" if (prereqBranch.containsKey(\"nOf\")) {","lastModifiedDate":"2023-11-04"},{"lineNumber":397,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d \"and\";","lastModifiedDate":"2023-11-04"},{"lineNumber":398,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cArrayList\u003cObjects\u003e\u003e initial \u003d","lastModifiedDate":"2023-11-04"},{"lineNumber":399,"author":{"gitId":"ryanlohyr"},"content":" (ArrayList\u003cArrayList\u003cObjects\u003e\u003e) prereqBranch.get(\"nOf\");","lastModifiedDate":"2023-11-04"},{"lineNumber":400,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cObjects\u003e formattedInitial \u003d initial.get(1);","lastModifiedDate":"2023-11-04"},{"lineNumber":401,"author":{"gitId":"ryanlohyr"},"content":" JSONArray prereqBranchArray \u003d (JSONArray) formattedInitial;","lastModifiedDate":"2023-11-04"},{"lineNumber":402,"author":{"gitId":"ryanlohyr"},"content":" return checkPrereq(prereqBranchArray, key, completedModules);","lastModifiedDate":"2023-11-04"},{"lineNumber":403,"author":{"gitId":"ryanlohyr"},"content":" } else {","lastModifiedDate":"2023-11-04"},{"lineNumber":404,"author":{"gitId":"ryanlohyr"},"content":" String key \u003d (String) prereqBranch.keySet().toArray()[0];","lastModifiedDate":"2023-11-04"},{"lineNumber":405,"author":{"gitId":"SebasFok"},"content":" JSONArray prereqBranchArray \u003d (JSONArray) prereqBranch.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":406,"author":{"gitId":"SebasFok"},"content":" return checkPrereq(prereqBranchArray, key, completedModules);","lastModifiedDate":"2023-11-01"},{"lineNumber":407,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":408,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":409,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":410,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":411,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":412,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":413,"author":{"gitId":"SebasFok"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":414,"author":{"gitId":"SebasFok"},"content":" for (Object module : modulePrereqArray) {","lastModifiedDate":"2023-10-30"},{"lineNumber":415,"author":{"gitId":"SebasFok"},"content":" if (module instanceof String) {","lastModifiedDate":"2023-10-30"},{"lineNumber":416,"author":{"gitId":"SebasFok"},"content":" String formattedModule \u003d ((String) module).replace(\":D\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":417,"author":{"gitId":"SebasFok"},"content":" formattedModule \u003d formattedModule.replace(\"%\", \"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":418,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":419,"author":{"gitId":"SebasFok"},"content":" if (!completedModules.exists(formattedModule)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":420,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":421,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":422,"author":{"gitId":"SebasFok"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":423,"author":{"gitId":"SebasFok"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-31"},{"lineNumber":424,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":425,"author":{"gitId":"SebasFok"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":426,"author":{"gitId":"SebasFok"},"content":" JSONObject prereqBranch \u003d (JSONObject) module;","lastModifiedDate":"2023-10-30"},{"lineNumber":427,"author":{"gitId":"SebasFok"},"content":" String key \u003d (String) prereqBranch.keySet().toArray()[0];","lastModifiedDate":"2023-10-30"},{"lineNumber":428,"author":{"gitId":"SebasFok"},"content":" JSONArray prereqBranchArray \u003d (JSONArray) prereqBranch.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":429,"author":{"gitId":"SebasFok"},"content":" if (!checkPrereq(prereqBranchArray, key, completedModules)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":430,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":431,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":432,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":433,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":434,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":435,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":436,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":437,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":438,"author":{"gitId":"ryanlohyr"},"content":" }catch(ClassCastException e){","lastModifiedDate":"2023-11-04"},{"lineNumber":439,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Error checking prereq for this module\");","lastModifiedDate":"2023-11-04"},{"lineNumber":440,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-04"},{"lineNumber":441,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":442,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":443,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":444,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":445,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":446,"author":{"gitId":"rohitcube"},"content":" * Retrieves a list of modules from an external API and returns it as a JSONArray.","lastModifiedDate":"2023-11-01"},{"lineNumber":447,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":448,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":449,"author":{"gitId":"rohitcube"},"content":" * @return A JSONArray containing module information.","lastModifiedDate":"2023-11-01"},{"lineNumber":450,"author":{"gitId":"rohitcube"},"content":" * @throws RuntimeException If there is an issue with the HTTP request or JSON parsing.","lastModifiedDate":"2023-11-01"},{"lineNumber":451,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":452,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":453,"author":{"gitId":"rohitcube"},"content":" public static JSONArray listAllModules() {","lastModifiedDate":"2023-10-28"},{"lineNumber":454,"author":{"gitId":"rohitcube"},"content":" try {","lastModifiedDate":"2023-10-28"},{"lineNumber":455,"author":{"gitId":"rohitcube"},"content":" String url \u003d \"https://api.nusmods.com/v2/2023-2024/moduleList.json\";","lastModifiedDate":"2023-10-28"},{"lineNumber":456,"author":{"gitId":"rohitcube"},"content":" String responseBody \u003d sendHttpRequestAndGetResponseBody(url);","lastModifiedDate":"2023-11-01"},{"lineNumber":457,"author":{"gitId":"rohitcube"},"content":" JSONParser parser \u003d new JSONParser();","lastModifiedDate":"2023-10-28"},{"lineNumber":458,"author":{"gitId":"rohitcube"},"content":" return (JSONArray) parser.parse(responseBody);","lastModifiedDate":"2023-11-01"},{"lineNumber":459,"author":{"gitId":"rohitcube"},"content":" } catch (URISyntaxException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":460,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Sorry, there was an error with\" +","lastModifiedDate":"2023-10-28"},{"lineNumber":461,"author":{"gitId":"rohitcube"},"content":" \" the provided URL: \" + e.getMessage());","lastModifiedDate":"2023-10-28"},{"lineNumber":462,"author":{"gitId":"rohitcube"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-28"},{"lineNumber":463,"author":{"gitId":"rohitcube"},"content":" } catch (IOException | InterruptedException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":464,"author":{"gitId":"rohitcube"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-10-28"},{"lineNumber":465,"author":{"gitId":"rohitcube"},"content":" } catch (ParseException e) {","lastModifiedDate":"2023-10-28"},{"lineNumber":466,"author":{"gitId":"rohitcube"},"content":" //to be replaced with more robust error class in the future","lastModifiedDate":"2023-10-28"},{"lineNumber":467,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Sorry, the JSON object could not be parsed\");","lastModifiedDate":"2023-10-28"},{"lineNumber":468,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":469,"author":{"gitId":"rohitcube"},"content":" return null;","lastModifiedDate":"2023-10-28"},{"lineNumber":470,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":471,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":472,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":473,"author":{"gitId":"rohitcube"},"content":" * Searches for modules containing a specified keyword in their title within a given module list.","lastModifiedDate":"2023-11-01"},{"lineNumber":474,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":475,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":476,"author":{"gitId":"rohitcube"},"content":" * @param keyword The keyword to search for.","lastModifiedDate":"2023-11-01"},{"lineNumber":477,"author":{"gitId":"rohitcube"},"content":" * @param moduleList The list of modules to search within.","lastModifiedDate":"2023-11-01"},{"lineNumber":478,"author":{"gitId":"rohitcube"},"content":" * @return A JSONArray containing modules matching the keyword.","lastModifiedDate":"2023-11-01"},{"lineNumber":479,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":480,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":481,"author":{"gitId":"rohitcube"},"content":" public static JSONArray search(String keyword, JSONArray moduleList) {","lastModifiedDate":"2023-10-28"},{"lineNumber":482,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesContainingKeyword \u003d new JSONArray();","lastModifiedDate":"2023-10-28"},{"lineNumber":483,"author":{"gitId":"rohitcube"},"content":" if (keyword.isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":484,"author":{"gitId":"rohitcube"},"content":" return new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":485,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":486,"author":{"gitId":"rohitcube"},"content":" for (Object moduleObject : moduleList) {","lastModifiedDate":"2023-10-28"},{"lineNumber":487,"author":{"gitId":"rohitcube"},"content":" JSONObject module \u003d (JSONObject) moduleObject; // Cast to JSONObject","lastModifiedDate":"2023-10-28"},{"lineNumber":488,"author":{"gitId":"rohitcube"},"content":" String title \u003d (String) module.get(\"title\");","lastModifiedDate":"2023-10-28"},{"lineNumber":489,"author":{"gitId":"rohitcube"},"content":" if (title.contains(keyword)) {","lastModifiedDate":"2023-10-28"},{"lineNumber":490,"author":{"gitId":"rohitcube"},"content":" modulesContainingKeyword.add(module);","lastModifiedDate":"2023-10-30"},{"lineNumber":491,"author":{"gitId":"rohitcube"},"content":" //not sure how to resolve this yellow line","lastModifiedDate":"2023-10-28"},{"lineNumber":492,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":493,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":494,"author":{"gitId":"rohitcube"},"content":" return modulesContainingKeyword;","lastModifiedDate":"2023-10-28"},{"lineNumber":495,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":496,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":497,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":498,"author":{"gitId":"rohitcube"},"content":" * Executes commands based on user input for module information retrieval.","lastModifiedDate":"2023-11-01"},{"lineNumber":499,"author":{"gitId":"rohitcube"},"content":" * Supports commands: \"description\", \"workload\", \"all\".","lastModifiedDate":"2023-11-01"},{"lineNumber":500,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":501,"author":{"gitId":"ryanlohyr"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-04"},{"lineNumber":502,"author":{"gitId":"rohitcube"},"content":" * @param command The command provided by the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":503,"author":{"gitId":"rohitcube"},"content":" * @param userInput The user input string containing the command and module code (if applicable).","lastModifiedDate":"2023-11-01"},{"lineNumber":504,"author":{"gitId":"rohitcube"},"content":" * @throws UnknownCommandException If an unknown command is provided.","lastModifiedDate":"2023-11-01"},{"lineNumber":505,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":506,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":507,"author":{"gitId":"rohitcube"},"content":" public static void infoCommands(String command, String userInput) {","lastModifiedDate":"2023-11-01"},{"lineNumber":508,"author":{"gitId":"rohitcube"},"content":" if (command.equals(\"description\")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":509,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":510,"author":{"gitId":"rohitcube"},"content":" userInput.substring(userInput.indexOf(\"description\") + 11).trim().toUpperCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":511,"author":{"gitId":"rohitcube"},"content":" if (!Api.getDescription(moduleCode).isEmpty()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":512,"author":{"gitId":"rohitcube"},"content":" String description \u003d Api.getDescription(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":513,"author":{"gitId":"rohitcube"},"content":" System.out.println(description);","lastModifiedDate":"2023-10-30"},{"lineNumber":514,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":515,"author":{"gitId":"rohitcube"},"content":" } else if (command.equals(\"workload\")) {","lastModifiedDate":"2023-10-28"},{"lineNumber":516,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d userInput.substring(userInput.indexOf(\"workload\") + 8).trim().toUpperCase();","lastModifiedDate":"2023-11-01"},{"lineNumber":517,"author":{"gitId":"rohitcube"},"content":" if (!Api.getWorkload(moduleCode).isEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":518,"author":{"gitId":"rohitcube"},"content":" JSONArray workload \u003d Api.getWorkload(moduleCode);","lastModifiedDate":"2023-10-30"},{"lineNumber":519,"author":{"gitId":"rohitcube"},"content":" System.out.println(workload);","lastModifiedDate":"2023-10-30"},{"lineNumber":520,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":521,"author":{"gitId":"rohitcube"},"content":" } else if (command.equals(\"all\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":522,"author":{"gitId":"rohitcube"},"content":" JSONArray allModules \u003d listAllModules();","lastModifiedDate":"2023-10-30"},{"lineNumber":523,"author":{"gitId":"rohitcube"},"content":" assert allModules !\u003d null;","lastModifiedDate":"2023-11-01"},{"lineNumber":524,"author":{"gitId":"ryanlohyr"},"content":" ModuleInfoView.printJsonArray(allModules);","lastModifiedDate":"2023-11-04"},{"lineNumber":525,"author":{"gitId":"rohitcube"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":526,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"man\");","lastModifiedDate":"2023-11-02"},{"lineNumber":527,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidCommandforInfoCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":528,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":529,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":530,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":531,"author":{"gitId":"rohitcube"},"content":" public static void searchCommand(String userInput) {","lastModifiedDate":"2023-11-01"},{"lineNumber":532,"author":{"gitId":"rohitcube"},"content":" if (!Parser.isValidKeywordInput(userInput)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":533,"author":{"gitId":"ryanlohyr"},"content":" UserError.emptyKeywordforSearchCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":534,"author":{"gitId":"rohitcube"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":535,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":536,"author":{"gitId":"rohitcube"},"content":" String keywords \u003d userInput.substring(userInput.indexOf(\"search\") + 6);","lastModifiedDate":"2023-11-01"},{"lineNumber":537,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint \u003d Api.search(keywords, Api.listAllModules());","lastModifiedDate":"2023-11-01"},{"lineNumber":538,"author":{"gitId":"rohitcube"},"content":" if (modulesToPrint.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":539,"author":{"gitId":"ryanlohyr"},"content":" UserError.emptyArrayforSearchCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":540,"author":{"gitId":"rohitcube"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":541,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":542,"author":{"gitId":"ryanlohyr"},"content":" ModuleInfoView.searchHeader();","lastModifiedDate":"2023-11-04"},{"lineNumber":543,"author":{"gitId":"ryanlohyr"},"content":" ModuleInfoView.printJsonArray(modulesToPrint);","lastModifiedDate":"2023-11-04"},{"lineNumber":544,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":545,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"SebasFok":110,"ryanlohyr":219,"janelleenqi":2,"rohitcube":214}},{"path":"src/main/java/seedu/duke/models/logic/CompletePreqs.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.ModuleList;","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"CerIsaiah"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"CerIsaiah"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"CerIsaiah"},"content":"import java.util.HashSet;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"CerIsaiah"},"content":"import java.util.List;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"CerIsaiah"},"content":"import java.util.Set;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"CerIsaiah"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"CerIsaiah"},"content":" * CompletePreqs checks which mods are unlocked once you finish a specific module","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"CerIsaiah"},"content":"public class CompletePreqs {","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"CerIsaiah"},"content":" //Full list of mods with modulesWithPreqs","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"CerIsaiah"},"content":" private HashMap\u003cString, List\u003cString\u003e\u003e modulesWithPreqs;","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"CerIsaiah"},"content":" private ArrayList\u003cString\u003e addToModulesCompleted;","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"CerIsaiah"},"content":" // To track modules that are already unlocked","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"CerIsaiah"},"content":" private Set\u003cString\u003e unlockedModulesSet;","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"CerIsaiah"},"content":" public CompletePreqs(HashMap\u003cString, List\u003cString\u003e\u003e inputMods) {","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"CerIsaiah"},"content":" modulesWithPreqs \u003d new HashMap\u003c\u003e(inputMods);","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"CerIsaiah"},"content":" unlockedModulesSet \u003d new HashSet\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"CerIsaiah"},"content":" addToModulesCompleted \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"CerIsaiah"},"content":" * Create a list of completed mods, hardcoded from startup.","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"CerIsaiah"},"content":" * @param list","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"CerIsaiah"},"content":" public void initializeCompletedMods(ModuleList list) {","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" addToModulesCompleted.addAll(list.getModuleCodes());","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"CerIsaiah"},"content":" for (String mod : addToModulesCompleted) {","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"CerIsaiah"},"content":" processModuleForUnlockingWithoutPrint(mod);","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"CerIsaiah"},"content":" * Prints what mods have been unlocked after input","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"CerIsaiah"},"content":" * @param moduleCompleted","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"CerIsaiah"},"content":" public void getUnlockedMods(String moduleCompleted) {","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"CerIsaiah"},"content":" // Check prerequisites of the moduleCompleted","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"CerIsaiah"},"content":" if (modulesWithPreqs.containsKey(moduleCompleted)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"CerIsaiah"},"content":" List\u003cString\u003e unmetPrerequisites \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"CerIsaiah"},"content":" for (String preq : modulesWithPreqs.get(moduleCompleted)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(preq)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"CerIsaiah"},"content":" unmetPrerequisites.add(preq);","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"CerIsaiah"},"content":" //Stops if a completedMod shouldn\u0027t be able to be completed with proper preqs","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"CerIsaiah"},"content":" if (!unmetPrerequisites.isEmpty()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(moduleCompleted +","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" \" cannot be marked as completed because of uncompleted prerequisites: \"","lastModifiedDate":"2023-10-19"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" + unmetPrerequisites);","lastModifiedDate":"2023-10-19"},{"lineNumber":63,"author":{"gitId":"CerIsaiah"},"content":" return;","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"CerIsaiah"},"content":" //If its not marked as completed, properly add it to the list","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(moduleCompleted)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"CerIsaiah"},"content":" addToModulesCompleted.add(moduleCompleted);","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(\"Mod completed: \" + moduleCompleted);","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"CerIsaiah"},"content":" printUnlockedMods(moduleCompleted);","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"CerIsaiah"},"content":" * This is only used for the first initalization of the mods.","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"CerIsaiah"},"content":" * @param moduleCompleted","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" private void processModuleForUnlockingWithoutPrint(String moduleCompleted) {","lastModifiedDate":"2023-10-19"},{"lineNumber":80,"author":{"gitId":"CerIsaiah"},"content":" ArrayList\u003cString\u003e newMods \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"CerIsaiah"},"content":" for (String key : modulesWithPreqs.keySet()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"CerIsaiah"},"content":" //If new unlocked mod isn\u0027t marked as complete or unlocked already","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"CerIsaiah"},"content":" if (!unlockedModulesSet.contains(key) \u0026\u0026 !addToModulesCompleted.contains(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"CerIsaiah"},"content":" boolean allPrerequisitesMet \u003d true;","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"CerIsaiah"},"content":" for (String preq : modulesWithPreqs.get(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(preq)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"CerIsaiah"},"content":" //Make sure preq isn\u0027t already marked as done","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"CerIsaiah"},"content":" allPrerequisitesMet \u003d false;","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"CerIsaiah"},"content":" if (allPrerequisitesMet) {","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"CerIsaiah"},"content":" newMods.add(key);","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"CerIsaiah"},"content":" unlockedModulesSet.add(key);","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":103,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":104,"author":{"gitId":"CerIsaiah"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"CerIsaiah"},"content":" * @param moduleCompleted","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"CerIsaiah"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"CerIsaiah"},"content":" public void printUnlockedMods(String moduleCompleted) {","lastModifiedDate":"2023-10-25"},{"lineNumber":108,"author":{"gitId":"CerIsaiah"},"content":" ArrayList\u003cString\u003e newlyUnlockedMods \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"CerIsaiah"},"content":" for (String key : modulesWithPreqs.keySet()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"CerIsaiah"},"content":" //If new unlocked mod isn\u0027t marked as complete or unlocked already","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"CerIsaiah"},"content":" if (!unlockedModulesSet.contains(key) \u0026\u0026 !addToModulesCompleted.contains(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"CerIsaiah"},"content":" boolean allPrerequisitesMet \u003d true;","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"CerIsaiah"},"content":" for (String preq : modulesWithPreqs.get(key)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"CerIsaiah"},"content":" if (!addToModulesCompleted.contains(preq)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"CerIsaiah"},"content":" //Make sure preq isn\u0027t already marked as done","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"CerIsaiah"},"content":" allPrerequisitesMet \u003d false;","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"CerIsaiah"},"content":" break;","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":120,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"CerIsaiah"},"content":" if (allPrerequisitesMet) {","lastModifiedDate":"2023-10-18"},{"lineNumber":122,"author":{"gitId":"CerIsaiah"},"content":" newlyUnlockedMods.add(key);","lastModifiedDate":"2023-10-18"},{"lineNumber":123,"author":{"gitId":"CerIsaiah"},"content":" unlockedModulesSet.add(key);","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":126,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":127,"author":{"gitId":"CerIsaiah"},"content":" for (String mod : newlyUnlockedMods) {","lastModifiedDate":"2023-10-18"},{"lineNumber":128,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(mod + \" has been unlocked!\");","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":131,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":132,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":133,"author":{"gitId":"CerIsaiah"},"content":" public void printModsCompleted(){","lastModifiedDate":"2023-10-25"},{"lineNumber":134,"author":{"gitId":"CerIsaiah"},"content":" for (String mod: addToModulesCompleted){","lastModifiedDate":"2023-10-25"},{"lineNumber":135,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(mod + \"has been completed\");","lastModifiedDate":"2023-10-25"},{"lineNumber":136,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":137,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":138,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":139,"author":{"gitId":"janelleenqi"},"content":" public boolean checkModInput(String[] words, ArrayList\u003cString\u003e majorModuleCodes){","lastModifiedDate":"2023-11-04"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" if (words.length \u003d\u003d 1){","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"janelleenqi"},"content":" if (majorModuleCodes.contains(words[0].toUpperCase())){","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"CerIsaiah"},"content":" return true;","lastModifiedDate":"2023-10-25"},{"lineNumber":143,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":144,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(\"Please enter a available mod: \");","lastModifiedDate":"2023-10-25"},{"lineNumber":145,"author":{"gitId":"janelleenqi"},"content":" System.out.println(majorModuleCodes);","lastModifiedDate":"2023-11-04"},{"lineNumber":146,"author":{"gitId":"CerIsaiah"},"content":" return false;","lastModifiedDate":"2023-10-25"},{"lineNumber":147,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"CerIsaiah"},"content":" System.out.println(\"Please enter a available mod after the complete keyword\");","lastModifiedDate":"2023-10-25"},{"lineNumber":149,"author":{"gitId":"janelleenqi"},"content":" System.out.println(majorModuleCodes);","lastModifiedDate":"2023-11-04"},{"lineNumber":150,"author":{"gitId":"CerIsaiah"},"content":" return false;","lastModifiedDate":"2023-10-25"},{"lineNumber":151,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"CerIsaiah"},"content":"}","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"SebasFok":2,"ryanlohyr":8,"janelleenqi":8,"CerIsaiah":136}},{"path":"src/main/java/seedu/duke/models/logic/DataRepository.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import java.io.File;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"public class DataRepository {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" * Retrieves a list of modules requirements for a specified major.","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" * @param major The major for which to retrieve requirements.","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" * @return An ArrayList of module codes.","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" * @throws RuntimeException If the specified major requirements file is not found.","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" public static ArrayList\u003cString\u003e getRequirements(String major) {","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-10-28"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" String fileName \u003d String.format(\"src/main/java/seedu/duke/models/data/%sRequirementsModuleCodes\", major);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" File f \u003d new File(fileName);","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" if (!f.exists()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" String[] courseArray \u003d determineRequirements(major);","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" return new ArrayList\u003c\u003e(Arrays.asList(courseArray));","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" return processCourseFile(f);","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" * Processes a course file, extracts relevant information, and returns a list of course codes.","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" * @param f The file to be processed.","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList of course codes extracted from the file.","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" * @throws FileNotFoundException If the specified file is not found.","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" private static ArrayList\u003cString\u003e processCourseFile(File f) throws FileNotFoundException {","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e currentArray \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" Scanner s \u003d new Scanner(f);","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" String currentLine \u003d s.nextLine();","lastModifiedDate":"2023-10-28"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" String[] words \u003d currentLine.split(\" \");","lastModifiedDate":"2023-10-28"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" if (!currentLine.isEmpty() \u0026\u0026 !currentLine.startsWith(\"*\")) { // not empty line, not title","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" currentArray.add(words[0]);","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" return currentArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" * Determines the course requirements based on the specified major. Function is used if file is not found","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" * @param major A string representing the major (e.g., \"CEG\" for Computer Engineering, \"CS\" for Computer Science).","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" * @return An array of strings containing the course requirements for the specified major.","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" private static String[] determineRequirements(String major) {","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" String[] courseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" String[] csCourseArray \u003d {","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" \"CS1101S\", \"ES2660\", \"GEC1000\", \"GEA1000\", \"GESS1000\",","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" \"GEN2000\", \"IS1108\", \"CS1231S\", \"CS2030S\", \"CS2040S\",","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" \"CS2100\", \"CS2101\", \"CS2103T\", \"CS2106\", \"CS2109S\",","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" \"CS3230\", \"MA1521\", \"MA1522\", \"ST2334\", \"CP3880\"","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" };","lastModifiedDate":"2023-11-04"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" String[] cegCourseArray \u003d {","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" \"CG1111A\", \"MA1511\", \"MA1512\", \"CS1010\", \"GESS1000\",","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" \"GEC1000\", \"GEN2000\", \"ES2631\", \"GEA1000\", \"DTK1234\",","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" \"EG1311\", \"IE2141\", \"EE2211\", \"EG2501\", \"CDE2000\",","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" \"PF1101\", \"CG4002\", \"MA1508E\", \"EG2401A\", \"CP3880\",","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" \"CG2111A\", \"CS1231\", \"CG2023\", \"CG2027\", \"CG2028\",","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" \"CG2271\", \"ST2334\", \"CS2040C\", \"CS2113\", \"EE2026\", \"EE4204\"","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" };","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" if(major.equals(\"CEG\")){","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" courseArray \u003d cegCourseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" }else{","lastModifiedDate":"2023-11-04"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" courseArray \u003d csCourseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" return courseArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":91,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"janelleenqi"},"content":" * Returns the file path for the requirements of a specified major.","lastModifiedDate":"2023-10-29"},{"lineNumber":93,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":94,"author":{"gitId":"janelleenqi"},"content":" * @param major The major for which to retrieve the requirements file path.","lastModifiedDate":"2023-10-29"},{"lineNumber":95,"author":{"gitId":"janelleenqi"},"content":" * @return The file path to the major\u0027s requirements file.","lastModifiedDate":"2023-10-29"},{"lineNumber":96,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":97,"author":{"gitId":"janelleenqi"},"content":" public static String getFullRequirements(Major major) {","lastModifiedDate":"2023-10-28"},{"lineNumber":98,"author":{"gitId":"janelleenqi"},"content":" return String.format(\"src/main/java/seedu/duke/models/data/%sRequirements\", major.toString());","lastModifiedDate":"2023-10-28"},{"lineNumber":99,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ryanlohyr":75,"janelleenqi":26}},{"path":"src/main/java/seedu/duke/models/logic/MajorRequirements.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.views.CommandLineView;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"public class MajorRequirements {","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" public static void printRequiredModules(String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" if (!major.equals(\"CEG\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" CommandLineView.displayMessage(\"Sorry this major has not be included in our app yet.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":" return;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" CommandLineView.displayMessage(","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" \"#\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d#\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" \"║\\tModular Requirements for CEG \\tUnits\\t║\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" \"#\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d#\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" \"│\\tCommon Curriculum Requirements \\t60\\t\\t│\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" \"\\tGES1000 (Singapore Studies) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" \"\\tGEC1000 (Cultures and Connections) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" \"\\tGEN2000 (Communities and Engagement) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" \"\\tES2631 Critique \u0026 Communication of Thinking \u0026 Design (Critique \u0026 Expression)\\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS1010 Programming Methodology (Digital Literacy) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" \"\\tGEA1000 Quantitative Reasoning with Data (Data Literacy) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" \"\\tDTK1234 Design Thinking (Design Thinking) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":" \"\\tEG1311 Design and Make (Maker Space) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" \"\\tIE2141 Systems Thinking and Dynamics (Systems Thinking) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" \"\\tEE2211 Introduction to Machine Learning (Artificial Intelligence) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" \"\\tCDE2501 Liveable Cities (Sustainable Futures) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" \"\\tCDE2000 (Creating Narratives) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" \"\\tPF1101 Fundamentals of Project Management (Project Management) \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG4002 Computer Engineering Capstone Project 1 (Integrated Project) \\t8\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" \"│\\tProgramme Requirements \\t60\\t\\t│\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" \" ~~\\tEngineering Core \\t20\\t ~~\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" \"\\tMA1511 Engineering Calculus \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" \"\\tMA1512 Differential Equations for Engineering \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" \"\\tMA1508E Linear Algebra for Engineering \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":" \"\\tEG2401A Engineering Professionalism \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" \"\\tCP3880 Advanced Technology Attachment Programme \\t12\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" \" ~~\\tCEG Major \\t40\\t ~~\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG1111A Engineering Principles and Practice I \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2111A Engineering Principles and Practice II \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS1231 Discrete Structures \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2023 Signals \u0026 Systems \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2027 Transistor-level Digital Circuit \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2028 Computer Organization \\t2\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" \"\\tCG2271 Real-time Operating System \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS2040C Data Structures and Algorithms \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":" \"\\tCS2113 Software Engineering \u0026 Object-Oriented Programming \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"janelleenqi"},"content":" \"\\tEE2026 Digital Design \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":" \"\\tEE4204 Computer Networks \\t4\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":" \"│\\tUnrestricted Electives \\t40\\t\\t│\\n\" +","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":" \"+-------------------------------------------------------------------------------------------+\");","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ryanlohyr":4,"janelleenqi":61}},{"path":"src/main/java/seedu/duke/models/logic/ScheduleGenerator.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import java.util.LinkedList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import java.util.Queue;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.getModulePrereqBasedOnCourse;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.DataRepository.getRequirements;","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"public class ScheduleGenerator {","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" * Generates a recommended schedule for a given course based on its requirements and prerequisites.","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * @param course The course for which to generate a recommended schedule.","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList of strings representing the recommended schedule in order of completion.","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" public static ArrayList\u003cString\u003e generateRecommendedSchedule(String course){","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e requirements \u003d getRequirements(course);","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" HashMap\u003cString, Integer\u003e degreeMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" Queue\u003cString\u003e q \u003d new LinkedList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e schedule \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" HashMap\u003cString, ArrayList\u003cString\u003e\u003e adjacencyList \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" //initialisation","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" for(String requirement: requirements) {","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" adjacencyList.put(requirement, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" degreeMap.put(requirement, 0);","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" for (String requirement : requirements) {","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e prereqArray \u003d getModulePrereqBasedOnCourse(requirement, course);","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" if (prereqArray \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" prereqArray \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" //we need to create an adjacency list to add all the connections","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" // from pre req -\u003e item","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" for (String s : prereqArray) {","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" adjacencyList.get(s).add(requirement);","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" Integer value \u003d degreeMap.get(requirement) + 1;","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" degreeMap.put(requirement, value);","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" for (String key : degreeMap.keySet()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" Integer value \u003d degreeMap.get(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" if(value \u003d\u003d 0){","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" q.offer(key);","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" while(!q.isEmpty()){","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" String curr \u003d q.poll();","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" schedule.add(curr);","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e currReq \u003d adjacencyList.get(curr);","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" for (String s : currReq) {","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" int num \u003d degreeMap.get(s) - 1;","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" degreeMap.put(s, num);","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" if (num \u003d\u003d 0) {","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" q.offer(s);","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" return schedule;","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ryanlohyr":74}},{"path":"src/main/java/seedu/duke/models/schema/CommandManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"/**","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" * This class represents the command system for the application.","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" * It stores and provides descriptions for each available command.","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"public class CommandManager {","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" private HashMap\u003cString, String\u003e commandsAndDescription;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" public CommandManager() {","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" addCurrentCommands();","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" * Populates the commandsAndDescription HashMap with the current commands and their descriptions.","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" private void addCurrentCommands() {","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"info\", \"Displays information about a specific module.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"left\", \"Displays a list of remaining modules.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"pace\", \"Computes and displays your graduation pace.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"prereq\", \"Displays the prerequisites for a specific module.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"recommend\", \"Displays a recommended schedule based on a keyword.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"required\", \"Displays the full requirements for your major.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"complete\", \"Marks a module as complete on schedule planner.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"Bye\", \"Exits the program.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"help\", \"Shows the list of commands.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"add\", \"Adds module to the recommended schedule planner.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"delete\", \"Deletes module from the schedule planner.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"schedule\", \"Shows schedule planner\");","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" commandsAndDescription.put(\"search\", \"search for modules to take based on keyword\");","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves the description for a specific command.","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" * @param command The command to retrieve the description for.","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" * @return The description of the command, or \"Command not recognized\" if the command is not in the HashMap.","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" public String getDescription(String command) {","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" return commandsAndDescription.getOrDefault(command, \"Command not recognized\");","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" * Retrieves a list of all available commands.","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList containing all available commands.","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" public ArrayList\u003cString\u003e getListOfCommands() {","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" return new ArrayList\u003c\u003e(commandsAndDescription.keySet());","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" * Returns a formatted list of all commands and their descriptions.","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" * @return An ArrayList of strings, where each string represents a command and its description.","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" public ArrayList\u003cString\u003e printListOfCommands() {","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e commandList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" for (HashMap.Entry\u003cString, String\u003e entry : commandsAndDescription.entrySet()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" String command \u003d entry.getKey();","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" String description \u003d entry.getValue();","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" commandList.add(command + \": \" + description);","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" return commandList;","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":71}},{"path":"src/main/java/seedu/duke/models/schema/Major.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":" * The `Major` enum represents different majors that can be selected by our application.","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"public enum Major {","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" CEG, CS","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"SebasFok":6,"ryanlohyr":2}},{"path":"src/main/java/seedu/duke/models/schema/Module.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.Api.getFullModuleInfo;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"public class Module {","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" //module class requires Name","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" private String moduleName;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" private String moduleDescription;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" private String moduleCode;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" private int moduleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" private boolean isCompleted;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * Represents a module with the specified module code. This class fetches module information","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" * using the NUSMods API and stores details such as the module description, name, credits, and completion status.","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module.","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" public Module(String moduleCode) throws NullPointerException, RuntimeException{","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" //add wtv info u want...","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" if (moduleCode.isEmpty()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" throw new NullPointerException();","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" JSONObject response \u003d getFullModuleInfo(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" assert response !\u003d null: \"Response from NUSMods API is null\";","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" assert !response.isEmpty(): \"Response Object is empty\";","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" this.moduleCode \u003d moduleCode;","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" this.isCompleted \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" this.moduleDescription \u003d (String) response.get(\"description\");","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" this.moduleName \u003d (String) response.get(\"title\");","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" try{","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" this.moduleCredits \u003d (Integer) response.get(\"moduleCredit\");","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" }catch (ClassCastException e){","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" this.moduleCredits \u003d 4;","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" } catch (RuntimeException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" throw e;","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" * Marks this module as completed.","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" public void markModuleAsCompleted() {","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" this.isCompleted \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" public boolean getCompletionStatus() {","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" return isCompleted;","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" * Gets the credits of this module.","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" * @return The number of credits for this module.","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" public int getModuleCredits() {","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" return this.moduleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" * Gets the module code.","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" * @return The code of this module.","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" public String getModuleCode() {","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" return this.moduleCode;","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":66,"janelleenqi":13}},{"path":"src/main/java/seedu/duke/models/schema/ModuleList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.ModuleInfoView.printModuleArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":" * A class representing a list of modules and providing operations to manage them.","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"public class ModuleList {","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" private ArrayList\u003cModule\u003e mainModuleList;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" private int numberOfModules;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" * Constructs a ModuleList from a space-separated string of modules.","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" * @param modules A space-separated string of module codes.","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" public ModuleList(String modules) {","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" mainModuleList \u003d new ArrayList\u003cModule\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":" if (modules \u003d\u003d null || modules.isEmpty()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" return;","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" String[] moduleArray \u003d modules.split(\" \");","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" //ArrayList\u003cString\u003e moduleCodes \u003d new ArrayList\u003cString\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" //numberOfModules \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" for (String module : moduleArray) {","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" mainModuleList.add(new Module(module));","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" numberOfModules +\u003d 1;","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" System.out.println(\"null pointer\");","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" //fail","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" } catch (NullPointerException e) {","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" new ModuleList();","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" * Constructs an empty ModuleList.","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":" public ModuleList() {","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":" mainModuleList \u003d new ArrayList\u003cModule\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"janelleenqi"},"content":" numberOfModules \u003d 0;","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" public void addModule (Module module) {","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":" mainModuleList.add(module);","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":" public void deleteModule (Module module) {","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":" mainModuleList.remove(module);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"janelleenqi"},"content":" public boolean exists(String moduleCodeA) throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"janelleenqi"},"content":" if (mainModuleList \u003d\u003d null) {","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"janelleenqi"},"content":" throw new InvalidObjectException(\"Null Module List\");","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"janelleenqi"},"content":" if (moduleCodeA \u003d\u003d null) {","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"janelleenqi"},"content":" throw new InvalidObjectException(\"Null Module Code\");","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"janelleenqi"},"content":" for (Module moduleB : mainModuleList) {","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"janelleenqi"},"content":" if (moduleCodeA.equals(moduleB.getModuleCode())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"janelleenqi"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"janelleenqi"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"janelleenqi"},"content":" * Retrieves the list of modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":89,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"janelleenqi"},"content":" * @author janelleenqi","lastModifiedDate":"2023-10-24"},{"lineNumber":91,"author":{"gitId":"janelleenqi"},"content":" * @return The ArrayList containing the modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cModule\u003e getMainModuleList() {","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"janelleenqi"},"content":" assert mainModuleList !\u003d null: \"null mainModuleList\";","lastModifiedDate":"2023-10-24"},{"lineNumber":95,"author":{"gitId":"janelleenqi"},"content":" return mainModuleList;","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"janelleenqi"},"content":" public Module getModule(String moduleCode) throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList) {","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"janelleenqi"},"content":" if (moduleCode.equals(module.getModuleCode())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"janelleenqi"},"content":" return module;","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"janelleenqi"},"content":" throw new InvalidObjectException(\"Module does not exist.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" public ArrayList\u003cString\u003e getModulesPlanned(){","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e completedModuleCodes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" completedModuleCodes.add(module.getModuleCode());","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" return completedModuleCodes;","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":115,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getModulesCompleted(){","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e completedModuleCodes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":" if (module.getCompletionStatus()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"janelleenqi"},"content":" completedModuleCodes.add(module.getModuleCode());","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"janelleenqi"},"content":" return completedModuleCodes;","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"CerIsaiah"},"content":" public void printMainModuleList(){","lastModifiedDate":"2023-10-25"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":" printModuleArray(mainModuleList);","lastModifiedDate":"2023-11-04"},{"lineNumber":128,"author":{"gitId":"CerIsaiah"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":129,"author":{"gitId":"CerIsaiah"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":130,"author":{"gitId":"janelleenqi"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"janelleenqi"},"content":" * Retrieves the number of modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"janelleenqi"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"janelleenqi"},"content":" * @return The number of modules.","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"janelleenqi"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"janelleenqi"},"content":" public int getNumberOfModules() {","lastModifiedDate":"2023-10-16"},{"lineNumber":136,"author":{"gitId":"janelleenqi"},"content":" assert numberOfModules \u003e\u003d 0: \"negative numberOfModules\";","lastModifiedDate":"2023-10-24"},{"lineNumber":137,"author":{"gitId":"janelleenqi"},"content":" return numberOfModules;","lastModifiedDate":"2023-10-16"},{"lineNumber":138,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":140,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":" * Changes the number of modules by the specified difference.","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":" * @param difference The difference by which to change the number of modules.","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"SebasFok"},"content":" * A positive value increases the number, while a negative value decreases it.","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":" public void changeNumberOfModules(int difference) {","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"SebasFok"},"content":" numberOfModules +\u003d difference;","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":151,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getModuleCodes() {","lastModifiedDate":"2023-11-04"},{"lineNumber":152,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e moduleCodes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":153,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-04"},{"lineNumber":154,"author":{"gitId":"janelleenqi"},"content":" moduleCodes.add(module.getModuleCode());","lastModifiedDate":"2023-11-04"},{"lineNumber":155,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":156,"author":{"gitId":"janelleenqi"},"content":" return moduleCodes;","lastModifiedDate":"2023-11-04"},{"lineNumber":157,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":158,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":159,"author":{"gitId":"janelleenqi"},"content":" public int getIndex(String moduleCode) {","lastModifiedDate":"2023-11-04"},{"lineNumber":160,"author":{"gitId":"janelleenqi"},"content":" int i \u003d 0;","lastModifiedDate":"2023-11-04"},{"lineNumber":161,"author":{"gitId":"janelleenqi"},"content":" for (Module module: mainModuleList){","lastModifiedDate":"2023-11-04"},{"lineNumber":162,"author":{"gitId":"janelleenqi"},"content":" if (moduleCode.equals(module.getModuleCode())) {","lastModifiedDate":"2023-11-04"},{"lineNumber":163,"author":{"gitId":"janelleenqi"},"content":" return i;","lastModifiedDate":"2023-11-04"},{"lineNumber":164,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":165,"author":{"gitId":"janelleenqi"},"content":" i++;","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":167,"author":{"gitId":"janelleenqi"},"content":" return -1;","lastModifiedDate":"2023-11-04"},{"lineNumber":168,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":169,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"SebasFok":11,"ryanlohyr":14,"janelleenqi":141,"CerIsaiah":3}},{"path":"src/main/java/seedu/duke/models/schema/Schedule.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"import static seedu.duke.models.logic.Api.doesModuleExist;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":"import static seedu.duke.models.logic.Api.satisfiesAllPrereq;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":" * The `Schedule` class represents a student\u0027s course schedule and extends the `ModuleList` class.","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":" * It allows a student to manage and manipulate their enrolled modules across multiple semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"SebasFok"},"content":"public class Schedule extends ModuleList {","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"SebasFok"},"content":" private static final int MAXIMUM_SEMESTERS \u003d 8;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"SebasFok"},"content":" protected int[] modulesPerSem;","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"SebasFok"},"content":" * Constructs a new `Schedule` with the provided modules and distribution across semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":" * @param modules A string containing module codes representing the student\u0027s schedule.","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"SebasFok"},"content":" * @param modulesPerSem An array indicating the distribution of modules across semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"SebasFok"},"content":" public Schedule(String modules, int[] modulesPerSem) {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" super(modules);","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"SebasFok"},"content":" this.modulesPerSem \u003d modulesPerSem;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" * Constructs a new, empty `Schedule` with no modules and a default semester distribution.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"SebasFok"},"content":" public Schedule() {","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"SebasFok"},"content":" super();","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" this.modulesPerSem \u003d new int[]{0, 0, 0, 0, 0, 0, 0, 0};","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" * Retrieves the maximum number of semesters allowed in a student\u0027s course schedule.","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" * @return The maximum number of semesters allowed.","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" public static int getMaximumSemesters() {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"SebasFok"},"content":" return MAXIMUM_SEMESTERS;","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" public void addRecommendedScheduleListToSchedule(ArrayList\u003cString\u003e scheduleToAdd) {","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" final int modsToAddPerSem \u003d 5;","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" int currentIndexOfMod \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" int currentSem \u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" for (String module : scheduleToAdd) {","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"janelleenqi"},"content":" // Check if the module fulfill pre req, else we move it to next sem","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" // ModuleList completedModules \u003d new ModuleList(String.join(\" \", getMainModuleList()));","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" int indexToAdd \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" for (int i \u003d 1; i \u003c currentSem; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" indexToAdd +\u003d this.modulesPerSem[i - 1];","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" //Sub list as we only want modules before the current target semester","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" List\u003cString\u003e completedModulesArray \u003d getModuleCodes().subList(0, (indexToAdd));","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" ModuleList completedModules \u003d new ModuleList(String.join(\" \", completedModulesArray));","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" if(!satisfiesAllPrereq(module,completedModules)){","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" currentSem +\u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" currentIndexOfMod \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" addModuleWithoutCheckingPrereq(module, currentSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e){","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" currentIndexOfMod +\u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" if(currentIndexOfMod \u003e\u003d modsToAddPerSem){","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" currentIndexOfMod \u003d 0;","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" currentSem +\u003d 1;","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"SebasFok"},"content":" * Adds a module to the schedule for a specified semester.","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"SebasFok"},"content":" * @param module The module code to be added.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"SebasFok"},"content":" * @param targetSem The target semester (an integer from 1 to 8) in which to add the module.","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"SebasFok"},"content":" * @throws IllegalArgumentException If the provided semester is out of the valid range (1 to 8),","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"SebasFok"},"content":" * or if the module already exists in the schedule, or if the module is not valid.","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"SebasFok"},"content":" * @throws InvalidObjectException If the module is null.","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"SebasFok"},"content":" * @throws FailPrereqException If the prerequisites for the module are not satisfied","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"SebasFok"},"content":" public void addModule(String module, int targetSem) throws IllegalArgumentException, InvalidObjectException,","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"SebasFok"},"content":" FailPrereqException {","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"SebasFok"},"content":" if (targetSem \u003c 1 || targetSem \u003e MAXIMUM_SEMESTERS) {","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Please select an integer from 1 to 8 for semester selection\");","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"SebasFok"},"content":" if (exists(module)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Module already exists in the schedule\");","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"SebasFok"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"SebasFok"},"content":" throw new InvalidObjectException(\"Module cannot be null\");","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":109,"author":{"gitId":"SebasFok"},"content":" int indexToAdd \u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":110,"author":{"gitId":"SebasFok"},"content":" for (int i \u003d 1; i \u003c targetSem; i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"SebasFok"},"content":" indexToAdd +\u003d this.modulesPerSem[i - 1];","lastModifiedDate":"2023-10-29"},{"lineNumber":112,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" //Sub list as we only want modules before the current target semester","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" List\u003cString\u003e completedModulesArray \u003d getModulesPlanned().subList(0, (indexToAdd));","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" ModuleList completedModules;","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":" if (!completedModulesArray.isEmpty()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":118,"author":{"gitId":"janelleenqi"},"content":" completedModules \u003d new ModuleList(String.join(\" \", completedModulesArray));","lastModifiedDate":"2023-11-04"},{"lineNumber":119,"author":{"gitId":"janelleenqi"},"content":" } else {","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"janelleenqi"},"content":" completedModules \u003d new ModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"SebasFok"},"content":" if (satisfiesAllPrereq(module, completedModules)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" //module initialization will be here","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"janelleenqi"},"content":" this.getMainModuleList().add(indexToAdd, new Module(module));","lastModifiedDate":"2023-11-04"},{"lineNumber":128,"author":{"gitId":"SebasFok"},"content":" modulesPerSem[targetSem - 1] +\u003d 1;","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"SebasFok"},"content":" changeNumberOfModules(1);","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"SebasFok"},"content":" return;","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":132,"author":{"gitId":"SebasFok"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Please select a valid module\");","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"SebasFok"},"content":" throw new FailPrereqException(\"Unable to add module as prerequisites not satisfied for: \" + module);","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"SebasFok"},"content":" * Deletes a module from the schedule by its module code.","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":" * @param module The module code to be deleted from the schedule.","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":" * @throws FailPrereqException If the module to be deleted is a prerequisite for other modules in the schedule.","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":" * @throws IllegalArgumentException If the provided module code is not valid, the module is not in the schedule","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":" public void deleteModule(String module) throws FailPrereqException, IllegalArgumentException {","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"janelleenqi"},"content":" //int targetIndex \u003d getMainModuleList().indexOf(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":148,"author":{"gitId":"janelleenqi"},"content":" int targetIndex \u003d getIndex(module);","lastModifiedDate":"2023-11-04"},{"lineNumber":149,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":150,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":151,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"SebasFok"},"content":" if (!doesModuleExist(module)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Please select a valid module\");","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"SebasFok"},"content":" if (targetIndex \u003d\u003d -1) {","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Module is not in schedule\");","lastModifiedDate":"2023-11-02"},{"lineNumber":158,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"SebasFok"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":" int moduleCount \u003d modulesPerSem[0];","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":" while ((moduleCount - 1) \u003c targetIndex) {","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":" moduleCount +\u003d modulesPerSem[targetSem];","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":" targetSem +\u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":" int nextSemStartingIndex \u003d moduleCount;","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":" int lastModuleIndex \u003d getNumberOfModules() - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"janelleenqi"},"content":" List\u003cString\u003e completedModulesArray \u003d getModuleCodes().subList(0, nextSemStartingIndex);","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":" ModuleList completedModules \u003d new ModuleList(String.join(\" \", completedModulesArray));","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":" completedModules.getMainModuleList().remove(module);","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"SebasFok"},"content":" List\u003cString\u003e modulesAheadArray;","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":" modulesAheadArray \u003d getModuleCodes().subList(nextSemStartingIndex, lastModuleIndex + 1);","lastModifiedDate":"2023-11-04"},{"lineNumber":179,"author":{"gitId":"SebasFok"},"content":" } catch (IndexOutOfBoundsException | IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"SebasFok"},"content":" modulesAheadArray \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"SebasFok"},"content":" for (String moduleAhead : modulesAheadArray){","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"SebasFok"},"content":" if (!satisfiesAllPrereq(moduleAhead, completedModules)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"SebasFok"},"content":" throw new FailPrereqException(\"Unable to delete module. This module is a prerequisite for \"","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"SebasFok"},"content":" + moduleAhead);","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":189,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":190,"author":{"gitId":"SebasFok"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":191,"author":{"gitId":"SebasFok"},"content":" // This catch should never occur as it should not be possible to add an invalid module","lastModifiedDate":"2023-11-02"},{"lineNumber":192,"author":{"gitId":"SebasFok"},"content":" assert false;","lastModifiedDate":"2023-11-02"},{"lineNumber":193,"author":{"gitId":"SebasFok"},"content":" throw new IllegalArgumentException(\"Invalid Module in Schedule\");","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":195,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":196,"author":{"gitId":"SebasFok"},"content":" getMainModuleList().remove(module);","lastModifiedDate":"2023-10-31"},{"lineNumber":197,"author":{"gitId":"SebasFok"},"content":" modulesPerSem[targetSem - 1] -\u003d 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"SebasFok"},"content":" changeNumberOfModules(-1);","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":201,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":202,"author":{"gitId":"ryanlohyr"},"content":" * Adds a module to the schedule for a specified semester.","lastModifiedDate":"2023-11-04"},{"lineNumber":203,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":204,"author":{"gitId":"ryanlohyr"},"content":" * @param module The module code to be added.","lastModifiedDate":"2023-11-04"},{"lineNumber":205,"author":{"gitId":"ryanlohyr"},"content":" * @param targetSem The target semester (an integer from 1 to 8) in which to add the module.","lastModifiedDate":"2023-11-04"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" * @throws IllegalArgumentException If the provided semester is out of the valid range (1 to 8),","lastModifiedDate":"2023-11-04"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":" * or if the module already exists in the schedule, or if the module is not valid.","lastModifiedDate":"2023-11-04"},{"lineNumber":208,"author":{"gitId":"ryanlohyr"},"content":" * @throws InvalidObjectException If the module is null.","lastModifiedDate":"2023-11-04"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":" * @throws FailPrereqException If the prerequisites for the module are not satisfied","lastModifiedDate":"2023-11-04"},{"lineNumber":210,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":211,"author":{"gitId":"ryanlohyr"},"content":" public void addModuleWithoutCheckingPrereq(String module, int targetSem)","lastModifiedDate":"2023-11-04"},{"lineNumber":212,"author":{"gitId":"ryanlohyr"},"content":" throws","lastModifiedDate":"2023-11-04"},{"lineNumber":213,"author":{"gitId":"ryanlohyr"},"content":" InvalidObjectException,","lastModifiedDate":"2023-11-04"},{"lineNumber":214,"author":{"gitId":"ryanlohyr"},"content":" IllegalArgumentException {","lastModifiedDate":"2023-11-04"},{"lineNumber":215,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":216,"author":{"gitId":"ryanlohyr"},"content":" if (targetSem \u003c 1 || targetSem \u003e MAXIMUM_SEMESTERS) {","lastModifiedDate":"2023-11-04"},{"lineNumber":217,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Please select an integer from 1 to 8 for semester selection\");","lastModifiedDate":"2023-11-04"},{"lineNumber":218,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":219,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":220,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-04"},{"lineNumber":221,"author":{"gitId":"ryanlohyr"},"content":" if (exists(module)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":222,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Module already exists in the schedule\");","lastModifiedDate":"2023-11-04"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":225,"author":{"gitId":"ryanlohyr"},"content":" throw new InvalidObjectException(\"Module cannot be null\");","lastModifiedDate":"2023-11-04"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":227,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":" int indexToAdd \u003d 0;","lastModifiedDate":"2023-11-04"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" for (int i \u003d 1; i \u003c targetSem; i++) {","lastModifiedDate":"2023-11-04"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":" indexToAdd +\u003d this.modulesPerSem[i - 1];","lastModifiedDate":"2023-11-04"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":233,"author":{"gitId":"ryanlohyr"},"content":" this.getMainModuleList().add(indexToAdd, new Module(module));","lastModifiedDate":"2023-11-04"},{"lineNumber":234,"author":{"gitId":"ryanlohyr"},"content":" modulesPerSem[targetSem - 1] +\u003d 1;","lastModifiedDate":"2023-11-04"},{"lineNumber":235,"author":{"gitId":"ryanlohyr"},"content":" changeNumberOfModules(1);","lastModifiedDate":"2023-11-04"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":237,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":238,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":239,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":240,"author":{"gitId":"SebasFok"},"content":" * Prints the student\u0027s course schedule, displaying modules organized by semesters.","lastModifiedDate":"2023-10-31"},{"lineNumber":241,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":242,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"SebasFok"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":244,"author":{"gitId":"SebasFok"},"content":" public void printMainModuleList() {","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"SebasFok"},"content":" int moduleCounter \u003d 0;","lastModifiedDate":"2023-10-30"},{"lineNumber":246,"author":{"gitId":"SebasFok"},"content":" for (int i \u003d 0; i \u003c modulesPerSem.length; i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"SebasFok"},"content":" System.out.print(\"Sem \" + (i + 1) + \": \");","lastModifiedDate":"2023-10-30"},{"lineNumber":248,"author":{"gitId":"SebasFok"},"content":" for (int j \u003d 0; j \u003c modulesPerSem[i]; j++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":249,"author":{"gitId":"janelleenqi"},"content":" System.out.print(getMainModuleList().get(moduleCounter).getModuleCode() + \" \");","lastModifiedDate":"2023-11-04"},{"lineNumber":250,"author":{"gitId":"SebasFok"},"content":" moduleCounter++;","lastModifiedDate":"2023-10-30"},{"lineNumber":251,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":252,"author":{"gitId":"SebasFok"},"content":" System.out.println();","lastModifiedDate":"2023-10-30"},{"lineNumber":253,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":254,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":255,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"SebasFok":166,"ryanlohyr":73,"janelleenqi":16}},{"path":"src/main/java/seedu/duke/models/schema/Student.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import seedu.duke.exceptions.MissingModuleException;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"import static seedu.duke.models.logic.DataRepository.getRequirements;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":" * The Student class represents a student with a name, major, and module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":"public class Student {","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"SebasFok"},"content":" private String name;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" private String major;","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"SebasFok"},"content":" private Schedule schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" private String year;","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" private int completedModuleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" private ModuleList modulesPlanned;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" private ArrayList\u003cString\u003e majorModuleCodes;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"SebasFok"},"content":" * Constructs a student with a name, major, and module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"SebasFok"},"content":" * @param name The name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"SebasFok"},"content":" * @param major The major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"SebasFok"},"content":" * @param schedule The module schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" public Student(String name, String major, Schedule schedule) {","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" this.major \u003d major;","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":" this.schedule \u003d schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" this.year \u003d null;","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" this.modulesPlanned \u003d new ModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" * Constructs a student with a null name, null major, and an empty module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":" public Student() {","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" this.name \u003d null;","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" this.major \u003d null;","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" this.schedule \u003d new Schedule();","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" this.year \u003d null;","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" this.modulesPlanned \u003d new ModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"SebasFok"},"content":" * Sets the class schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"SebasFok"},"content":" * @param schedule The new module schedule.","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"SebasFok"},"content":" public void setSchedule(Schedule schedule) {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"SebasFok"},"content":" this.schedule \u003d schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"SebasFok"},"content":" * Retrieves the module schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"SebasFok"},"content":" * @return The module schedule of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"SebasFok"},"content":" public Schedule getSchedule() {","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"SebasFok"},"content":" return schedule;","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" public int getCurrentModuleCredits(){","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" return completedModuleCredits;","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" * Retrieves the name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"SebasFok"},"content":" * @return The name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"SebasFok"},"content":" public String getName() {","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"SebasFok"},"content":" return name;","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":81,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"SebasFok"},"content":" * Retrieves the major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"SebasFok"},"content":" * @return The major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"SebasFok"},"content":" * @throws NullPointerException If the major has not been set (i.e., it is `null`).","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" public String getMajor(){","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"SebasFok"},"content":" return major;","lastModifiedDate":"2023-10-17"},{"lineNumber":90,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":91,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" * Sets the first major without the major command","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" * @author Isaiah Cerven","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput must be validated in parser as CS or CEG","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" public void setFirstMajor(String userInput){","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" setMajor(userInput.toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(e);","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"janelleenqi"},"content":" public void addModuleSchedule(String moduleCode, int targetSem) throws InvalidObjectException, FailPrereqException {","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" this.schedule.addModule(moduleCode,targetSem);","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"janelleenqi"},"content":" this.modulesPlanned.addModule(new Module(moduleCode));","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" * Completes a module with the specified module code.","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module to be completed.","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"janelleenqi"},"content":" public void completeModuleSchedule(String moduleCode) {","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cModule\u003e modulesPlanned \u003d this.modulesPlanned.getMainModuleList();","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":" for (Module module : modulesPlanned) {","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" if (module.getModuleCode().equals(moduleCode)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" this.completedModuleCredits +\u003d module.getModuleCredits();","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":" module.markModuleAsCompleted();","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" return;","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" public void printSchedule(){","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" this.schedule.printMainModuleList();","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" * Deletes a module with the specified module code. This method also updates the completed","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" * module credits and removes the module from the planned modules list.","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" * @param moduleCode The code of the module to be deleted.","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" * @throws FailPrereqException If deleting the module fails due to prerequisite dependencies.","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"janelleenqi"},"content":" public void deleteModuleSchedule(String moduleCode) throws FailPrereqException, MissingModuleException {","lastModifiedDate":"2023-11-04"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":" this.schedule.deleteModule(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"janelleenqi"},"content":" Module module;","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"janelleenqi"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"janelleenqi"},"content":" module \u003d modulesPlanned.getModule(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"janelleenqi"},"content":" } catch (InvalidObjectException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"janelleenqi"},"content":" throw new MissingModuleException(moduleCode + \" is not in Modules Planner.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"janelleenqi"},"content":" this.completedModuleCredits -\u003d module.getModuleCredits();","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"janelleenqi"},"content":" modulesPlanned.deleteModule(module);","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":" public String getYear() {","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":" return year;","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" public void setYear(String year) {","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" this.year \u003d year;","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":" * Sets the name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"SebasFok"},"content":" * @param name The new name of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":167,"author":{"gitId":"SebasFok"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"SebasFok"},"content":" * Sets the major of the student.","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":174,"author":{"gitId":"SebasFok"},"content":" * @param major The new major to set.","lastModifiedDate":"2023-10-30"},{"lineNumber":175,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":176,"author":{"gitId":"ryanlohyr"},"content":" public void setMajor(String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"SebasFok"},"content":" this.major \u003d major;","lastModifiedDate":"2023-10-17"},{"lineNumber":178,"author":{"gitId":"janelleenqi"},"content":" majorModuleCodes \u003d getRequirements(major.toString());","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getModuleCodesLeft () {","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e moduleCodesLeft \u003d new ArrayList\u003cString\u003e();","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e completedModuleCodes \u003d modulesPlanned.getModulesCompleted();","lastModifiedDate":"2023-11-03"},{"lineNumber":184,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"janelleenqi"},"content":" for (String moduleCode: majorModuleCodes) {","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"janelleenqi"},"content":" if (!completedModuleCodes.contains(moduleCode)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"janelleenqi"},"content":" moduleCodesLeft.add(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"janelleenqi"},"content":" return moduleCodesLeft;","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":192,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":193,"author":{"gitId":"janelleenqi"},"content":" public ArrayList\u003cString\u003e getMajorModuleCodes() {","lastModifiedDate":"2023-11-04"},{"lineNumber":194,"author":{"gitId":"janelleenqi"},"content":" return majorModuleCodes;","lastModifiedDate":"2023-11-04"},{"lineNumber":195,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":196,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":197,"author":{"gitId":"janelleenqi"},"content":" public ModuleList getModulesPlanned() {","lastModifiedDate":"2023-11-04"},{"lineNumber":198,"author":{"gitId":"janelleenqi"},"content":" return modulesPlanned;","lastModifiedDate":"2023-11-04"},{"lineNumber":199,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":200,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"SebasFok":84,"ryanlohyr":76,"janelleenqi":40}},{"path":"src/main/java/seedu/duke/models/schema/UserCommands.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public interface UserCommands {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" String EXIT_COMMAND \u003d \"Bye\";","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" String LEFT_COMMAND \u003d \"left\";","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" String PACE_COMMAND \u003d \"pace\";","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":" String PREREQUISITE_COMMAND \u003d \"prereq\";","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":" String RECOMMEND_COMMAND \u003d \"recommend\";","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":" String SET_MAJOR_COMMAND \u003d \"major\";","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" String ADD_MODULE_COMMAND \u003d \"add\";","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" String DELETE_MODULE_COMMAND \u003d \"delete\";","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" String VIEW_SCHEDULE_COMMAND \u003d \"schedule\";","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" String COMPLETE_MODULE_COMMAND \u003d \"complete\";","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" String REQUIRED_MODULES_COMMAND \u003d \"required\";","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" String INFO_COMMAND \u003d \"info\";","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" String SEARCH_MODULE_COMMAND \u003d \"search\";","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" String HELP_COMMAND \u003d \"help\";","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":19}},{"path":"src/main/java/seedu/duke/utils/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.models.schema.Major;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.UserCommands;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.utils.errors.UserError;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"public class Parser {","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" * Parses a user input string to extract and return the main command.","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The user input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" * @return The main command from the input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" public static String parseCommand(String userInput){","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" String[] keywords \u003d userInput.split(\" \");","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" return keywords[0];","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" * Excludes the command and extracts and returns an array of arguments from a user input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The user input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" * @return An array of arguments from the input string.","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" public static String[] parseArguments(String userInput){","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" String[] keywords \u003d userInput.split(\" \");","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" return Arrays.copyOfRange(keywords, 1, keywords.length);","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * Checks if the given academic year input is valid.","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * The academic year should be in the format \"Yn/Sx\", where \u0027n\u0027 represents the year","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" * and \u0027x\u0027 represents the semester (e.g., Y1/S1, Y2/S2).","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" * @author @ryanlohyr","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" * @param userInput The academic year input to be validated.","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" * @return true if the input is a valid academic year, false otherwise.","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" * @throws IllegalArgumentException if the input format is incorrect or if the year or semester is invalid.","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" public static boolean isValidAcademicYear( String userInput ) {","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" String[] parts \u003d userInput.split(\"/\");","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" if(parts.length !\u003d 2){","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Needs to be in format of Y2/S1\");","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" String year \u003d parts[0].toUpperCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" String semester \u003d parts[1].toUpperCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" //last year","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" if(year.equals(\"Y4\") \u0026\u0026 semester.equals(\"S2\")){","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Its your last sem!! A bit too late ya....\");","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" //validate semester","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" if(!semester.equals(\"S1\") \u0026\u0026 !semester.equals(\"S2\")){","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Invalid Semester\");","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" //validate year","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" if (!(year.equals(\"Y1\") || year.equals(\"Y2\") || year.equals(\"Y3\") || year.equals(\"Y4\"))) {","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" // The input is not \"Y1,\" \"Y2,\" \"Y3,\" or \"Y4\"","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" throw new IllegalArgumentException(\"Invalid Year\");","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" public boolean checkNameInput(String userInput, ArrayList\u003cString\u003e forbiddenCommands) {","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" // Check for non-empty string","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" if (userInput.trim().isEmpty()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name cannot be empty. Please enter a valid name.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" // Check for length constraints","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" int minLength \u003d 2; // Minimum length for a valid name","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" int maxLength \u003d 50; // Maximum length for a valid name","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" if (userInput.length() \u003c minLength || userInput.length() \u003e maxLength) {","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name must be between \" + minLength + \" and \" + maxLength + \" characters.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" // Check for valid characters","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" if (!userInput.matches(\"[a-zA-Z- \u0027]+\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name can only contain letters, spaces, hyphens, and apostrophes.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" // Check for no leading or trailing spaces","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" if (!userInput.equals(userInput.trim())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Name cannot start or end with a space.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" if (forbiddenCommands.contains(userInput.trim().toLowerCase())) {","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid name. This name is reserved for commands. Please enter a different name.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"rohitcube"},"content":" * Checks the validity of user input based on the provided command and words array.","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"rohitcube"},"content":" * @param command The command provided by the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" * @param arguments An array of words parsed from the user input.","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"rohitcube"},"content":" * @return True if the input is valid, false otherwise.","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" public static boolean isValidInputForCommand(String command, String[] arguments) {","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":" switch (command) {","lastModifiedDate":"2023-10-28"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.PREREQUISITE_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003c 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-10-28"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-28"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.RECOMMEND_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" //arguments need to be empty","lastModifiedDate":"2023-11-04"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003e 0) {","lastModifiedDate":"2023-11-04"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" return false;","lastModifiedDate":"2023-10-28"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" break;","lastModifiedDate":"2023-10-28"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.SET_MAJOR_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003d\u003d 0) {","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"SebasFok"},"content":" return true;","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003e 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidMajorFormat();","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" Major.valueOf(arguments[0].toUpperCase());","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"SebasFok"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"SebasFok"},"content":" String availableMajors \u003d Arrays.toString(Major.values());","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidMajor(availableMajors);","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.ADD_MODULE_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length !\u003d 2) {","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidAddFormat();","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"SebasFok"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" Integer.parseInt(arguments[1]);","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"SebasFok"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidSemester();","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.DELETE_MODULE_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length !\u003d 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidDeleteFormat();","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"SebasFok"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"SebasFok"},"content":" break;","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"ryanlohyr"},"content":" case UserCommands.INFO_COMMAND: {","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"ryanlohyr"},"content":" if (arguments.length \u003c 1) {","lastModifiedDate":"2023-11-03"},{"lineNumber":174,"author":{"gitId":"ryanlohyr"},"content":" UserError.emptyInputforInfoCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":175,"author":{"gitId":"rohitcube"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"ryanlohyr"},"content":" if (!arguments[0].equals(\"description\") \u0026\u0026 !arguments[0].equals(\"workload\")","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"ryanlohyr"},"content":" \u0026\u0026 !arguments[0].equals(\"all\") \u0026\u0026 !arguments[0].equals(\"requirements\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"ryanlohyr"},"content":" UserError.invalidCommandforInfoCommand();","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"rohitcube"},"content":" return false;","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"rohitcube"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" default: {","lastModifiedDate":"2023-10-28"},{"lineNumber":186,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-10-28"},{"lineNumber":187,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":188,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":189,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":190,"author":{"gitId":"ryanlohyr"},"content":" return true;","lastModifiedDate":"2023-10-28"},{"lineNumber":191,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":192,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":193,"author":{"gitId":"rohitcube"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"rohitcube"},"content":" * Checks the validity of keyword input for a search command.","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"rohitcube"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"rohitcube"},"content":" * @author rohitcube","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"rohitcube"},"content":" * @param userInput The user input string containing the search command and keywords.","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"rohitcube"},"content":" * @return True if the keyword input is valid, false otherwise.","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"rohitcube"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"rohitcube"},"content":" public static boolean isValidKeywordInput(String userInput) {","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"rohitcube"},"content":" String keywords \u003d userInput.substring(userInput.indexOf(\"search\") + 6);","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"rohitcube"},"content":" // need to add a function to make search case-insensitive","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"rohitcube"},"content":" return !keywords.trim().isEmpty();","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"SebasFok":26,"ryanlohyr":155,"rohitcube":26}},{"path":"src/main/java/seedu/duke/utils/UnknownCommandException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"public class UnknownCommandException extends Exception{","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"rohitcube"},"content":" public UnknownCommandException(String command) {","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"rohitcube"},"content":" super(\"Unknown command: \" + command);","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"ryanlohyr":1,"rohitcube":6}},{"path":"src/main/java/seedu/duke/utils/errors/ClassError.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils.errors;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public class ClassError {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" public static void defaultClassError(Object message){","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(message);","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":7}},{"path":"src/main/java/seedu/duke/utils/errors/HttpError.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils.errors;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public class HttpError {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":5}},{"path":"src/main/java/seedu/duke/utils/errors/UserError.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.utils.errors;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"public class UserError {","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":" public static void invalidInput(){","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Invalid Input provided\");","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":" public static void invalidMajorFormat() {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please select a major using this format: major [major]\");","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"To check your current major, type: major\");","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":" public static void invalidMajor(String availableMajors) {","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please select a major from this list: \" + availableMajors);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" public static void invalidModule(String moduleCode){","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" String response \u003d String.format(\"Sorry, Module %s does not exist\",moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(response);","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" public static void displayInvalidInputCommand(String command){","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" String response \u003d String.format(\"Invalid command %s. Type help to see the available commands\",command);","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(response);","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" public static void displayInvalidMethodCommand(String command){","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" String response \u003d String.format(\"Invalid argument for command %s\", command);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(response);","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"SebasFok"},"content":" public static void invalidAddFormat() {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please add a module using this format: add [module code] [semester]\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"SebasFok"},"content":" public static void invalidSemester() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please select an integer from 1 to 8 for semester selection\");","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":" public static void invalidDeleteFormat() {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"Please delete a module using this format: delete [module code]\");","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"rohitcube"},"content":" public static void emptyInputforInfoCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Empty input detected. Please enter a valid input after the info command.\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"rohitcube"},"content":" \" (E.g description, workload, all)\");","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"rohitcube"},"content":" public static void invalidCommandforInfoCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Please enter a valid command after the info command. (E.g description, workload, all)\");","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"rohitcube"},"content":" public static void emptyKeywordforSearchCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Empty input detected. Please enter a valid keyword after the search command.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"rohitcube"},"content":" public static void emptyArrayforSearchCommand() {","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"rohitcube"},"content":" System.out.println(\"Oops! Your search results came up empty. Please try searching with different keywords.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"janelleenqi"},"content":" public static void emptyMajor() {","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"janelleenqi"},"content":" System.out.println(\"Major has not been provided yet.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"janelleenqi"},"content":" public static void moduleDoesNotExist(String moduleCode) {","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"janelleenqi"},"content":" System.out.println(moduleCode + \"does not exist in your schedule.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"SebasFok":18,"ryanlohyr":23,"janelleenqi":8,"rohitcube":18}},{"path":"src/main/java/seedu/duke/views/CommandLineView.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.views;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.CommandManager;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"import static seedu.duke.models.logic.Api.getModulePrereqBasedOnCourse;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"public class CommandLineView {","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" public static void displayWelcome(){","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" String logo \u003d \" ____ _ \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" + \"| _ \\\\ _ _| | _____ \\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" + \"| | | | | | | |/ / _ \\\\\\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" + \"| |_| | |_| | \u003c __/\\n\"","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" + \"|____/ \\\\__,_|_|\\\\_\\\\___|\\n\";","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Hello from\\n\" + logo);","lastModifiedDate":"2023-10-12"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" public static void displayGoodbye(){","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Goodbye.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" public static void displayReady(){","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Now you\u0027re all set to use NUSDegs to kick start your degree planning!\");","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" displayHelp();","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" public static void displayHelp(){","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Type \u0027help\u0027 to see the available commands\");","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" public static void displayGetMajor(String name){","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"Welcome \" + name + \"! What major are you? (Only two available: CEG or CS)\");","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" public static void displayGetYear(){","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"What Year and Semester are you? Ex: Y1/S2 for year 1 semester 2\");","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" public static void handleMajorMessage(int userInputLength, String major) {","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" assert (userInputLength \u003d\u003d 0 || userInputLength \u003d\u003d 1);","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" if (userInputLength \u003d\u003d 0) {","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" if (major \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"No major selected!\");","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"SebasFok"},"content":" return;","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Current major is \" + major + \".\");","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"SebasFok"},"content":" return;","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Major \" + major + \" selected!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" public static void printListOfCommands(CommandManager commandManager) {","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" for (String command : commandManager.printListOfCommands()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(command);","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" public static void showPrereqCEG(String module) {","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"SebasFok"},"content":" System.out.println(\"This module\u0027s prerequisites are \"","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"SebasFok"},"content":" + getModulePrereqBasedOnCourse(module.toUpperCase(),\"CEG\"));","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" public static void displaySuccessfulAddMessage() {","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Module Successfully Added\");","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" public static void displaySuccessfulDeleteMessage() {","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"SebasFok"},"content":" displayMessage(\"Module Successfully Deleted\");","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"SebasFok"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"SebasFok"},"content":" * Display a message to the command line view.","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"SebasFok"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"SebasFok"},"content":" * @param o The object to be displayed.","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"SebasFok"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" public static void displayMessage(Object o) {","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"SebasFok"},"content":" System.out.println(o);","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" public static void printNewline(){","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":" System.out.println();","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"SebasFok":32,"ryanlohyr":53,"janelleenqi":1}},{"path":"src/main/java/seedu/duke/views/ModuleInfoView.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.views;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.json.simple.JSONArray;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Module;","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"public class ModuleInfoView {","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" public static void print(String output) {","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(output);","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" public static void printLine() {","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(\"_________________________________________\");","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":" public static void printJsonArray(JSONArray modules) {","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":" for (Object module: modules) {","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":" JSONObject castedModule \u003d (JSONObject) module;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":" print(\"Title: \" + (String)castedModule.get(\"title\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":" print(\"Module Code: \" + (String)castedModule.get(\"moduleCode\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":" printLine();","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":" public static void searchHeader() {","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":" printLine();","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" print(\"These are the modules that contain your keyword in the title:\");","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" print(\"\");","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" * Print a list of modules in columns with a specified maximum height.","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" * @param modules An ArrayList of module names to be printed.","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" public static void printModuleStringArray(ArrayList\u003cString\u003e modules){","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" int maxColumnHeight \u003d 5;","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" for (int i \u003d 0; i \u003c modules.size(); i +\u003d maxColumnHeight) {","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":" for (int j \u003d 0; j \u003c maxColumnHeight \u0026\u0026 i + j \u003c modules.size(); j++) {","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d (i + j + 1) + \". \" + modules.get(i + j);","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" System.out.printf(\"%-15s\", module);","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" System.out.println();","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" * Print a list of modules in columns with a specified maximum height.","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" * @author ryanlohyr","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" * @param modules An ArrayList of module names to be printed.","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" public static void printModuleArray(ArrayList\u003cModule\u003e modules){","lastModifiedDate":"2023-11-04"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" int maxColumnHeight \u003d 5;","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" for (int i \u003d 0; i \u003c modules.size(); i +\u003d maxColumnHeight) {","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":" for (int j \u003d 0; j \u003c maxColumnHeight \u0026\u0026 i + j \u003c modules.size(); j++) {","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" String module \u003d (i + j + 1) + \". \" + modules.get(i + j);","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" System.out.printf(\"%-15s\", module);","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" System.out.println();","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"ryanlohyr":67}},{"path":"src/test/java/seedu/duke/ApiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"rohitcube"},"content":"package seedu.duke;","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONArray;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"rohitcube"},"content":"import org.json.simple.JSONObject;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.logic.Api;","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"rohitcube"},"content":"import java.util.Objects;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"rohitcube"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.views.ModuleInfoView;","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"rohitcube"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"rohitcube"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"rohitcube"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"rohitcube"},"content":"public class ApiTest {","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"rohitcube"},"content":" void testGetModuleInfo_shouldReturnTrueForCS2113() {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"rohitcube"},"content":" String correctModuleInfo \u003d \"\\\"description\\\":\\\"This course introduces the necessary skills for systematic \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"rohitcube"},"content":" \"and rigorous development of software systems. It covers\";","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d \"CS2113\";","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"rohitcube"},"content":" String moduleInfo \u003d null;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"rohitcube"},"content":" moduleInfo \u003d Objects.requireNonNull(Api.getFullModuleInfo(moduleCode)).toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"rohitcube"},"content":" assertNotNull(moduleInfo, \"Module info should not be null\");","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"rohitcube"},"content":" assertTrue(moduleInfo.contains(correctModuleInfo), \"Module info should contain relevant info\");","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"rohitcube"},"content":" void testGetDescription_shouldReturnEquals() {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"rohitcube"},"content":" String correctDescription \u003d \"This course introduces the necessary skills for systematic and \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"rohitcube"},"content":" \"rigorous development of software systems. It covers requirements, design, implementation, \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"rohitcube"},"content":" \"quality assurance, and project management aspects of small-to-medium size multi-person software\" +","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"rohitcube"},"content":" \" projects. The course uses the Object Oriented Programming paradigm. Students of this course will \" +","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"rohitcube"},"content":" \"receive hands-on practice of tools commonly used in the industry, such as test automation tools,\" +","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"rohitcube"},"content":" \" build automation tools, and code revisioning tools will be covered.\";","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"rohitcube"},"content":" String moduleCode \u003d \"CS2113\";","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"rohitcube"},"content":" String description \u003d Api.getDescription(moduleCode);","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"rohitcube"},"content":" assertEquals(correctDescription, description);","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"rohitcube"},"content":" void testGetWorkload_shouldReturnCorrectValue() {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"rohitcube"},"content":" // uses unchecked or unsafe operations, Note: Recompile with -Xlint:unchecked for details.","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"rohitcube"},"content":" JSONArray workload \u003d Api.getWorkload(\"CS2113\");","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"rohitcube"},"content":" JSONArray jsonArray \u003d new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(2);","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(0);","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(3);","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"rohitcube"},"content":" jsonArray.add(4);","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"rohitcube"},"content":" String jsonString1 \u003d jsonArray.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"rohitcube"},"content":" String jsonString2 \u003d workload.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"rohitcube"},"content":" assertEquals(jsonString2, jsonString1);","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"rohitcube"},"content":" void testListAllModules() {","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"rohitcube"},"content":" Api.listAllModules();","lastModifiedDate":"2023-10-28"},{"lineNumber":61,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":64,"author":{"gitId":"rohitcube"},"content":" void testSearchModules_emptyInput_expectedEmptyJsonArray() {","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint;","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"rohitcube"},"content":" modulesToPrint \u003d Api.search(\" \", Api.listAllModules());","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"rohitcube"},"content":" assertEquals(0, modulesToPrint.size(), \"The JSON array should be empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"rohitcube"},"content":" void testSearchModules_invalidInput_expectedEmptyJsonArray() {","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint;","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"rohitcube"},"content":" modulesToPrint \u003d Api.search(\"bs#4%ggh\", Api.listAllModules());","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"rohitcube"},"content":" assertEquals(0, modulesToPrint.size(), \"The JSON array should be empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"rohitcube"},"content":" void testSearchModules_validInput_expectedJsonArray() {","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint;","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"rohitcube"},"content":" modulesToPrint \u003d Api.search(\"Trustworthy Machine Learning\", Api.listAllModules());","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"rohitcube"},"content":" JSONArray expectedArray \u003d new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"rohitcube"},"content":" JSONObject expectedObject \u003d new JSONObject();","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"rohitcube"},"content":" expectedObject.put(\"moduleCode\", \"CS5562\");","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"rohitcube"},"content":" JSONArray semester1 \u003d new JSONArray();","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"rohitcube"},"content":" semester1.add(1);","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"rohitcube"},"content":" expectedObject.put(\"semesters\", semester1);","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"rohitcube"},"content":" expectedObject.put(\"title\", \"Trustworthy Machine Learning\");","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"rohitcube"},"content":" expectedArray.add(expectedObject);","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"rohitcube"},"content":" String expectedOutput \u003d expectedArray.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"rohitcube"},"content":" String output \u003d modulesToPrint.toJSONString();","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"rohitcube"},"content":" assertEquals(expectedOutput, output, \"The string should be equal\");","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":93,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":94,"author":{"gitId":"rohitcube"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":95,"author":{"gitId":"rohitcube"},"content":" void testPrintJsonArray() {","lastModifiedDate":"2023-10-28"},{"lineNumber":96,"author":{"gitId":"rohitcube"},"content":" JSONArray modulesToPrint \u003d Api.search(\"Machine Learning\", Api.listAllModules());","lastModifiedDate":"2023-10-28"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" ModuleInfoView.printJsonArray(modulesToPrint);","lastModifiedDate":"2023-11-04"},{"lineNumber":98,"author":{"gitId":"rohitcube"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":99,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":100,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"rohitcube"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":102,"author":{"gitId":"rohitcube"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ryanlohyr":3,"rohitcube":99}},{"path":"src/test/java/seedu/duke/controllers/ModuleMethodsControllerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.controllers;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Schedule;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"import seedu.duke.models.schema.Student;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.computePace;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleMethodsController.determinePrereq;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.ScheduleGenerator.generateRecommendedSchedule;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displayMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.displaySuccessfulAddMessage;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.views.CommandLineView.showPrereqCEG;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"ryanlohyr"},"content":"class ModuleMethodsControllerTest {","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"ryanlohyr"},"content":" private final ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"ryanlohyr"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"ryanlohyr"},"content":" private Student student;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"ryanlohyr"},"content":" @BeforeEach","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"ryanlohyr"},"content":" public void setUpStreams() {","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"ryanlohyr"},"content":" this.student \u003d new Student();","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"ryanlohyr"},"content":" student.setName(\"Ryan Loh\");","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"ryanlohyr"},"content":" student.setFirstMajor(\"CEG\");","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"ryanlohyr"},"content":" student.setYear(\"Y2/S1\");","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ryanlohyr"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"ryanlohyr"},"content":" @AfterEach","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"ryanlohyr"},"content":" public void restoreStreams() {","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"ryanlohyr"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"ryanlohyr"},"content":" void computePaceWithoutArgument() {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {};","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"ryanlohyr"},"content":" int creditsCompleted \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsCompleted);","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(String.format(\"You currently have %s MCs till graduation\", 160 - 60), printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"ryanlohyr"},"content":" void computePaceInvalidArgument() {","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y2s1\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(\"Needs to be in format of Y2/S1\", printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"ryanlohyr"},"content":" void computePaceInvalidSemester() {","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"ryanlohyr"},"content":" ModulePlannerController controller \u003d new ModulePlannerController();","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y2/s10\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":76,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":77,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":78,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":80,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":81,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(\"Invalid Semester\", printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":82,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":83,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":84,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ryanlohyr"},"content":" void computePaceInvalidYear() {","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y20/s1\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":87,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(\"Invalid Year\", printedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"ryanlohyr"},"content":" void computePaceValidYear() {","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"ryanlohyr"},"content":" String[] userInput \u003d {\"y2/s1\"};","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"ryanlohyr"},"content":" int creditsLeft \u003d 60;","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"ryanlohyr"},"content":" computePace(userInput, creditsLeft);","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"ryanlohyr"},"content":" // Capture the printed output","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"ryanlohyr"},"content":" String line \u003d \"You have 100MCs for 5 semesters. Recommended Pace: 20MCs per sem until graduation\";","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"ryanlohyr"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, line);","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"ryanlohyr"},"content":" void determinePrereq_invalidModuleCode() {","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"ryanlohyr"},"content":" String invalidModuleCode \u003d \"cs134.\";","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"ryanlohyr"},"content":" String major \u003d \"CEG\";","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(invalidModuleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"ryanlohyr"},"content":" String expectedResponse \u003d \"Invalid Module Code :Only alphabets and digits are allowed in module codes!\";","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedResponse);","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"ryanlohyr"},"content":" void determinePrereq_validModuleCodeWithNoPreReq() {","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"ryanlohyr"},"content":" String invalidModuleCode \u003d \"GEN2061\";","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"ryanlohyr"},"content":" String major \u003d \"CEG\";","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(invalidModuleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"ryanlohyr"},"content":" String expectedResponse \u003d \"Module GEN2061 has no prerequisites.\";","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedResponse);","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"ryanlohyr"},"content":" void determinePrereq_validModuleCodeWithPreReq() {","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"ryanlohyr"},"content":" String invalidModuleCode \u003d \"EE2211\";","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"ryanlohyr"},"content":" String major \u003d \"CEG\";","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"ryanlohyr"},"content":" determinePrereq(invalidModuleCode, major);","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"ryanlohyr"},"content":" String expectedResponse \u003d \"[CS1010, MA1511, MA1508E]\";","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedResponse);","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"ryanlohyr"},"content":" void testPrereq_addValidModuleToStudent() throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"ryanlohyr"},"content":" String moduleCode \u003d \"EG1311\";","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"ryanlohyr"},"content":" boolean doesModuleExist \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(moduleCode, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":144,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"ryanlohyr"},"content":" Schedule currentSchedule \u003d student.getSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"ryanlohyr"},"content":" doesModuleExist \u003d currentSchedule.exists(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Module Successfully Added\\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 1: EG1311 \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 2: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 3: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 4: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 5: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 6: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 7: \\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":163,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 8:\";","lastModifiedDate":"2023-11-03"},{"lineNumber":164,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":165,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":166,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":169,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":170,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":171,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":172,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":173,"author":{"gitId":"ryanlohyr"},"content":" assertTrue(doesModuleExist);","lastModifiedDate":"2023-11-03"},{"lineNumber":174,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":175,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":177,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"ryanlohyr"},"content":" void testPrereq_addInValidModuleToStudent() throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"ryanlohyr"},"content":" String moduleCode \u003d \"eEG1311\";","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"ryanlohyr"},"content":" boolean doesModuleExist \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(moduleCode, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":184,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"ryanlohyr"},"content":" Schedule currentSchedule \u003d student.getSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"ryanlohyr"},"content":" doesModuleExist \u003d currentSchedule.exists(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":192,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":193,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":194,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":195,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Invalid Module Name\\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":196,"author":{"gitId":"ryanlohyr"},"content":" \"Please select a valid module\";","lastModifiedDate":"2023-11-03"},{"lineNumber":197,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":198,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":199,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":200,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":201,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":203,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":204,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":205,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":206,"author":{"gitId":"ryanlohyr"},"content":" assertFalse(doesModuleExist);","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":210,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":211,"author":{"gitId":"ryanlohyr"},"content":" void testPrereq_addInvalidModuleToStudent() throws InvalidObjectException {","lastModifiedDate":"2023-11-03"},{"lineNumber":212,"author":{"gitId":"ryanlohyr"},"content":" String moduleCode \u003d \"CS2113\";","lastModifiedDate":"2023-11-03"},{"lineNumber":213,"author":{"gitId":"ryanlohyr"},"content":" int targetSem \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"ryanlohyr"},"content":" boolean doesModuleExist \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":215,"author":{"gitId":"ryanlohyr"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":216,"author":{"gitId":"janelleenqi"},"content":" student.addModuleSchedule(moduleCode, targetSem);","lastModifiedDate":"2023-11-04"},{"lineNumber":217,"author":{"gitId":"ryanlohyr"},"content":" displaySuccessfulAddMessage();","lastModifiedDate":"2023-11-03"},{"lineNumber":218,"author":{"gitId":"ryanlohyr"},"content":" student.printSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":219,"author":{"gitId":"ryanlohyr"},"content":" Schedule currentSchedule \u003d student.getSchedule();","lastModifiedDate":"2023-11-03"},{"lineNumber":220,"author":{"gitId":"ryanlohyr"},"content":" doesModuleExist \u003d currentSchedule.exists(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"ryanlohyr"},"content":" } catch (InvalidObjectException | IllegalArgumentException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(e.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"ryanlohyr"},"content":" } catch (FailPrereqException f) {","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"ryanlohyr"},"content":" showPrereqCEG(moduleCode);","lastModifiedDate":"2023-11-03"},{"lineNumber":225,"author":{"gitId":"ryanlohyr"},"content":" displayMessage(f.getMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":226,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":227,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":228,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"This module\u0027s prerequisites are [CS2040C]\\n\" +","lastModifiedDate":"2023-11-03"},{"lineNumber":229,"author":{"gitId":"ryanlohyr"},"content":" \"Unable to add module as prerequisites not satisfied for: CS2113\";","lastModifiedDate":"2023-11-03"},{"lineNumber":230,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":231,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":232,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":233,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-03"},{"lineNumber":234,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-03"},{"lineNumber":235,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-03"},{"lineNumber":236,"author":{"gitId":"ryanlohyr"},"content":" assertFalse(doesModuleExist);","lastModifiedDate":"2023-11-03"},{"lineNumber":237,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(printedOutput, expectedOutput);","lastModifiedDate":"2023-11-03"},{"lineNumber":238,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":239,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":240,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":241,"author":{"gitId":"ryanlohyr"},"content":" void testRecommend_generateCEGRecommendedSchedule() {","lastModifiedDate":"2023-11-04"},{"lineNumber":242,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(student.getMajor());","lastModifiedDate":"2023-11-04"},{"lineNumber":243,"author":{"gitId":"ryanlohyr"},"content":" System.out.println(recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":244,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":245,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"[GEA1000, MA1511, MA1512, DTK1234, GESS1000, CS1010, GEN2000, EG2501, EG1311\"","lastModifiedDate":"2023-11-04"},{"lineNumber":246,"author":{"gitId":"ryanlohyr"},"content":" + \", GEC1000, PF1101, CDE2000, IE2141, CG1111A, EG2401A, ES2631, ST2334, MA1508E, CS1231, CG2023, \"","lastModifiedDate":"2023-11-04"},{"lineNumber":247,"author":{"gitId":"ryanlohyr"},"content":" + \"CG2111A, CS2040C, CG2027, EE2026, EE4204, EE2211, CG2271, CS2113, CG2028, CP3880, CG4002]\";","lastModifiedDate":"2023-11-04"},{"lineNumber":248,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(expectedOutput, printedOutput);","lastModifiedDate":"2023-11-04"},{"lineNumber":249,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":250,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":251,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":252,"author":{"gitId":"ryanlohyr"},"content":" void testRecommend_addCEGRecommendedScheduleToStudent() {","lastModifiedDate":"2023-11-04"},{"lineNumber":253,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(\"CEG\");","lastModifiedDate":"2023-11-04"},{"lineNumber":254,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().addRecommendedScheduleListToSchedule(recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":255,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().printMainModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":256,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":257,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Sem 1: GESS1000 DTK1234 MA1512 MA1511 GEA1000 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":258,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 2: GEC1000 EG1311 EG2501 GEN2000 CS1010 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":259,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 3: EG2401A CG1111A IE2141 CDE2000 PF1101 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":260,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 4: CG2023 CS1231 MA1508E ST2334 ES2631 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":261,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 5: EE4204 EE2026 CG2027 CS2040C CG2111A \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":262,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 6: CG2028 CS2113 CG2271 EE2211 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":263,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 7: CG4002 CP3880 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":264,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 8:\";","lastModifiedDate":"2023-11-04"},{"lineNumber":265,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":266,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":267,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":268,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":269,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":270,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":271,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":272,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":273,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":274,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(expectedOutput, printedOutput);","lastModifiedDate":"2023-11-04"},{"lineNumber":275,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":276,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":277,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":278,"author":{"gitId":"ryanlohyr"},"content":" void testRecommend_addCSRecommendedScheduleToStudent() {","lastModifiedDate":"2023-11-04"},{"lineNumber":279,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e recommendedSchedule \u003d generateRecommendedSchedule(\"CS\");","lastModifiedDate":"2023-11-04"},{"lineNumber":280,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().addRecommendedScheduleListToSchedule(recommendedSchedule);","lastModifiedDate":"2023-11-04"},{"lineNumber":281,"author":{"gitId":"ryanlohyr"},"content":" student.getSchedule().printMainModuleList();","lastModifiedDate":"2023-11-04"},{"lineNumber":282,"author":{"gitId":"ryanlohyr"},"content":" String printedOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":283,"author":{"gitId":"ryanlohyr"},"content":" String expectedOutput \u003d \"Sem 1: CS1231S MA1522 IS1108 MA1521 GEA1000 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":284,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 2: GEN2000 GESS1000 CS1101S CS2101 ES2660 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":285,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 3: CS2100 CS2040S CS2030S ST2334 GEC1000 \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":286,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 4: CS2103T \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":287,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 5: CP3880 CS2106 CS3230 CS2109S \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":288,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 6: \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":289,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 7: \\n\" +","lastModifiedDate":"2023-11-04"},{"lineNumber":290,"author":{"gitId":"ryanlohyr"},"content":" \"Sem 8:\";","lastModifiedDate":"2023-11-04"},{"lineNumber":291,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":292,"author":{"gitId":"ryanlohyr"},"content":" printedOutput \u003d printedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":293,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":294,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":295,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":296,"author":{"gitId":"ryanlohyr"},"content":" expectedOutput \u003d expectedOutput","lastModifiedDate":"2023-11-04"},{"lineNumber":297,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\\n\", \"\\n\")","lastModifiedDate":"2023-11-04"},{"lineNumber":298,"author":{"gitId":"ryanlohyr"},"content":" .replaceAll(\"\\r\", \"\\n\");","lastModifiedDate":"2023-11-04"},{"lineNumber":299,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":300,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(expectedOutput, printedOutput);","lastModifiedDate":"2023-11-04"},{"lineNumber":301,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":302,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":303,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":304,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"ryanlohyr":301,"janelleenqi":3}},{"path":"src/test/java/seedu/duke/models/logic/DataRepositoryTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":"class DataRepositoryTest {","lastModifiedDate":"2023-10-28"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-10-28"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" void validRequirementsReturned() {","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e cegRequirementArray \u003d DataRepository.getRequirements(\"CEG\");","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" int numberOfRequiredCegMods \u003d 31;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":" assertEquals(numberOfRequiredCegMods,cegRequirementArray.size());","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"ryanlohyr":17}},{"path":"src/test/java/seedu/duke/models/logic/MajorRequirementsTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"janelleenqi"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.controllers.ModuleServiceController.getRequiredModules;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":"class MajorRequirementsTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" private final ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" public void setUpStreams() {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" @AfterEach","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" public void restoreStreams() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" void printRequiredModules_validMajor_expectRequiredModulesShown() {","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"ryanlohyr"},"content":" getRequiredModules(\"CEG\");","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" // Capture the printed output","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" String printedOutput \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" // Assert the printed output matches the expected value","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" assertTrue(printedOutput.startsWith(","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" \"#\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d#\")","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" );","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"ryanlohyr":2,"janelleenqi":38}},{"path":"src/test/java/seedu/duke/models/logic/ScheduleGeneratorTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ryanlohyr"},"content":"package seedu.duke.models.logic;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"ryanlohyr"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"ryanlohyr"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"ryanlohyr"},"content":"import static seedu.duke.models.logic.ScheduleGenerator.generateRecommendedSchedule;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"ryanlohyr"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"ryanlohyr"},"content":"class ScheduleGeneratorTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"ryanlohyr"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"ryanlohyr"},"content":" void validRecommendedSchedule() {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"ryanlohyr"},"content":" ArrayList\u003cString\u003e cegRequirementArray \u003d generateRecommendedSchedule(\"CEG\");","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"ryanlohyr"},"content":" assert(!cegRequirementArray.isEmpty());","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"ryanlohyr"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"ryanlohyr"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"ryanlohyr":15}},{"path":"src/test/java/seedu/duke/models/schema/ModuleListTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"import java.io.InvalidObjectException;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":"class ModuleListTest {","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":" //success scenario 1: 1 input String, 1 ModuleList that contains input String --\u003e true","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" void existsTest_moduleListContainsModule_expectTrue() throws InvalidObjectException {","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" String inputString \u003d \"CS1231S\";","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList(\"CS1231S CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230\");","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" boolean result \u003d ml.exists(inputString);","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" assertTrue(result);","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" //success scenario 2: 1 input String, 1 ModuleList that does not contain input String --\u003e false","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" void existsTest_moduleListDoesNotContainModule_expectFalse() throws InvalidObjectException {","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":" String inputString \u003d \"CS1231S\";","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList(\"CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230\");","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" boolean result \u003d ml.exists(inputString);","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" assertFalse(result);","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" //failure scenario 1: input null string, 1 ModuleList --\u003e throw exception","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" void existsTest_nullInput_expectException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList(\"CS2030S CS2040S CS2100 CS2101 CS2106 CS2109S CS3230\");","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"janelleenqi"},"content":" assertThrows(InvalidObjectException.class, () -\u003e ml.exists(null));","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"janelleenqi"},"content":" //success scenario 3: input string, 1 empty ModuleList --\u003e false","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"janelleenqi"},"content":" void existsTest_nullMainModuleList_expectException() throws InvalidObjectException {","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"janelleenqi"},"content":" String inputString \u003d \"CS1231S\";","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"janelleenqi"},"content":" ModuleList ml \u003d new ModuleList();","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"janelleenqi"},"content":" //test","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"janelleenqi"},"content":" boolean result \u003d ml.exists(inputString);","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"janelleenqi"},"content":" assertFalse(result);","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"janelleenqi"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"SebasFok":1,"janelleenqi":53}},{"path":"src/test/java/seedu/duke/models/schema/ScheduleTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"SebasFok"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"SebasFok"},"content":"import seedu.duke.exceptions.FailPrereqException;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"SebasFok"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"SebasFok"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"SebasFok"},"content":"class ScheduleTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"SebasFok"},"content":" //success scenario: String containing valid module, int containing valid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"SebasFok"},"content":" //module satisfies prereqs --\u003e module added","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_correctInputsSatisfyPrereqs_expectModuleAdded() throws Exception {","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule();","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"SebasFok"},"content":" schedule.addModule(\"CS1010\", 1);","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"SebasFok"},"content":" ArrayList\u003cString\u003e testArray\u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"SebasFok"},"content":" testArray.add(\"CS1010\");","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" assertEquals(testArray, schedule.getModuleCodes());","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"SebasFok"},"content":" //failure scenario 1: String containing valid module, int containing valid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"SebasFok"},"content":" //module does not satisfy prereqs --\u003e throw FailPrereqException","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_correctInputsDoesNotSatisfyPrereqs_expectException() {","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule(\"CS1231S MA1511\", new int[]{2, 0, 0, 0, 0, 0, 0, 0});","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"SebasFok"},"content":" assertThrows(FailPrereqException.class, () -\u003e schedule.addModule(\"CS2040C\", 1));","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"SebasFok"},"content":" //failure scenario 2: String containing invalid module, int containing valid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"SebasFok"},"content":" //--\u003e throws IllegalArgumentException","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_invalidModule_expectException() {","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule(\"CS1231S MA1511\", new int[]{2, 0, 0, 0, 0, 0, 0, 0});","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"SebasFok"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e schedule.addModule(\"wrong\", 1));","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"SebasFok"},"content":" //failure scenario 3: String containing valid module, int containing invalid targetSem","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"SebasFok"},"content":" //--\u003e throws IllegalArgumentException","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"SebasFok"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"SebasFok"},"content":" void addModuleTest_invalidTargetSem_expectException() {","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"SebasFok"},"content":" Schedule schedule \u003d new Schedule(\"CS1231S MA1511\", new int[]{2, 0, 0, 0, 0, 0, 0, 0});","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"SebasFok"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e schedule.addModule(\"CS2040C\", 1000));","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"SebasFok"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"SebasFok":50,"janelleenqi":1}},{"path":"src/test/java/seedu/duke/models/schema/StudentTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"SebasFok"},"content":"package seedu.duke.models.schema;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"janelleenqi"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"janelleenqi"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"janelleenqi"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"SebasFok"},"content":"public class StudentTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"SebasFok"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"janelleenqi"},"content":" //success scenario: difference (not working)","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"janelleenqi"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"janelleenqi"},"content":" void getModuleCodesLeft_majorSet_expectArrayList() {","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"janelleenqi"},"content":" Student student \u003d new Student();","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"janelleenqi"},"content":" student.setMajor(\"CEG\");","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"janelleenqi"},"content":" //actual: student.getModuleCodesLeft();","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"janelleenqi"},"content":" //expected:","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e expected \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e majorModuleCodes \u003d student.getMajorModuleCodes();","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"janelleenqi"},"content":" ArrayList\u003cString\u003e modulesInPlanner \u003d student.getModulesPlanned().getModulesCompleted();","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"janelleenqi"},"content":" for (String moduleCode : majorModuleCodes) {","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"janelleenqi"},"content":" if (!modulesInPlanner.contains(moduleCode)) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"janelleenqi"},"content":" expected.add(moduleCode);","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"janelleenqi"},"content":" assertEquals(expected, student.getModuleCodesLeft());","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"janelleenqi"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"janelleenqi"},"content":" // getModuleCodesLeft_noMajorSet_expectException()","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"janelleenqi"},"content":" // getDifferenceTest_twoModuleList_expectDifference()","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"janelleenqi"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"janelleenqi"},"content":" // success scenario 2: 1 empty ModuleList, 1 ModuleList --\u003e difference which is empty","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"janelleenqi"},"content":" // getDifferenceTest_oneEmptyModuleListAnotherModuleList_expectEmptyDifference()","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"janelleenqi"},"content":" // failure scenario 1: null ModuleList input --\u003e throw exception","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"janelleenqi"},"content":" // getDifferenceTest_nullModuleListInput_expectException()","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"SebasFok"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"SebasFok":5,"janelleenqi":33}}] diff --git a/AY2324S1-CS2113-T17-4_tp_master/commits.json b/AY2324S1-CS2113-T17-4_tp_master/commits.json index 56ec690..fdcef03 100644 --- a/AY2324S1-CS2113-T17-4_tp_master/commits.json +++ b/AY2324S1-CS2113-T17-4_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"SebasFok":[{"date":"2023-10-05","commitResults":[{"hash":"aeef6fad05b0f6d0f0c354e9db79ba3ecbdfbef9","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-06","commitResults":[{"hash":"2039386c7d8e661b4e7bf66f1d4fa3ea80da23ac","isMergeCommit":false,"messageTitle":"Add AboutUs information for Sebastian","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}}]},{"date":"2023-10-07","commitResults":[{"hash":"de8365c98e9274e9c7b40228f5c687bbb7774a2e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-08","commitResults":[{"hash":"a728f005673371e58b95131d45ece32ea30c5cf6","isMergeCommit":true,"messageTitle":"Merge pull request #4 from janelleenqi/branch-Edit-AboutUs-v1","messageBody":"janelleenqi-AboutUs","fileTypesAndContributionMap":{}},{"hash":"a53713ffad1e3c43fb6821740bbbae2f0b934975","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2336e0f03aede437eefc987d98349c05b02aecc3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-4/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5677d80546a6e55ae3fc9b3c2f9efc6cc36ddfbc","isMergeCommit":true,"messageTitle":"Merge pull request #5 from ryanlohyr/master","messageBody":"Ryanlohyr-AboutUs","fileTypesAndContributionMap":{}},{"hash":"f10394ae22fddfcc20621826cb53a03dd516d990","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-4/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"0d840309811b905770039ac8ee89b6c803eb14ee","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9c3ef1f3c1cd7136c584fdbcd2b00be6f53e8069","isMergeCommit":false,"messageTitle":"Fix AboutUs page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"d97257fe38507e38b90b874e965ec94cc6b5c00a","isMergeCommit":false,"messageTitle":"Revert \"Fix AboutUs page\"","messageBody":"This reverts commit 9c3ef1f3c1cd7136c584fdbcd2b00be6f53e8069.\n","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"d0a5cf6d3dab23e3ab691ed2f8a77ddb0e301864","isMergeCommit":false,"messageTitle":"Fix AboutUs page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"a6429ace4f7089682cc2c231fd5a974b2abacea8","isMergeCommit":true,"messageTitle":"Merge pull request #8 from SebasFok/branch-FixAboutUs","messageBody":"Fix about us page","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"be9eda9ae041c25d60d33065384ebbafb11b421b","isMergeCommit":false,"messageTitle":"Add student class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0}}},{"hash":"f37c8d8033f4f5340abf8af3f6cfee7194242bee","isMergeCommit":false,"messageTitle":"Add \"major\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"2ed39fab10850f7beac9b1dea7710dab4ee3b966","isMergeCommit":false,"messageTitle":"Add enum for majors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":8}}},{"hash":"a777fd584c0ae40bcd4d764c056dde18112af52d","isMergeCommit":false,"messageTitle":"Add tests for \u0027updateMajor\u0027 function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":26,"deletions":0}}},{"hash":"88ac029553890db8c4945a2fd9d5dce17ff67011","isMergeCommit":false,"messageTitle":"Remove unused imports","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"20e6817a7cccc59b82ffed3fccf09a44a67b767c","isMergeCommit":true,"messageTitle":"Merge pull request #16 from SebasFok/branch-SelectMajor","messageBody":"Add major feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"f8bdc1bbed8355ad7010bcf3a1dfe6a49b2ac42d","isMergeCommit":false,"messageTitle":"Fix Major command bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":11},"test-code":{"insertions":34,"deletions":24}}},{"hash":"1fd6f85f957f1380b71520ff1ccca4efea83951c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok-FixMajor","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/duke/controllers/ModulePlannerControllerTest.java\n","fileTypesAndContributionMap":{}},{"hash":"7ef09a89be73ba92a5b1c84aa9bb8ed37f8681d0","isMergeCommit":false,"messageTitle":"Fix CheckStyle Issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"d98977a14d7f4b3d2de12892a24cd09b46fc462d","isMergeCommit":true,"messageTitle":"Merge pull request #36 from SebasFok/SebasFok-FixMajor","messageBody":"Fix major bugs","fileTypesAndContributionMap":{}},{"hash":"f179c1478f01690019185e566c6739999e30a483","isMergeCommit":false,"messageTitle":"Create Developer Guide for Major feature","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":38,"deletions":0}}},{"hash":"f2b9bf9248cc0a203e4a62ab5303f80e85729dad","isMergeCommit":true,"messageTitle":"Merge pull request #37 from SebasFok/SebasFok-DGForMajorFeature","messageBody":"Create Developer Guide for Major feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"6a58a6751ee1a84baf1623b1201b1b840108544d","isMergeCommit":false,"messageTitle":"Add addModule function with many bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":79,"deletions":1}}}]},{"date":"2023-10-30","commitResults":[{"hash":"cf2a0ce5fe1067ed64f5c5ba55deae1e6a50b1aa","isMergeCommit":false,"messageTitle":"Improve addModule function to include mods outside of CEG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":183,"deletions":34},"test-code":{"insertions":4,"deletions":4}}},{"hash":"9f4bc310f738e82ecd1df2fd2dd43a9769f43ad6","isMergeCommit":false,"messageTitle":"Add javadocs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":72,"deletions":0}}},{"hash":"5f9c2fdbb5d1045ad9b5ea7a848473d675df96a4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok/feat/addModule","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/controllers/ModulePlannerController.java\n#\tsrc/main/java/seedu/duke/models/schema/Student.java\n#\tsrc/main/java/seedu/duke/views/CommandLineView.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"864e30c9844e51150ee31b52dfe169b0cec01173","isMergeCommit":false,"messageTitle":"Integrate add and major with parser function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":152,"deletions":125}}},{"hash":"d504b38d405a6f65395c26b49fd08db0f46d2a3b","isMergeCommit":false,"messageTitle":"Add tests for schedule class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":54,"deletions":35}}},{"hash":"53d1bb6d5e07e59e9983d68248b770bb700994de","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok/feat/addModule","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bca44c9428f6726e104d285b298432ced794735a","isMergeCommit":false,"messageTitle":"Rearrange ModuleList class and improve code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":7},"other":{"insertions":3,"deletions":3},"test-code":{"insertions":4,"deletions":8}}},{"hash":"081610573924cba8d01e88d9ecd08756a41b5c5d","isMergeCommit":false,"messageTitle":"Fix checkstyleTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"96518e79c1e6dcca8c49d7eebb5efa6a9d473696","isMergeCommit":true,"messageTitle":"Merge pull request #48 from SebasFok/SebasFok/feat/addModule","messageBody":"Add feature \u0027add\u0027","fileTypesAndContributionMap":{}},{"hash":"1280f14dda8423e1883881f5a091b07c96e6e314","isMergeCommit":false,"messageTitle":"Add delete function without tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":134,"deletions":0}}},{"hash":"c18c201d74b0f9cd7ab73d2209f91b40159ed227","isMergeCommit":true,"messageTitle":"Merge pull request #49 from SebasFok/SebasFok/feat/deleteModule","messageBody":"Add delete function without tests","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"5f40e9843e87f5a96df8d50e2cca9a775d078bd4","isMergeCommit":false,"messageTitle":"Fix \u0027satisfiesAllPrereq\u0027 bug and change error handling for add and delete functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":53}}},{"hash":"62a05cd4874eb97695d36f3f84c36e9a1687eb7a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok/feat/deleteModule","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/controllers/ModulePlannerController.java\n","fileTypesAndContributionMap":{}},{"hash":"67c2257f949528614651163941e816a17730a797","isMergeCommit":true,"messageTitle":"Merge pull request #51 from SebasFok/SebasFok/feat/deleteModule","messageBody":"Fix \u0027satisfiesAllPrereq\u0027 bug and change error handling for add and delete functions","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"f1135994d5a47c0ff1552c282cc228cc01c45478","isMergeCommit":false,"messageTitle":"Fix out of range integer causing application to crash","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"1d9bbb153908b9557ed64709520ba2baff34bdc8","isMergeCommit":true,"messageTitle":"Merge pull request #62 from SebasFok/SebasFok/bug/FixAdd","messageBody":"Fix out of range integer for add function causing application to crash","fileTypesAndContributionMap":{}},{"hash":"9c1e2f98aafc233c490d43419cfd1fcfb2b3146c","isMergeCommit":false,"messageTitle":"Add UG for add and delete features","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":74,"deletions":13}}},{"hash":"e84f9903ede1659394d7489dc1ccc05e636141ab","isMergeCommit":false,"messageTitle":"Fix spacing in aboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6b53c13ee03a04940f7568ae01707cd9a5fe7909","isMergeCommit":true,"messageTitle":"Merge pull request #70 from SebasFok/SebasFok/docs/UGForAddAndDelete","messageBody":"Update UG for add and delete","fileTypesAndContributionMap":{}},{"hash":"fc090101766fa7c9599ec8ff80fd98353ec9c6d6","isMergeCommit":false,"messageTitle":"Change add and delete to void functions and improve error handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":67,"deletions":49},"docs":{"insertions":4,"deletions":2},"test-code":{"insertions":25,"deletions":19}}},{"hash":"09ac0893fcb897e7cb958544284c01e32acfeafb","isMergeCommit":true,"messageTitle":"Merge pull request #71 from SebasFok/SebasFok/feat/improveErrorHandlingForAddDelete","messageBody":"Change add and delete to void functions and improve error handling","fileTypesAndContributionMap":{}}]}],"ryanlohyr":[{"date":"2023-10-07","commitResults":[{"hash":"a04733a9b91f0436d9e7599a9dbe7438aa6089a5","isMergeCommit":false,"messageTitle":"Update ryan portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}}]},{"date":"2023-10-12","commitResults":[{"hash":"f7df8565f0f1c09b3e97078aa0914ec8c8beb51e","isMergeCommit":false,"messageTitle":"create project base layout","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":12}}},{"hash":"448ac15a82ee8f25745d15ad226d9a5dd0f6bc55","isMergeCommit":false,"messageTitle":"Create base project layout","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":12}}},{"hash":"9bddadace6b3fe56ea34260bfbf808a576b7e336","isMergeCommit":false,"messageTitle":"Revert \"Create base project layout\"","messageBody":"This reverts commit 448ac15a82ee8f25745d15ad226d9a5dd0f6bc55.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":66}}},{"hash":"5cb0e57054f2e47ba0c944876577e4b36e3cb793","isMergeCommit":true,"messageTitle":"Merge branch \u0027ryan-createLayout\u0027 of https://github.com/ryanlohyr/tp into ryan-createLayout","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"de707c380d524d5b537fa700b0bd3337eb46c778","isMergeCommit":false,"messageTitle":"Fix test bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"52772484e68d1498e236d83c230d6226cc9b0dc3","isMergeCommit":true,"messageTitle":"Merge pull request #7 from ryanlohyr/ryan-createLayout","messageBody":"Create project base layout","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"813fa09444c9155f79f736faadd281e068a13fe7","isMergeCommit":false,"messageTitle":"Add pace feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":4,"deletions":0}}},{"hash":"92685f4a8354d7c9339df54862e8ad730875ae31","isMergeCommit":false,"messageTitle":"Add pace feature v2","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":88,"deletions":3},"test-code":{"insertions":86,"deletions":3}}},{"hash":"e4f352e491e6bee1e281a3aeac2b5cbec16e50ce","isMergeCommit":false,"messageTitle":"fix window os bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":16},"test-code":{"insertions":2,"deletions":4}}},{"hash":"ab09a619ac2be800ae064c73f1b41ce734c8f64b","isMergeCommit":true,"messageTitle":"Merge pull request #9 from ryanlohyr/ryan-paceFeature","messageBody":"Add pace feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"22c9f54fa9950fed39f4313ac4569cfa59a40694","isMergeCommit":false,"messageTitle":"add pace feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":18}}},{"hash":"d3fc98e585ca694c04d379ebc953ff02c874042a","isMergeCommit":true,"messageTitle":"Merge pull request #14 from ryanlohyr/ryan-paceFeature","messageBody":"add pace feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"c12b196537f7101680d6b70f81d40496e13cb010","isMergeCommit":false,"messageTitle":"fix format bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":82,"deletions":79}}},{"hash":"7b5a888b1c9c716564aee6458077499f76f301ab","isMergeCommit":true,"messageTitle":"fix test bug","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0e0f7bfab9fd4d4c361e5a315b233c8e07248f71","isMergeCommit":true,"messageTitle":"Merge pull request #22 from ryanlohyr/master","messageBody":"fix formatting and unit test bug","fileTypesAndContributionMap":{}},{"hash":"94d07e6718756e5e3ca942fe01955a4ba192be5c","isMergeCommit":true,"messageTitle":"Merge pull request #21 from rohitcube/master","messageBody":"Add API class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"b36f87967ffacbc039d25221df0214ffb7ec9530","isMergeCommit":false,"messageTitle":"Create developer guide for pace feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2},"other":{"insertions":1,"deletions":1},"docs":{"insertions":28,"deletions":0},"test-code":{"insertions":2,"deletions":1}}},{"hash":"ff1fed86da7619c2faa142dc10f0a5c93da3f6e7","isMergeCommit":true,"messageTitle":"Merge pull request #27 from ryanlohyr/ryan/developer-guide","messageBody":"Create developer guide for pace feature","tags":["v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"bd43a06ecf5d38a83e18e921c2b2471b97d790f3","isMergeCommit":false,"messageTitle":"Fix repo structure and api mods issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":10},"other":{"insertions":6,"deletions":9},"test-code":{"insertions":4,"deletions":3}}},{"hash":"71fc4612770b0946010116462f06af6ebe347f79","isMergeCommit":true,"messageTitle":"Merge pull request #41 from ryanlohyr/ryan/fix/repo-structure","messageBody":"Fix repo structure and api mods issue","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"472947849c656b0915df4c8752e547ff55cbb61b","isMergeCommit":false,"messageTitle":"Restructure project and add prerequisite function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":242,"deletions":35},"test-code":{"insertions":22,"deletions":50}}},{"hash":"d28259e7dc130809d475536cfcad9c14f94ae623","isMergeCommit":true,"messageTitle":"Merge pull request #42 from ryanlohyr/ryan/feat/prerequisite","messageBody":"Restructure project and add prerequisite function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"b1828a422a3e3a19c118015fb0f9374d930d30de","isMergeCommit":false,"messageTitle":"Add prerequisite situation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":160,"deletions":72}}},{"hash":"cda218d71e6ee63c97c7e20f1e8fe7d3670ece32","isMergeCommit":false,"messageTitle":"Add Schedule test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":0}}},{"hash":"6c9ea469481379ecb26005d228c5988712575256","isMergeCommit":false,"messageTitle":"Add Schedule test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"test-code":{"insertions":16,"deletions":0}}},{"hash":"997497f77a16f936a1ffd5a6a4688833de9ef88e","isMergeCommit":true,"messageTitle":"Resolve Merge Conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0478bda092fd4425af775eac75fb11519c565e6b","isMergeCommit":false,"messageTitle":"Fix Bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":69}}},{"hash":"4805ee511043b604fe9ed08f7cc3869590a28481","isMergeCommit":false,"messageTitle":"Fix styling","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"ea979917405714aaf2774d6a957fc747151c8e35","isMergeCommit":true,"messageTitle":"Merge pull request #45 from ryanlohyr/ryan/feat/prerequisite","messageBody":"Add Feature Recommend Schedule based on course","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"4b916b4c12831abc3498377015b36ef83cfed004","isMergeCommit":false,"messageTitle":"Add feature to add recommended schedule to current","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":14}}},{"hash":"24508d6f66ab2c9538ab011f5d05d9bcff3d44b5","isMergeCommit":true,"messageTitle":"Merge changes","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0ed9c6273f0349c55fdb0b9792debee61c287456","isMergeCommit":true,"messageTitle":"Merge pull request #50 from ryanlohyr/feat/implementCustomErrors","messageBody":"Merge code","fileTypesAndContributionMap":{}},{"hash":"aad140b9ae476c31ea8e82e0e40b12b4e28fdb2a","isMergeCommit":false,"messageTitle":"Fix schedule function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}}]},{"date":"2023-11-02","commitResults":[{"hash":"79f991ce7a81a0813e7e75fe8a090e07f9019c44","isMergeCommit":true,"messageTitle":"Fix bugs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4f4e3c0ebad7ce3253c85faa5edbbcf96a0b87cb","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-4:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2c9a30db8402b7ca5daec3ae84e18a68e601db18","isMergeCommit":false,"messageTitle":"Fix linting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"a1c318bf054e75ef63aea4154e840b1ed107470a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/ryanlohyr/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7dff28309f8c6ab74c57f9956a2027119c99cc1b","isMergeCommit":true,"messageTitle":"Merge pull request #61 from ryanlohyr/master","messageBody":"Fix bugs","fileTypesAndContributionMap":{}},{"hash":"dd8d7f914d7786727e3b6d847ecaadbd4f3a18ec","isMergeCommit":false,"messageTitle":"Actually removed dummy code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":14}}},{"hash":"a5e00fb54d59552a32c11c139e52f9da603922fd","isMergeCommit":true,"messageTitle":"Merge pull request #64 from ryanlohyr/master","messageBody":"Remove dummy code ","fileTypesAndContributionMap":{}},{"hash":"798985f4bd10030d227468fe99d007edc2bed3ef","isMergeCommit":false,"messageTitle":"Add static data","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":2}}},{"hash":"dc68bc6eb23a9bd050722c4118b58846733074ce","isMergeCommit":false,"messageTitle":"Fix checkstylemain","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":9}}},{"hash":"14b3bbc2e8e8a26b550bb71b6c8311ca7cc57c3f","isMergeCommit":false,"messageTitle":"Remove print statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"2d4163786f8cfad399c9fa76701b3909bee7283b","isMergeCommit":true,"messageTitle":"Merge pull request #67 from ryanlohyr/master","messageBody":"Add static data","fileTypesAndContributionMap":{}},{"hash":"73fc538e4d54dd0569516f04702c820219c9c1c7","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":38,"deletions":0}}},{"hash":"08fc0bc276ee4dc66c06d5aa7e052415d3403f39","isMergeCommit":true,"messageTitle":"Merge pull request #72 from ryanlohyr/master","messageBody":"Add Recommend Feature to DeveloperGuide.md","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"714f5a6392becf5a4a990f224fab7c7f0d1b64bf","isMergeCommit":false,"messageTitle":"Refactor magic literals into commands interface and added help function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":168,"deletions":26},"test-code":{"insertions":5,"deletions":1}}},{"hash":"91cc8d43440b01de0911f46a91dd155f80b68b37","isMergeCommit":false,"messageTitle":"Restructure codebase","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":477,"deletions":274},"other":{"insertions":11,"deletions":8},"test-code":{"insertions":16,"deletions":18}}},{"hash":"3a306344d094002d3fbfb95e254eed41bd00560b","isMergeCommit":false,"messageTitle":"Add ModulesTaken and Completed variables","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":1}}},{"hash":"3f1c3d637bb30e69ae36ac183dab37d3a0139aa9","isMergeCommit":false,"messageTitle":"Add Module class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":8}}},{"hash":"1c57038e24ec1e0fccdb829561b9fac9412fe5f9","isMergeCommit":false,"messageTitle":"fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"a05b0dde3c5f9dffc3aaeda5997eac2e84c4f6f5","isMergeCommit":true,"messageTitle":"Merge pull request #73 from ryanlohyr/ryan/feat/restructureCodebase","messageBody":"Restructure Codebase","fileTypesAndContributionMap":{}},{"hash":"b37110256c26ccc1e28713ad80d5f6d37c122adb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":24,"deletions":0}}},{"hash":"c62f61193678485139e8334b14d48b85330617ad","isMergeCommit":true,"messageTitle":"Merge pull request #76 from AY2324S1-CS2113-T17-4/ryanlohyr-updateUserGuide","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}},{"hash":"be00f82ee808605355150f3909b24f9ad65c064a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":0}}},{"hash":"59abb8850440768f83370de48e152f0c0d48c336","isMergeCommit":true,"messageTitle":"Merge pull request #77 from AY2324S1-CS2113-T17-4/ryanlohyr/updateUserGuide","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}},{"hash":"59d46c90c06c4644e993cd927219a69ea0971bd0","isMergeCommit":false,"messageTitle":"Add overall architecture diagram and sequence diagram","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0},"docs":{"insertions":26,"deletions":2}}},{"hash":"a14684604466a12de7464f2712c15d8961988de6","isMergeCommit":false,"messageTitle":"Restructure Error handler","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":27},"other":{"insertions":4,"deletions":4},"test-code":{"insertions":48,"deletions":0}}},{"hash":"02b7d4f6cb9130dd16e4875d605279490acbed40","isMergeCommit":true,"messageTitle":"Merge pull request #78 from ryanlohyr/ryan/feat/updateDG","messageBody":"Add overall architecture diagram and sequence diagram","fileTypesAndContributionMap":{}},{"hash":"2e12ea66085f5133768d1539accbff3c00931083","isMergeCommit":true,"messageTitle":"Merge pull request #79 from ryanlohyr/ryan/feat/integrationTest","messageBody":"Restructure Error handler","fileTypesAndContributionMap":{}},{"hash":"e7f952e70d426fee6516b809491aff44e53a8216","isMergeCommit":false,"messageTitle":"Refactor major to string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":99,"deletions":99},"test-code":{"insertions":6,"deletions":7}}},{"hash":"780abdb4661b0f2f205a58eeb2dcb8e4eb4aeef3","isMergeCommit":false,"messageTitle":"Fix checkstyletest errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":0,"deletions":2}}},{"hash":"0ee6847b1bd1dee15807d32de2bdb8998f933720","isMergeCommit":false,"messageTitle":"Update ModuleMethodsController.java","messageBody":"Fix check style","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"4a9da733161f3cb61b8864be06a17002d3a08479","isMergeCommit":false,"messageTitle":"Add integration tests for add module","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":17},"test-code":{"insertions":218,"deletions":146}}},{"hash":"4bc55d929ed00a053f9acebdc3212bed4f97f026","isMergeCommit":true,"messageTitle":"Merge pull request #80 from ryanlohyr/ryan/feat/integrationTest","messageBody":"Refactor major to string as well as code quality enhancements","fileTypesAndContributionMap":{}},{"hash":"5216aea0afec95b88b830c36d29866f7a0fbc961","isMergeCommit":true,"messageTitle":"Merge master changes","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"6e4f64b88370dc08a61bb8ada4f4d9902bf00f89","isMergeCommit":false,"messageTitle":"Fix windows newline error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":13,"deletions":0}}},{"hash":"a887e6ec49588e4a8ebf39a59cd8db6e99db22a2","isMergeCommit":false,"messageTitle":"Fix windows bug","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":0}}},{"hash":"df49fbdae4b57e96554b689a610f990c65132794","isMergeCommit":true,"messageTitle":"Merge pull request #81 from ryanlohyr/ryan/feat/integrationTest","messageBody":"Integration tests for \u0027add module to student\u0027","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"0c027b646ac0bc5c0d4df7443cc52d397cfd7906","isMergeCommit":false,"messageTitle":"Add Integration tests and optimise recommended schedule","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":80,"deletions":41},"test-code":{"insertions":33,"deletions":0}}},{"hash":"4297caf49c394475bf0282c1fa04f6d7c1a01836","isMergeCommit":false,"messageTitle":"Fix windows failed test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":10,"deletions":3}}},{"hash":"7ecccaa08fdb2ea93d8d7e0033b6712fb923edfd","isMergeCommit":true,"messageTitle":"Merge pull request #131 from ryanlohyr/ryan/feat/optimise","messageBody":"Add Integration tests and optimise recommended schedule","fileTypesAndContributionMap":{}},{"hash":"a5f3dc0e9acdebae40163dce9630af84397eb9b2","isMergeCommit":false,"messageTitle":"Add support for CS and integration tests for adding CS to schedule","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":177,"deletions":100},"test-code":{"insertions":39,"deletions":3}}},{"hash":"a9e8048156cd07128a7479376f8d61037a9c7fbb","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":18}}},{"hash":"0e66e0c0190a2dc205dc6b2aa151d9302190607a","isMergeCommit":false,"messageTitle":"Fix unit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":11}}},{"hash":"56a505c4ccf188f7a9d005631b4e4210faffed44","isMergeCommit":false,"messageTitle":"Add invalidModuleCode Exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":1},"test-code":{"insertions":1,"deletions":1}}},{"hash":"591b990c47d6ecf0b35265d1c3929c280b370361","isMergeCommit":true,"messageTitle":"Merge pull request #132 from ryanlohyr/ryan/feat/addCSRecommended","messageBody":"Add support for CS and integration tests for adding CS to schedule","fileTypesAndContributionMap":{}}]}],"janelleenqi":[{"date":"2023-10-07","commitResults":[{"hash":"b8e95e351ff1f9e8058d1fa4512b9fed2a801ff5","isMergeCommit":true,"messageTitle":"Merge pull request #1 from SebasFok/SebasFok-AboutUs","messageBody":"Add AboutUs information for Sebastian","fileTypesAndContributionMap":{}},{"hash":"215bbf707ba73e12fe4a3852bd195add31b9563b","isMergeCommit":false,"messageTitle":"Edit AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"20248cfdb579d3a65dba6b00480f73fd6818e9de","isMergeCommit":true,"messageTitle":"Merge pull request #3 from rohitcube/master","messageBody":"added profile - rohit","fileTypesAndContributionMap":{}},{"hash":"320cf1073f08efaeb681a28d2a71a2c05d03f61a","isMergeCommit":false,"messageTitle":"Edit AboutUs.md to include github","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"eeadb9d732a337b8cd7c73ed135d8d5aabf3ba2e","isMergeCommit":true,"messageTitle":"Merge AboutUs.md","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"e9a420df1a3a38da09d884a238231f1d151f3f37","isMergeCommit":false,"messageTitle":"add \"left\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":97,"deletions":22}}},{"hash":"d61cfbec5c631f4536a0498f84b53a469717b7a9","isMergeCommit":false,"messageTitle":"delete unnecessary lines","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"9fec7539e4da6bde4964b8bb37ea3827706ac546","isMergeCommit":false,"messageTitle":"add ModuleListTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":44,"deletions":0}}},{"hash":"22d2823da7d4c2553ed68abf4765cc2f69476943","isMergeCommit":false,"messageTitle":"add listModulesLeftTest for successful scenario in ModulePlannerControllerTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":20,"deletions":0}}},{"hash":"c14bd0e9753371612f42b4a7653b130eedb55459","isMergeCommit":false,"messageTitle":"add existsTest for successful scenarios in ModuleListTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":24,"deletions":2}}},{"hash":"fe408d5d36d769ff7ccd93af2aa871dbb174bc36","isMergeCommit":false,"messageTitle":"add some exception handling for ModuleList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":14}}},{"hash":"fff60307f1c5bdb366bcd603e5b712359400b076","isMergeCommit":false,"messageTitle":"add failure scenarios for existsTest and getDifferenceTest in ModuleListTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":8},"test-code":{"insertions":30,"deletions":7}}},{"hash":"21c26955eebadc657445a51c384758035a3bde48","isMergeCommit":false,"messageTitle":"add javadoc comments for functions in the \"left\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":0}}},{"hash":"8789c06c3791750c5fd338706ea328ffb9040de7","isMergeCommit":false,"messageTitle":"Add success scenario where mainModuleList is empty for existsTest for ModuleListTest. This closes #10","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":16},"test-code":{"insertions":11,"deletions":0}}},{"hash":"bd71200339e77f407935b3039a6437d4e41a9cd7","isMergeCommit":false,"messageTitle":"Edit for build-and-check Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":30},"test-code":{"insertions":9,"deletions":7}}},{"hash":"1c3dba0cc588f9746f2a6706955df611cf1dac8c","isMergeCommit":false,"messageTitle":"Edit 2 for build-and-check Gradle (add new line at the end of the file)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"7103ecb9071ddb693815469edc4a98c724696ce3","isMergeCommit":false,"messageTitle":"Edit 3 for build-and-check Gradle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"28c461ff31ca243dacb48ca80caca708351319c5","isMergeCommit":true,"messageTitle":"Merge pull request #13 from janelleenqi/branch-left-command","messageBody":"Add Left Command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"4dad4e47e3274967b37f8fdf9168819dc7d8c360","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"ee22092cdb466e755f74b1d931009faf2a8450a3","isMergeCommit":false,"messageTitle":"Reorganise files in directory","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":2,"deletions":1}}},{"hash":"4bb7e1ca9fd650a59260929e471b6fdcc5cf9ae8","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"86a67bc781962dfebf96ff33220836d88f56949d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-shift-file","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"844497020cb6212656e880719bbbd03584f59310","isMergeCommit":false,"messageTitle":"Assertions Enabled in the build.gradle","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":1}}},{"hash":"8fe8d35becdda7684f96ce0a750afda64d581a87","isMergeCommit":false,"messageTitle":"Add assertions to ModuleList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0}}},{"hash":"634977a79898a14c9da7a96127606077f40d63f6","isMergeCommit":false,"messageTitle":"Update DeveloperGuide for Left","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":34,"deletions":8}}},{"hash":"71a99acc2f14adcb21441720314b3036f25b8db3","isMergeCommit":false,"messageTitle":"Fixes #10, fixes #33","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a4358197e7e9da71f5b3a7cce3beb7eabcd57224","isMergeCommit":true,"messageTitle":"Merge pull request #34 from janelleenqi/branch-ensure-project-deliverables","messageBody":"Add assertions, Update Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"b9fac348cbba2fe6641b522779774367f60831de","isMergeCommit":false,"messageTitle":"Update getRequirements to get only module codes from full CEGRequirements.txt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":1}}},{"hash":"449948670f2fb2639a341e9afc3dbb1d1699d626","isMergeCommit":false,"messageTitle":"Add skeleton of \"required\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":8}}}]},{"date":"2023-10-29","commitResults":[{"hash":"67ba22e5c71002d4c29b71c0e9bc4aa7e1c8f176","isMergeCommit":false,"messageTitle":"Show half table","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":1}}},{"hash":"a457e05e8264244efecf3d6ea200b01d860c35a1","isMergeCommit":false,"messageTitle":"Complete simple formatting for \"required\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":41}}},{"hash":"0dcce0323d8643c7a55fcfe68a49bb214cd8cacc","isMergeCommit":false,"messageTitle":"add \"required\" feature for the major \"CS\"","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"18be58c5dbf0b09b3bb9857962bd2280647d269c","isMergeCommit":false,"messageTitle":"fix formatting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":41}}},{"hash":"1faae023633cccdbcfc83c9a94571c4ce4e45f12","isMergeCommit":false,"messageTitle":"extract getLongestStringLength(File f)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":18}}},{"hash":"c05f39be85d642b4f2a36be9ee52c10f29533ab7","isMergeCommit":false,"messageTitle":"Add javadoc comments for DataRepository.java and CommandLineView.java Fixes #32","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":13}}},{"hash":"12fd2b79dbf99a1a8a651b64d25f9fb6181b4fb4","isMergeCommit":false,"messageTitle":"Attempt 1 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"e2871c016b80321b3234435cc5974b8129f695c9","isMergeCommit":false,"messageTitle":"Attempt 2 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"eea92354de414fdad713768272e01cfdce39024e","isMergeCommit":false,"messageTitle":"Attempt 3 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"254e7224502763d17b0a1c66d8e6515a1a8a1e84","isMergeCommit":false,"messageTitle":"Attempt 4 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"1ffc685b47a7f14c4b49644b8b3db652af1b0510","isMergeCommit":false,"messageTitle":"Attempt 5 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"f0a922ee6e36aba351cdef5d26c728ad822b153a","isMergeCommit":false,"messageTitle":"Attempt 6 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"9ce59a225b8d020f0c5382d2b1df7d3a1b5e2dbb","isMergeCommit":false,"messageTitle":"Attempt 7 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"d1d510937b71872b8a2b0811da87577be201e34b","isMergeCommit":false,"messageTitle":"Attempt 8 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"c2e9b4592b7961585605487af164075e734256d9","isMergeCommit":false,"messageTitle":"Attempt 9 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"206bda85747cccf85dd05ad738bd880a6e1470b9","isMergeCommit":false,"messageTitle":"Fixes #32","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"01ac435a7756ed81d1085a174bf4719f2805934e","isMergeCommit":true,"messageTitle":"Merge pull request #43 from janelleenqi/Janelle/feature/required-modules","messageBody":"Add feature \"required\"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"c3d197e0536be889cb750228d5f7d4c652222802","isMergeCommit":false,"messageTitle":"Add \u0027left\u0027 and \u0027required\u0027 features into UserGuide #46","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":63,"deletions":0}}},{"hash":"9267bc7e448778e21a576ee511e19d71d32185b2","isMergeCommit":false,"messageTitle":"Add \u0027required\u0027 feature for DeveloperGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":22,"deletions":0}}},{"hash":"3c2031b0be0f32d6db441a45bcf41f589de4172d","isMergeCommit":false,"messageTitle":"Code Quality for ModuleListTest. Fixes #39","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":4}}},{"hash":"1776269a3b23aaf47c7c7659c451d44a3b95efc3","isMergeCommit":false,"messageTitle":"Fix for unmappable characters by changing to # and +","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"0566fe1c15652802ee08dbb73ab2d4808bfd8792","isMergeCommit":false,"messageTitle":"Refactor getRequiredModules","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":5}}},{"hash":"39f679c867106583dd3cce7d80189ebcbb0cc2b5","isMergeCommit":false,"messageTitle":"Add success test case for \u0027required\u0027 feature","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":93,"deletions":0}}},{"hash":"ccadbfc43e487e46c0967fdf9ad1e4fdac7d04b4","isMergeCommit":false,"messageTitle":"Delete redundant lines for testing of \u0027required\u0027 feature \u0027#32","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":4}}},{"hash":"efd719136a6985714eddcd66a40b53ea724be921","isMergeCommit":false,"messageTitle":"Gradle checkstyleTest edits","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":7,"deletions":6}}},{"hash":"b701756192c954e149ea783bd211e2055b804f78","isMergeCommit":false,"messageTitle":"Add .trim() to both actual output and expected output","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"d493c2f156ba0cb3cec61356319bd9d47b0ad011","isMergeCommit":false,"messageTitle":"solve line is longer than 120 problem","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"f5606088b1d004de01e6b69778d8a27ea44b8028","isMergeCommit":false,"messageTitle":"solve line is longer than 120 problem again","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"6f64a2635a1120c0b4594c0256379bc440de9bf2","isMergeCommit":false,"messageTitle":"Revert \"add\"","messageBody":"This reverts commit 3994c04761f6f7f30798732bb9ea82273de207f0.\n","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"73401fde2d9aa54abee4fb750195e8b6b816d52c","isMergeCommit":false,"messageTitle":"String.format","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"d4e9c6c90d7333990ace3d6735775050ffea528b","isMergeCommit":false,"messageTitle":"startsWith","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":52}}},{"hash":"553444abe4f5a4ec0f78221e13143e90cb8c4cf3","isMergeCommit":false,"messageTitle":"delete","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"15f2e47338862cbd87e1d5c323cf7bd9e8ece1cc","isMergeCommit":true,"messageTitle":"Merge pull request #47 from janelleenqi/Janelle/feature/success-testing-for-required","messageBody":"Add positive testing for \u0027required\u0027 feature","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"c23c2ea0a47fdc3dcf6f7dfa71c3a2f6293f27ec","isMergeCommit":false,"messageTitle":"Update modulesMajor to use real data, refactor \"left\" and \"required\" features","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":205,"deletions":145},"other":{"insertions":3,"deletions":3},"test-code":{"insertions":36,"deletions":19}}},{"hash":"d00f0ec78b7918584314623cea6fdb6bb265eede","isMergeCommit":false,"messageTitle":"Add Javadoc Comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":3}}},{"hash":"4f97c1963ced94c74ac6f2cd36eef08e8536c5f9","isMergeCommit":true,"messageTitle":"Merge Conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"067c18e3bda59bb92c3f4e021ebe5f139ca64b7f","isMergeCommit":true,"messageTitle":"Merge pull request #57 from rohitcube/rohit/feat/add-fuzzy-search-to-API-class","messageBody":"Update User Guide","fileTypesAndContributionMap":{}},{"hash":"7c2515604d709b40372f8ecee55240a7ac793445","isMergeCommit":true,"messageTitle":"Merge Conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3600646a5b2954d6972b5b0b822f1365d0dd39c1","isMergeCommit":false,"messageTitle":"improves #47 #13","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"8ad18c6b8d66abfd6e9fd7326367c4613053f0df","isMergeCommit":true,"messageTitle":"Merge pull request #59 from janelleenqi/Janelle/feature/left-function-improve","messageBody":"Update modulesMajor","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"79f97143f3a25c66178c32aa2ef40b5264a08c0d","isMergeCommit":false,"messageTitle":"fixes #27","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":7},"docs":{"insertions":2,"deletions":2}}},{"hash":"81d9043ca68bafd58de577128be4d15c76114d94","isMergeCommit":true,"messageTitle":"merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c5d099d1153b9d41de064c667fd5a048bdf4049f","isMergeCommit":true,"messageTitle":"Merge pull request #63 from janelleenqi/Janelle/fix/complete","messageBody":"Fix Complete Feature","fileTypesAndContributionMap":{}},{"hash":"7a397044030222664d7c609f8dd874db2d6c2575","isMergeCommit":false,"messageTitle":"fix bug in #32","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":3}}},{"hash":"3031f9915a79df267965565dc276e001eff575bc","isMergeCommit":true,"messageTitle":"merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0fbbce1e41174eeeeb5a7639d938823a01622a6f","isMergeCommit":true,"messageTitle":"Merge pull request #65 from janelleenqi/Janelle/fix/required","messageBody":"Fix bug in \"required\" feature","fileTypesAndContributionMap":{}},{"hash":"81abd31e1ead822715cf36bd85c60f9259460266","isMergeCommit":false,"messageTitle":"remove txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":60,"deletions":120}}},{"hash":"d008aa58359a4c03b67f2133c1a127394294c30e","isMergeCommit":false,"messageTitle":"checkstyle fixes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5},"test-code":{"insertions":2,"deletions":3}}},{"hash":"2bbabbdeae1704bc7572b3a9b3927e58dd3c868c","isMergeCommit":true,"messageTitle":"Merge pull request #69 from janelleenqi/Janelle/fix/remove-txt-files","messageBody":"Remove txt files for required","tags":["v2.0","v1.01"],"fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"4d97258274cc7992c1cd9f10f8d4fde09ee7b1f3","isMergeCommit":false,"messageTitle":"Add Left Sequence Diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":49,"deletions":0}}},{"hash":"1439244e6e6bea7bb48a30de5b09cf6255f4beb3","isMergeCommit":false,"messageTitle":"Edit Left Sequence Diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":4}}},{"hash":"c577cbe307f062f479ef439b591b658a655ecbe0","isMergeCommit":false,"messageTitle":"Add Required Sequence Diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":35,"deletions":0}}},{"hash":"0e5711b55dd8196fdbf359865ceb5c91b9037d55","isMergeCommit":false,"messageTitle":"Add Required and Left Sequence Diagram to DeveloperGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":20}}},{"hash":"8ff0da4548e548624d6bb227436007c9967d9a82","isMergeCommit":true,"messageTitle":"Merge pull request #74 from janelleenqi/Janelle/guide/update","messageBody":"Add sequence diagram for \"left\" and \"required\" command","fileTypesAndContributionMap":{}},{"hash":"c4277cca7df9536c80877fc3bd17f157b84e5a8a","isMergeCommit":false,"messageTitle":"Update User Guide and add screenshots","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":43}}},{"hash":"845c203f35fd873d40810af5c9baba36a407f15e","isMergeCommit":false,"messageTitle":"Update User Guide and add screenshots #46","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"f9ac770dba703311a88a27077c3d9f81436564a3","isMergeCommit":true,"messageTitle":"Merge pull request #75 from janelleenqi/Janelle/guide/update_UG","messageBody":"Update UG","fileTypesAndContributionMap":{}},{"hash":"99e003e9b11ea615e0b04bbf30fbeed61abb7e94","isMergeCommit":false,"messageTitle":"Fix Refactoring of ModuleList Part 1","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":57,"deletions":14}}},{"hash":"69220d6a6bd97f8fcf50732eb1b3ac87a42059ee","isMergeCommit":false,"messageTitle":"Fix Refactoring of ModuleList Part 1 (still have errors)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":57,"deletions":47}}},{"hash":"48ae4f3f58241b322fea993c4fe3b0fb3f8651a9","isMergeCommit":true,"messageTitle":"Merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2383a2aa287af2dbbe7f9314285f66ca9a817d8e","isMergeCommit":false,"messageTitle":"Merge (with errors)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-04","commitResults":[{"hash":"aa40cfd17cdd82124d6c7b4f307544fc0ec02bb8","isMergeCommit":true,"messageTitle":"Merge (with errors)","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c13e33310a18149ad005827bd0bec9090900512d","isMergeCommit":false,"messageTitle":"add and delete can work with cs1010 sem 1","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":98},"test-code":{"insertions":15,"deletions":8}}},{"hash":"e332ab82a72efd08de3cae680dc7f660ab1d6366","isMergeCommit":false,"messageTitle":"pass SUT tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":46},"test-code":{"insertions":37,"deletions":89}}},{"hash":"137dfa54275392eaa568beeb722ec90d894be7d0","isMergeCommit":false,"messageTitle":"pass checkstyle tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":16},"test-code":{"insertions":4,"deletions":2}}},{"hash":"56c8bbf3f8f26a7271427d933faf890a74896ca7","isMergeCommit":false,"messageTitle":"refactor code (mainModuleList in Module List from ArrayList\u003cString\u003e to ArrayList\u003cModule\u003e) fixes #129","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":5}}},{"hash":"b6d785235a1232c7459c93afeb1d773ae076ead1","isMergeCommit":true,"messageTitle":"Merge pull request #130 from janelleenqi/Janelle/fix/refactor","messageBody":"Refactor for Module List and Student","fileTypesAndContributionMap":{}}]}],"rohitcube":[{"date":"2023-10-07","commitResults":[{"hash":"a705965a345d0fb777a8268c24a02cb95f3c7009","isMergeCommit":false,"messageTitle":"added profile - rohit","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-09","commitResults":[{"hash":"67dfcdb437ce0cff8d2449ca49a32c15acb77cd7","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"526e6983d8cb279b409a14132ce402926860616a","isMergeCommit":true,"messageTitle":"Merge pull request #6 from rohitcube/master","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"abbb47faf32f9201108d53c0b360b528451fdc81","isMergeCommit":false,"messageTitle":"Added API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":110,"deletions":1},"other":{"insertions":1,"deletions":0},"test-code":{"insertions":19,"deletions":0}}},{"hash":"3295f1687ef050ad59ed4739c2bbb84b0b40cbf1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e6920151453fa8acfaef5a9c2c94aaf1a4288172","isMergeCommit":true,"messageTitle":"Fixed unresolved merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4bbac7ecc89de2ea1f18a0b3fe5aa5e1bc4f2265","isMergeCommit":false,"messageTitle":"Add API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}},{"hash":"6cd6c37ead68c4b389fb5c88296604599be37272","isMergeCommit":true,"messageTitle":"Add API class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"06e8865dc23823bff453a73e8ecfa52fffea2b1e","isMergeCommit":false,"messageTitle":"Add API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-19","commitResults":[{"hash":"3127654c68e3fcba58f73ccccf5737502ee90421","isMergeCommit":false,"messageTitle":"Fix indentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":75,"deletions":78},"test-code":{"insertions":0,"deletions":4}}},{"hash":"dca72b7be67ea4541f4246de06a127116d3f8d54","isMergeCommit":true,"messageTitle":"Merge CompletePreqs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f58efff20a7620a2b3490ea0e2d2d10cd90a3b67","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-4:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3858e4f65cfdeeeb9619b94b7bc63b076bba9f71","isMergeCommit":false,"messageTitle":"Fix CheckstyleMain","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":9},"test-code":{"insertions":9,"deletions":8}}},{"hash":"048fcd3aceef10dca2c3f33158706897d68b3bab","isMergeCommit":false,"messageTitle":"Remove API Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":102},"test-code":{"insertions":0,"deletions":16}}},{"hash":"fde33ba4b836e32a85c0f5125f315203cbbba6c6","isMergeCommit":true,"messageTitle":"Merge pull request #23 from rohitcube/branch-AddAPIClass","messageBody":"Remove API Class","tags":["v0.1"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"b2440a2441f95ea27fb2d5a8ea2804c3189bc3a9","isMergeCommit":false,"messageTitle":"Add API Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":0},"test-code":{"insertions":51,"deletions":0}}},{"hash":"a74c4c143857f517b7518f354aa339e5b90c9eb6","isMergeCommit":false,"messageTitle":"Add API Class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"43d67d6a9cb7a1e38683a3f6edd3f56b9c49baa1","isMergeCommit":true,"messageTitle":"Merge pull request #35 from rohitcube/Add-API-class-and-parser","messageBody":"Add API class and functions","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"6dcec60b621b4f3a3b9e66fbf1c5318b5201e3f7","isMergeCommit":false,"messageTitle":"Add functions that return json to API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":4},"test-code":{"insertions":0,"deletions":1}}},{"hash":"c4b9c1f6be1164dc52cef97da20ee323e347d0e4","isMergeCommit":false,"messageTitle":"Deleted \u0027info\u0027 command from module controller","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":11}}},{"hash":"ff4016383cf24bb5d6c682ea99fd9fd321149ad6","isMergeCommit":true,"messageTitle":"Merge pull request #40 from rohitcube/rohit/fix/add-json-functions-to-api-class","messageBody":"Rohit/fix/add json functions to api class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"2ca63dde17f55b7b0e8e3f0c1b3be342010437c3","isMergeCommit":false,"messageTitle":"Add search, info, description and workload functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":144,"deletions":22},"test-code":{"insertions":32,"deletions":11}}}]},{"date":"2023-10-30","commitResults":[{"hash":"4451d088837dd51df80f1b703f8fd7ecf0838949","isMergeCommit":false,"messageTitle":"Add search, info, description and workload functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":12},"test-code":{"insertions":49,"deletions":11}}},{"hash":"bbbf0826c9a9c123a813ada18a08c516f184e59b","isMergeCommit":false,"messageTitle":"Add tests for Api class and error handling (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":8},"test-code":{"insertions":9,"deletions":4}}},{"hash":"77c8a84bf8fc586257dcfe925a85898e4918caa7","isMergeCommit":true,"messageTitle":"Resolve conflicts with team repo (#30)","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8c80c73fa2d454bc9650a75b8eea902c3e1000ef","isMergeCommit":false,"messageTitle":"Update test variable names (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":10,"deletions":10}}}]},{"date":"2023-11-01","commitResults":[{"hash":"c0a2009020d81655620688e8f1e47e1905b5c14d","isMergeCommit":false,"messageTitle":"Update test variable names (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":105,"deletions":92}}},{"hash":"9d83c0f9f08ae906721c8ca7aff6a2b2d8ab3cbc","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-search-function-to-api-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/controllers/ModulePlannerController.java\n#\tsrc/main/java/seedu/duke/models/logic/Api.java\n","fileTypesAndContributionMap":{}},{"hash":"8e12f33d024ff7bb4101e5039569ebd1de41bae9","isMergeCommit":false,"messageTitle":"Resolve merge, add error messages for info and search commands (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":14}}},{"hash":"e752687525b4e8926275dac2b891c36f8c33523d","isMergeCommit":false,"messageTitle":"Add comments to functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":153,"deletions":73}}},{"hash":"93e90c4e667ab8d18c1dc02d5e2afd40bfe5906d","isMergeCommit":false,"messageTitle":"Add comments to functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":105,"deletions":110}}},{"hash":"2db8d33f2f2fa9b5e354054cfa8cbe51779357dc","isMergeCommit":true,"messageTitle":"Merge pull request #52 from rohitcube/rohit/feat/add-search-function-to-api-class","messageBody":"Add search function to api class","fileTypesAndContributionMap":{}},{"hash":"7f83666efdc70d14f9a99f53dc0273143d5389cc","isMergeCommit":false,"messageTitle":"Add author tag (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"531291a8d050b72fc369f8021a4a32a55499a421","isMergeCommit":false,"messageTitle":"Add author tag (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"014572732b65f145e0f5871ab77ce8965f7357ee","isMergeCommit":true,"messageTitle":"Merge pull request #53 from rohitcube/rohit/feat/add-search-function-to-api-class","messageBody":"Add author tag","fileTypesAndContributionMap":{}},{"hash":"b62653d85acbe230e324e735571819e5c2c34ff9","isMergeCommit":false,"messageTitle":"Abstract out methods from controller, changes to handle exceptions within the function (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":38}}},{"hash":"e2da2acfc867499c672c7fac4aad59f58f0d366e","isMergeCommit":false,"messageTitle":"Abstract out methods from controller, handle exceptions within function (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":11},"test-code":{"insertions":0,"deletions":5}}},{"hash":"db43264fbab3c7ce54cd4dc68fcdba8e4c3258b5","isMergeCommit":false,"messageTitle":"Abstract out methods from controller, handle exceptions within function (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"ca0a48f34ad3e9f6ae38c13609d848f199678600","isMergeCommit":true,"messageTitle":"Merge pull request #55 from rohitcube/rohit/feat/add-search-function-to-api-class","messageBody":"Refactor code from controller","fileTypesAndContributionMap":{}},{"hash":"c2cf751646e60fa094aa7150b51aa0fcb4506756","isMergeCommit":false,"messageTitle":"Deleted comments from API class(#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":24}}},{"hash":"7cd16ba0ac51e58fd456c5ef65861d6300680ee9","isMergeCommit":false,"messageTitle":"update user guide and DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":62,"deletions":8}}},{"hash":"08edb2d81abab8cb850daf3127f1ff86b50988c4","isMergeCommit":false,"messageTitle":"update user guide and DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"333bdeb5f10a3836d2bdfa13bac2cb7ef9153c7b","isMergeCommit":false,"messageTitle":"fixed bugs for info command (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":2},"test-code":{"insertions":11,"deletions":0}}},{"hash":"04a452e9d7be6cce3cccfc9e3cf9f7a411d84e0e","isMergeCommit":false,"messageTitle":"fixed bugs for info command (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":10}}},{"hash":"32dfdf0cefc8bb490008431f86284c793d0b02f6","isMergeCommit":false,"messageTitle":"fixed bugs for info command (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"3d03d2575163b44a209481067caa552adf4d286e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-fuzzy-search-to-API-class","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"44a62845adbabf17e8a0f4c971c0f185b3bee1ff","isMergeCommit":true,"messageTitle":"Merge pull request #60 from rohitcube/rohit/feat/add-fuzzy-search-to-API-class","messageBody":"Fixed bug for info command","fileTypesAndContributionMap":{}},{"hash":"0e679846e27246feed3fcdf387596d59883c7164","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"e9ca492412215ec6f73dabec1fdb6651102a6455","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-fuzzy-search-to-API-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f46bcb0d8ae084858347dfb081e34e97e110a3ad","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":8}}},{"hash":"fc01cb318160ff6d58c94fb4a3578a891ba4a542","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-fuzzy-search-to-API-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"470f82019d57ad0d287664024bad05222655a46f","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"b2ca119d39a1af12fca503bdc6f3cd9e67a6a3aa","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":6}}},{"hash":"9f9d8aadfb912f35987426ea0eecf1a6284edccc","isMergeCommit":true,"messageTitle":"Merge pull request #66 from rohitcube/rohit/feat/add-fuzzy-search-to-API-class","messageBody":"Fix bugs","tags":["v1.1"],"fileTypesAndContributionMap":{}}]}],"CerIsaiah":[{"date":"2023-10-08","commitResults":[{"hash":"d6daf466c3aae14881d7203cec549477dda5aca9","isMergeCommit":false,"messageTitle":"Add photo and aboutUs information","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"621e25c4f695763044e239140052377d8211fa05","isMergeCommit":true,"messageTitle":"Add aboutUs information","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-09","commitResults":[{"hash":"1e56807ba29080daddc8d8d177aa0110c772c699","isMergeCommit":false,"messageTitle":"Fixed merge conflicts with about us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}}]},{"date":"2023-10-18","commitResults":[{"hash":"5c7739cc63dfdba986b90ce2f2fcce5c0683a2b2","isMergeCommit":false,"messageTitle":"Add the complete class command to mark when a class is complete","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":165,"deletions":3}}},{"hash":"e39a5de84acff43f9364ed22ee1dda158fca3ecf","isMergeCommit":true,"messageTitle":"Merge major and complete commands","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"348b3da8aa36d1612001cf37da34c02482855c12","isMergeCommit":false,"messageTitle":"Fix merge tests conflicts","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":1},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-25","commitResults":[{"hash":"1cb45d2901f18782158ee8871e09adb98caee588","isMergeCommit":false,"messageTitle":"fix complete feature bugs and optimized features","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":9}}},{"hash":"4a6d6f64b8e288c9ff071bb39982f18ab1824149","isMergeCommit":true,"messageTitle":"Merge pull request #38 from CerIsaiah/bug-completefeature","messageBody":"fix complete feature bugs and optimized features","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"SebasFok":{"docs":117,"functional-code":476,"test-code":56},"ryanlohyr":{"docs":107,"functional-code":1316,"test-code":336},"janelleenqi":{"docs":206,"functional-code":373,"test-code":128,"other":1},"rohitcube":{"docs":48,"functional-code":307,"test-code":101,"other":1},"CerIsaiah":{"docs":6,"functional-code":198,"test-code":0}},"authorContributionVariance":{"SebasFok":9664.73,"ryanlohyr":93492.34,"janelleenqi":19730.04,"rohitcube":22047.438,"CerIsaiah":704.4729},"authorDisplayNameMap":{"SebasFok":"CS2113-T17-4 SEBA..HUNG","ryanlohyr":"CS2113-T17-4 RYAN.. RUI","janelleenqi":"CS2113-T17-4 LIOW..ELLE","rohitcube":"CS2113-T17-4 ROHI..THAN","CerIsaiah":"CS2113-T17-4 CERV..DEAN"}} +{"authorDailyContributionsMap":{"SebasFok":[{"date":"2023-10-05","commitResults":[{"hash":"aeef6fad05b0f6d0f0c354e9db79ba3ecbdfbef9","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-06","commitResults":[{"hash":"2039386c7d8e661b4e7bf66f1d4fa3ea80da23ac","isMergeCommit":false,"messageTitle":"Add AboutUs information for Sebastian","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}}]},{"date":"2023-10-07","commitResults":[{"hash":"de8365c98e9274e9c7b40228f5c687bbb7774a2e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-08","commitResults":[{"hash":"a728f005673371e58b95131d45ece32ea30c5cf6","isMergeCommit":true,"messageTitle":"Merge pull request #4 from janelleenqi/branch-Edit-AboutUs-v1","messageBody":"janelleenqi-AboutUs","fileTypesAndContributionMap":{}},{"hash":"a53713ffad1e3c43fb6821740bbbae2f0b934975","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2336e0f03aede437eefc987d98349c05b02aecc3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-4/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5677d80546a6e55ae3fc9b3c2f9efc6cc36ddfbc","isMergeCommit":true,"messageTitle":"Merge pull request #5 from ryanlohyr/master","messageBody":"Ryanlohyr-AboutUs","fileTypesAndContributionMap":{}},{"hash":"f10394ae22fddfcc20621826cb53a03dd516d990","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T17-4/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"0d840309811b905770039ac8ee89b6c803eb14ee","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9c3ef1f3c1cd7136c584fdbcd2b00be6f53e8069","isMergeCommit":false,"messageTitle":"Fix AboutUs page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"d97257fe38507e38b90b874e965ec94cc6b5c00a","isMergeCommit":false,"messageTitle":"Revert \"Fix AboutUs page\"","messageBody":"This reverts commit 9c3ef1f3c1cd7136c584fdbcd2b00be6f53e8069.\n","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"d0a5cf6d3dab23e3ab691ed2f8a77ddb0e301864","isMergeCommit":false,"messageTitle":"Fix AboutUs page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"a6429ace4f7089682cc2c231fd5a974b2abacea8","isMergeCommit":true,"messageTitle":"Merge pull request #8 from SebasFok/branch-FixAboutUs","messageBody":"Fix about us page","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"be9eda9ae041c25d60d33065384ebbafb11b421b","isMergeCommit":false,"messageTitle":"Add student class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0}}},{"hash":"f37c8d8033f4f5340abf8af3f6cfee7194242bee","isMergeCommit":false,"messageTitle":"Add \"major\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"2ed39fab10850f7beac9b1dea7710dab4ee3b966","isMergeCommit":false,"messageTitle":"Add enum for majors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":8}}},{"hash":"a777fd584c0ae40bcd4d764c056dde18112af52d","isMergeCommit":false,"messageTitle":"Add tests for \u0027updateMajor\u0027 function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":26,"deletions":0}}},{"hash":"88ac029553890db8c4945a2fd9d5dce17ff67011","isMergeCommit":false,"messageTitle":"Remove unused imports","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"20e6817a7cccc59b82ffed3fccf09a44a67b767c","isMergeCommit":true,"messageTitle":"Merge pull request #16 from SebasFok/branch-SelectMajor","messageBody":"Add major feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"f8bdc1bbed8355ad7010bcf3a1dfe6a49b2ac42d","isMergeCommit":false,"messageTitle":"Fix Major command bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":11},"test-code":{"insertions":34,"deletions":24}}},{"hash":"1fd6f85f957f1380b71520ff1ccca4efea83951c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok-FixMajor","messageBody":"# Conflicts:\n#\tsrc/test/java/seedu/duke/controllers/ModulePlannerControllerTest.java\n","fileTypesAndContributionMap":{}},{"hash":"7ef09a89be73ba92a5b1c84aa9bb8ed37f8681d0","isMergeCommit":false,"messageTitle":"Fix CheckStyle Issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"d98977a14d7f4b3d2de12892a24cd09b46fc462d","isMergeCommit":true,"messageTitle":"Merge pull request #36 from SebasFok/SebasFok-FixMajor","messageBody":"Fix major bugs","fileTypesAndContributionMap":{}},{"hash":"f179c1478f01690019185e566c6739999e30a483","isMergeCommit":false,"messageTitle":"Create Developer Guide for Major feature","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":38,"deletions":0}}},{"hash":"f2b9bf9248cc0a203e4a62ab5303f80e85729dad","isMergeCommit":true,"messageTitle":"Merge pull request #37 from SebasFok/SebasFok-DGForMajorFeature","messageBody":"Create Developer Guide for Major feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"6a58a6751ee1a84baf1623b1201b1b840108544d","isMergeCommit":false,"messageTitle":"Add addModule function with many bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":79,"deletions":1}}}]},{"date":"2023-10-30","commitResults":[{"hash":"cf2a0ce5fe1067ed64f5c5ba55deae1e6a50b1aa","isMergeCommit":false,"messageTitle":"Improve addModule function to include mods outside of CEG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":183,"deletions":34},"test-code":{"insertions":4,"deletions":4}}},{"hash":"9f4bc310f738e82ecd1df2fd2dd43a9769f43ad6","isMergeCommit":false,"messageTitle":"Add javadocs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":72,"deletions":0}}},{"hash":"5f9c2fdbb5d1045ad9b5ea7a848473d675df96a4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok/feat/addModule","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/controllers/ModulePlannerController.java\n#\tsrc/main/java/seedu/duke/models/schema/Student.java\n#\tsrc/main/java/seedu/duke/views/CommandLineView.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"864e30c9844e51150ee31b52dfe169b0cec01173","isMergeCommit":false,"messageTitle":"Integrate add and major with parser function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":152,"deletions":125}}},{"hash":"d504b38d405a6f65395c26b49fd08db0f46d2a3b","isMergeCommit":false,"messageTitle":"Add tests for schedule class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":54,"deletions":35}}},{"hash":"53d1bb6d5e07e59e9983d68248b770bb700994de","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok/feat/addModule","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bca44c9428f6726e104d285b298432ced794735a","isMergeCommit":false,"messageTitle":"Rearrange ModuleList class and improve code quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":7},"other":{"insertions":3,"deletions":3},"test-code":{"insertions":4,"deletions":8}}},{"hash":"081610573924cba8d01e88d9ecd08756a41b5c5d","isMergeCommit":false,"messageTitle":"Fix checkstyleTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"96518e79c1e6dcca8c49d7eebb5efa6a9d473696","isMergeCommit":true,"messageTitle":"Merge pull request #48 from SebasFok/SebasFok/feat/addModule","messageBody":"Add feature \u0027add\u0027","fileTypesAndContributionMap":{}},{"hash":"1280f14dda8423e1883881f5a091b07c96e6e314","isMergeCommit":false,"messageTitle":"Add delete function without tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":134,"deletions":0}}},{"hash":"c18c201d74b0f9cd7ab73d2209f91b40159ed227","isMergeCommit":true,"messageTitle":"Merge pull request #49 from SebasFok/SebasFok/feat/deleteModule","messageBody":"Add delete function without tests","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"5f40e9843e87f5a96df8d50e2cca9a775d078bd4","isMergeCommit":false,"messageTitle":"Fix \u0027satisfiesAllPrereq\u0027 bug and change error handling for add and delete functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":53}}},{"hash":"62a05cd4874eb97695d36f3f84c36e9a1687eb7a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into SebasFok/feat/deleteModule","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/controllers/ModulePlannerController.java\n","fileTypesAndContributionMap":{}},{"hash":"67c2257f949528614651163941e816a17730a797","isMergeCommit":true,"messageTitle":"Merge pull request #51 from SebasFok/SebasFok/feat/deleteModule","messageBody":"Fix \u0027satisfiesAllPrereq\u0027 bug and change error handling for add and delete functions","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"f1135994d5a47c0ff1552c282cc228cc01c45478","isMergeCommit":false,"messageTitle":"Fix out of range integer causing application to crash","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"1d9bbb153908b9557ed64709520ba2baff34bdc8","isMergeCommit":true,"messageTitle":"Merge pull request #62 from SebasFok/SebasFok/bug/FixAdd","messageBody":"Fix out of range integer for add function causing application to crash","fileTypesAndContributionMap":{}},{"hash":"9c1e2f98aafc233c490d43419cfd1fcfb2b3146c","isMergeCommit":false,"messageTitle":"Add UG for add and delete features","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":74,"deletions":13}}},{"hash":"e84f9903ede1659394d7489dc1ccc05e636141ab","isMergeCommit":false,"messageTitle":"Fix spacing in aboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6b53c13ee03a04940f7568ae01707cd9a5fe7909","isMergeCommit":true,"messageTitle":"Merge pull request #70 from SebasFok/SebasFok/docs/UGForAddAndDelete","messageBody":"Update UG for add and delete","fileTypesAndContributionMap":{}},{"hash":"fc090101766fa7c9599ec8ff80fd98353ec9c6d6","isMergeCommit":false,"messageTitle":"Change add and delete to void functions and improve error handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":67,"deletions":49},"docs":{"insertions":4,"deletions":2},"test-code":{"insertions":25,"deletions":19}}},{"hash":"09ac0893fcb897e7cb958544284c01e32acfeafb","isMergeCommit":true,"messageTitle":"Merge pull request #71 from SebasFok/SebasFok/feat/improveErrorHandlingForAddDelete","messageBody":"Change add and delete to void functions and improve error handling","fileTypesAndContributionMap":{}}]}],"ryanlohyr":[{"date":"2023-10-07","commitResults":[{"hash":"a04733a9b91f0436d9e7599a9dbe7438aa6089a5","isMergeCommit":false,"messageTitle":"Update ryan portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}}]},{"date":"2023-10-12","commitResults":[{"hash":"f7df8565f0f1c09b3e97078aa0914ec8c8beb51e","isMergeCommit":false,"messageTitle":"create project base layout","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":12}}},{"hash":"448ac15a82ee8f25745d15ad226d9a5dd0f6bc55","isMergeCommit":false,"messageTitle":"Create base project layout","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":12}}},{"hash":"9bddadace6b3fe56ea34260bfbf808a576b7e336","isMergeCommit":false,"messageTitle":"Revert \"Create base project layout\"","messageBody":"This reverts commit 448ac15a82ee8f25745d15ad226d9a5dd0f6bc55.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":66}}},{"hash":"5cb0e57054f2e47ba0c944876577e4b36e3cb793","isMergeCommit":true,"messageTitle":"Merge branch \u0027ryan-createLayout\u0027 of https://github.com/ryanlohyr/tp into ryan-createLayout","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"de707c380d524d5b537fa700b0bd3337eb46c778","isMergeCommit":false,"messageTitle":"Fix test bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"52772484e68d1498e236d83c230d6226cc9b0dc3","isMergeCommit":true,"messageTitle":"Merge pull request #7 from ryanlohyr/ryan-createLayout","messageBody":"Create project base layout","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"813fa09444c9155f79f736faadd281e068a13fe7","isMergeCommit":false,"messageTitle":"Add pace feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":4,"deletions":0}}},{"hash":"92685f4a8354d7c9339df54862e8ad730875ae31","isMergeCommit":false,"messageTitle":"Add pace feature v2","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":88,"deletions":3},"test-code":{"insertions":86,"deletions":3}}},{"hash":"e4f352e491e6bee1e281a3aeac2b5cbec16e50ce","isMergeCommit":false,"messageTitle":"fix window os bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":16},"test-code":{"insertions":2,"deletions":4}}},{"hash":"ab09a619ac2be800ae064c73f1b41ce734c8f64b","isMergeCommit":true,"messageTitle":"Merge pull request #9 from ryanlohyr/ryan-paceFeature","messageBody":"Add pace feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"22c9f54fa9950fed39f4313ac4569cfa59a40694","isMergeCommit":false,"messageTitle":"add pace feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":18}}},{"hash":"d3fc98e585ca694c04d379ebc953ff02c874042a","isMergeCommit":true,"messageTitle":"Merge pull request #14 from ryanlohyr/ryan-paceFeature","messageBody":"add pace feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"c12b196537f7101680d6b70f81d40496e13cb010","isMergeCommit":false,"messageTitle":"fix format bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":82,"deletions":79}}},{"hash":"7b5a888b1c9c716564aee6458077499f76f301ab","isMergeCommit":true,"messageTitle":"fix test bug","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0e0f7bfab9fd4d4c361e5a315b233c8e07248f71","isMergeCommit":true,"messageTitle":"Merge pull request #22 from ryanlohyr/master","messageBody":"fix formatting and unit test bug","fileTypesAndContributionMap":{}},{"hash":"94d07e6718756e5e3ca942fe01955a4ba192be5c","isMergeCommit":true,"messageTitle":"Merge pull request #21 from rohitcube/master","messageBody":"Add API class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"b36f87967ffacbc039d25221df0214ffb7ec9530","isMergeCommit":false,"messageTitle":"Create developer guide for pace feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2},"other":{"insertions":1,"deletions":1},"docs":{"insertions":28,"deletions":0},"test-code":{"insertions":2,"deletions":1}}},{"hash":"ff1fed86da7619c2faa142dc10f0a5c93da3f6e7","isMergeCommit":true,"messageTitle":"Merge pull request #27 from ryanlohyr/ryan/developer-guide","messageBody":"Create developer guide for pace feature","tags":["v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"bd43a06ecf5d38a83e18e921c2b2471b97d790f3","isMergeCommit":false,"messageTitle":"Fix repo structure and api mods issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":10},"other":{"insertions":6,"deletions":9},"test-code":{"insertions":4,"deletions":3}}},{"hash":"71fc4612770b0946010116462f06af6ebe347f79","isMergeCommit":true,"messageTitle":"Merge pull request #41 from ryanlohyr/ryan/fix/repo-structure","messageBody":"Fix repo structure and api mods issue","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"472947849c656b0915df4c8752e547ff55cbb61b","isMergeCommit":false,"messageTitle":"Restructure project and add prerequisite function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":242,"deletions":35},"test-code":{"insertions":22,"deletions":50}}},{"hash":"d28259e7dc130809d475536cfcad9c14f94ae623","isMergeCommit":true,"messageTitle":"Merge pull request #42 from ryanlohyr/ryan/feat/prerequisite","messageBody":"Restructure project and add prerequisite function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"b1828a422a3e3a19c118015fb0f9374d930d30de","isMergeCommit":false,"messageTitle":"Add prerequisite situation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":160,"deletions":72}}},{"hash":"cda218d71e6ee63c97c7e20f1e8fe7d3670ece32","isMergeCommit":false,"messageTitle":"Add Schedule test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":0}}},{"hash":"6c9ea469481379ecb26005d228c5988712575256","isMergeCommit":false,"messageTitle":"Add Schedule test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"test-code":{"insertions":16,"deletions":0}}},{"hash":"997497f77a16f936a1ffd5a6a4688833de9ef88e","isMergeCommit":true,"messageTitle":"Resolve Merge Conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0478bda092fd4425af775eac75fb11519c565e6b","isMergeCommit":false,"messageTitle":"Fix Bugs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":69}}},{"hash":"4805ee511043b604fe9ed08f7cc3869590a28481","isMergeCommit":false,"messageTitle":"Fix styling","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"ea979917405714aaf2774d6a957fc747151c8e35","isMergeCommit":true,"messageTitle":"Merge pull request #45 from ryanlohyr/ryan/feat/prerequisite","messageBody":"Add Feature Recommend Schedule based on course","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"4b916b4c12831abc3498377015b36ef83cfed004","isMergeCommit":false,"messageTitle":"Add feature to add recommended schedule to current","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":14}}},{"hash":"24508d6f66ab2c9538ab011f5d05d9bcff3d44b5","isMergeCommit":true,"messageTitle":"Merge changes","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0ed9c6273f0349c55fdb0b9792debee61c287456","isMergeCommit":true,"messageTitle":"Merge pull request #50 from ryanlohyr/feat/implementCustomErrors","messageBody":"Merge code","fileTypesAndContributionMap":{}},{"hash":"aad140b9ae476c31ea8e82e0e40b12b4e28fdb2a","isMergeCommit":false,"messageTitle":"Fix schedule function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}}]},{"date":"2023-11-02","commitResults":[{"hash":"79f991ce7a81a0813e7e75fe8a090e07f9019c44","isMergeCommit":true,"messageTitle":"Fix bugs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4f4e3c0ebad7ce3253c85faa5edbbcf96a0b87cb","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-4:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2c9a30db8402b7ca5daec3ae84e18a68e601db18","isMergeCommit":false,"messageTitle":"Fix linting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"a1c318bf054e75ef63aea4154e840b1ed107470a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/ryanlohyr/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7dff28309f8c6ab74c57f9956a2027119c99cc1b","isMergeCommit":true,"messageTitle":"Merge pull request #61 from ryanlohyr/master","messageBody":"Fix bugs","fileTypesAndContributionMap":{}},{"hash":"dd8d7f914d7786727e3b6d847ecaadbd4f3a18ec","isMergeCommit":false,"messageTitle":"Actually removed dummy code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":14}}},{"hash":"a5e00fb54d59552a32c11c139e52f9da603922fd","isMergeCommit":true,"messageTitle":"Merge pull request #64 from ryanlohyr/master","messageBody":"Remove dummy code ","fileTypesAndContributionMap":{}},{"hash":"798985f4bd10030d227468fe99d007edc2bed3ef","isMergeCommit":false,"messageTitle":"Add static data","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":2}}},{"hash":"dc68bc6eb23a9bd050722c4118b58846733074ce","isMergeCommit":false,"messageTitle":"Fix checkstylemain","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":9}}},{"hash":"14b3bbc2e8e8a26b550bb71b6c8311ca7cc57c3f","isMergeCommit":false,"messageTitle":"Remove print statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"2d4163786f8cfad399c9fa76701b3909bee7283b","isMergeCommit":true,"messageTitle":"Merge pull request #67 from ryanlohyr/master","messageBody":"Add static data","fileTypesAndContributionMap":{}},{"hash":"73fc538e4d54dd0569516f04702c820219c9c1c7","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":38,"deletions":0}}},{"hash":"08fc0bc276ee4dc66c06d5aa7e052415d3403f39","isMergeCommit":true,"messageTitle":"Merge pull request #72 from ryanlohyr/master","messageBody":"Add Recommend Feature to DeveloperGuide.md","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"714f5a6392becf5a4a990f224fab7c7f0d1b64bf","isMergeCommit":false,"messageTitle":"Refactor magic literals into commands interface and added help function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":168,"deletions":26},"test-code":{"insertions":5,"deletions":1}}},{"hash":"91cc8d43440b01de0911f46a91dd155f80b68b37","isMergeCommit":false,"messageTitle":"Restructure codebase","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":477,"deletions":274},"other":{"insertions":11,"deletions":8},"test-code":{"insertions":16,"deletions":18}}},{"hash":"3a306344d094002d3fbfb95e254eed41bd00560b","isMergeCommit":false,"messageTitle":"Add ModulesTaken and Completed variables","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":1}}},{"hash":"3f1c3d637bb30e69ae36ac183dab37d3a0139aa9","isMergeCommit":false,"messageTitle":"Add Module class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":8}}},{"hash":"1c57038e24ec1e0fccdb829561b9fac9412fe5f9","isMergeCommit":false,"messageTitle":"fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"a05b0dde3c5f9dffc3aaeda5997eac2e84c4f6f5","isMergeCommit":true,"messageTitle":"Merge pull request #73 from ryanlohyr/ryan/feat/restructureCodebase","messageBody":"Restructure Codebase","fileTypesAndContributionMap":{}},{"hash":"b37110256c26ccc1e28713ad80d5f6d37c122adb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":24,"deletions":0}}},{"hash":"c62f61193678485139e8334b14d48b85330617ad","isMergeCommit":true,"messageTitle":"Merge pull request #76 from AY2324S1-CS2113-T17-4/ryanlohyr-updateUserGuide","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}},{"hash":"be00f82ee808605355150f3909b24f9ad65c064a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":0}}},{"hash":"59abb8850440768f83370de48e152f0c0d48c336","isMergeCommit":true,"messageTitle":"Merge pull request #77 from AY2324S1-CS2113-T17-4/ryanlohyr/updateUserGuide","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}},{"hash":"59d46c90c06c4644e993cd927219a69ea0971bd0","isMergeCommit":false,"messageTitle":"Add overall architecture diagram and sequence diagram","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0},"docs":{"insertions":26,"deletions":2}}},{"hash":"a14684604466a12de7464f2712c15d8961988de6","isMergeCommit":false,"messageTitle":"Restructure Error handler","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":27},"other":{"insertions":4,"deletions":4},"test-code":{"insertions":48,"deletions":0}}},{"hash":"02b7d4f6cb9130dd16e4875d605279490acbed40","isMergeCommit":true,"messageTitle":"Merge pull request #78 from ryanlohyr/ryan/feat/updateDG","messageBody":"Add overall architecture diagram and sequence diagram","fileTypesAndContributionMap":{}},{"hash":"2e12ea66085f5133768d1539accbff3c00931083","isMergeCommit":true,"messageTitle":"Merge pull request #79 from ryanlohyr/ryan/feat/integrationTest","messageBody":"Restructure Error handler","fileTypesAndContributionMap":{}},{"hash":"e7f952e70d426fee6516b809491aff44e53a8216","isMergeCommit":false,"messageTitle":"Refactor major to string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":99,"deletions":99},"test-code":{"insertions":6,"deletions":7}}},{"hash":"780abdb4661b0f2f205a58eeb2dcb8e4eb4aeef3","isMergeCommit":false,"messageTitle":"Fix checkstyletest errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":0,"deletions":2}}},{"hash":"0ee6847b1bd1dee15807d32de2bdb8998f933720","isMergeCommit":false,"messageTitle":"Update ModuleMethodsController.java","messageBody":"Fix check style","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"4a9da733161f3cb61b8864be06a17002d3a08479","isMergeCommit":false,"messageTitle":"Add integration tests for add module","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":17},"test-code":{"insertions":218,"deletions":146}}},{"hash":"4bc55d929ed00a053f9acebdc3212bed4f97f026","isMergeCommit":true,"messageTitle":"Merge pull request #80 from ryanlohyr/ryan/feat/integrationTest","messageBody":"Refactor major to string as well as code quality enhancements","fileTypesAndContributionMap":{}},{"hash":"5216aea0afec95b88b830c36d29866f7a0fbc961","isMergeCommit":true,"messageTitle":"Merge master changes","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"6e4f64b88370dc08a61bb8ada4f4d9902bf00f89","isMergeCommit":false,"messageTitle":"Fix windows newline error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":13,"deletions":0}}},{"hash":"a887e6ec49588e4a8ebf39a59cd8db6e99db22a2","isMergeCommit":false,"messageTitle":"Fix windows bug","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":0}}},{"hash":"df49fbdae4b57e96554b689a610f990c65132794","isMergeCommit":true,"messageTitle":"Merge pull request #81 from ryanlohyr/ryan/feat/integrationTest","messageBody":"Integration tests for \u0027add module to student\u0027","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"0c027b646ac0bc5c0d4df7443cc52d397cfd7906","isMergeCommit":false,"messageTitle":"Add Integration tests and optimise recommended schedule","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":80,"deletions":41},"test-code":{"insertions":33,"deletions":0}}},{"hash":"4297caf49c394475bf0282c1fa04f6d7c1a01836","isMergeCommit":false,"messageTitle":"Fix windows failed test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":10,"deletions":3}}},{"hash":"7ecccaa08fdb2ea93d8d7e0033b6712fb923edfd","isMergeCommit":true,"messageTitle":"Merge pull request #131 from ryanlohyr/ryan/feat/optimise","messageBody":"Add Integration tests and optimise recommended schedule","fileTypesAndContributionMap":{}},{"hash":"a5f3dc0e9acdebae40163dce9630af84397eb9b2","isMergeCommit":false,"messageTitle":"Add support for CS and integration tests for adding CS to schedule","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":177,"deletions":100},"test-code":{"insertions":39,"deletions":3}}},{"hash":"a9e8048156cd07128a7479376f8d61037a9c7fbb","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":18}}},{"hash":"0e66e0c0190a2dc205dc6b2aa151d9302190607a","isMergeCommit":false,"messageTitle":"Fix unit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":11}}},{"hash":"56a505c4ccf188f7a9d005631b4e4210faffed44","isMergeCommit":false,"messageTitle":"Add invalidModuleCode Exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":1},"test-code":{"insertions":1,"deletions":1}}},{"hash":"591b990c47d6ecf0b35265d1c3929c280b370361","isMergeCommit":true,"messageTitle":"Merge pull request #132 from ryanlohyr/ryan/feat/addCSRecommended","messageBody":"Add support for CS and integration tests for adding CS to schedule","fileTypesAndContributionMap":{}},{"hash":"c3c51f20182eccfe541c4a622dd2de947526b7f8","isMergeCommit":false,"messageTitle":"Add beautifed ui for arrays","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":58},"test-code":{"insertions":2,"deletions":2}}},{"hash":"85f0b935aadba2e6be0220273f33102c4f9c14ae","isMergeCommit":true,"messageTitle":"Merge pull request #133 from ryanlohyr/ryan/feat/addCSRecommended","messageBody":"Add beautifed ui for arrays","fileTypesAndContributionMap":{}}]}],"janelleenqi":[{"date":"2023-10-07","commitResults":[{"hash":"b8e95e351ff1f9e8058d1fa4512b9fed2a801ff5","isMergeCommit":true,"messageTitle":"Merge pull request #1 from SebasFok/SebasFok-AboutUs","messageBody":"Add AboutUs information for Sebastian","fileTypesAndContributionMap":{}},{"hash":"215bbf707ba73e12fe4a3852bd195add31b9563b","isMergeCommit":false,"messageTitle":"Edit AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"20248cfdb579d3a65dba6b00480f73fd6818e9de","isMergeCommit":true,"messageTitle":"Merge pull request #3 from rohitcube/master","messageBody":"added profile - rohit","fileTypesAndContributionMap":{}},{"hash":"320cf1073f08efaeb681a28d2a71a2c05d03f61a","isMergeCommit":false,"messageTitle":"Edit AboutUs.md to include github","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"eeadb9d732a337b8cd7c73ed135d8d5aabf3ba2e","isMergeCommit":true,"messageTitle":"Merge AboutUs.md","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"e9a420df1a3a38da09d884a238231f1d151f3f37","isMergeCommit":false,"messageTitle":"add \"left\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":97,"deletions":22}}},{"hash":"d61cfbec5c631f4536a0498f84b53a469717b7a9","isMergeCommit":false,"messageTitle":"delete unnecessary lines","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"9fec7539e4da6bde4964b8bb37ea3827706ac546","isMergeCommit":false,"messageTitle":"add ModuleListTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":44,"deletions":0}}},{"hash":"22d2823da7d4c2553ed68abf4765cc2f69476943","isMergeCommit":false,"messageTitle":"add listModulesLeftTest for successful scenario in ModulePlannerControllerTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":20,"deletions":0}}},{"hash":"c14bd0e9753371612f42b4a7653b130eedb55459","isMergeCommit":false,"messageTitle":"add existsTest for successful scenarios in ModuleListTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":24,"deletions":2}}},{"hash":"fe408d5d36d769ff7ccd93af2aa871dbb174bc36","isMergeCommit":false,"messageTitle":"add some exception handling for ModuleList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":14}}},{"hash":"fff60307f1c5bdb366bcd603e5b712359400b076","isMergeCommit":false,"messageTitle":"add failure scenarios for existsTest and getDifferenceTest in ModuleListTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":8},"test-code":{"insertions":30,"deletions":7}}},{"hash":"21c26955eebadc657445a51c384758035a3bde48","isMergeCommit":false,"messageTitle":"add javadoc comments for functions in the \"left\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":0}}},{"hash":"8789c06c3791750c5fd338706ea328ffb9040de7","isMergeCommit":false,"messageTitle":"Add success scenario where mainModuleList is empty for existsTest for ModuleListTest. This closes #10","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":16},"test-code":{"insertions":11,"deletions":0}}},{"hash":"bd71200339e77f407935b3039a6437d4e41a9cd7","isMergeCommit":false,"messageTitle":"Edit for build-and-check Gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":30},"test-code":{"insertions":9,"deletions":7}}},{"hash":"1c3dba0cc588f9746f2a6706955df611cf1dac8c","isMergeCommit":false,"messageTitle":"Edit 2 for build-and-check Gradle (add new line at the end of the file)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"7103ecb9071ddb693815469edc4a98c724696ce3","isMergeCommit":false,"messageTitle":"Edit 3 for build-and-check Gradle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"28c461ff31ca243dacb48ca80caca708351319c5","isMergeCommit":true,"messageTitle":"Merge pull request #13 from janelleenqi/branch-left-command","messageBody":"Add Left Command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"4dad4e47e3274967b37f8fdf9168819dc7d8c360","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"ee22092cdb466e755f74b1d931009faf2a8450a3","isMergeCommit":false,"messageTitle":"Reorganise files in directory","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":2,"deletions":1}}},{"hash":"4bb7e1ca9fd650a59260929e471b6fdcc5cf9ae8","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"86a67bc781962dfebf96ff33220836d88f56949d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-shift-file","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"844497020cb6212656e880719bbbd03584f59310","isMergeCommit":false,"messageTitle":"Assertions Enabled in the build.gradle","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":1}}},{"hash":"8fe8d35becdda7684f96ce0a750afda64d581a87","isMergeCommit":false,"messageTitle":"Add assertions to ModuleList","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0}}},{"hash":"634977a79898a14c9da7a96127606077f40d63f6","isMergeCommit":false,"messageTitle":"Update DeveloperGuide for Left","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":34,"deletions":8}}},{"hash":"71a99acc2f14adcb21441720314b3036f25b8db3","isMergeCommit":false,"messageTitle":"Fixes #10, fixes #33","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a4358197e7e9da71f5b3a7cce3beb7eabcd57224","isMergeCommit":true,"messageTitle":"Merge pull request #34 from janelleenqi/branch-ensure-project-deliverables","messageBody":"Add assertions, Update Developer Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"b9fac348cbba2fe6641b522779774367f60831de","isMergeCommit":false,"messageTitle":"Update getRequirements to get only module codes from full CEGRequirements.txt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":1}}},{"hash":"449948670f2fb2639a341e9afc3dbb1d1699d626","isMergeCommit":false,"messageTitle":"Add skeleton of \"required\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":8}}}]},{"date":"2023-10-29","commitResults":[{"hash":"67ba22e5c71002d4c29b71c0e9bc4aa7e1c8f176","isMergeCommit":false,"messageTitle":"Show half table","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":1}}},{"hash":"a457e05e8264244efecf3d6ea200b01d860c35a1","isMergeCommit":false,"messageTitle":"Complete simple formatting for \"required\" feature","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":41}}},{"hash":"0dcce0323d8643c7a55fcfe68a49bb214cd8cacc","isMergeCommit":false,"messageTitle":"add \"required\" feature for the major \"CS\"","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"18be58c5dbf0b09b3bb9857962bd2280647d269c","isMergeCommit":false,"messageTitle":"fix formatting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":41}}},{"hash":"1faae023633cccdbcfc83c9a94571c4ce4e45f12","isMergeCommit":false,"messageTitle":"extract getLongestStringLength(File f)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":18}}},{"hash":"c05f39be85d642b4f2a36be9ee52c10f29533ab7","isMergeCommit":false,"messageTitle":"Add javadoc comments for DataRepository.java and CommandLineView.java Fixes #32","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":13}}},{"hash":"12fd2b79dbf99a1a8a651b64d25f9fb6181b4fb4","isMergeCommit":false,"messageTitle":"Attempt 1 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"e2871c016b80321b3234435cc5974b8129f695c9","isMergeCommit":false,"messageTitle":"Attempt 2 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"eea92354de414fdad713768272e01cfdce39024e","isMergeCommit":false,"messageTitle":"Attempt 3 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"254e7224502763d17b0a1c66d8e6515a1a8a1e84","isMergeCommit":false,"messageTitle":"Attempt 4 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"1ffc685b47a7f14c4b49644b8b3db652af1b0510","isMergeCommit":false,"messageTitle":"Attempt 5 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"f0a922ee6e36aba351cdef5d26c728ad822b153a","isMergeCommit":false,"messageTitle":"Attempt 6 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"9ce59a225b8d020f0c5382d2b1df7d3a1b5e2dbb","isMergeCommit":false,"messageTitle":"Attempt 7 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"d1d510937b71872b8a2b0811da87577be201e34b","isMergeCommit":false,"messageTitle":"Attempt 8 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"c2e9b4592b7961585605487af164075e734256d9","isMergeCommit":false,"messageTitle":"Attempt 9 of fixing unicode problems","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"206bda85747cccf85dd05ad738bd880a6e1470b9","isMergeCommit":false,"messageTitle":"Fixes #32","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"01ac435a7756ed81d1085a174bf4719f2805934e","isMergeCommit":true,"messageTitle":"Merge pull request #43 from janelleenqi/Janelle/feature/required-modules","messageBody":"Add feature \"required\"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"c3d197e0536be889cb750228d5f7d4c652222802","isMergeCommit":false,"messageTitle":"Add \u0027left\u0027 and \u0027required\u0027 features into UserGuide #46","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":63,"deletions":0}}},{"hash":"9267bc7e448778e21a576ee511e19d71d32185b2","isMergeCommit":false,"messageTitle":"Add \u0027required\u0027 feature for DeveloperGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":22,"deletions":0}}},{"hash":"3c2031b0be0f32d6db441a45bcf41f589de4172d","isMergeCommit":false,"messageTitle":"Code Quality for ModuleListTest. Fixes #39","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":4}}},{"hash":"1776269a3b23aaf47c7c7659c451d44a3b95efc3","isMergeCommit":false,"messageTitle":"Fix for unmappable characters by changing to # and +","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"0566fe1c15652802ee08dbb73ab2d4808bfd8792","isMergeCommit":false,"messageTitle":"Refactor getRequiredModules","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":5}}},{"hash":"39f679c867106583dd3cce7d80189ebcbb0cc2b5","isMergeCommit":false,"messageTitle":"Add success test case for \u0027required\u0027 feature","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":93,"deletions":0}}},{"hash":"ccadbfc43e487e46c0967fdf9ad1e4fdac7d04b4","isMergeCommit":false,"messageTitle":"Delete redundant lines for testing of \u0027required\u0027 feature \u0027#32","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":4}}},{"hash":"efd719136a6985714eddcd66a40b53ea724be921","isMergeCommit":false,"messageTitle":"Gradle checkstyleTest edits","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":7,"deletions":6}}},{"hash":"b701756192c954e149ea783bd211e2055b804f78","isMergeCommit":false,"messageTitle":"Add .trim() to both actual output and expected output","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}},{"hash":"d493c2f156ba0cb3cec61356319bd9d47b0ad011","isMergeCommit":false,"messageTitle":"solve line is longer than 120 problem","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"f5606088b1d004de01e6b69778d8a27ea44b8028","isMergeCommit":false,"messageTitle":"solve line is longer than 120 problem again","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"6f64a2635a1120c0b4594c0256379bc440de9bf2","isMergeCommit":false,"messageTitle":"Revert \"add\"","messageBody":"This reverts commit 3994c04761f6f7f30798732bb9ea82273de207f0.\n","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"73401fde2d9aa54abee4fb750195e8b6b816d52c","isMergeCommit":false,"messageTitle":"String.format","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"d4e9c6c90d7333990ace3d6735775050ffea528b","isMergeCommit":false,"messageTitle":"startsWith","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":52}}},{"hash":"553444abe4f5a4ec0f78221e13143e90cb8c4cf3","isMergeCommit":false,"messageTitle":"delete","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"15f2e47338862cbd87e1d5c323cf7bd9e8ece1cc","isMergeCommit":true,"messageTitle":"Merge pull request #47 from janelleenqi/Janelle/feature/success-testing-for-required","messageBody":"Add positive testing for \u0027required\u0027 feature","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"c23c2ea0a47fdc3dcf6f7dfa71c3a2f6293f27ec","isMergeCommit":false,"messageTitle":"Update modulesMajor to use real data, refactor \"left\" and \"required\" features","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":205,"deletions":145},"other":{"insertions":3,"deletions":3},"test-code":{"insertions":36,"deletions":19}}},{"hash":"d00f0ec78b7918584314623cea6fdb6bb265eede","isMergeCommit":false,"messageTitle":"Add Javadoc Comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":3}}},{"hash":"4f97c1963ced94c74ac6f2cd36eef08e8536c5f9","isMergeCommit":true,"messageTitle":"Merge Conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"067c18e3bda59bb92c3f4e021ebe5f139ca64b7f","isMergeCommit":true,"messageTitle":"Merge pull request #57 from rohitcube/rohit/feat/add-fuzzy-search-to-API-class","messageBody":"Update User Guide","fileTypesAndContributionMap":{}},{"hash":"7c2515604d709b40372f8ecee55240a7ac793445","isMergeCommit":true,"messageTitle":"Merge Conflicts","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3600646a5b2954d6972b5b0b822f1365d0dd39c1","isMergeCommit":false,"messageTitle":"improves #47 #13","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"8ad18c6b8d66abfd6e9fd7326367c4613053f0df","isMergeCommit":true,"messageTitle":"Merge pull request #59 from janelleenqi/Janelle/feature/left-function-improve","messageBody":"Update modulesMajor","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"79f97143f3a25c66178c32aa2ef40b5264a08c0d","isMergeCommit":false,"messageTitle":"fixes #27","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":7},"docs":{"insertions":2,"deletions":2}}},{"hash":"81d9043ca68bafd58de577128be4d15c76114d94","isMergeCommit":true,"messageTitle":"merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c5d099d1153b9d41de064c667fd5a048bdf4049f","isMergeCommit":true,"messageTitle":"Merge pull request #63 from janelleenqi/Janelle/fix/complete","messageBody":"Fix Complete Feature","fileTypesAndContributionMap":{}},{"hash":"7a397044030222664d7c609f8dd874db2d6c2575","isMergeCommit":false,"messageTitle":"fix bug in #32","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":3}}},{"hash":"3031f9915a79df267965565dc276e001eff575bc","isMergeCommit":true,"messageTitle":"merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"0fbbce1e41174eeeeb5a7639d938823a01622a6f","isMergeCommit":true,"messageTitle":"Merge pull request #65 from janelleenqi/Janelle/fix/required","messageBody":"Fix bug in \"required\" feature","fileTypesAndContributionMap":{}},{"hash":"81abd31e1ead822715cf36bd85c60f9259460266","isMergeCommit":false,"messageTitle":"remove txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":60,"deletions":120}}},{"hash":"d008aa58359a4c03b67f2133c1a127394294c30e","isMergeCommit":false,"messageTitle":"checkstyle fixes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5},"test-code":{"insertions":2,"deletions":3}}},{"hash":"2bbabbdeae1704bc7572b3a9b3927e58dd3c868c","isMergeCommit":true,"messageTitle":"Merge pull request #69 from janelleenqi/Janelle/fix/remove-txt-files","messageBody":"Remove txt files for required","tags":["v2.0","v1.01"],"fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"4d97258274cc7992c1cd9f10f8d4fde09ee7b1f3","isMergeCommit":false,"messageTitle":"Add Left Sequence Diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":49,"deletions":0}}},{"hash":"1439244e6e6bea7bb48a30de5b09cf6255f4beb3","isMergeCommit":false,"messageTitle":"Edit Left Sequence Diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":4}}},{"hash":"c577cbe307f062f479ef439b591b658a655ecbe0","isMergeCommit":false,"messageTitle":"Add Required Sequence Diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":35,"deletions":0}}},{"hash":"0e5711b55dd8196fdbf359865ceb5c91b9037d55","isMergeCommit":false,"messageTitle":"Add Required and Left Sequence Diagram to DeveloperGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":20}}},{"hash":"8ff0da4548e548624d6bb227436007c9967d9a82","isMergeCommit":true,"messageTitle":"Merge pull request #74 from janelleenqi/Janelle/guide/update","messageBody":"Add sequence diagram for \"left\" and \"required\" command","fileTypesAndContributionMap":{}},{"hash":"c4277cca7df9536c80877fc3bd17f157b84e5a8a","isMergeCommit":false,"messageTitle":"Update User Guide and add screenshots","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":43}}},{"hash":"845c203f35fd873d40810af5c9baba36a407f15e","isMergeCommit":false,"messageTitle":"Update User Guide and add screenshots #46","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"f9ac770dba703311a88a27077c3d9f81436564a3","isMergeCommit":true,"messageTitle":"Merge pull request #75 from janelleenqi/Janelle/guide/update_UG","messageBody":"Update UG","fileTypesAndContributionMap":{}},{"hash":"99e003e9b11ea615e0b04bbf30fbeed61abb7e94","isMergeCommit":false,"messageTitle":"Fix Refactoring of ModuleList Part 1","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":57,"deletions":14}}},{"hash":"69220d6a6bd97f8fcf50732eb1b3ac87a42059ee","isMergeCommit":false,"messageTitle":"Fix Refactoring of ModuleList Part 1 (still have errors)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":57,"deletions":47}}},{"hash":"48ae4f3f58241b322fea993c4fe3b0fb3f8651a9","isMergeCommit":true,"messageTitle":"Merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2383a2aa287af2dbbe7f9314285f66ca9a817d8e","isMergeCommit":false,"messageTitle":"Merge (with errors)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-04","commitResults":[{"hash":"aa40cfd17cdd82124d6c7b4f307544fc0ec02bb8","isMergeCommit":true,"messageTitle":"Merge (with errors)","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c13e33310a18149ad005827bd0bec9090900512d","isMergeCommit":false,"messageTitle":"add and delete can work with cs1010 sem 1","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":98},"test-code":{"insertions":15,"deletions":8}}},{"hash":"e332ab82a72efd08de3cae680dc7f660ab1d6366","isMergeCommit":false,"messageTitle":"pass SUT tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":46},"test-code":{"insertions":37,"deletions":89}}},{"hash":"137dfa54275392eaa568beeb722ec90d894be7d0","isMergeCommit":false,"messageTitle":"pass checkstyle tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":16},"test-code":{"insertions":4,"deletions":2}}},{"hash":"56c8bbf3f8f26a7271427d933faf890a74896ca7","isMergeCommit":false,"messageTitle":"refactor code (mainModuleList in Module List from ArrayList\u003cString\u003e to ArrayList\u003cModule\u003e) fixes #129","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":5}}},{"hash":"b6d785235a1232c7459c93afeb1d773ae076ead1","isMergeCommit":true,"messageTitle":"Merge pull request #130 from janelleenqi/Janelle/fix/refactor","messageBody":"Refactor for Module List and Student","fileTypesAndContributionMap":{}}]}],"rohitcube":[{"date":"2023-10-07","commitResults":[{"hash":"a705965a345d0fb777a8268c24a02cb95f3c7009","isMergeCommit":false,"messageTitle":"added profile - rohit","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-09","commitResults":[{"hash":"67dfcdb437ce0cff8d2449ca49a32c15acb77cd7","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"526e6983d8cb279b409a14132ce402926860616a","isMergeCommit":true,"messageTitle":"Merge pull request #6 from rohitcube/master","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"abbb47faf32f9201108d53c0b360b528451fdc81","isMergeCommit":false,"messageTitle":"Added API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":110,"deletions":1},"other":{"insertions":1,"deletions":0},"test-code":{"insertions":19,"deletions":0}}},{"hash":"3295f1687ef050ad59ed4739c2bbb84b0b40cbf1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e6920151453fa8acfaef5a9c2c94aaf1a4288172","isMergeCommit":true,"messageTitle":"Fixed unresolved merge","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4bbac7ecc89de2ea1f18a0b3fe5aa5e1bc4f2265","isMergeCommit":false,"messageTitle":"Add API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}},{"hash":"6cd6c37ead68c4b389fb5c88296604599be37272","isMergeCommit":true,"messageTitle":"Add API class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"06e8865dc23823bff453a73e8ecfa52fffea2b1e","isMergeCommit":false,"messageTitle":"Add API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-19","commitResults":[{"hash":"3127654c68e3fcba58f73ccccf5737502ee90421","isMergeCommit":false,"messageTitle":"Fix indentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":75,"deletions":78},"test-code":{"insertions":0,"deletions":4}}},{"hash":"dca72b7be67ea4541f4246de06a127116d3f8d54","isMergeCommit":true,"messageTitle":"Merge CompletePreqs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f58efff20a7620a2b3490ea0e2d2d10cd90a3b67","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T17-4:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"3858e4f65cfdeeeb9619b94b7bc63b076bba9f71","isMergeCommit":false,"messageTitle":"Fix CheckstyleMain","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":9},"test-code":{"insertions":9,"deletions":8}}},{"hash":"048fcd3aceef10dca2c3f33158706897d68b3bab","isMergeCommit":false,"messageTitle":"Remove API Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":102},"test-code":{"insertions":0,"deletions":16}}},{"hash":"fde33ba4b836e32a85c0f5125f315203cbbba6c6","isMergeCommit":true,"messageTitle":"Merge pull request #23 from rohitcube/branch-AddAPIClass","messageBody":"Remove API Class","tags":["v0.1"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"b2440a2441f95ea27fb2d5a8ea2804c3189bc3a9","isMergeCommit":false,"messageTitle":"Add API Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":0},"test-code":{"insertions":51,"deletions":0}}},{"hash":"a74c4c143857f517b7518f354aa339e5b90c9eb6","isMergeCommit":false,"messageTitle":"Add API Class","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"43d67d6a9cb7a1e38683a3f6edd3f56b9c49baa1","isMergeCommit":true,"messageTitle":"Merge pull request #35 from rohitcube/Add-API-class-and-parser","messageBody":"Add API class and functions","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"6dcec60b621b4f3a3b9e66fbf1c5318b5201e3f7","isMergeCommit":false,"messageTitle":"Add functions that return json to API class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":4},"test-code":{"insertions":0,"deletions":1}}},{"hash":"c4b9c1f6be1164dc52cef97da20ee323e347d0e4","isMergeCommit":false,"messageTitle":"Deleted \u0027info\u0027 command from module controller","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":11}}},{"hash":"ff4016383cf24bb5d6c682ea99fd9fd321149ad6","isMergeCommit":true,"messageTitle":"Merge pull request #40 from rohitcube/rohit/fix/add-json-functions-to-api-class","messageBody":"Rohit/fix/add json functions to api class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"2ca63dde17f55b7b0e8e3f0c1b3be342010437c3","isMergeCommit":false,"messageTitle":"Add search, info, description and workload functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":144,"deletions":22},"test-code":{"insertions":32,"deletions":11}}}]},{"date":"2023-10-30","commitResults":[{"hash":"4451d088837dd51df80f1b703f8fd7ecf0838949","isMergeCommit":false,"messageTitle":"Add search, info, description and workload functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":12},"test-code":{"insertions":49,"deletions":11}}},{"hash":"bbbf0826c9a9c123a813ada18a08c516f184e59b","isMergeCommit":false,"messageTitle":"Add tests for Api class and error handling (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":8},"test-code":{"insertions":9,"deletions":4}}},{"hash":"77c8a84bf8fc586257dcfe925a85898e4918caa7","isMergeCommit":true,"messageTitle":"Resolve conflicts with team repo (#30)","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8c80c73fa2d454bc9650a75b8eea902c3e1000ef","isMergeCommit":false,"messageTitle":"Update test variable names (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":10,"deletions":10}}}]},{"date":"2023-11-01","commitResults":[{"hash":"c0a2009020d81655620688e8f1e47e1905b5c14d","isMergeCommit":false,"messageTitle":"Update test variable names (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":105,"deletions":92}}},{"hash":"9d83c0f9f08ae906721c8ca7aff6a2b2d8ab3cbc","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-search-function-to-api-class","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/controllers/ModulePlannerController.java\n#\tsrc/main/java/seedu/duke/models/logic/Api.java\n","fileTypesAndContributionMap":{}},{"hash":"8e12f33d024ff7bb4101e5039569ebd1de41bae9","isMergeCommit":false,"messageTitle":"Resolve merge, add error messages for info and search commands (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":14}}},{"hash":"e752687525b4e8926275dac2b891c36f8c33523d","isMergeCommit":false,"messageTitle":"Add comments to functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":153,"deletions":73}}},{"hash":"93e90c4e667ab8d18c1dc02d5e2afd40bfe5906d","isMergeCommit":false,"messageTitle":"Add comments to functions (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":105,"deletions":110}}},{"hash":"2db8d33f2f2fa9b5e354054cfa8cbe51779357dc","isMergeCommit":true,"messageTitle":"Merge pull request #52 from rohitcube/rohit/feat/add-search-function-to-api-class","messageBody":"Add search function to api class","fileTypesAndContributionMap":{}},{"hash":"7f83666efdc70d14f9a99f53dc0273143d5389cc","isMergeCommit":false,"messageTitle":"Add author tag (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"531291a8d050b72fc369f8021a4a32a55499a421","isMergeCommit":false,"messageTitle":"Add author tag (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"014572732b65f145e0f5871ab77ce8965f7357ee","isMergeCommit":true,"messageTitle":"Merge pull request #53 from rohitcube/rohit/feat/add-search-function-to-api-class","messageBody":"Add author tag","fileTypesAndContributionMap":{}},{"hash":"b62653d85acbe230e324e735571819e5c2c34ff9","isMergeCommit":false,"messageTitle":"Abstract out methods from controller, changes to handle exceptions within the function (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":38}}},{"hash":"e2da2acfc867499c672c7fac4aad59f58f0d366e","isMergeCommit":false,"messageTitle":"Abstract out methods from controller, handle exceptions within function (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":11},"test-code":{"insertions":0,"deletions":5}}},{"hash":"db43264fbab3c7ce54cd4dc68fcdba8e4c3258b5","isMergeCommit":false,"messageTitle":"Abstract out methods from controller, handle exceptions within function (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"ca0a48f34ad3e9f6ae38c13609d848f199678600","isMergeCommit":true,"messageTitle":"Merge pull request #55 from rohitcube/rohit/feat/add-search-function-to-api-class","messageBody":"Refactor code from controller","fileTypesAndContributionMap":{}},{"hash":"c2cf751646e60fa094aa7150b51aa0fcb4506756","isMergeCommit":false,"messageTitle":"Deleted comments from API class(#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":24}}},{"hash":"7cd16ba0ac51e58fd456c5ef65861d6300680ee9","isMergeCommit":false,"messageTitle":"update user guide and DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":62,"deletions":8}}},{"hash":"08edb2d81abab8cb850daf3127f1ff86b50988c4","isMergeCommit":false,"messageTitle":"update user guide and DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"333bdeb5f10a3836d2bdfa13bac2cb7ef9153c7b","isMergeCommit":false,"messageTitle":"fixed bugs for info command (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":2},"test-code":{"insertions":11,"deletions":0}}},{"hash":"04a452e9d7be6cce3cccfc9e3cf9f7a411d84e0e","isMergeCommit":false,"messageTitle":"fixed bugs for info command (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":10}}},{"hash":"32dfdf0cefc8bb490008431f86284c793d0b02f6","isMergeCommit":false,"messageTitle":"fixed bugs for info command (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"3d03d2575163b44a209481067caa552adf4d286e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-fuzzy-search-to-API-class","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"44a62845adbabf17e8a0f4c971c0f185b3bee1ff","isMergeCommit":true,"messageTitle":"Merge pull request #60 from rohitcube/rohit/feat/add-fuzzy-search-to-API-class","messageBody":"Fixed bug for info command","fileTypesAndContributionMap":{}},{"hash":"0e679846e27246feed3fcdf387596d59883c7164","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"e9ca492412215ec6f73dabec1fdb6651102a6455","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-fuzzy-search-to-API-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f46bcb0d8ae084858347dfb081e34e97e110a3ad","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":8}}},{"hash":"fc01cb318160ff6d58c94fb4a3578a891ba4a542","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into rohit/feat/add-fuzzy-search-to-API-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"470f82019d57ad0d287664024bad05222655a46f","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"b2ca119d39a1af12fca503bdc6f3cd9e67a6a3aa","isMergeCommit":false,"messageTitle":"fixed bugs for info command again (#30)","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":6}}},{"hash":"9f9d8aadfb912f35987426ea0eecf1a6284edccc","isMergeCommit":true,"messageTitle":"Merge pull request #66 from rohitcube/rohit/feat/add-fuzzy-search-to-API-class","messageBody":"Fix bugs","tags":["v1.1"],"fileTypesAndContributionMap":{}}]}],"CerIsaiah":[{"date":"2023-10-08","commitResults":[{"hash":"d6daf466c3aae14881d7203cec549477dda5aca9","isMergeCommit":false,"messageTitle":"Add photo and aboutUs information","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}},{"hash":"621e25c4f695763044e239140052377d8211fa05","isMergeCommit":true,"messageTitle":"Add aboutUs information","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-09","commitResults":[{"hash":"1e56807ba29080daddc8d8d177aa0110c772c699","isMergeCommit":false,"messageTitle":"Fixed merge conflicts with about us","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}}]},{"date":"2023-10-18","commitResults":[{"hash":"5c7739cc63dfdba986b90ce2f2fcce5c0683a2b2","isMergeCommit":false,"messageTitle":"Add the complete class command to mark when a class is complete","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":165,"deletions":3}}},{"hash":"e39a5de84acff43f9364ed22ee1dda158fca3ecf","isMergeCommit":true,"messageTitle":"Merge major and complete commands","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"348b3da8aa36d1612001cf37da34c02482855c12","isMergeCommit":false,"messageTitle":"Fix merge tests conflicts","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":1},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-25","commitResults":[{"hash":"1cb45d2901f18782158ee8871e09adb98caee588","isMergeCommit":false,"messageTitle":"fix complete feature bugs and optimized features","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":9}}},{"hash":"4a6d6f64b8e288c9ff071bb39982f18ab1824149","isMergeCommit":true,"messageTitle":"Merge pull request #38 from CerIsaiah/bug-completefeature","messageBody":"fix complete feature bugs and optimized features","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"SebasFok":{"docs":117,"functional-code":476,"test-code":56},"ryanlohyr":{"docs":107,"functional-code":1399,"test-code":338},"janelleenqi":{"docs":206,"functional-code":362,"test-code":128,"other":1},"rohitcube":{"docs":48,"functional-code":273,"test-code":99,"other":1},"CerIsaiah":{"docs":6,"functional-code":192,"test-code":0}},"authorContributionVariance":{"SebasFok":9664.73,"ryanlohyr":97249.305,"janelleenqi":19730.04,"rohitcube":22047.438,"CerIsaiah":704.4729},"authorDisplayNameMap":{"SebasFok":"CS2113-T17-4 SEBA..HUNG","ryanlohyr":"CS2113-T17-4 RYAN.. RUI","janelleenqi":"CS2113-T17-4 LIOW..ELLE","rohitcube":"CS2113-T17-4 ROHI..THAN","CerIsaiah":"CS2113-T17-4 CERV..DEAN"}} diff --git a/AY2324S1-CS2113-T18-1_tp_master/authorship.json b/AY2324S1-CS2113-T18-1_tp_master/authorship.json index 01afaf7..6571e06 100644 --- a/AY2324S1-CS2113-T18-1_tp_master/authorship.json +++ b/AY2324S1-CS2113-T18-1_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Duke project template","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"This is a project template for a greenfield Java project. It\u0027s named after Chess and Master. Given below are instructions on how to use it.","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"## Setting up in Intellij","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"Prerequisites: JDK 11 (use the exact version), update Intellij to the most recent version.","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"1. **Ensure Intellij JDK 11 is defined as an SDK**, as described [here](https://www.jetbrains.com/help/idea/sdk.html#set-up-jdk) -- this step is not needed if you have used JDK 11 in a previous Intellij project.","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"1. **Import the project _as a Gradle project_**, as described [here](https://se-education.org/guides/tutorials/intellijImportGradleProject.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"1. **Verify the set up**: After the importing is complete, locate the `src/main/java/seedu/duke/Duke.java` file, right-click it, and choose `Run Duke.main()`. If the setup is correct, you should see something like the below:","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" \u003e Task :compileJava","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":" \u003e Task :processResources NO-SOURCE","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":" \u003e Task :classes","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":" \u003e Task :Duke.main()","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":" Hello from","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" ____ _ ","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" | _ \\ _ _| | _____ ","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" | | | | | | | |/ / _ \\","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" | |_| | |_| | \u003c __/","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" |____/ \\__,_|_|\\_\\___|","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":25,"author":{"gitId":"-"},"content":" What is your name?","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" Type some word and press enter to let the execution proceed to the end.","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"## Build automation using Gradle","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"* This project uses Gradle for build automation and dependency management. It includes a basic build script as well (i.e. the `build.gradle` file).","lastModifiedDate":"2020-05-24"},{"lineNumber":32,"author":{"gitId":"-"},"content":"* If you are new to Gradle, refer to the [Gradle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/gradle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":34,"author":{"gitId":"-"},"content":"## Testing","lastModifiedDate":"2020-05-24"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"-"},"content":"### I/O redirection tests","lastModifiedDate":"2020-05-24"},{"lineNumber":37,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"* To run _I/O redirection_ tests (aka _Text UI tests_), navigate to the `text-ui-test` and run the `runtest(.bat/.sh)` script.","lastModifiedDate":"2020-05-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":40,"author":{"gitId":"-"},"content":"### JUnit tests","lastModifiedDate":"2020-05-24"},{"lineNumber":41,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":42,"author":{"gitId":"-"},"content":"* A skeleton JUnit test (`src/test/java/seedu/duke/DukeTest.java`) is provided with this project template. ","lastModifiedDate":"2020-05-24"},{"lineNumber":43,"author":{"gitId":"-"},"content":"* If you are new to JUnit, refer to the [JUnit Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/junit.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":45,"author":{"gitId":"-"},"content":"## Checkstyle","lastModifiedDate":"2020-05-24"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":47,"author":{"gitId":"-"},"content":"* A sample CheckStyle rule configuration is provided in this project.","lastModifiedDate":"2020-05-24"},{"lineNumber":48,"author":{"gitId":"-"},"content":"* If you are new to Checkstyle, refer to the [Checkstyle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/checkstyle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":50,"author":{"gitId":"-"},"content":"## CI using GitHub Actions","lastModifiedDate":"2020-05-24"},{"lineNumber":51,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":52,"author":{"gitId":"-"},"content":"The project uses [GitHub actions](https://github.com/features/actions) for CI. When you push a commit to this repo or PR against it, GitHub actions will run automatically to build and verify the code as updated by the commit/PR.","lastModifiedDate":"2020-05-24"},{"lineNumber":53,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":54,"author":{"gitId":"-"},"content":"## Documentation","lastModifiedDate":"2020-05-24"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"-"},"content":"`/docs` folder contains a skeleton version of the project documentation.","lastModifiedDate":"2020-05-24"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"-"},"content":"Steps for publishing documentation to the public: ","lastModifiedDate":"2020-05-24"},{"lineNumber":59,"author":{"gitId":"-"},"content":"1. If you are using this project template for an individual project, go your fork on GitHub.\u003cbr\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":60,"author":{"gitId":"-"},"content":" If you are using this project template for a team project, go to the team fork on GitHub.","lastModifiedDate":"2020-05-24"},{"lineNumber":61,"author":{"gitId":"-"},"content":"1. Click on the `settings` tab.","lastModifiedDate":"2020-05-24"},{"lineNumber":62,"author":{"gitId":"-"},"content":"1. Scroll down to the `GitHub Pages` section.","lastModifiedDate":"2020-05-24"},{"lineNumber":63,"author":{"gitId":"-"},"content":"1. Set the `source` as `master branch /docs folder`.","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"-"},"content":"1. Optionally, use the `choose a theme` button to choose a theme for your documentation.","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"onx001":1,"-":63}},{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" mainClass.set(\"chessmaster.ChessMaster\")","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" archiveBaseName.set(\"chessmaster\")","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"compileJava.options.encoding \u003d \u0027UTF-8\u0027","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"tasks.withType(JavaCompile) {","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" options.encoding \u003d \u0027UTF-8\u0027","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"ken-ruster":1,"TongZhengHong":7,"-":45}},{"path":"build.xml","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"\u003cproject name\u003d\"ChessMaster\" basedir\u003d\".\" default\u003d\"main\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"src.dir\" value\u003d\"src/main/java\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"build.dir\" value\u003d\"build\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"classes.dir\" value\u003d\"${build.dir}/classes\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"jar.dir\" value\u003d\"${build.dir}/jar\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"main-class\" value\u003d\"chessmaster.ChessMaster\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"clean\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" \u003cdelete dir\u003d\"${build.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"compile\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" \u003cmkdir dir\u003d\"${classes.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" \u003cjavac includeantruntime\u003d\"false\" target\u003d\"11\" source\u003d\"11\" encoding\u003d\"utf8\" srcdir\u003d\"${src.dir}\" destdir\u003d\"${classes.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"jar\" depends\u003d\"compile\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" \u003cmkdir dir\u003d\"${jar.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" \u003cjar destfile\u003d\"${jar.dir}/${ant.project.name}.jar\" basedir\u003d\"${classes.dir}\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" \u003cmanifest\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" \u003cattribute name\u003d\"Main-Class\" value\u003d\"${main-class}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" \u003c/manifest\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" \u003c/jar\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"run\" depends\u003d\"jar\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" \u003cjava jar\u003d\"${jar.dir}/${ant.project.name}.jar\" fork\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"clean-build\" depends\u003d\"clean,jar\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"main\" depends\u003d\"clean,run\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"\u003c/project\u003e","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"TongZhengHong":35}},{"path":"config/checkstyle/checkstyle.xml","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"\u003c?xml version\u003d\"1.0\" encoding\u003d\"UTF-8\"?\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":2,"author":{"gitId":"-"},"content":"\u003c!DOCTYPE module PUBLIC","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":" \"-//Checkstyle//DTD Checkstyle Configuration 1.3//EN\"","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":" \"https://checkstyle.org/dtds/configuration_1_3.dtd\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"\u003c!--","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":" This configuration file enforces rules for the coding standard at","lastModifiedDate":"2022-05-29"},{"lineNumber":8,"author":{"gitId":"-"},"content":" https://se-education.org/guides/conventions/java/basic.html","lastModifiedDate":"2022-05-29"},{"lineNumber":9,"author":{"gitId":"-"},"content":"--\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"\u003cmodule name\u003d\"Checker\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"FileTabCharacter\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":14,"author":{"gitId":"-"},"content":" \u003c!-- Checks that there are no tab characters in the file. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":15,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"NewlineAtEndOfFile\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":18,"author":{"gitId":"-"},"content":" \u003c!-- Accept LF, CR or CRLF to accomodate devs who prefer different line endings --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":19,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"lineSeparator\" value\u003d\"lf_cr_crlf\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":20,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":21,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":22,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"RegexpSingleline\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":23,"author":{"gitId":"-"},"content":" \u003c!-- Checks that FIXME is not used in comments. TODO is preferred. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":24,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"((//.*)|(\\*.*))FIXME\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":25,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"message\" value\u003d\u0027TODO is preferred to FIXME.\"\u0027 /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":26,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":27,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"SuppressionFilter\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":29,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"file\" value\u003d\"${config_loc}/suppressions.xml\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":30,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":32,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LineLength\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"-"},"content":" \u003c!-- Checks if a line is too long. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":34,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"max\" value\u003d\"120\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":35,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":37,"author":{"gitId":"-"},"content":" \u003c!-- All Java AST specific tests live under TreeWalker module. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":38,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"TreeWalker\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":40,"author":{"gitId":"-"},"content":" \u003c!-- Required to allow exceptions in code style --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":41,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"SuppressionCommentFilter\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"offCommentFormat\" value\u003d\"CHECKSTYLE.OFF\\: ([\\w\\|]+)\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"onCommentFormat\" value\u003d\"CHECKSTYLE.ON\\: ([\\w\\|]+)\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":44,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"checkFormat\" value\u003d\"$1\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":45,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":47,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":48,"author":{"gitId":"-"},"content":" IMPORT CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":49,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":50,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":51,"author":{"gitId":"-"},"content":" \u003c!-- Checks for redundant import statements.","lastModifiedDate":"2022-04-29"},{"lineNumber":52,"author":{"gitId":"-"},"content":" An import statement is redundant if:","lastModifiedDate":"2022-04-29"},{"lineNumber":53,"author":{"gitId":"-"},"content":" * It is a duplicate of another import. This is, when a class is imported more than once.","lastModifiedDate":"2022-04-29"},{"lineNumber":54,"author":{"gitId":"-"},"content":" * The class non-statically imported is from the java.lang package, e.g. importing java.lang.String.","lastModifiedDate":"2022-04-29"},{"lineNumber":55,"author":{"gitId":"-"},"content":" * The class non-statically imported is from the same package as the current package.","lastModifiedDate":"2022-04-29"},{"lineNumber":56,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":57,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"RedundantImport\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":58,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":59,"author":{"gitId":"-"},"content":" \u003c!-- Checks for unused import statements.","lastModifiedDate":"2022-04-29"},{"lineNumber":60,"author":{"gitId":"-"},"content":" An import statement is unused if:","lastModifiedDate":"2022-04-29"},{"lineNumber":61,"author":{"gitId":"-"},"content":" It\u0027s not referenced in the file.","lastModifiedDate":"2022-04-29"},{"lineNumber":62,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":63,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"UnusedImports\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":64,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":65,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"AvoidStarImport\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":66,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":67,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":68,"author":{"gitId":"-"},"content":" NAMING CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":69,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":70,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":71,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"PackageName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":72,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for package names against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":73,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z]+(\\.[a-z][a-z0-9]{1,})*$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":74,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":75,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":76,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":77,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"TypeName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":78,"author":{"gitId":"-"},"content":" \u003c!-- Validates static, final fields against the expression \"^[A-Z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":79,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"TypeName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":80,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":81,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":82,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":83,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ConstantName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":84,"author":{"gitId":"-"},"content":" \u003c!-- Validates non-private, static, final fields against the expression \"^[A-Z][A-Z0-9]*(_[A-Z0-9]+)*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":85,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"ConstantName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":86,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"applyToPrivate\" value\u003d\"false\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":87,"author":{"gitId":"-"},"content":" \u003cmessage key\u003d\"name.invalidPattern\"","lastModifiedDate":"2020-05-24"},{"lineNumber":88,"author":{"gitId":"-"},"content":" value\u003d\"Variable \u0027\u0027{0}\u0027\u0027 should be in ALL_CAPS (if it is a constant) or be private (otherwise).\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":89,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":90,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":91,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":92,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"StaticVariableName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":93,"author":{"gitId":"-"},"content":" \u003c!-- Validates static, non-final fields against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":94,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"StaticVariableName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":95,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z][a-zA-Z0-9]*_?$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":96,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":97,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":98,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":99,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MemberName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":100,"author":{"gitId":"-"},"content":" \u003c!-- Validates non-static members against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":101,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"MemberName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":102,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z][a-zA-Z0-9]*$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":103,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":104,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":105,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":106,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MethodName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":107,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for method names against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":108,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"MethodName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":109,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z][a-zA-Z0-9]*(_[a-z][a-zA-Z0-9]+){0,2}$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":110,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":111,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":112,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ParameterName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":113,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for method parameters against the expression \"^[a-z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":114,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":115,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":116,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":117,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LocalFinalVariableName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":118,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for local final variables against the expression \"^[a-z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":119,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":120,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":121,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":122,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LocalVariableName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":123,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for local variables against the expression \"^[a-z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":124,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":125,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":126,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":127,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":128,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":129,"author":{"gitId":"-"},"content":" LENGTH and CODING CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":130,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":131,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":132,"author":{"gitId":"-"},"content":" \u003c!-- Checks that array type declarations follow Java Style","lastModifiedDate":"2022-04-29"},{"lineNumber":133,"author":{"gitId":"-"},"content":" Java style: public static void main(String[] args) // Allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":134,"author":{"gitId":"-"},"content":" C style: public static void main(String args[]) // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":135,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":136,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ArrayTypeStyle\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":137,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":138,"author":{"gitId":"-"},"content":" \u003c!-- Checks if a catch block is empty and does not contain any comments. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":139,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"EmptyCatchBlock\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":140,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":141,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LeftCurly\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":142,"author":{"gitId":"-"},"content":" \u003c!-- Checks for placement of the left curly brace (\u0027{\u0027). --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":143,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":144,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":145,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":146,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"RightCurly\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":147,"author":{"gitId":"-"},"content":" \u003c!-- Checks right curlies on CATCH, ELSE, and TRY blocks are on","lastModifiedDate":"2022-04-29"},{"lineNumber":148,"author":{"gitId":"-"},"content":" the same line. e.g., the following example is fine:","lastModifiedDate":"2022-04-29"},{"lineNumber":149,"author":{"gitId":"-"},"content":" \u003cpre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":150,"author":{"gitId":"-"},"content":" if {","lastModifiedDate":"2022-04-29"},{"lineNumber":151,"author":{"gitId":"-"},"content":" ...","lastModifiedDate":"2022-04-29"},{"lineNumber":152,"author":{"gitId":"-"},"content":" } else","lastModifiedDate":"2022-04-29"},{"lineNumber":153,"author":{"gitId":"-"},"content":" \u003c/pre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":154,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":155,"author":{"gitId":"-"},"content":" \u003c!-- This next example is not fine:","lastModifiedDate":"2022-04-29"},{"lineNumber":156,"author":{"gitId":"-"},"content":" \u003cpre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":157,"author":{"gitId":"-"},"content":" if {","lastModifiedDate":"2022-04-29"},{"lineNumber":158,"author":{"gitId":"-"},"content":" ...","lastModifiedDate":"2022-04-29"},{"lineNumber":159,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2022-04-29"},{"lineNumber":160,"author":{"gitId":"-"},"content":" else","lastModifiedDate":"2022-04-29"},{"lineNumber":161,"author":{"gitId":"-"},"content":" \u003c/pre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":162,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":163,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":164,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":165,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":166,"author":{"gitId":"-"},"content":" \u003c!-- Checks for braces around loop blocks --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":167,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"NeedBraces\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":168,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":169,"author":{"gitId":"-"},"content":" if (true) return 1; // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":171,"author":{"gitId":"-"},"content":" if (true) { return 1; } // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":173,"author":{"gitId":"-"},"content":" else if {","lastModifiedDate":"2022-04-29"},{"lineNumber":174,"author":{"gitId":"-"},"content":" return 1; // else if should always be multi line","lastModifiedDate":"2022-04-29"},{"lineNumber":175,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2022-04-29"},{"lineNumber":176,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":177,"author":{"gitId":"-"},"content":" if (true)","lastModifiedDate":"2022-04-29"},{"lineNumber":178,"author":{"gitId":"-"},"content":" return 1; // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":179,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":180,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowEmptyLoopBody\" value\u003d\"true\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":181,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":182,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":183,"author":{"gitId":"-"},"content":" \u003c!-- Checks that each variable declaration is in its own statement and on its own line. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":184,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MultipleVariableDeclarations\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":185,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":186,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"OneStatementPerLine\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":187,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":188,"author":{"gitId":"-"},"content":" \u003c!-- Checks that long constants are defined with an upper ell.--\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":189,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"UpperEll\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":190,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":191,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"FallThrough\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":192,"author":{"gitId":"-"},"content":" \u003c!-- Warn about falling through to the next case statement. Similar to","lastModifiedDate":"2022-04-29"},{"lineNumber":193,"author":{"gitId":"-"},"content":" javac -Xlint:fallthrough, but the check is suppressed if a single-line comment","lastModifiedDate":"2022-04-29"},{"lineNumber":194,"author":{"gitId":"-"},"content":" on the last non-blank line preceding the fallen-into case contains \u0027fall through\u0027 (or","lastModifiedDate":"2022-04-29"},{"lineNumber":195,"author":{"gitId":"-"},"content":" some other variants which we don\u0027t publicized to promote consistency).","lastModifiedDate":"2022-04-29"},{"lineNumber":196,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":197,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"reliefPattern\"","lastModifiedDate":"2022-04-29"},{"lineNumber":198,"author":{"gitId":"-"},"content":" value\u003d\"fall through|Fall through|fallthru|Fallthru|falls through|Falls through|fallthrough|Fallthrough|No break|NO break|no break|continue on\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":199,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":200,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":201,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MissingSwitchDefault\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":202,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":203,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":204,"author":{"gitId":"-"},"content":" ORDER CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":205,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":206,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":207,"author":{"gitId":"-"},"content":" \u003c!-- Checks that the order of at-clauses follows the tagOrder default property value order.","lastModifiedDate":"2022-04-29"},{"lineNumber":208,"author":{"gitId":"-"},"content":" @author, @version, @param, @return, @throws, @exception, @see, @since, @serial, @serialField, @serialData, @deprecated","lastModifiedDate":"2022-04-29"},{"lineNumber":209,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":210,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"AtclauseOrder\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":211,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":212,"author":{"gitId":"-"},"content":" \u003c!-- Checks if the Class and Interface declarations is organized in this order","lastModifiedDate":"2022-04-29"},{"lineNumber":213,"author":{"gitId":"-"},"content":" 1. Class (static) variables. Order: public, protected, package level (no access modifier), private.","lastModifiedDate":"2022-04-29"},{"lineNumber":214,"author":{"gitId":"-"},"content":" 2. Instance variables. Order: public, protected, package level (no access modifier), private.","lastModifiedDate":"2022-04-29"},{"lineNumber":215,"author":{"gitId":"-"},"content":" 3. Constructors","lastModifiedDate":"2022-04-29"},{"lineNumber":216,"author":{"gitId":"-"},"content":" 4. Methods","lastModifiedDate":"2022-04-29"},{"lineNumber":217,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":218,"author":{"gitId":"-"},"content":" \u003cmodule name \u003d\"DeclarationOrder\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":219,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":220,"author":{"gitId":"-"},"content":" \u003c!-- Checks that default is after all cases in a switch statement --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":221,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"DefaultComesLast\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":222,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":223,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ModifierOrder\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":224,"author":{"gitId":"-"},"content":" \u003c!-- Warn if modifier order is inconsistent with JLS3 8.1.1, 8.3.1, and","lastModifiedDate":"2022-04-29"},{"lineNumber":225,"author":{"gitId":"-"},"content":" 8.4.3. The prescribed order is:","lastModifiedDate":"2022-04-29"},{"lineNumber":226,"author":{"gitId":"-"},"content":" public, protected, private, abstract, static, final, transient, volatile,","lastModifiedDate":"2022-04-29"},{"lineNumber":227,"author":{"gitId":"-"},"content":" synchronized, native, strictfp","lastModifiedDate":"2022-04-29"},{"lineNumber":228,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":229,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":230,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":231,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"OverloadMethodsDeclarationOrder\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":233,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":234,"author":{"gitId":"-"},"content":" WHITESPACE CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":235,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":236,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":237,"author":{"gitId":"-"},"content":" \u003c!-- Checks that comments are indented relative to their position in the code --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":238,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"CommentsIndentation\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":239,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":240,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"Indentation\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":241,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"caseIndent\" value\u003d\"0\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":242,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"throwsIndent\" value\u003d\"8\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":243,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":244,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" \u003cmodule name\u003d\"WhitespaceAround\"\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"allowEmptyLambdas\" value\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"allowEmptyTypes\" value\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"allowEmptyMethods\" value\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" \u003c/module\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":251,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"NoWhitespaceBeforeCaseDefaultColon\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":252,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":253,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":254,"author":{"gitId":"-"},"content":" JAVADOC CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":255,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":256,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":257,"author":{"gitId":"-"},"content":" \u003c!-- Checks that all block-tags are ordered correctly. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":258,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"AtclauseOrder\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":259,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":260,"author":{"gitId":"-"},"content":" \u003c!-- Checks that Javadoc block tags appear only at the beginning of the line. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":261,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocBlockTagLocation\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":262,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":263,"author":{"gitId":"-"},"content":" \u003c!-- Checks that all Javadoc comments start from the second line. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":264,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocContentLocationCheck\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":265,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":266,"author":{"gitId":"-"},"content":" \u003c!-- Checks that each line in Javadoc has leading asterisks. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":267,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocMissingLeadingAsterisk\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":268,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":269,"author":{"gitId":"-"},"content":" \u003c!-- Checks that each non-empty line in Javadoc has whitespace after leading asterisk. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":270,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocMissingWhitespaceAfterAsterisk\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":271,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":272,"author":{"gitId":"-"},"content":" \u003c!-- Checks that for block tags, indentation of continuation lines is at least 4 spaces. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":273,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocTagContinuationIndentation\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":274,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":275,"author":{"gitId":"-"},"content":" \u003c!-- Checks the Javadoc\u0027s format for every class, enumeration and interface. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":276,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocType\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":277,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowMissingParamTags\" value\u003d\"true\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":278,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":279,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":280,"author":{"gitId":"-"},"content":" \u003c!-- Checks the Javadoc\u0027s format for every method (excluding getters, setters and constructors). --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":281,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocMethod\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":282,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowedAnnotations\" value\u003d\"Override, Test, BeforeAll, BeforeEach, AfterAll, AfterEach, Subscribe\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":283,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"accessModifiers\" value\u003d\"public\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":284,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"validateThrows\" value\u003d\"false\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":285,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowMissingParamTags\" value\u003d\"true\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":286,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowMissingReturnTag\" value\u003d\"true\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":287,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"tokens\" value\u003d\"METHOD_DEF, ANNOTATION_FIELD_DEF\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":288,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":289,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":290,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"InvalidJavadocPosition\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":291,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":292,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":293,"author":{"gitId":"-"},"content":"\u003c/module\u003e","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"TongZhengHong":6,"-":287}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"antrikshdhand"},"content":"| Name | ID | Github |","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"antrikshdhand"},"content":"|-----------------|-----------|---------------|","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"antrikshdhand"},"content":"| Antriksh Dhand | A0278458J | antrikshdhand |","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"antrikshdhand"},"content":"| Oh Ken Wei | A0251850J | ken-ruster |","lastModifiedDate":"2023-10-05"},{"lineNumber":7,"author":{"gitId":"antrikshdhand"},"content":"| Ou Ningxiang | A0249445W | onx001 |","lastModifiedDate":"2023-10-05"},{"lineNumber":8,"author":{"gitId":"antrikshdhand"},"content":"| Tong Zheng Hong | A0251819Y | TongZhengHong |","lastModifiedDate":"2023-10-05"},{"lineNumber":9,"author":{"gitId":"antrikshdhand"},"content":"| Tricia Boo Koh | A0264665U | TriciaBK |","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"antrikshdhand":7,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"## Design \u0026 implementation","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"![](images/OverallArchitecture.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"### Architecture","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"The Architecture Diagram given above explains the high-level design of the application. Given below is a quick overview of main components and how they interact with each other.","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"#### Main components of the architecture","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"`ChessMaster` is the main invocation of the application. It handles the loading of previous chess games from the storage file and running of the chess `Game` instance. ","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"The remaining logic is handled by the following components:","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"- **UI**: The User Interface of the application","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"- **Game**: Executes user commands in game and CPU moves","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"- **Storage**: Reads and write chess game information to the hard disk","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"- **ChessBoard**: Holds the current chess board state in memory","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"- **Parser**: Parses string representations into relevant classes (`Command`, `Move`, `ChessPiece`, etc)","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"Our application also uses other classes to store information about the chess game and provide utility functions for the main components to function. This include: `Command`, `Move`, `Coordinate`, `Color`, `Player`, `ChessTile` and `ChessPiece(s).`","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":"### ChessMaster component","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"\u003c!-- Here is a partial class diagram of ChessMaster. --\u003e","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"The sequence diagram below illustrates the interactions within the ChessMaster component, when they launch the program. ","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"![](images/ChessMasterSequence.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"How does ChessMaster component work:","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"1. Attempts to load previously stored game in storage","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"2. If previous game exists, asks the user if a new game or the previous game should be loaded. ","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"3. If a new game is selected, the user will be prompted for the color to start. ","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":"4. Start running the new or previous game instance. ","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"### Game component","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"The sequence diagram below illustrates the interactions within the Game component, taking a move of \"a2 a3\" as example.","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"![](images/GameSequence.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"How does the Game component work:","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"1. Solicits input from user. Users can provide game commands, if not recognised, it will parsed as a `MoveCommand`.","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"2. The returned command will be executed.","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"3. If user entered a game command (not MoveCommand), the next user input will be solicited.","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"4. If a MoveCommand is identified, the user\u0027s input will be parsed as a Move object with checks to ensure it is a valid move on the chessboard.","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"5. The user\u0027s validated Move will be executed on the chess board. This move will then be saved in the storage file.","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"6. Next, it will be the CPU\u0027s turn to play. The best move will be calculated by the CPU object and it will be executed on the chess board. This move will also be saved in the storage file.","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"7. Once both the user and CPU has made their moves, the game state will be checked where the number of kings on the board and the winner will be determined.","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"TriciaBK"},"content":"### Architecture","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"ken-ruster"},"content":"### User Input Handling - `Parser` and `Command`","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"ken-ruster"},"content":"Below is a class diagram representing the Command and Parser classes.","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"![](images/ParserCommandDiagram.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"ken-ruster"},"content":"In order to handle user input into the program during the game, the `Parser` class was implemented.","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"ken-ruster"},"content":"Below is a sequence diagram describing the process of handling user input passed from `Game`:","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"![](images/ParseCommandSequence.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"ken-ruster"},"content":"`Parser` works to resolve a player\u0027s input in the following manner:","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"ken-ruster"},"content":"1. When `Parser` is called to parse a command, it returns the relevant `Command` object (More precisely,","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"ken-ruster"},"content":"one of its subclasses e.g. `MoveCommand`), which is then executed by `Game`.","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"ken-ruster"},"content":"2. Depending on the type of `Command` returned, the following may occur: ","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"ken-ruster"},"content":" 1. If it is a `MoveCommand`, the Command calls `parseMove` to instantiate the `Move`,","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"ken-ruster"},"content":" which is passed back to `Game` to be executed in the main logic.","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"ken-ruster"},"content":" 2. If it is a `ShowMovesCommand`, `parseAlgebraicCoor` is called to obtain the position of the piece as a ","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"ken-ruster"},"content":" `Coordinate` object. The available coordinates are printed using `showAvailableCoordinates`, then stored as a String","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"ken-ruster"},"content":" by `getAvailableCoordinatesString()`.","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"ken-ruster"},"content":"3. The result is then encapsulated in a `CommandResult` and returned to `Game` to be handled.","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"ken-ruster"},"content":"4. If the player made a move resulting in a promotion, `parsePromote` is called.","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"ken-ruster"},"content":"5. `Parser` calls `getColor` and `getPosition` to retrieve relevant data from the `ChessPiece` ","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"ken-ruster"},"content":"the player wants to promote.","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"ken-ruster"},"content":"6. The user\u0027s input is parsed and a new `ChessPiece` is returned.","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"ken-ruster"},"content":"`Parser` also contains methods to fulfil parsing needs in other parts of the program, for instance `parseChessPiece`, ","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"ken-ruster"},"content":"which is called while loading the .txt file containing save data, called for each character representing a ","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"ken-ruster"},"content":"singular chess piece. Using a Case statement, it returns the relevant `ChessPiece` object depending on the character","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"ken-ruster"},"content":"(representing the type of piece), and whether it is capitalised (representing colour).","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"ken-ruster"},"content":"How the parsing works:","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"ken-ruster"},"content":"- When called upon to parse a user command, the `Parser` class returns a relevant subclass of the `Command` class","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"ken-ruster"},"content":" (i.e. entering a valid command \"XYZ\" will cause `Parser` to return an `XYZCommand` object)","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"ken-ruster"},"content":"- Each `Command` subclass contains the relevant methods to execute the specified command","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"ken-ruster"},"content":"(AbortCommand, ShowCommand, etc.) and inherit from the abstract `Command` class.","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":"### Minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"The minimax algorithm is used to determine the best move for the AI to make. It is a recursive algorithm that works by alternatingly minimising opponent scores and maximising CPU scores. The algorithm is implemented in the `Minimax` class.","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":"![](images/MiniMaxSequenceDiagram.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":"How the minimax algorithm works:","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":"1. The `Minimax` class is called by the `Game` class to determine the best move for the CPU to make.","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":"2. The `Minimax` class calls the `getPossibleMoves` method in the `ChessBoard` class to get all possible moves for the CPU.","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":"3. The `Minimax` class then calls the `getBestMove` method to determine the best move for the CPU to make by maximising CPU score and minimizing the player score.","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":"4. The `getBestMove` method calls the `getBestMove` method recursively to populate the child scores.","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":"5. The `getBestMove` method returns the best move for the CPU to make.","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TriciaBK"},"content":"### Storage Component","lastModifiedDate":"2023-10-27"},{"lineNumber":112,"author":{"gitId":"TriciaBK"},"content":"**API:**","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"TriciaBK"},"content":"Below is a class diagram representing the Storage class.","lastModifiedDate":"2023-10-27"},{"lineNumber":115,"author":{"gitId":"TriciaBK"},"content":"The Storage component is responsible for handling the storage and retrieval of chess game state.","lastModifiedDate":"2023-10-27"},{"lineNumber":116,"author":{"gitId":"TriciaBK"},"content":"![](images/StorageClass.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":117,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":118,"author":{"gitId":"TriciaBK"},"content":"![](images/StorageSequence.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":120,"author":{"gitId":"TriciaBK"},"content":"* Creates the necessary parent directories for the file and the file itself if they don\u0027t exist ","lastModifiedDate":"2023-10-27"},{"lineNumber":121,"author":{"gitId":"TriciaBK"},"content":"* Saves the current state of the ChessBoard to the file. It includes the player\u0027s color information and current player\u0027s turn as the first line and the state of the chessboard in an 8x8 format.","lastModifiedDate":"2023-10-27"},{"lineNumber":122,"author":{"gitId":"TriciaBK"},"content":"* Allows resetting the game by clearing the contents of the file.","lastModifiedDate":"2023-10-27"},{"lineNumber":123,"author":{"gitId":"TriciaBK"},"content":"* Loads the state of the chessboard from the file by constructing a 2D array of ChessTile objects.","lastModifiedDate":"2023-10-27"},{"lineNumber":124,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":125,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":126,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":127,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":128,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":129,"author":{"gitId":"TriciaBK"},"content":"1. Novice players trying to practice chess and play chess offline without a chess set. ","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"TriciaBK"},"content":"2. Time-poor users looking for a very simple, clean, gimmick-free chess application.","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":132,"author":{"gitId":"TriciaBK"},"content":"- Chess novices can use ChessMaster CLI to learn the game\u0027s rules and practice their skills.","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"TriciaBK"},"content":"- Busy students can open the application up in their terminal easily for a quick game of chess.","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"TriciaBK"},"content":"- The CLI interface is intuitive, making it easy for beginners to understand moves and strategies","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":136,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":137,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":138,"author":{"gitId":"-"},"content":"| Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2020-05-24"},{"lineNumber":139,"author":{"gitId":"TriciaBK"},"content":"|---------|------------|--------------------------------------------------------|--------------------------------------------------------|","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"-"},"content":"| v1.0 | new user | see usage instructions | refer to them when I forget how to use the application |","lastModifiedDate":"2020-05-24"},{"lineNumber":141,"author":{"gitId":"TriciaBK"},"content":"| v1.0 | player | do only valid moves | play chess properly |","lastModifiedDate":"2023-11-02"},{"lineNumber":142,"author":{"gitId":"TriciaBK"},"content":"| v1.0 | player | start a new game | play chess multiple times |","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"onx001"},"content":"| v1.0 | player | see the current state of the chess board on every turn | think about what move to play |","lastModifiedDate":"2023-10-26"},{"lineNumber":144,"author":{"gitId":"onx001"},"content":"| v1.0 | player | tell which symbol represents which piece | know what is where |","lastModifiedDate":"2023-10-26"},{"lineNumber":145,"author":{"gitId":"onx001"},"content":"| v1.0 | player | specify move coordinates | move the piece I want how I want it |","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"onx001"},"content":"| v1.0 | player | promote pieces when the option is available | play extended games properly |","lastModifiedDate":"2023-10-26"},{"lineNumber":147,"author":{"gitId":"onx001"},"content":"| v1.0 | player | have the option to abort the game | leave the game when I no longer want to play |","lastModifiedDate":"2023-10-26"},{"lineNumber":148,"author":{"gitId":"TriciaBK"},"content":"| v1.0 | player | save and get back to a game | leave when I am busy and resume a game when I am free |","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"TriciaBK"},"content":"| v2.0 | new player | see available moves for a piece | learn the rules of chess and valid moves |","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"TriciaBK"},"content":"| v2.0 | new player | refresh the rules of chess anytime | recap and learn the rules of chess |","lastModifiedDate":"2023-11-02"},{"lineNumber":151,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":"{more to be added}","lastModifiedDate":"2023-10-27"},{"lineNumber":153,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":157,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":158,"author":{"gitId":"TriciaBK"},"content":"1. Should work on any mainstream OS as long as it has Java 11 or above installed. ","lastModifiedDate":"2023-10-27"},{"lineNumber":159,"author":{"gitId":"TriciaBK"},"content":"2. A user with a basic understanding of chess should be able to navigate the game without difficulty. ","lastModifiedDate":"2023-10-27"},{"lineNumber":160,"author":{"gitId":"TriciaBK"},"content":"{More to be added}","lastModifiedDate":"2023-10-27"},{"lineNumber":161,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":162,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":163,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":164,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":165,"author":{"gitId":"-"},"content":"* *glossary item* - Definition","lastModifiedDate":"2020-05-24"},{"lineNumber":166,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":167,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":168,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":169,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"ken-ruster":34,"TriciaBK":31,"onx001":24,"TongZhengHong":50,"-":31}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"# ChessMaster","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"ChessMasterCLI is a command-line interface (CLI) chess game designed to make learning and training accessible for beginners while offering an engaging experience for all skill levels. This sleek and user-friendly chess simulator provides a platform for novice players to build their skills and understanding of the game.","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"For more information: ","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"ken-ruster":1,"TongZhengHong":2,"-":5}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"# ChessMaster User Guide","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"ChessMasterCLI is a command-line interface (CLI) chess game designed to make learning and training accessible for beginners while offering an engaging experience for all skill levels. This sleek and user-friendly chess simulator provides a platform for novice players to build their skills and understanding of the game.","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"- [Quick Start](#quick-start)","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"- [Starting a game](#starting-a-game)","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"- [Gameplay]()","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"- [Features](#features)","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" - Gameplay features","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" - [Make a move](#make-a-move)","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" - [Show available moves: `moves`](#show-available-moves-moves)","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" - [Show current chess board: `show`](#show-current-chess-board-show)","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" - Getting help","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" - [Show chess rules: `rules`](#show-chess-rules-rules)","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" - [Show commands: `help`](#show-commands-help)","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" - [Legend: `legend`](#view-pieces-representation-legend-)","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" - [Aborting game: `abort`](#aborting-game-abort)","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"- [Command Summary](#command-summary)","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":22,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"1. Ensure you have **Java 11 or above** installed in your system.","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"2. Download the latest version of `ChessMaster.jar` from [here](https://github.com/AY2324S1-CS2113-T18-1/tp/releases).","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":"3. Open a terminal instance and navigate into the folder that contains the downloaded ChessMaster.jar file.","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"```bash","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"cd PATH_TO_JAR_FILE","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"4. Run the jar application with the following command:","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"```bash","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"java -jar ChessMaster.jar","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"You should be greeted by a welcome message from ChessMaster:","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"Hey there, chess geek! You have stumbled upon the one and only:","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" ________ __ ___ __","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" / ____/ /_ ___ __________ / |/ /___ ______/ /____ _____","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" / / / __ \\/ _ \\/ ___/ ___/ / /|_/ / __ `/ ___/ __/ _ \\/ ___/","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" / /___/ / / / __(__ |__ ) / / / / /_/ (__ ) /_/ __/ /","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" \\____/_/ /_/\\___/____/____/ /_/ /_/\\__,_/____/\\__/\\___/_/","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"where CHESS becomes an exciting journey of strategy and skill!","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"## Starting a game","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":"Upon launching the application, ChessMaster checks if there is a previous game in progress. If a previous game exists, you\u0027ll be presented with the option to continue from where you left off. Please enter `y` for **yes** and `n` for **no**.","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":"You have an ongoing previous chess game. Continue game? [y/n]","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":"However, if you prefer to **start a fresh game** or if **no previous game is found**, ChessMaster will prompt you to select your preferred color—whether it\u0027s \"White\" or \"Black.\" Please enter `b` for **black** and `w` for **white**.","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"Choose your starting color to start new game! [b/w]","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":"Next, you can choose the difficulty of the AI you will be pitched against! The current supported difficulty levels range from 1 to 4. Please enter the number corresponding to your preferred difficulty level.","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":"Choose your difficulty level! [1/2/3/4]","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":"Now, you\u0027ll be off to a rewarding journey of enhancing your chess skills and enjoying the timeless game of strategy and tactics with ChessMaster!","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":"## Gameplay","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":"The gameplay system of ChessMaster provides you with the flexibility to enter either a **command** or a **move** during your turn. ","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":"- If you opt for a **command**, the system will promptly solicit your next action, allowing you to access various [features](#features) seamlessly. However, when you decide to make a move, the system will evaluate your input for validity. ","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":"- Only when you enter a **valid move** will your turn be passed to the CPU, enabling it to respond with its strategic move. ","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":"Additionally, every time a move is executed, ChessMaster provides a comprehensive view of the chessboard, displaying the state of the game following the previous move.","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"\u003ctable\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":"\u003ctr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" \u003cth\u003eUser Move\u003c/th\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" \u003cth\u003eCPU move\u003c/th\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"\u003c/tr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":"\u003ctr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"\u003ctd\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":"d2 d4","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":"You moved Pawn from d2 to d4","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" (8) | R | N | B | Q | K | B | N | R | (8)","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" (7) | P | P | P | P | P | P | P | P | (7)","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" (6) | | | | | | | | | (6)","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" (5) | | | | | | | | | (5)","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" (4) | | | |(p)| | | | | (4)","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" (3) | | | | | | | | | (3)","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" (2) | p | p | p |( )| p | p | p | p | (2)","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" (1) | r | n | b | q | k | b | n | r | (1)","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":"\u003c/td\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":"\u003ctd\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":"ChessMaster moved Pawn from e7 to e5","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"TongZhengHong"},"content":" (8) | R | N | B | Q | K | B | N | R | (8)","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"TongZhengHong"},"content":" (7) | P | P | P | P |( )| P | P | P | (7)","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"TongZhengHong"},"content":" (6) | | | | | | | | | (6)","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"TongZhengHong"},"content":" (5) | | | | |(P)| | | | (5)","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"TongZhengHong"},"content":" (4) | | | | p | | | | | (4)","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"TongZhengHong"},"content":" (3) | | | | | | | | | (3)","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"TongZhengHong"},"content":" (2) | p | p | p | | p | p | p | p | (2)","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"TongZhengHong"},"content":" (1) | r | n | b | q | k | b | n | r | (1)","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"TongZhengHong"},"content":"\u003c/td\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"TongZhengHong"},"content":"\u003c/tr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"TongZhengHong"},"content":"\u003c/table\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":157,"author":{"gitId":"ken-ruster"},"content":"## Ending the game","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"ken-ruster"},"content":"The game will automatically end and a victor be declared when one side has been checkmated (i.e. their king is in check, ","lastModifiedDate":"2023-11-01"},{"lineNumber":160,"author":{"gitId":"ken-ruster"},"content":"and there is no possible escape), or if their king has been captured.","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"-"},"content":"## Features ","lastModifiedDate":"2020-05-24"},{"lineNumber":163,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":"### Make a move","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"ken-ruster"},"content":"To make a move, simply enter the coordinate of the piece to be moved, followed by the coordinates it is to be moved to.","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"ken-ruster"},"content":"Format: `[column][row] [column][row]`","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"ken-ruster"},"content":"Examples: ","lastModifiedDate":"2023-11-01"},{"lineNumber":171,"author":{"gitId":"ken-ruster"},"content":"- `a2 a4`","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"ken-ruster"},"content":"- `b3 g6`","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"ken-ruster"},"content":"ChessMaster also automatically checks if the move was valid and legal before it is executed, and shows the following error","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"ken-ruster"},"content":"message in the case of an invalid move:","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"ken-ruster"},"content":"`Oops, that move isn\u0027t valid!`","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":"### Show available moves: `moves`","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"ken-ruster"},"content":"Shows the available moves for a piece on the board. This command can be used for both yours and the enemy\u0027s pieces.","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"ken-ruster"},"content":"Format: `moves [column][row]`","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":186,"author":{"gitId":"ken-ruster"},"content":"Example: ","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"ken-ruster"},"content":"moves e5","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"ken-ruster"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"ken-ruster"},"content":" (8) | R | N | B | Q | K | B | N | R | (8)","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"ken-ruster"},"content":" (7) | P | P | P |[ ]| |[P]| P | P | (7)","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"ken-ruster"},"content":" (6) | | |[ ]| P | | |[ ]| | (6)","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"ken-ruster"},"content":" (5) | | | | |{n}| | | | (5)","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"ken-ruster"},"content":" (4) | | |[ ]| | | |[ ]| | (4)","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"ken-ruster"},"content":" (3) | | | |[ ]| |[ ]| | | (3)","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"ken-ruster"},"content":" (2) | p | p | p | p | p | p | p | p | (2)","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"ken-ruster"},"content":" (1) | r | n | b | q | k | b | | r | (1)","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"ken-ruster"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"ken-ruster"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"ken-ruster"},"content":"Available coordinates for Knight at e5: ","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"ken-ruster"},"content":"f7 d7 f3 d3 g6 g4 c6 c4 ","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"ken-ruster"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"ken-ruster"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"TongZhengHong"},"content":"### Show current chess board: `show`","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"ken-ruster"},"content":"Shows the current state of the chess board.","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"ken-ruster"},"content":"Format: `show`","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"TongZhengHong"},"content":"### Show chess rules: `rules`","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"ken-ruster"},"content":"Obtain a quick refresher on the rules of chess","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"ken-ruster"},"content":"Format: `rules`","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"ken-ruster"},"content":"### Show commands: `help`","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"ken-ruster"},"content":"Show a list of commands and what they do","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"ken-ruster"},"content":"Format: `help`","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":234,"author":{"gitId":"TriciaBK"},"content":"### View pieces representation: `legend` ","lastModifiedDate":"2023-11-02"},{"lineNumber":235,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":236,"author":{"gitId":"TriciaBK"},"content":"Display a legend that explains the piece representations","lastModifiedDate":"2023-11-02"},{"lineNumber":237,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":238,"author":{"gitId":"TriciaBK"},"content":"Format: `legend`","lastModifiedDate":"2023-11-02"},{"lineNumber":239,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":240,"author":{"gitId":"ken-ruster"},"content":"### Saving and loading games","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":242,"author":{"gitId":"ken-ruster"},"content":"Every time a turn ends, ChessMaster will save the current state of the game. When ChessMaster is restarted, the","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"ken-ruster"},"content":"user will be prompted to choose whether to load the saved game or begin a new one. ChessMaster only supports a single","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"ken-ruster"},"content":"saved game, and starting a new one will delete the existing save file.","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":246,"author":{"gitId":"ken-ruster"},"content":"### Aborting game: `abort`","lastModifiedDate":"2023-11-01"},{"lineNumber":247,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":248,"author":{"gitId":"ken-ruster"},"content":"Exit the ChessMaster application.","lastModifiedDate":"2023-11-01"},{"lineNumber":249,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":250,"author":{"gitId":"ken-ruster"},"content":"Format: `abort`","lastModifiedDate":"2023-11-01"},{"lineNumber":251,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":252,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":253,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":254,"author":{"gitId":"-"},"content":"**Q**: How do I transfer my data to another computer? ","lastModifiedDate":"2020-05-24"},{"lineNumber":255,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":256,"author":{"gitId":"ken-ruster"},"content":"**A**: You can navigate to your root folder, and find the file `data/ChessMaster.txt`. Transfer the file to your other computer,","lastModifiedDate":"2023-11-01"},{"lineNumber":257,"author":{"gitId":"ken-ruster"},"content":"and find the `data` folder in the ChessMaster install folder in the other computer. Copy the file into the folder. Start ChessMaster,","lastModifiedDate":"2023-11-01"},{"lineNumber":258,"author":{"gitId":"ken-ruster"},"content":"and type `y` when prompted to load a saved game.","lastModifiedDate":"2023-11-01"},{"lineNumber":259,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":260,"author":{"gitId":"ken-ruster"},"content":"**Q**: How do I play with another person?","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"ken-ruster"},"content":"**A**: Currently, ChessMaster does not support multiplayer. ","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"ken-ruster"},"content":"**Q**: Can we play timed games?","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"ken-ruster"},"content":"**A**: ChessMaster does not come with an internal timer. However, you are able to use your own chess timer or stopwatch ","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"ken-ruster"},"content":"to simulate timed games.","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":269,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":270,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":271,"author":{"gitId":"TongZhengHong"},"content":"| Action | Format |","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"TriciaBK"},"content":"|---------------|-------------------------------|","lastModifiedDate":"2023-11-02"},{"lineNumber":273,"author":{"gitId":"ken-ruster"},"content":"| Move | `[column][row] [column][row]` |","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"ken-ruster"},"content":"| Show moves | `moves [column][row]` |","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"ken-ruster"},"content":"| Show board | `show` |","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"TriciaBK"},"content":"| Rules | `rules` |","lastModifiedDate":"2023-11-02"},{"lineNumber":277,"author":{"gitId":"ken-ruster"},"content":"| Help | `help` |","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"TriciaBK"},"content":"| Pieces legend | `legend` |","lastModifiedDate":"2023-11-02"},{"lineNumber":279,"author":{"gitId":"TongZhengHong"},"content":"| Abort | `abort` |","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ken-ruster":81,"TriciaBK":10,"onx001":6,"TongZhengHong":150,"-":33}},{"path":"docs/diagrams/ChessMasterSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"@startuml ChessMasterSequence","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"actor User as user #BlanchedAlmond","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"participant \":UI\" as ui #IndianRed","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"participant \":ChessMaster\" as chessMaster #LightPink","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"participant \":Game\" as game #Orange","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"participant \":Storage\" as storage #DeepSkyBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"user -\u003e chessMaster : start","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"activate chessMaster","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -\u003e storage : loadBoard()","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"activate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"storage --\u003e chessMaster : prevBoard:ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"deactivate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"alt [. Previous board exists]","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" chessMaster -\u003e ui : shouldStartNewGame()","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"yes/no\"","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e chessMaster : :boolean","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" opt [startNewGame]","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" chessMaster -\u003e ui : chooseColor","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"black/white\"","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e chessMaster : playerColor:Color","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"else [. No previous board]","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" chessMaster -\u003e ui : chooseColor","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"black/white\"","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e chessMaster : playerColor:Color","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"create game","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"activate game","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -\u003e game : run()","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"game --\u003e chessMaster","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"destroy game","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"chessMaster --\u003e user","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"deactivate chessMaster","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TongZhengHong":56}},{"path":"docs/diagrams/GameSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"@startuml GameSequence","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"actor User as user #BlanchedAlmond","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"participant \":UI\" as ui #IndianRed","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"participant \":Parser\" as parser #LightPink","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"participant \":Game\" as game #Orchid","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"participant \":ChessBoard\" as board #Orange","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"participant \":CPU\" as cpu #SkyBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"participant \":Storage\" as storage #PaleTurquoise","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"activate game #AliceBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"loop [hasGameEnded]","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e ui : getUserCommand()","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"a2 a3\"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e game : :String","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e parser : parseCommand(\"a2 a3\")","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" activate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" parser --\u003e game : :Command","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" deactivate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" opt [isMoveCommand]","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e parser : parseMove(\"a2 a3\")","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" activate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" parser --\u003e game : humanMove:Move","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" deactivate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e board : executeMove(humanMove)","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" activate board","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" board --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" deactivate board","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e storage : saveBoard()","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" activate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" storage --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" deactivate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e cpu : getBestMove()","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" activate cpu","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" cpu --\u003e game : cpuMove:Move","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" deactivate cpu","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e board : executeMove(cpuMove)","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" activate board","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" board --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" deactivate board","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e storage : saveBoard()","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" activate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" storage --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" deactivate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e board : checkEndState()","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" activate board","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" board --\u003e game : hasGameEnded:bool","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" deactivate board","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"game --\u003e user","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"destroy game","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TongZhengHong":70}},{"path":"docs/diagrams/MiniMaxSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"@startuml MiniMaxSequenceDiagram","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"actor CPU as user #BlanchedAlmond","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"participant \":MiniMax\" as MM #IndianRed","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"participant \"Board :ChessBoard\" as CB #LightPink","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":"participant \":Move\" as M #Orange","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"participant \":BoardScoreTuple\" as BST #SkyBlue","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"participant \":ChessMasterException\" as E #PaleTurquoise","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":"create MM","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":"activate MM #AliceBlue","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":"user -\u003e MM : getBestMove()","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":"MM -\u003e MM : mostPoints()","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":"loop [\"depth \u003c maxDepth\"]","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" MM -\u003e CB : getBoard()","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" deactivate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" CB --\u003e MM : ChessBoard","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" activate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Initialize variables","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" MM -\u003e CB : getPoints()","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" deactivate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" CB --\u003e MM : points","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" activate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" MM -\u003e CB : Clone board","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" CB --\u003e CB : board.clone()","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" CB -\u003e M** : setPiece()","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":" activate M","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"onx001"},"content":" M -\u003e CB : Execute move","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"onx001"},"content":" deactivate M","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":" CB -\u003e CB : Calculate new score","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" CB -\u003e BST** : Create BoardScoreTuple","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":" activate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":" BST --\u003e BST : BoardScoreTuple","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" deactivate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" CB -\u003e E : Handle exception (if any)","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" CB -\u003e MM : Continue loop","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" loop [\"depth \u003c maxDepth\"]","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" activate MM","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Recursively call mostPoints() while incrementing depth","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" MM --\u003e MM : bestTuple","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" deactivate MM","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" end","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Update bestScore based on player turn","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Update bestTuple with bestScore and bestMove","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"onx001"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":"MM -\u003e BST : getBestMove()","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":"activate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"onx001"},"content":"BST --\u003e MM : bestMove","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"onx001"},"content":"deactivate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":"MM -\u003e user : Return bestMove","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":"deactivate MM","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":"destroy MM","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":"destroy CB","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":"destroy M","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":"destroy BST","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"onx001":75}},{"path":"docs/diagrams/OverallArchitecture.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"@startuml OverallArchitecture","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"rectangle ChessMaster as chessMaster #LightPink","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"rectangle Parser as parser #AliceBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"rectangle Game as game #Orchid","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"rectangle UI as ui #IndianRed","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"rectangle Storage as storage #SkyBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"rectangle ChessBoard as board #Orange","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"actor User as user #BlanchedAlmond","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"user -d-\u003e ui","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -r-\u003e ui","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -d-\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -u-\u003e storage","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -u-\u003e board","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"game -\u003e storage","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"game -u-\u003e board","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"game -u-\u003e ui","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"storage .up.\u003e board","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TongZhengHong":24}},{"path":"docs/diagrams/ParseCommandSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"participant \":Game\" as Game","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"participant \":Parser\" as Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"participant \":Command\" as Command","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"participant \":CommandResult\" as CommandResult","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"participant \"coord:Coordinate\" as Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"participant \"board:ChessBoard\" as ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"participant \"promoteFrom: ChessPiece\" as ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":"Game -\u003e Parser: parseCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"activate Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":"create Command","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":"Parser -\u003e Command ++","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":"Command --\u003e Parser --: Command","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":"Game \u003c-- Parser --: Command","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":"Game -\u003e Command ++: execute","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":"alt MoveCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e Parser ++: parseMove","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" Parser --\u003e Command --: Move","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":"else ShowMoveCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" create Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e Coordinate ++: parseAlgebraicCoor","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" Coordinate --\u003e Command --: coord","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e ChessBoard ++: showAvailableCoordinates","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" ChessBoard --","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e ChessBoard ++: getAvailableCoordinatesString","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" ChessBoard --\u003e Command --: String","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" destroy Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":"Command -\u003e CommandResult**","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":"activate CommandResult","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":"CommandResult --\u003e Command--","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":"Game \u003c-- Command --: CommandResult","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":"opt canPromote","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":"Game -\u003e Parser ++: parsePromote","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"Parser -\u003e ChessPiece ++: getColour","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":"ChessPiece --\u003e Parser --: Color","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"Parser -\u003e ChessPiece ++: getPosition","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":"ChessPiece --\u003e Parser --: Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":"Game \u003c-- Parser --: ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"ken-ruster":48}},{"path":"docs/diagrams/ParserCommandDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"package command{","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":" abstract class Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":" +execute()","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":" +isMoveCommand()","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":" class MoveCommand {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":" -userInput: String","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":" -move: Move","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":" +getMove(): Move","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":" class ShowMovesCommand {","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" -userInput: String","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" -piece: ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" +getPiece(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" class XYZCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":" note top: Includes subclasses AbortCommand, HelpCommand, etc.","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" XYZCommand -|\u003e Command","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" ShowMovesCommand --|\u003e Command","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" MoveCommand --|\u003e Command","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":"package parser{","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" class Parser {","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" +{static} parsePromote(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" +{static} parseMove(): Move","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" +{static} parseChessPiece(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" +{static} parseCommand(): Command","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" +{static} parsePlayerColor(): Color","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":"class Storage","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":"class Game","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":"class Human","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":"command.MoveCommand ..\u003e parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":"command.ShowMovesCommand ..\u003e parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"command.XYZCommand ..\u003e parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"Game \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":"Storage \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":"Human \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":"ChessBoard \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"ken-ruster":47}},{"path":"docs/diagrams/StorageClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"class Storage {","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":" - filePathString: String","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":" + Storage(filePath: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":" + saveBoard(board: ChessBoard, playerColor: Color): void","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":" + resetBoard(): void","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":" + loadBoard(): ChessTile[][]","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" + loadPlayerColor(): Color","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":" - createChessMasterFile(): void","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"class ChessBoard {","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" - SIZE: int","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":"class ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":"class Color","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e File","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e Color","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TriciaBK":26}},{"path":"docs/diagrams/StorageSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"actor User","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"participant \":Storage\" as Storage","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"participant \":File\" as File","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"participant \":FileWriter\" as FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"participant \":Scanner\" as Scanner","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"participant \":ChessTile\" as ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"participant \":String\" as String","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"create Storage","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : new Storage(): String","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"create File","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e File++ : new File()","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"File --\u003e Storage-- : storageFile:File","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e File++ : exists()","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":"File --\u003e Storage-- : boolean","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":"alt File: !exists()","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" File -\u003e File++ : createParentDirectories()","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" File --\u003e File--","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" File -\u003e File++ : createNewFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" File --\u003e File--","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : saveBoard(): ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":"create FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++ : new FileWriter(): File","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage-- : fileWriter: FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++: fileWriter.write(): playerColor.name()","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e ChessBoard++ : getPlayerColor()","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TriciaBK"},"content":"ChessBoard --\u003e FileWriter-- : Color","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e FileWriter++ : write(): Color","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e FileWriter++ : fileWriter.write(): System.lineSeparator()","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TriciaBK"},"content":"loop for row from 0 to ChessBoard.SIZE-1","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TriciaBK"},"content":" alt row loop","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TriciaBK"},"content":" FileWriter -\u003e FileWriter++ : .write(): System.lineSeparator()","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TriciaBK"},"content":" FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TriciaBK"},"content":" loop for col from 0 to ChessBoard.SIZE-1","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e ChessBoard++ : getPieceAtCoor(): Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TriciaBK"},"content":" create Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TriciaBK"},"content":" ChessBoard -\u003e Coordinate++","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TriciaBK"},"content":" Coordinate --\u003e ChessBoard-- : Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TriciaBK"},"content":" ChessBoard --\u003e Storage-- : piece","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"TriciaBK"},"content":" FileWriter -\u003e FileWriter++ : write(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"TriciaBK"},"content":" FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"TriciaBK"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"TriciaBK"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e FileWriter++ : close()","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : resetBoard(): ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"TriciaBK"},"content":"create FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++ : new FileWriter(): File","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage-- : fileWriter: FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++: .write(): String","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++: .close()","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : loadBoard(): ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"TriciaBK"},"content":"create Scanner","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Scanner++ : new Scanner(): File","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"TriciaBK"},"content":"Scanner --\u003e Storage-- : fileScanner: Scanner","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"TriciaBK"},"content":"alt FileScanner: hasNext()","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Scanner++: nextLine()","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"TriciaBK"},"content":" Scanner --\u003e Storage --","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage: Initialize rowIndex, boardTiles","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"TriciaBK"},"content":"create ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e ChessTile++","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"TriciaBK"},"content":"ChessTile --\u003e Storage-- : boardTiles: ChessTile[][]","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"TriciaBK"},"content":"loop (rowIndex \u003c ChessBoard.SIZE \u0026\u0026 fileScanner.hasNext())","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Scanner++ : nextLine()","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"TriciaBK"},"content":" Scanner --\u003e Storage-- : chessRowLine: String","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"TriciaBK"},"content":" alt chessRowLine.length() !\u003d ChessBoard.SIZE","lastModifiedDate":"2023-10-27"},{"lineNumber":99,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Scanner++: close()","lastModifiedDate":"2023-10-27"},{"lineNumber":100,"author":{"gitId":"TriciaBK"},"content":" Scanner --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"TriciaBK"},"content":" end alt","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"TriciaBK"},"content":" loop for col from 0 to ChessBoard.SIZE-1","lastModifiedDate":"2023-10-27"},{"lineNumber":103,"author":{"gitId":"TriciaBK"},"content":" create String","lastModifiedDate":"2023-10-27"},{"lineNumber":104,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e String++ : valueOf(): chessRowLine.charAt(col)","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"TriciaBK"},"content":" String --\u003e Storage-- : chessPieceString: String","lastModifiedDate":"2023-10-27"},{"lineNumber":106,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Parser++ : chessPieceString","lastModifiedDate":"2023-10-27"},{"lineNumber":107,"author":{"gitId":"TriciaBK"},"content":" Parser --\u003e Storage -- : initialPiece: ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":108,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":109,"author":{"gitId":"TriciaBK"},"content":" create ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":110,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e ChessTile++","lastModifiedDate":"2023-10-27"},{"lineNumber":111,"author":{"gitId":"TriciaBK"},"content":" ChessTile --\u003e Storage-- : boardTiles: ChessTile[][]","lastModifiedDate":"2023-10-27"},{"lineNumber":112,"author":{"gitId":"TriciaBK"},"content":" end loop","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Scanner++: close","lastModifiedDate":"2023-10-27"},{"lineNumber":115,"author":{"gitId":"TriciaBK"},"content":"Scanner --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":116,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User: boardTiles","lastModifiedDate":"2023-10-27"},{"lineNumber":117,"author":{"gitId":"TriciaBK"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TriciaBK":117}},{"path":"src/main/java/chessmaster/ChessMaster.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster;","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Game;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.storage.Storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"/**","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" * Main entry-point for ChessMaster application.","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"public class ChessMaster {","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private static final String FILE_PATH_STRING \u003d \"data/ChessMaster.txt\";","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" private TextUI ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" private ChessBoard board;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" private Storage storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" private int difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" private Color playerColor;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" private Color currentTurnColor \u003d Color.WHITE;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" private ChessMaster() {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" ui \u003d new TextUI();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" storage \u003d new Storage(FILE_PATH_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" ui.printWelcomeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" playerColor \u003d storage.loadPlayerColor();","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" difficulty \u003d storage.loadDifficulty();","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" currentTurnColor \u003d storage.loadCurrentColor();","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[][] existingBoard \u003d storage.loadBoard();","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" board \u003d new ChessBoard(playerColor, existingBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" board.setDifficulty(difficulty);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" if (shouldStartNewGame()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" loadNewGame();","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" } catch (ChessMasterException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" ui.printLoadBoardError();","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" loadNewGame();","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" private boolean shouldStartNewGame() {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" ui.promptContinuePrevGame(false);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" String input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" while (!input.equals(\"y\") \u0026\u0026 !input.equals(\"n\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" ui.promptContinuePrevGame(true);","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" if (input.equals(\"y\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" ui.printContinuePrevGame(playerColor.name());","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" return true;","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" private void loadNewGame() {","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" ui.promptStartingColor(false);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" String input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" while (!input.equals(\"b\") \u0026\u0026 !input.equals(\"w\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" ui.promptStartingColor(true);","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" playerColor \u003d input.equals(\"b\") ? Color.BLACK : Color.WHITE;","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" board \u003d new ChessBoard(playerColor);","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" ui.printStartNewGame(playerColor.name());","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":" ui.promptDifficulty(false);","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" while (!input.equals(\"1\") \u0026\u0026 !input.equals(\"2\") ","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" \u0026\u0026 !input.equals(\"3\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" ui.promptDifficulty(true);","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" difficulty \u003d Integer.parseInt(input);","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" board.setDifficulty(difficulty);","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":" currentTurnColor \u003d Color.WHITE;","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" private void run() { ","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" Game game \u003d new Game(playerColor, currentTurnColor, board, storage, ui, difficulty);","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" game.run();","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" public static void main(String[] args) {","lastModifiedDate":"2019-07-29"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":" new ChessMaster().run();","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"onx001":22,"TongZhengHong":80}},{"path":"src/main/java/chessmaster/commands/AbortCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class AbortCommand extends Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String ABORT_COMAMND_STRING \u003d \"abort\";","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" private static final String ABORT_MESSAGE \u003d \"Exiting program... Thanks for playing!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" return new CommandResult(ABORT_MESSAGE);","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" public static boolean isAbortCommand(Command command) {","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" return command instanceof AbortCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":22}},{"path":"src/main/java/chessmaster/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public abstract CommandResult execute(ChessBoard board, TextUI ui) throws ChessMasterException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public boolean isMoveCommand() {","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof MoveCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/commands/CommandResult.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"/**","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" * Represents the result of a command execution.","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class CommandResult {","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" * The feedback message to be shown to the user. Contains a description of the","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" * execution result","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" private final String[] message;","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" public CommandResult(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" this.message \u003d message;","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public String[] getMessageStrings() {","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" return this.message;","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"TongZhengHong":23}},{"path":"src/main/java/chessmaster/commands/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" public static final String HELP_COMAMND_STRING \u003d \"help\";","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":" private static final String[] HELP_STRINGS \u003d { ","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":" \"Seems like you need some help!\",","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":" \"Here are the following commands to play:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" \"Move piece - Input coordinate of piece, followed by coordinate to move to\",","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" \" Format: [column][row] [column][row]\",","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":" \" E.g. a2 a3\",","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" \"Show available moves - Lists all the available moves for a piece\",","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" \" Format: moves [column][row]\",","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" \" E.g. moves a2\",","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":" \"Show board - Shows the current state of the chess board\",","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" \" Format: show\",","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" \"Obtain rules - Obtain a quick refresher on the rules of chess\",","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" \" Format: rules\",","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" \"View pieces representation - Display a legend that explains the piece representations\",","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" \" Format: legend\",","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" \"Abort game - Exit programme\",","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" \" Format: abort\",","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult(HELP_STRINGS);","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TriciaBK":36}},{"path":"src/main/java/chessmaster/commands/LegendCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Bishop;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Knight;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Rook;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"public class LegendCommand extends Command {","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" public static final String LEGEND_COMMAND_STRING \u003d \"legend\";","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" private static final String[] LEGEND_STRINGS \u003d {","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" \"Black pieces:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black rook.\", Rook.ROOK_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black knight.\", Knight.KNIGHT_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black bishop.\", Bishop.BISHOP_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black queen.\", Queen.QUEEN_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black king.\", King.KING_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black pawn.\", Pawn.PAWN_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" \" \",","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" \"White pieces:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white rook.\", Rook.ROOK_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white knight.\", Knight.KNIGHT_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white bishop.\", Bishop.BISHOP_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white queen.\", Queen.QUEEN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white king.\", King.KING_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white pawn.\", Pawn.PAWN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" };","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult(LEGEND_STRINGS);","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"TriciaBK":40}},{"path":"src/main/java/chessmaster/commands/MoveCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.InvalidMoveException;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"public class MoveCommand extends Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final String MOVE_COMAMND_STRING \u003d \"move\";","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" private static final String MOVE_PIECE_MESSAGE \u003d \"You moved %s from %s to %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" private String userInput;","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private Move move;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public MoveCommand(String inputString) {","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" this.userInput \u003d inputString;","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" * Executes the command based on user input, which is expected to consist of two","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" * algebraic coordinate strings separated by whitespace.","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" * @return A CommandResult object containing the result of the command.","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" * @throws ChessMasterException If the user input cannot be parsed into two","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" * coordinate objects.","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) throws ChessMasterException {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" move \u003d Parser.parseMove(userInput, board);","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" if (!move.isValid(board)) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" throw new InvalidMoveException();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" String pieceString \u003d move.getPiece().getClass().getSimpleName();","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" String displayString \u003d String.format(MOVE_PIECE_MESSAGE, pieceString, move.getFrom(), move.getTo());","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" return new CommandResult(displayString);","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" public Move getMove() throws InvalidMoveException {","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" if (move \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" throw new InvalidMoveException();","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" return move;","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":50}},{"path":"src/main/java/chessmaster/commands/RulesCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Bishop;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Knight;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Rook;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"public class RulesCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" public static final String RULES_COMAMND_STRING \u003d \"rules\";","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" private static final String[] RULES_STRINGS \u003d {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" \"Here are simple chess rules to get you started:\",","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":" \"Piece movement:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Pawn (\\\"%s\\\") move forward one square but capture diagonally.\", Pawn.PAWN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Rooks (\\\"%s\\\") move horizontally and vertically any number of squares.\", Rook.ROOK_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Knights (\\\"%s\\\") move in an L-shape.\", Knight.KNIGHT_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Bishops (\\\"%s\\\") move diagonally any number of squares.\", Bishop.BISHOP_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Queens (\\\"%s\\\") move any number of squares in any direction.\", Queen.QUEEN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Kings (\\\"%s\\\") move one square in any direction.\", King.KING_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":" \"Special Rules:\",","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":" \" Castling - King and rook move simultaneously to safeguard the king.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":" \" En Passant - Pawn capturing when moving two squares from starting position.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" \" Pawn Promotion - Promote a pawn to another piece (except king) upon reaching the back rank.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" \"Objective:\",","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":" \" Game ends when one player\u0027s king is in checkmate, under attack and can\u0027t escape capture.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":" \" The delivering player wins the game.\"","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":" };","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult(RULES_STRINGS);","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"TriciaBK":44}},{"path":"src/main/java/chessmaster/commands/ShowCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"public class ShowCommand extends Command {","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" public static final String SHOW_COMAMND_STRING \u003d \"show\";","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":" private static final String SHOW_STRING \u003d \"Here is the current board state:\";","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":" ui.printText(SHOW_STRING);","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult();","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"TriciaBK":20}},{"path":"src/main/java/chessmaster/commands/ShowMovesCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"//@@author ken-ruster","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.NullPieceException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":"public class ShowMovesCommand extends Command {","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":" public static final String SHOW_MOVE_COMMAND_STRING \u003d \"moves\";","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":" private String userInput;","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" private ChessPiece piece;","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" public ShowMovesCommand(String userInput) {","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" this.userInput \u003d userInput;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) throws ChessMasterException {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" Coordinate coord \u003d Coordinate.parseAlgebraicCoor(userInput);","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" piece \u003d board.getPieceAtCoor(coord);","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" if (piece.isEmptyPiece()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" throw new NullPieceException();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" Coordinate[] possibleCoordinates \u003d piece.getFlattenedCoordinates(board);","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" ui.printChessBoardAvailableMoves(board.getBoard(), piece, possibleCoordinates);","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" String[] displayString \u003d piece.getAvailableCoordinatesString(board);","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" return new CommandResult(displayString);","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":" public ChessPiece getPiece() {","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" return this.piece;","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ken-ruster":38}},{"path":"src/main/java/chessmaster/exceptions/ChessMasterException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"public class ChessMasterException extends Exception {","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" public ChessMasterException(String message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"TongZhengHong":8}},{"path":"src/main/java/chessmaster/exceptions/InvalidMoveException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class InvalidMoveException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public InvalidMoveException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_INVALID_MOVE_EXCEPTION);","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public InvalidMoveException(String message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/LoadBoardException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"public class LoadBoardException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":" public LoadBoardException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" super(ExceptionMessages.MESSAGE_LOAD_BOARD_EXCEPTION);","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":" public LoadBoardException(String message) {","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":" super(message);","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"TriciaBK":17}},{"path":"src/main/java/chessmaster/exceptions/MoveOpponentPieceException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class MoveOpponentPieceException extends ChessMasterException {","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public MoveOpponentPieceException() {","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_MOVE_OPPONENT_EXCEPTION);","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public MoveOpponentPieceException(String message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/NullPieceException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class NullPieceException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public NullPieceException() {","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_NULL_PIECE_EXCEPTION);","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public NullPieceException(String message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/ParseChessPieceException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ParseChessPieceException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public ParseChessPieceException() {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_PARSE_CHESS_PIECE_EXCEPTION);","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public ParseChessPieceException(String message) {","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"TongZhengHong":16}},{"path":"src/main/java/chessmaster/exceptions/ParseColorException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ParseColorException extends ChessMasterException {","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public ParseColorException() {","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_PARSE_COLOR_EXCEPTION);","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public ParseColorException(String message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/ParseCoordinateException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ParseCoordinateException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public ParseCoordinateException() {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_PARSE_COORDINATE_EXCEPTION);","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public ParseCoordinateException(String message) {","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"TongZhengHong":16}},{"path":"src/main/java/chessmaster/exceptions/SaveBoardException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"public class SaveBoardException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":" public SaveBoardException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" super(ExceptionMessages.MESSAGE_SAVE_BOARD_EXCEPTION);","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":" public SaveBoardException(String message) {","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":" super(message);","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"TriciaBK":17}},{"path":"src/main/java/chessmaster/game/BoardScoreTuple.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"public class BoardScoreTuple implements Comparable\u003cBoardScoreTuple\u003e {","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":" private ChessBoard board;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":" private int score;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":" private Move move;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":" public BoardScoreTuple(ChessBoard board, int score, Move move) {","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" this.board \u003d board;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" this.score \u003d score;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" this.move \u003d move;","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" public ChessBoard getBoard() {","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" return board;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" public int getScore() {","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" return score;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" public Move getMove() {","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" return move;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" public int compareTo(BoardScoreTuple tuple) {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" if (this.score \u003e tuple.getScore()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" return 1;","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" } else if (this.score \u003c tuple.getScore()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" return -1;","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" return 0;","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"onx001":37}},{"path":"src/main/java/chessmaster/game/ChessBoard.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.InvalidMoveException;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"public class ChessBoard {","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public static final int SIZE \u003d 8;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int TOP_ROW_INDEX \u003d 0;","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public static final int BOTTOM_ROW_INDEX \u003d 7;","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" public static final int MAX_PIECES \u003d 16;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private static final String[][] STARTING_CHESSBOARD_BLACK \u003d { ","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" { \"r\", \"n\", \"b\", \"q\", \"k\", \"b\", \"n\", \"r\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" { \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" { \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" { \"R\", \"N\", \"B\", \"Q\", \"K\", \"B\", \"N\", \"R\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" private static final String[][] STARTING_CHESSBOARD_WHITE \u003d { ","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" { \"R\", \"N\", \"B\", \"Q\", \"K\", \"B\", \"N\", \"R\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" { \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\" },","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" { \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\" },","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" { \"r\", \"n\", \"b\", \"q\", \"k\", \"b\", \"n\", \"r\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" private Color playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" private boolean isWhiteKingAlive \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" private boolean isBlackKingAlive \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" private int difficulty \u003d 4;","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"antrikshdhand"},"content":" private final ChessTile[][] board \u003d new ChessTile[SIZE][SIZE];","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" public ChessBoard(Color playerColor) {","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" this.playerColor \u003d playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c SIZE; row++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c SIZE; col++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" String chessPieceString \u003d playerColor.isBlack()","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" ? STARTING_CHESSBOARD_BLACK[row][col]","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" : STARTING_CHESSBOARD_WHITE[row][col];","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece initialPiece \u003d Parser.parseChessPiece(chessPieceString, row, col);","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" board[row][col] \u003d new ChessTile(initialPiece);","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"ken-ruster"},"content":" assert (board[row][col] !\u003d null);","lastModifiedDate":"2023-10-20"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" this.playerColor \u003d playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" public ChessBoard(Color playerColor, ChessTile[][] boardTiles) {","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" this.playerColor \u003d playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c SIZE; row++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c SIZE; col++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" board[row][col] \u003d boardTiles[row][col];","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" * Gets a copy of the current chessboard as a 2D array of ChessTile objects.","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" * This method creates a deep copy of the chessboard, allowing for the independent","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" * examination of the board\u0027s state without modifying the original chessboard.","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" * @return A 2D array copy of ChessTile objects representing the current state of the chessboard.","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" public ChessTile[][] getBoard() {","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[][] copy \u003d new ChessTile[SIZE][SIZE];","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c SIZE; i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" copy[i] \u003d board[i].clone();","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" return copy;","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" public Color getPlayerColor() {","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" return this.playerColor;","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" public void setDifficulty(int difficulty) {","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" this.difficulty \u003d difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" public int getDifficulty() {","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":" return this.difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" public boolean isChecked() {","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":" Move[] moves \u003d getAllMoves(playerColor.getOppositeColour());","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":" for (Move move : moves) {","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":" Coordinate to \u003d move.getTo();","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":" if (this.getPieceAtCoor(to) instanceof King) {","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"onx001"},"content":" public boolean isCheckmated() {","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"onx001"},"content":" Move[] moves \u003d getAllMoves(playerColor);","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"onx001"},"content":" for (Move move : moves) {","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"onx001"},"content":" ChessBoard newBoard \u003d this.clone();","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":" newBoard.executeMove(move);","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":" } catch (InvalidMoveException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"onx001"},"content":" continue;","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"onx001"},"content":" if (!newBoard.isChecked()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"onx001"},"content":" public Move[] getAllMoves(Color color) {","lastModifiedDate":"2023-10-23"},{"lineNumber":130,"author":{"gitId":"onx001"},"content":" //Declare arraylist of moves as allMoves","lastModifiedDate":"2023-10-23"},{"lineNumber":131,"author":{"gitId":"onx001"},"content":" ArrayList\u003cMove\u003e allMoves \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":132,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":133,"author":{"gitId":"onx001"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":134,"author":{"gitId":"onx001"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":135,"author":{"gitId":"onx001"},"content":" Coordinate coor \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-23"},{"lineNumber":136,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d getPieceAtCoor(coor);","lastModifiedDate":"2023-10-23"},{"lineNumber":137,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":138,"author":{"gitId":"onx001"},"content":" if (piece.isSameColorAs(color)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":139,"author":{"gitId":"onx001"},"content":" Coordinate[] possibleCoordinates \u003d piece.getFlattenedCoordinates(this);","lastModifiedDate":"2023-10-23"},{"lineNumber":140,"author":{"gitId":"onx001"},"content":" for (Coordinate possible: possibleCoordinates) {","lastModifiedDate":"2023-10-23"},{"lineNumber":141,"author":{"gitId":"onx001"},"content":" Move move \u003d new Move(coor, possible, piece);","lastModifiedDate":"2023-10-23"},{"lineNumber":142,"author":{"gitId":"onx001"},"content":" allMoves.add(move);","lastModifiedDate":"2023-10-23"},{"lineNumber":143,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":144,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":145,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":146,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":147,"author":{"gitId":"onx001"},"content":" return allMoves.toArray(new Move[0]);","lastModifiedDate":"2023-10-23"},{"lineNumber":148,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":149,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":150,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":151,"author":{"gitId":"TongZhengHong"},"content":" public void setPromotionPiece(Coordinate coord, ChessPiece promotedPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":152,"author":{"gitId":"TongZhengHong"},"content":" getTileAtCoor(coord).updateTileChessPiece(promotedPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":153,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":155,"author":{"gitId":"TongZhengHong"},"content":" public void setTile(int row, int col, ChessTile tile) {","lastModifiedDate":"2023-10-22"},{"lineNumber":156,"author":{"gitId":"TongZhengHong"},"content":" board[row][col] \u003d tile;","lastModifiedDate":"2023-10-22"},{"lineNumber":157,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":158,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":160,"author":{"gitId":"TongZhengHong"},"content":" * Gets the ChessTile object located at the specified coordinate on the","lastModifiedDate":"2023-10-22"},{"lineNumber":161,"author":{"gitId":"TongZhengHong"},"content":" * chessboard.","lastModifiedDate":"2023-10-22"},{"lineNumber":162,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":163,"author":{"gitId":"TongZhengHong"},"content":" * @param coor The coordinate of the position to retrieve the tile for.","lastModifiedDate":"2023-10-22"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":" * @return The ChessTile object at the specified coordinate.","lastModifiedDate":"2023-10-22"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":166,"author":{"gitId":"TongZhengHong"},"content":" private ChessTile getTileAtCoor(Coordinate coor) {","lastModifiedDate":"2023-10-18"},{"lineNumber":167,"author":{"gitId":"TongZhengHong"},"content":" return board[coor.getY()][coor.getX()];","lastModifiedDate":"2023-10-18"},{"lineNumber":168,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":169,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":170,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":171,"author":{"gitId":"TongZhengHong"},"content":" * Gets the chess piece located at the specified coordinate on the chessboard.","lastModifiedDate":"2023-10-22"},{"lineNumber":172,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":173,"author":{"gitId":"TongZhengHong"},"content":" * @param coor The coordinate of the position to check.","lastModifiedDate":"2023-10-22"},{"lineNumber":174,"author":{"gitId":"TongZhengHong"},"content":" * @return The ChessPiece object at the specified coordinate. If empty piece at","lastModifiedDate":"2023-10-22"},{"lineNumber":175,"author":{"gitId":"TongZhengHong"},"content":" * coordinate, returns EmptyPiece object","lastModifiedDate":"2023-10-22"},{"lineNumber":176,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" public ChessPiece getPieceAtCoor(Coordinate coor) {","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" ChessTile tile \u003d getTileAtCoor(coor);","lastModifiedDate":"2023-10-18"},{"lineNumber":179,"author":{"gitId":"TongZhengHong"},"content":" return tile.getChessPiece();","lastModifiedDate":"2023-10-16"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":183,"author":{"gitId":"TongZhengHong"},"content":" * Executes a chess move on the chessboard.","lastModifiedDate":"2023-10-18"},{"lineNumber":184,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":185,"author":{"gitId":"TongZhengHong"},"content":" * @param move The Move object representing the move to be executed.","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"TongZhengHong"},"content":" * @throws InvalidMoveException If the move is not valid according to the game","lastModifiedDate":"2023-10-22"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":" * rules.","lastModifiedDate":"2023-10-22"},{"lineNumber":188,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":189,"author":{"gitId":"TongZhengHong"},"content":" public void executeMove(Move move) throws InvalidMoveException {","lastModifiedDate":"2023-10-18"},{"lineNumber":190,"author":{"gitId":"TongZhengHong"},"content":" Coordinate startCoor \u003d move.getFrom();","lastModifiedDate":"2023-10-18"},{"lineNumber":191,"author":{"gitId":"TongZhengHong"},"content":" Coordinate destCoor \u003d move.getTo();","lastModifiedDate":"2023-10-18"},{"lineNumber":192,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece chessPiece \u003d move.getPiece();","lastModifiedDate":"2023-10-18"},{"lineNumber":193,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":194,"author":{"gitId":"TongZhengHong"},"content":" if (!move.isValid(this)) {","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"TongZhengHong"},"content":" throw new InvalidMoveException();","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":197,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"TongZhengHong"},"content":" chessPiece.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":199,"author":{"gitId":"TongZhengHong"},"content":" chessPiece.updatePosition(destCoor);","lastModifiedDate":"2023-10-19"},{"lineNumber":200,"author":{"gitId":"TongZhengHong"},"content":" getTileAtCoor(startCoor).setTileEmpty(startCoor);","lastModifiedDate":"2023-10-20"},{"lineNumber":201,"author":{"gitId":"TongZhengHong"},"content":" getTileAtCoor(destCoor).updateTileChessPiece(chessPiece);","lastModifiedDate":"2023-10-18"},{"lineNumber":202,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":203,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":204,"author":{"gitId":"onx001"},"content":" if (move.isLeftCastling() \u0026\u0026 startCoor.isOffsetWithinBoard(-4, 0)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"onx001"},"content":" Coordinate rookStartCoor \u003d startCoor.addOffsetToCoordinate(-4, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"onx001"},"content":" Coordinate rookDestCoor \u003d startCoor.addOffsetToCoordinate(-1, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"onx001"},"content":" ChessPiece rook \u003d getTileAtCoor(rookStartCoor).getChessPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":208,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":209,"author":{"gitId":"onx001"},"content":" rook.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":210,"author":{"gitId":"onx001"},"content":" rook.updatePosition(rookDestCoor);","lastModifiedDate":"2023-10-19"},{"lineNumber":211,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":212,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookStartCoor).setTileEmpty(rookStartCoor);","lastModifiedDate":"2023-10-20"},{"lineNumber":213,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookDestCoor).updateTileChessPiece(rook);","lastModifiedDate":"2023-10-19"},{"lineNumber":214,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":215,"author":{"gitId":"onx001"},"content":" } else if (move.isRightCastling() \u0026\u0026 startCoor.isOffsetWithinBoard(3, 0)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"onx001"},"content":" Coordinate rookStartCoor \u003d startCoor.addOffsetToCoordinate(3, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"onx001"},"content":" Coordinate rookDestCoor \u003d startCoor.addOffsetToCoordinate(1, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"onx001"},"content":" ChessPiece rook \u003d getTileAtCoor(rookStartCoor).getChessPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":219,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":220,"author":{"gitId":"onx001"},"content":" rook.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":221,"author":{"gitId":"onx001"},"content":" rook.updatePosition(rookDestCoor);","lastModifiedDate":"2023-10-19"},{"lineNumber":222,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":223,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookStartCoor).setTileEmpty(rookStartCoor);","lastModifiedDate":"2023-10-20"},{"lineNumber":224,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookDestCoor).updateTileChessPiece(rook);","lastModifiedDate":"2023-10-19"},{"lineNumber":225,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":226,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":227,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":228,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-27"},{"lineNumber":229,"author":{"gitId":"ken-ruster"},"content":" public boolean canPromote(Move move) {","lastModifiedDate":"2023-10-19"},{"lineNumber":230,"author":{"gitId":"ken-ruster"},"content":" ChessPiece piece \u003d move.getPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":231,"author":{"gitId":"ken-ruster"},"content":" Coordinate endCoord \u003d move.getTo();","lastModifiedDate":"2023-10-19"},{"lineNumber":232,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":233,"author":{"gitId":"ken-ruster"},"content":" if (!piece.isPawn()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":234,"author":{"gitId":"ken-ruster"},"content":" return false;","lastModifiedDate":"2023-10-19"},{"lineNumber":235,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":236,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":237,"author":{"gitId":"ken-ruster"},"content":" if (isPieceFriendly(piece)) {","lastModifiedDate":"2023-10-26"},{"lineNumber":238,"author":{"gitId":"ken-ruster"},"content":" return endCoord.getY() \u003d\u003d TOP_ROW_INDEX;","lastModifiedDate":"2023-10-22"},{"lineNumber":239,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":240,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":241,"author":{"gitId":"ken-ruster"},"content":" if (isPieceOpponent(piece)) {","lastModifiedDate":"2023-10-26"},{"lineNumber":242,"author":{"gitId":"ken-ruster"},"content":" return endCoord.getY() \u003d\u003d BOTTOM_ROW_INDEX;","lastModifiedDate":"2023-10-22"},{"lineNumber":243,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":244,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":245,"author":{"gitId":"ken-ruster"},"content":" return false;","lastModifiedDate":"2023-10-19"},{"lineNumber":246,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":247,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":248,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":249,"author":{"gitId":"TriciaBK"},"content":" public boolean isEndGame() {","lastModifiedDate":"2023-10-20"},{"lineNumber":250,"author":{"gitId":"TriciaBK"},"content":" isWhiteKingAlive \u003d false; ","lastModifiedDate":"2023-10-22"},{"lineNumber":251,"author":{"gitId":"TriciaBK"},"content":" isBlackKingAlive \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":252,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":253,"author":{"gitId":"TriciaBK"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-20"},{"lineNumber":254,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-20"},{"lineNumber":255,"author":{"gitId":"TriciaBK"},"content":" Coordinate coor \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-20"},{"lineNumber":256,"author":{"gitId":"TriciaBK"},"content":" ChessPiece piece \u003d getPieceAtCoor(coor);","lastModifiedDate":"2023-10-20"},{"lineNumber":257,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":258,"author":{"gitId":"TriciaBK"},"content":" if (piece instanceof King) {","lastModifiedDate":"2023-10-22"},{"lineNumber":259,"author":{"gitId":"TriciaBK"},"content":" if (piece.isWhite()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":260,"author":{"gitId":"TriciaBK"},"content":" isWhiteKingAlive \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":261,"author":{"gitId":"TriciaBK"},"content":" } else if (piece.isBlack()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":262,"author":{"gitId":"TriciaBK"},"content":" isBlackKingAlive \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":263,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":264,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":265,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":266,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":267,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":268,"author":{"gitId":"TriciaBK"},"content":" return !isBlackKingAlive || !isWhiteKingAlive;","lastModifiedDate":"2023-10-22"},{"lineNumber":269,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":270,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":271,"author":{"gitId":"TriciaBK"},"content":" public Color getWinningColor() {","lastModifiedDate":"2023-10-22"},{"lineNumber":272,"author":{"gitId":"TriciaBK"},"content":" boolean whiteWin \u003d isWhiteKingAlive \u0026\u0026 !isBlackKingAlive;","lastModifiedDate":"2023-10-22"},{"lineNumber":273,"author":{"gitId":"TriciaBK"},"content":" boolean blackWin \u003d isBlackKingAlive \u0026\u0026 !isWhiteKingAlive;","lastModifiedDate":"2023-10-22"},{"lineNumber":274,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":275,"author":{"gitId":"TriciaBK"},"content":" if (whiteWin) {","lastModifiedDate":"2023-10-22"},{"lineNumber":276,"author":{"gitId":"TriciaBK"},"content":" return Color.WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":277,"author":{"gitId":"TriciaBK"},"content":" } else if (blackWin) {","lastModifiedDate":"2023-10-22"},{"lineNumber":278,"author":{"gitId":"TriciaBK"},"content":" return Color.BLACK;","lastModifiedDate":"2023-10-22"},{"lineNumber":279,"author":{"gitId":"TriciaBK"},"content":" } else {","lastModifiedDate":"2023-10-20"},{"lineNumber":280,"author":{"gitId":"TriciaBK"},"content":" return Color.EMPTY;","lastModifiedDate":"2023-10-22"},{"lineNumber":281,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":282,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":283,"author":{"gitId":"TriciaBK"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":284,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":285,"author":{"gitId":"onx001"},"content":" public int getPoints(Color color) {","lastModifiedDate":"2023-10-23"},{"lineNumber":286,"author":{"gitId":"onx001"},"content":" int points \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":287,"author":{"gitId":"onx001"},"content":" int enemyPoints \u003d 0;","lastModifiedDate":"2023-10-24"},{"lineNumber":288,"author":{"gitId":"onx001"},"content":" boolean isUpright;","lastModifiedDate":"2023-10-26"},{"lineNumber":289,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":290,"author":{"gitId":"onx001"},"content":" if (this.playerColor \u003d\u003d color) {","lastModifiedDate":"2023-10-26"},{"lineNumber":291,"author":{"gitId":"onx001"},"content":" isUpright \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":292,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":293,"author":{"gitId":"onx001"},"content":" isUpright \u003d false;","lastModifiedDate":"2023-10-26"},{"lineNumber":294,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":295,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":296,"author":{"gitId":"onx001"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":297,"author":{"gitId":"onx001"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":298,"author":{"gitId":"onx001"},"content":" Coordinate coor \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-23"},{"lineNumber":299,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d this.getPieceAtCoor(coor);","lastModifiedDate":"2023-10-23"},{"lineNumber":300,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":301,"author":{"gitId":"onx001"},"content":" if (piece.isSameColorAs(color)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":302,"author":{"gitId":"onx001"},"content":" points +\u003d piece.getPoints(isUpright);","lastModifiedDate":"2023-10-26"},{"lineNumber":303,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-24"},{"lineNumber":304,"author":{"gitId":"onx001"},"content":" enemyPoints +\u003d piece.getPoints(isUpright);","lastModifiedDate":"2023-10-26"},{"lineNumber":305,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":306,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":307,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":308,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":309,"author":{"gitId":"onx001"},"content":" return points - enemyPoints;","lastModifiedDate":"2023-10-24"},{"lineNumber":310,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":311,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":312,"author":{"gitId":"onx001"},"content":" public ChessBoard clone() {","lastModifiedDate":"2023-10-23"},{"lineNumber":313,"author":{"gitId":"onx001"},"content":" String stringRep \u003d this.toString();","lastModifiedDate":"2023-10-23"},{"lineNumber":314,"author":{"gitId":"onx001"},"content":" return toBoard(stringRep);","lastModifiedDate":"2023-10-23"},{"lineNumber":315,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":316,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":317,"author":{"gitId":"onx001"},"content":" public ChessBoard toBoard(String board) {","lastModifiedDate":"2023-10-23"},{"lineNumber":318,"author":{"gitId":"onx001"},"content":" ChessTile[][] boardTiles \u003d new ChessTile[SIZE][SIZE];","lastModifiedDate":"2023-10-23"},{"lineNumber":319,"author":{"gitId":"onx001"},"content":" int row \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":320,"author":{"gitId":"onx001"},"content":" int col \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":321,"author":{"gitId":"onx001"},"content":" for (int i \u003d 0; i \u003c board.length(); i++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":322,"author":{"gitId":"onx001"},"content":" String pieceString \u003d board.substring(i, i + 1);","lastModifiedDate":"2023-10-23"},{"lineNumber":323,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d Parser.parseChessPiece(pieceString, row, col);","lastModifiedDate":"2023-10-23"},{"lineNumber":324,"author":{"gitId":"onx001"},"content":" assert (row \u003c SIZE);","lastModifiedDate":"2023-10-24"},{"lineNumber":325,"author":{"gitId":"onx001"},"content":" assert (col \u003c SIZE);","lastModifiedDate":"2023-10-24"},{"lineNumber":326,"author":{"gitId":"onx001"},"content":" boardTiles[row][col] \u003d new ChessTile(piece);","lastModifiedDate":"2023-10-23"},{"lineNumber":327,"author":{"gitId":"onx001"},"content":" col++;","lastModifiedDate":"2023-10-23"},{"lineNumber":328,"author":{"gitId":"onx001"},"content":" if (col \u003d\u003d SIZE) {","lastModifiedDate":"2023-10-23"},{"lineNumber":329,"author":{"gitId":"onx001"},"content":" col \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":330,"author":{"gitId":"onx001"},"content":" row++;","lastModifiedDate":"2023-10-23"},{"lineNumber":331,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":332,"author":{"gitId":"onx001"},"content":" if (row \u003d\u003d SIZE) {","lastModifiedDate":"2023-10-24"},{"lineNumber":333,"author":{"gitId":"onx001"},"content":" break;","lastModifiedDate":"2023-10-24"},{"lineNumber":334,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":335,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":336,"author":{"gitId":"onx001"},"content":" return new ChessBoard(this.playerColor, boardTiles);","lastModifiedDate":"2023-10-26"},{"lineNumber":337,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":338,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":339,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":340,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":341,"author":{"gitId":"onx001"},"content":" StringBuilder boardString \u003d new StringBuilder();","lastModifiedDate":"2023-10-23"},{"lineNumber":342,"author":{"gitId":"onx001"},"content":" for (ChessTile[] row : board) {","lastModifiedDate":"2023-10-23"},{"lineNumber":343,"author":{"gitId":"onx001"},"content":" for (ChessTile tile : row) {","lastModifiedDate":"2023-10-23"},{"lineNumber":344,"author":{"gitId":"onx001"},"content":" boardString.append(tile.toFileString());","lastModifiedDate":"2023-10-24"},{"lineNumber":345,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":346,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":347,"author":{"gitId":"onx001"},"content":" return boardString.toString();","lastModifiedDate":"2023-10-23"},{"lineNumber":348,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":349,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":350,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":351,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPieceFriendly(ChessPiece otherPiece) {","lastModifiedDate":"2023-10-26"},{"lineNumber":352,"author":{"gitId":"TongZhengHong"},"content":" return this.playerColor \u003d\u003d otherPiece.getColor();","lastModifiedDate":"2023-10-26"},{"lineNumber":353,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":354,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":355,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPieceOpponent(ChessPiece otherPiece) {","lastModifiedDate":"2023-10-26"},{"lineNumber":356,"author":{"gitId":"TongZhengHong"},"content":" return this.playerColor !\u003d otherPiece.getColor();","lastModifiedDate":"2023-10-26"},{"lineNumber":357,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":358,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":22,"antrikshdhand":1,"TriciaBK":37,"onx001":160,"TongZhengHong":138}},{"path":"src/main/java/chessmaster/game/ChessTile.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.EmptyPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ChessTile {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public static final String TILE_DIVIDER \u003d \"|\";","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" private static final String EMPTY_TILE_STRING \u003d \" \";","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" private static final String EMPTY_TILE_MOVES_STRING \u003d \".\";","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":" private static final String BACKGROUND_RESET \u003d \"\\u001B[0m\";","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":" private static final String CAPTURABLE_BACKGROUND \u003d \"\\u001B[43m\";","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" /** Nullable ChessPiece object. Null signifies that this tile is empty */","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" private ChessPiece chessPiece;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" public ChessTile(Coordinate coor) {","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d new EmptyPiece(coor.getX(), coor.getY());","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" public ChessTile(ChessPiece piece) {","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d piece;","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" public ChessPiece getChessPiece() {","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece;","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public boolean isEmpty() {","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" public void setTileEmpty(Coordinate coor) {","lastModifiedDate":"2023-10-20"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d new EmptyPiece(coor.getX(),coor.getY());","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" * Updates the ChessTile with a new ChessPiece, considering piece interactions. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * 1. Replace the new piece on an EMPTY tile. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" * 2. Cannot capture a friendly piece; no change is made UNLESS it is for promotion. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" * 3. If new piece captures the opponent piece, mark the opponent piece as captured and replace it. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" * @param newPiece The new ChessPiece to place on the tile.","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" public void updateTileChessPiece(ChessPiece newPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" if (chessPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" // Move newPiece to empty tile","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d newPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" return;","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" } ","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" if (newPiece.isFriendly(chessPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" // Only update if friendly pawn piece is promoting","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (chessPiece.isPawn() \u0026\u0026 newPiece.isPromotionPiece()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d newPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" return; // Cannot capture friendly piece","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" } ","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" if (newPiece.isOpponent(chessPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" // Mark opponent piece as captured","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" chessPiece.setIsCaptured();","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d newPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_STRING : chessPiece.toString();","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" return String.format(\" %s \", tileContent);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" public String toStringSelected() {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_STRING : chessPiece.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" return CAPTURABLE_BACKGROUND + String.format(\"{%s}\", tileContent) + BACKGROUND_RESET;","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" public String toStringPrevMove() {","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_STRING : chessPiece.toString();","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" return CAPTURABLE_BACKGROUND + String.format(\"(%s)\", tileContent) + BACKGROUND_RESET;","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"ken-ruster"},"content":" public String toStringAvailableDest() {","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"ken-ruster"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_MOVES_STRING : chessPiece.toString();","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ken-ruster"},"content":" String addBrackets \u003d String.format(\"[%s]\", tileContent);","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"ken-ruster"},"content":" if (!isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"ken-ruster"},"content":" return CAPTURABLE_BACKGROUND + addBrackets + BACKGROUND_RESET;","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"ken-ruster"},"content":" return addBrackets;","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" public String toFileString() {","lastModifiedDate":"2023-10-24"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" return chessPiece.toString();","lastModifiedDate":"2023-10-24"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":17,"onx001":5,"TongZhengHong":75}},{"path":"src/main/java/chessmaster/game/Color.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"public enum Color {","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" WHITE, BLACK, EMPTY;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" * Get the opposite color given the player\u0027s color.","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" * Used to identify the color for CPU player.","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" * @return The opposite color.","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public Color getOppositeColour() {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" if (this \u003d\u003d Color.WHITE) {","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" return Color.BLACK;","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" } else if (this \u003d\u003d Color.BLACK) {","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" return Color.WHITE;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" return Color.EMPTY;","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" * Checks if a given color is white. ","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the color is white; false otherwise.","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public boolean isWhite() {","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" return this \u003d\u003d Color.WHITE;","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" * Checks if a given color is black. ","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the color is black; false otherwise.","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" public boolean isBlack() {","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" return this \u003d\u003d Color.BLACK;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" * Checks if a given color is empty.","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the color is empty; false otherwise.","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" public boolean isEmpty() {","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" return this \u003d\u003d Color.EMPTY;","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"TongZhengHong":49}},{"path":"src/main/java/chessmaster/game/Coordinate.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class Coordinate {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" private static final String BOARD_COLUMNS \u003d \"abcdefgh\";","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" private int x;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" private int y;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public Coordinate(int x, int y) {","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" this.x \u003d x;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" this.y \u003d y;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" assert !isCoorOutofBoard(x, y) : \"Coordinates (x,y) should NOT be out of chessboard (8x8 size)!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public int getX() {","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" return x;","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" public int getY() {","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" return y;","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" public static boolean isCoorOutofBoard(int x, int y) {","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" return (x \u003c 0 || x \u003e\u003d ChessBoard.SIZE) || (y \u003c 0 || y \u003e\u003d ChessBoard.SIZE);","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" * Checks if applying a given offset from the current position stays within the","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" * bounds of the chessboard.","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetX The horizontal offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetY The vertical offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the resulting position is within the board boundaries;","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * otherwise, false.","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" public boolean isOffsetWithinBoard(int offsetX, int offsetY) {","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int newX \u003d x + offsetX;","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" int newY \u003d y + offsetY;","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" return (newX \u003e\u003d 0 \u0026\u0026 newX \u003c ChessBoard.SIZE) \u0026\u0026","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" (newY \u003e\u003d 0 \u0026\u0026 newY \u003c ChessBoard.SIZE);","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" * Adds the given offsets to the current coordinate and returns the new","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" * coordinate.","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetX The horizontal offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetY The vertical offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" * @return A new coordinate after applying the offsets, or the current","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" * coordinate","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" * if the new position is out of the board boundaries.","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" public Coordinate addOffsetToCoordinate(int offsetX, int offsetY) {","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" int newX \u003d x + offsetX;","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" int newY \u003d y + offsetY;","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" if (isCoorOutofBoard(newX, newY)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" return new Coordinate(x, y);","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" return new Coordinate(newX, newY);","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" * Parses an algebraic chess coordinate notation (e.g., \"a1\") and returns a","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" * Coordinate object.","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" * @param notation The algebraic coordinate notation to parse.","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" * @return A Coordinate object representing the parsed chess coordinate.","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" * @throws ParseCoordinateException If the input notation is invalid or out of","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" * bounds.","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" public static Coordinate parseAlgebraicCoor(String notation) throws ParseCoordinateException {","lastModifiedDate":"2023-10-15"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" notation \u003d notation.toLowerCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" if (notation.length() !\u003d 2) {","lastModifiedDate":"2023-10-15"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-15"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" String colString \u003d Character.toString(notation.charAt(0));","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" boolean isColValid \u003d BOARD_COLUMNS.contains(colString);","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" String rowString \u003d String.valueOf(notation.charAt(1));","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" int rowInt \u003d Integer.parseInt(String.valueOf(rowString));","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" if (rowInt \u003c 1 || rowInt \u003e ChessBoard.SIZE || !isColValid) {","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" int indexX \u003d BOARD_COLUMNS.indexOf(colString); ","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" int indexY \u003d (rowInt - 8) * -1;","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" return new Coordinate(indexX, indexY);","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-15"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" public int[] calculateOffsetFrom(Coordinate otherCoordinate) {","lastModifiedDate":"2023-10-22"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d this.x - otherCoordinate.getX();","lastModifiedDate":"2023-10-22"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d this.y - otherCoordinate.getY();","lastModifiedDate":"2023-10-22"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" return new int[]{ offsetX, offsetY };","lastModifiedDate":"2023-10-22"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-16"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" return String.format(\"%s%d\", BOARD_COLUMNS.charAt(x), (ChessBoard.SIZE - y));","lastModifiedDate":"2023-10-17"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":" public boolean equals(Object obj) {","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"onx001"},"content":" if (obj instanceof Coordinate) {","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"onx001"},"content":" Coordinate other \u003d (Coordinate) obj;","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"onx001"},"content":" return x \u003d\u003d other.x \u0026\u0026 y \u003d\u003d other.y;","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-16"},{"lineNumber":124,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":125,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":126,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"onx001":11,"TongZhengHong":115}},{"path":"src/main/java/chessmaster/game/Game.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.AbortCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.Command;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.CommandResult;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.MoveCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.storage.Storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.CPU;","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.Human;","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.Player;","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"public class Game {","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" private static final String[] START_HELP_STRINGS \u003d {","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" \"Thank you for choosing ChessMaster! Here are the commands that you can use:\",","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" \"Move piece - Input coordinate of piece, followed by coordinate to move to\",","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" \" Format: [column][row] [column][row]\",","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" \" E.g. a2 a3\",","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" \"Show board - Shows the current state of the chess board\",","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" \" Format: show\",","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" \"Show available moves - Lists all the available moves for a piece at a coordinate\",","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" \" Format: moves [column][row]\",","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" \" E.g. moves a2\",","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" \"Abort game - Exit programme\",","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" \" Format: abort\",","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" \"Obtain rules - Obtain a quick refresher on the rules of chess\",","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" \" Format: rules\",","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" \"Obtain help - Show a list of commands and what they do\",","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" \" Format: help\"","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" private CPU cpu;","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" private Human human;","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" private Player currentPlayer;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" private TextUI ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" private ChessBoard board;","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" private Storage storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" private int difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" private Command command;","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" private boolean hasEnded;","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" public Game(Color playerColour, Color currentTurnColor, ChessBoard board, ","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" Storage storage, TextUI ui, int difficulty) {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" this.board \u003d board;","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" this.storage \u003d storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" this.difficulty \u003d difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" this.human \u003d new Human(playerColour, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" Color cpuColor \u003d playerColour.getOppositeColour();","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" this.cpu \u003d new CPU(cpuColor, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" // Choose which player goes first","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" currentPlayer \u003d currentTurnColor \u003d\u003d playerColour ? human : cpu;","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" assert playerColour !\u003d Color.EMPTY : \"Human player color should not be EMPTY!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" assert cpuColor !\u003d Color.EMPTY : \"CPU player color should not be EMPTY!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" assert currentPlayer !\u003d null : \"A player should always exist in a game!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" assert (0 \u003c difficulty) \u0026\u0026 (difficulty \u003c 5) : \"Difficulty should be between 1 and 4!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" public void run() {","lastModifiedDate":"2023-10-19"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" ui.printText(START_HELP_STRINGS);","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" while (!hasEnded \u0026\u0026 !AbortCommand.isAbortCommand(command)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" assert currentPlayer.isCPU() || currentPlayer.isHuman() : ","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" \"Player should only either be human or CPU!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" if (currentPlayer.isHuman()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" command \u003d getUserCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" if (!command.isMoveCommand()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" continue; // Get next command","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" Move playedMove \u003d handleHumanMove();","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" ui.printChessBoardWithMove(board.getBoard(), playedMove);","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" } else if (currentPlayer.isCPU()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" Move playedMove \u003d handleCPUMove();","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" ui.printChessBoardWithMove(board.getBoard(), playedMove);","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" } ","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" currentPlayer \u003d togglePlayerTurn();","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":" storage.saveBoard(board, currentPlayer.getColour());","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" hasEnded \u003d checkEndState(); // Resets board if end","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" } catch (ChessMasterException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" ui.printErrorMessage(e);","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" private Command getUserCommand() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" String userInputString \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" command \u003d Parser.parseCommand(userInputString);","lastModifiedDate":"2023-10-22"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" CommandResult result \u003d command.execute(board, ui);","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" ui.printCommandResult(result);","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" return command;","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" private Move handleHumanMove() throws ChessMasterException {","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" Move humanMove \u003d ((MoveCommand) command).getMove();","lastModifiedDate":"2023-10-23"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" board.executeMove(humanMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" human.addMove(humanMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" // Handle human promotion","lastModifiedDate":"2023-10-23"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" if (!board.isEndGame()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" if (board.canPromote(humanMove)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":" human.handlePromote(board, ui, humanMove);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":" return humanMove;","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":" private Move handleCPUMove() throws ChessMasterException {","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":" Move cpuMove \u003d cpu.getBestMove(board, difficulty);","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":" ui.printCPUMove(cpuMove);","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":" board.executeMove(cpuMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":" cpu.addMove(cpuMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":130,"author":{"gitId":"TongZhengHong"},"content":" return cpuMove;","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":132,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":133,"author":{"gitId":"TongZhengHong"},"content":" private boolean checkEndState() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":134,"author":{"gitId":"TongZhengHong"},"content":" boolean end \u003d board.isEndGame();","lastModifiedDate":"2023-10-22"},{"lineNumber":135,"author":{"gitId":"TongZhengHong"},"content":" if (end) {","lastModifiedDate":"2023-10-22"},{"lineNumber":136,"author":{"gitId":"TongZhengHong"},"content":" Color winningColor \u003d board.getWinningColor();","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"TongZhengHong"},"content":" Player winnerPlayer \u003d human.getColour() \u003d\u003d winningColor ? human : cpu;","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"TongZhengHong"},"content":" ui.printWinnerMessage(winnerPlayer);","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"TongZhengHong"},"content":" storage.resetBoard();","lastModifiedDate":"2023-10-23"},{"lineNumber":140,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":141,"author":{"gitId":"TongZhengHong"},"content":" return end;","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":143,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":144,"author":{"gitId":"TongZhengHong"},"content":" private Player togglePlayerTurn() {","lastModifiedDate":"2023-10-23"},{"lineNumber":145,"author":{"gitId":"TongZhengHong"},"content":" return currentPlayer.isHuman() ? cpu : human;","lastModifiedDate":"2023-10-23"},{"lineNumber":146,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":147,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":147}},{"path":"src/main/java/chessmaster/game/MiniMax.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"//@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"public class MiniMax {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":" protected int depth;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":" protected int maxDepth;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" protected int score;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" protected Move bestMove;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" protected ChessBoard board;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" protected Color color;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":" protected Color opponentColor;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" protected BoardScoreTuple tuple;","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" //declares all variables needed for the minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" public MiniMax(ChessBoard board, Color color, int maxDepth, int score) {","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" this.board \u003d board;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" this.color \u003d color;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" this.opponentColor \u003d color.getOppositeColour();","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" this.maxDepth \u003d maxDepth;","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" this.score \u003d score;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" this.tuple \u003d new BoardScoreTuple(board, score, null);","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" * returns the best move tuple for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" * @author onx001","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" * @param tuple the BoardScoreTuple to be weighed","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" * @param color the color of the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" * @param depth the current depth of the minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" * @param score the score of the current board","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" * @param isMax whether the current player is the CPU or the player","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" * @param maxDepth the maximum depth of the minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" * @return the best move tuple for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":" public static BoardScoreTuple mostPoints(BoardScoreTuple tuple, Color color, int depth, ","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" int score, boolean isMax, int maxDepth) {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"onx001"},"content":" //gets all the moves for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"onx001"},"content":" ChessBoard board \u003d tuple.getBoard();","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":" Color playerColor \u003d isMax ? color : color.getOppositeColour();","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" Move[] moves \u003d board.getAllMoves(playerColor);","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":" assert moves.length \u003e 0 : \"No moves available for \" + color + \" at depth \" + depth;","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":" BoardScoreTuple[] boards \u003d new BoardScoreTuple[moves.length];","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" int bestScore \u003d isMax ? Integer.MIN_VALUE : Integer.MAX_VALUE;","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" BoardScoreTuple bestTuple \u003d null;","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" //if the depth is the max depth, return the score of the board as base case","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" if (depth \u003d\u003d maxDepth) {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" int newscore \u003d board.getPoints(color);","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" return new BoardScoreTuple(board,newscore, null);","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" //for each move, clone the board and execute the move as a possibility","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" for (int i \u003d 0; i \u003c moves.length; i++) {","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" assert moves[i] !\u003d null : \"moves[i] is null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" ChessBoard newBoard \u003d board.clone();","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" Move move \u003d moves[i];","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"onx001"},"content":" Coordinate from \u003d move.getFrom();","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d newBoard.getPieceAtCoor(from);","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":" move.setPiece(piece);","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"onx001"},"content":" newBoard.executeMove(move);","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"onx001"},"content":" //get the score of the board after the move","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"onx001"},"content":" int newScore \u003d newBoard.getPoints(color);","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":" boards[i] \u003d new BoardScoreTuple(newBoard, newScore, move);","lastModifiedDate":"2023-10-24"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":" } catch (ChessMasterException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":" continue;","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":" //go through boards and find one with best points","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" for (int i \u003d 0; i \u003c boards.length; i++) {","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" BoardScoreTuple iterTuple \u003d boards[i];","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" assert iterTuple !\u003d null : \"iterTuple is null\";","lastModifiedDate":"2023-10-24"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":" assert iterTuple.getMove() !\u003d null : \"iterTuple move is null\";","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" //recursively call mostPoints to find the best move for current board","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" BoardScoreTuple tuple1 \u003d mostPoints(iterTuple, color, depth + 1, score, !isMax, maxDepth);","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":" //prints score as branch","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" //System.out.println(\"|\" + \"---\".repeat(depth) + \" \" + tuple1.getScore() + tuple.getMove());","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" //Sets new score to current child score","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" int newScore \u003d tuple1.getScore();","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" if (isMax) {","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" //maximises child score if CPU turn","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":" if (newScore \u003e bestScore) {","lastModifiedDate":"2023-10-24"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" bestScore \u003d newScore;","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" //minimises child score if player turn","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" if (newScore \u003c bestScore) {","lastModifiedDate":"2023-10-24"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" bestScore \u003d newScore;","lastModifiedDate":"2023-10-25"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" //set current tuple based on best child score","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":" bestTuple \u003d bestScore \u003d\u003d newScore ? iterTuple : bestTuple;","lastModifiedDate":"2023-10-25"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":" return bestTuple;","lastModifiedDate":"2023-10-24"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":" /** ","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":" * Kicks off minimax algorithm and returns the best move for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":111,"author":{"gitId":"onx001"},"content":" public Move getBestMove() {","lastModifiedDate":"2023-10-24"},{"lineNumber":112,"author":{"gitId":"onx001"},"content":" BoardScoreTuple bestTuple \u003d mostPoints(tuple, color, 0, score, true, maxDepth);","lastModifiedDate":"2023-10-26"},{"lineNumber":113,"author":{"gitId":"onx001"},"content":" Move bestMove \u003d bestTuple.getMove();","lastModifiedDate":"2023-10-24"},{"lineNumber":114,"author":{"gitId":"onx001"},"content":" return bestMove;","lastModifiedDate":"2023-10-24"},{"lineNumber":115,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"onx001":118}},{"path":"src/main/java/chessmaster/game/Move.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"// @author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"public class Move {","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":" private Coordinate from;","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":" private Coordinate to;","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":" private ChessPiece piece;","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" public Move(Coordinate from, Coordinate to, ChessPiece piece) {","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" this.from \u003d from;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" this.to \u003d to;","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" this.piece \u003d piece;","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" assert from !\u003d null \u0026\u0026 to !\u003d null : \"Coordinates in Move should not be null!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assert piece !\u003d null \u0026\u0026 !piece.isEmptyPiece() : \"Chess piece in Move should not be null or empty!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" public Coordinate getFrom() {","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" return from;","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" public Coordinate getTo() {","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" return to;","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" public ChessPiece getPiece() {","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" return piece;","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"antrikshdhand"},"content":" public void setFrom(Coordinate from) {","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"antrikshdhand"},"content":" this.from \u003d from;","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"antrikshdhand"},"content":" public void setTo(Coordinate to) {","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"antrikshdhand"},"content":" this.to \u003d to;","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"antrikshdhand"},"content":" public void setPiece(ChessPiece piece) {","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"antrikshdhand"},"content":" this.piece \u003d piece;","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" * Checks if the move is valid by checking if the to coordinate is in the","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" * possibleCoordinates 2d array","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" * @param board","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" * @return","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" public boolean isValid(ChessBoard board) {","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" Coordinate[][] coordinates \u003d piece.getAvailableCoordinates(board);","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" for (Coordinate[] direction : coordinates) {","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" for (Coordinate coor : direction) {","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" if (coor.equals(to)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"onx001"},"content":" public boolean isLeftCastling() {","lastModifiedDate":"2023-10-19"},{"lineNumber":67,"author":{"gitId":"onx001"},"content":" if (!(piece instanceof King)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":" int[] offset \u003d to.calculateOffsetFrom(from);","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":" return Arrays.equals(offset, ChessPiece.CASTLE_LEFT);","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" public boolean isRightCastling() {","lastModifiedDate":"2023-10-19"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" if (!(piece instanceof King)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" int[] offset \u003d to.calculateOffsetFrom(from);","lastModifiedDate":"2023-10-22"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" return Arrays.equals(offset, ChessPiece.CASTLE_RIGHT);","lastModifiedDate":"2023-10-22"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-24"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" return \"Move [from\u003d\" + from + \", to\u003d\" + to + \", piece\u003d\" + piece + \"]\";","lastModifiedDate":"2023-10-24"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" // @author TongZhengHong","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":" public boolean equals(Object obj) {","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" if (obj !\u003d null \u0026\u0026 obj instanceof Move) {","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" final Move other \u003d (Move) obj;","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" return from.equals(other.getFrom()) \u0026\u0026 to.equals(other.getTo()) \u0026\u0026 piece.equals(other.getPiece());","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"ken-ruster":26,"antrikshdhand":12,"onx001":52,"TongZhengHong":8}},{"path":"src/main/java/chessmaster/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.AbortCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.Command;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.HelpCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.MoveCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.RulesCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.ShowCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.ShowMovesCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.LegendCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.MoveOpponentPieceException;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.NullPieceException;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseColorException;","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Bishop;","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.EmptyPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Knight;","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-10-20"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Rook;","lastModifiedDate":"2023-10-20"},{"lineNumber":27,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":"public class Parser {","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" * Parses a string telling which chess piece the user wants to promote his piece","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" * to, and promotes the relevant piece","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":" * @param promoteFrom Chess piece to be promoted.","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" * @param promoteTo String representing the type of piece to be promoted to.","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":" * @return Promoted chess piece.","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":" public static ChessPiece parsePromote(ChessPiece promoteFrom, String promoteTo) {","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" Color color \u003d promoteFrom.getColor();","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":" Coordinate position \u003d promoteFrom.getPosition();","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" switch (promoteTo) {","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" case Bishop.BISHOP_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":" return new Bishop(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" case Queen.QUEEN_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":" return new Queen(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":" case Knight.KNIGHT_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":" return new Knight(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" case Rook.ROOK_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":51,"author":{"gitId":"ken-ruster"},"content":" return new Rook(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"ken-ruster"},"content":" default:","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"ken-ruster"},"content":" return promoteFrom;","lastModifiedDate":"2023-10-19"},{"lineNumber":54,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" * Parses a chess move from user input and creates a Move object. Used to read","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" * user inputs during the chess game.","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" * @param in The user input string with 2 algebraic coordinate notations","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" * (e.g., \"e2 e4\").","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" * @param board The ChessBoard where the move is taking place.","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" * @return Move object containing information about the move to be made.","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" * @throws ParseCoordinateException If the string entered is not in the","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" * algebraic coordinate notation.","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" * @throws NullPieceException","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" * @throws MoveOpponentPieceException","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" public static Move parseMove(String in, ChessBoard board) throws ParseCoordinateException,","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" NullPieceException, MoveOpponentPieceException {","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" String[] parseArray \u003d in.split(\"\\\\s+\", 2);","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" if (parseArray.length \u003c 2) {","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" Coordinate from \u003d Coordinate.parseAlgebraicCoor(parseArray[0]);","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" Coordinate to \u003d Coordinate.parseAlgebraicCoor(parseArray[1]);","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece relevantPiece \u003d board.getPieceAtCoor(from);","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" if (relevantPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" throw new NullPieceException();","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" } else if (board.isPieceOpponent(relevantPiece)) {","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" throw new MoveOpponentPieceException();","lastModifiedDate":"2023-10-22"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":" return new Move(from, to, relevantPiece);","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":" * Parses an input string and creates a ChessPiece object at the specified row","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" * and column. Used for loading ChessPiece(s) from storage file or loading","lastModifiedDate":"2023-10-22"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" * starting ChessBoard. Returns null for recognised input string to signify that","lastModifiedDate":"2023-10-22"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" * piece is empty (for ChessTile)","lastModifiedDate":"2023-10-22"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" * @param pieceString The string representation of the chess piece, e.g., \"bB\"","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" * for black bishop.","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" * @param row The row where the piece is located.","lastModifiedDate":"2023-10-16"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" * @param col The column where the piece is located.","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" * @return A ChessPiece object representing the parsed chess piece, or null if","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" * the pieceString is not recognized.","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" public static ChessPiece parseChessPiece(String pieceString, int row, int col) {","lastModifiedDate":"2023-10-15"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" switch (pieceString) {","lastModifiedDate":"2023-10-15"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" case Bishop.BISHOP_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" return new Bishop(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" case Bishop.BISHOP_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" return new Bishop(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" case King.KING_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" return new King(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" case King.KING_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" return new King(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" case Queen.QUEEN_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" return new Queen(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":" case Queen.QUEEN_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" return new Queen(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":" case Knight.KNIGHT_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":" return new Knight(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":" case Knight.KNIGHT_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":" return new Knight(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":" case Pawn.PAWN_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":" return new Pawn(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":" case Pawn.PAWN_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":" return new Pawn(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":" case Rook.ROOK_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":" return new Rook(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":130,"author":{"gitId":"TongZhengHong"},"content":" case Rook.ROOK_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"TongZhengHong"},"content":" return new Rook(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":132,"author":{"gitId":"TongZhengHong"},"content":" default:","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"TongZhengHong"},"content":" return new EmptyPiece(row, col);","lastModifiedDate":"2023-10-22"},{"lineNumber":134,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"TongZhengHong"},"content":" //@@author","lastModifiedDate":"2023-10-27"},{"lineNumber":137,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":138,"author":{"gitId":"TongZhengHong"},"content":" public static Command parseCommand(String in) {","lastModifiedDate":"2023-10-22"},{"lineNumber":139,"author":{"gitId":"TongZhengHong"},"content":" String[] splitInputStrings \u003d in.split(\"\\\\s+\", 2);","lastModifiedDate":"2023-10-22"},{"lineNumber":140,"author":{"gitId":"TongZhengHong"},"content":" String commandString \u003d splitInputStrings[0];","lastModifiedDate":"2023-10-22"},{"lineNumber":141,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"TongZhengHong"},"content":" switch (commandString) {","lastModifiedDate":"2023-10-22"},{"lineNumber":143,"author":{"gitId":"TriciaBK"},"content":" case ShowMovesCommand.SHOW_MOVE_COMMAND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"TriciaBK"},"content":" return new ShowMovesCommand(splitInputStrings[1]);","lastModifiedDate":"2023-11-02"},{"lineNumber":145,"author":{"gitId":"TriciaBK"},"content":" case ShowCommand.SHOW_COMAMND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"TriciaBK"},"content":" return new ShowCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"TriciaBK"},"content":" case RulesCommand.RULES_COMAMND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"TriciaBK"},"content":" return new RulesCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"TongZhengHong"},"content":" case HelpCommand.HELP_COMAMND_STRING:","lastModifiedDate":"2023-10-22"},{"lineNumber":150,"author":{"gitId":"onx001"},"content":" return new HelpCommand();","lastModifiedDate":"2023-10-19"},{"lineNumber":151,"author":{"gitId":"TriciaBK"},"content":" case LegendCommand.LEGEND_COMMAND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":" return new LegendCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":153,"author":{"gitId":"TongZhengHong"},"content":" case AbortCommand.ABORT_COMAMND_STRING:","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"onx001"},"content":" return new AbortCommand();","lastModifiedDate":"2023-10-19"},{"lineNumber":155,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":156,"author":{"gitId":"onx001"},"content":" default:","lastModifiedDate":"2023-10-19"},{"lineNumber":157,"author":{"gitId":"TongZhengHong"},"content":" return new MoveCommand(in);","lastModifiedDate":"2023-10-22"},{"lineNumber":158,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":159,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":160,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":161,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":162,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":163,"author":{"gitId":"TongZhengHong"},"content":" * Parses a player\u0027s color from a provided string and returns the corresponding Color enumeration.","lastModifiedDate":"2023-11-03"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":" * This method takes an input color string and converts it into the appropriate Color enumeration value, ","lastModifiedDate":"2023-11-03"},{"lineNumber":166,"author":{"gitId":"TongZhengHong"},"content":" * which can be either \u0027WHITE\u0027 or \u0027BLACK\u0027. ","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"TongZhengHong"},"content":" * It ensures that the provided color is valid and not \u0027EMPTY\u0027 since a player color can only be black or white.","lastModifiedDate":"2023-11-03"},{"lineNumber":169,"author":{"gitId":"TongZhengHong"},"content":" * If the input does not match any valid color, a ParseColorException is thrown.","lastModifiedDate":"2023-11-03"},{"lineNumber":170,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":171,"author":{"gitId":"TongZhengHong"},"content":" * @param inputColorString A string representing the player\u0027s color (\u0027WHITE\u0027 or \u0027BLACK\u0027).","lastModifiedDate":"2023-11-03"},{"lineNumber":172,"author":{"gitId":"TongZhengHong"},"content":" * @return The Color enumeration corresponding to the parsed color.","lastModifiedDate":"2023-11-03"},{"lineNumber":173,"author":{"gitId":"TongZhengHong"},"content":" * @throws ParseColorException If the input color is not valid or if it is \u0027EMPTY\u0027.","lastModifiedDate":"2023-11-03"},{"lineNumber":174,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":175,"author":{"gitId":"TongZhengHong"},"content":" public static Color parsePlayerColor(String inputColorString) throws ParseColorException {","lastModifiedDate":"2023-10-23"},{"lineNumber":176,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" Color color \u003d Color.valueOf(inputColorString);","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" if (color.isEmpty()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseColorException();","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":" return color;","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":183,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseColorException();","lastModifiedDate":"2023-10-22"},{"lineNumber":184,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":185,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":186,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"onx001"},"content":" public static int parseDifficulty(String inputDifficultyString) throws NumberFormatException {","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"onx001"},"content":" return Integer.parseInt(inputDifficultyString);","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"onx001"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"onx001"},"content":" throw new NumberFormatException();","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":32,"antrikshdhand":1,"TriciaBK":17,"onx001":16,"TongZhengHong":129}},{"path":"src/main/java/chessmaster/pieces/Bishop.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"public class Bishop extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String BISHOP_WHITE \u003d \"b\"; // ♗","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final String BISHOP_BLACK \u003d \"B\"; // ♝","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" UP_LEFT, UP_RIGHT, DOWN_LEFT, DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 30;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {{-2,-1,-1,-1,-1,-1,-1,-2},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {-2,-1,-1,-1,-1,-1,-1,-2}};","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public Bishop(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Bishop piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" * Returns available coordinates in multiple diagonal directions from the current position. ","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" * @param board the current board","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":" * @return available coordinates in a 2D array. The first index is of the direction and the second","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" * is of the coordinates in that direction.","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" int multiplier \u003d 1;","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" boolean isBlocked \u003d false;","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" ArrayList\u003cCoordinate\u003e possibleCoordInDirection \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" while (!isBlocked \u0026\u0026 multiplier \u003c ChessBoard.SIZE \u0026\u0026 position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" Coordinate possibleCoord \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(possibleCoord);","lastModifiedDate":"2023-10-20"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" isBlocked \u003d !destPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" possibleCoordInDirection.add(possibleCoord);","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" } ","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" multiplier++;","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" offsetX \u003d DIRECTIONS[dir][0] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" offsetY \u003d DIRECTIONS[dir][1] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" // Convert arraylist to array","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d possibleCoordInDirection.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? BISHOP_BLACK : BISHOP_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":2,"onx001":21,"TongZhengHong":55}},{"path":"src/main/java/chessmaster/pieces/ChessPiece.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"public abstract class ChessPiece {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public static final int[] CASTLE_LEFT \u003d {-2, 0};","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[] CASTLE_RIGHT \u003d {2, 0};","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_UP_LEFT \u003d {1, -2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_UP_RIGHT \u003d {-1, -2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_DOWN_LEFT \u003d {1, 2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_DOWN_RIGHT \u003d {-1, 2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] LEFT_UP_LEFT \u003d {2, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] LEFT_DOWN_LEFT \u003d {2, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] RIGHT_UP_RIGHT \u003d {-2, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] RIGHT_DOWN_RIGHT \u003d {-2, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_UP \u003d {0, -2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" protected static final int[] DOWN_DOWN \u003d {0, 2};","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP \u003d {0, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN \u003d {0, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] LEFT \u003d {1, 0};","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] RIGHT \u003d {-1, 0};","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_LEFT \u003d {1, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_RIGHT \u003d {-1, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_LEFT \u003d {1, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_RIGHT \u003d {-1, 1};","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" protected static final String[] NO_AVAILABLE_MOVES_STRING \u003d {\"There aren\u0027t any moves available for this piece!\"};","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" protected Color color;","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" protected Coordinate position;","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":" protected boolean hasMoved \u003d false;","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" protected boolean isCaptured \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"onx001"},"content":" protected int points \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" //initialise empty boardweights of 0 for parent class to be used for the AI","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":" private int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":" {{0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0}};","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" public ChessPiece(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" this.position \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" this.color \u003d color;","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" * Returns available coordinates in multiple directions from the current position. ","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" * The directions are dependent on the chess piece type. Each inner array stores the coordinates that is","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" * in the direction the current chess piece can move to.","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" * @return A 2D array of Coordinate arrays representing available coordinates in different directions.","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"ken-ruster"},"content":" public abstract Coordinate[][] getAvailableCoordinates(ChessBoard board);","lastModifiedDate":"2023-10-20"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":" * Get a flattened array of valid coordinates for the chess piece\u0027s moves based on its available coordinates ","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":" * and the current state of the ChessBoard.","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":" * @param board The ChessBoard representing the current game state.","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" * @return A 1D array of valid coordinates for the piece\u0027s legal moves.","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" public Coordinate[] getFlattenedCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":" Coordinate[][] availableCoordinates \u003d getAvailableCoordinates(board);","lastModifiedDate":"2023-10-19"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":" ArrayList\u003cCoordinate\u003e flattenedCoordinates \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-19"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" for (Coordinate[] direction : availableCoordinates) {","lastModifiedDate":"2023-10-19"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":" for (Coordinate possibleCoord : direction) {","lastModifiedDate":"2023-10-19"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":" if (this.isMoveValid(possibleCoord, board)) {","lastModifiedDate":"2023-10-19"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" flattenedCoordinates.add(possibleCoord);","lastModifiedDate":"2023-10-19"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" return flattenedCoordinates.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-19"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" public boolean isWhiteKing() {","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" return this instanceof King \u0026\u0026 this.isWhite();","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" public boolean isBlackKing() {","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" return this instanceof King \u0026\u0026 this.isBlack();","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" * Returns the validity of the move to the destination coordinate.","lastModifiedDate":"2023-10-16"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":" * @param destination","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":" * @param board","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":" * @return","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":" public boolean isMoveValid(Coordinate destination, ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":" Coordinate[][] availableCoordinates \u003d getAvailableCoordinates(board);","lastModifiedDate":"2023-10-17"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":" for (Coordinate[] direction : availableCoordinates) {","lastModifiedDate":"2023-10-16"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":" for (Coordinate possibleCoord : direction) {","lastModifiedDate":"2023-10-16"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":" if (possibleCoord.equals(destination)) {","lastModifiedDate":"2023-10-16"},{"lineNumber":111,"author":{"gitId":"onx001"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(destination);","lastModifiedDate":"2023-10-20"},{"lineNumber":112,"author":{"gitId":"onx001"},"content":" if (destPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":113,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-10-16"},{"lineNumber":114,"author":{"gitId":"onx001"},"content":" } else if (destPiece.isOpponent(this)) {","lastModifiedDate":"2023-10-24"},{"lineNumber":115,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-10-16"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"ken-ruster"},"content":" public String[] getAvailableCoordinatesString(ChessBoard board) {","lastModifiedDate":"2023-10-27"},{"lineNumber":125,"author":{"gitId":"ken-ruster"},"content":" StringBuilder out \u003d new StringBuilder();","lastModifiedDate":"2023-10-27"},{"lineNumber":126,"author":{"gitId":"ken-ruster"},"content":" Coordinate[][] availableCoordinates \u003d getAvailableCoordinates(board);","lastModifiedDate":"2023-10-17"},{"lineNumber":127,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":128,"author":{"gitId":"ken-ruster"},"content":" if (Arrays.stream(availableCoordinates).allMatch(","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"ken-ruster"},"content":" x -\u003e x.length \u003d\u003d 0","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"ken-ruster"},"content":" )) {","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"ken-ruster"},"content":" return NO_AVAILABLE_MOVES_STRING;","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"ken-ruster"},"content":" for (Coordinate[] direction : availableCoordinates) {","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"ken-ruster"},"content":" for (Coordinate possibleCoord : direction) {","lastModifiedDate":"2023-10-16"},{"lineNumber":136,"author":{"gitId":"ken-ruster"},"content":" out.append(possibleCoord + \" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":137,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":138,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":139,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":140,"author":{"gitId":"ken-ruster"},"content":" return new String[] {","lastModifiedDate":"2023-10-27"},{"lineNumber":141,"author":{"gitId":"ken-ruster"},"content":" String.format(\"Available coordinates for %s at %s: \", getPieceName(), this.position),","lastModifiedDate":"2023-10-27"},{"lineNumber":142,"author":{"gitId":"ken-ruster"},"content":" out.toString()","lastModifiedDate":"2023-10-27"},{"lineNumber":143,"author":{"gitId":"ken-ruster"},"content":" };","lastModifiedDate":"2023-10-27"},{"lineNumber":144,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":145,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":146,"author":{"gitId":"ken-ruster"},"content":" //@@author","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":148,"author":{"gitId":"ken-ruster"},"content":" public Coordinate getPosition() {","lastModifiedDate":"2023-10-17"},{"lineNumber":149,"author":{"gitId":"ken-ruster"},"content":" return this.position;","lastModifiedDate":"2023-10-17"},{"lineNumber":150,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":151,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":" public void updatePosition(Coordinate newCoordinate) {","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"TriciaBK"},"content":" this.position \u003d newCoordinate;","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":155,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"TongZhengHong"},"content":" public void setHasMoved() {","lastModifiedDate":"2023-10-22"},{"lineNumber":157,"author":{"gitId":"TongZhengHong"},"content":" this.hasMoved \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":158,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":159,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":160,"author":{"gitId":"onx001"},"content":" public boolean getHasMoved() {","lastModifiedDate":"2023-10-19"},{"lineNumber":161,"author":{"gitId":"onx001"},"content":" return this.hasMoved;","lastModifiedDate":"2023-10-19"},{"lineNumber":162,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":163,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-22"},{"lineNumber":166,"author":{"gitId":"TongZhengHong"},"content":" return \"ChessPiece [color\u003d\" + color + \", position\u003d\" + position + \"]\";","lastModifiedDate":"2023-10-22"},{"lineNumber":167,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":168,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":169,"author":{"gitId":"TongZhengHong"},"content":" public Color getColor() {","lastModifiedDate":"2023-10-22"},{"lineNumber":170,"author":{"gitId":"TongZhengHong"},"content":" return color;","lastModifiedDate":"2023-10-22"},{"lineNumber":171,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":172,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":173,"author":{"gitId":"TongZhengHong"},"content":" public boolean getIsCaptured() {","lastModifiedDate":"2023-10-22"},{"lineNumber":174,"author":{"gitId":"TongZhengHong"},"content":" return this.isCaptured;","lastModifiedDate":"2023-10-22"},{"lineNumber":175,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":176,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" public void setIsCaptured() {","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" this.isCaptured \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":179,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":180,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":181,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":183,"author":{"gitId":"onx001"},"content":" * Returns the points of the ChessPiece object. ","lastModifiedDate":"2023-10-26"},{"lineNumber":184,"author":{"gitId":"onx001"},"content":" * The points are calculated based on the ChessPiece\u0027s position","lastModifiedDate":"2023-10-26"},{"lineNumber":185,"author":{"gitId":"onx001"},"content":" * @param isUpright Whether the chess board is aligned to the player it is processed for.","lastModifiedDate":"2023-10-26"},{"lineNumber":186,"author":{"gitId":"onx001"},"content":" * @return The points of the ChessPiece object.","lastModifiedDate":"2023-10-26"},{"lineNumber":187,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":188,"author":{"gitId":"onx001"},"content":" public int getPoints(boolean isUpright) {","lastModifiedDate":"2023-10-26"},{"lineNumber":189,"author":{"gitId":"onx001"},"content":" int boardPoints;","lastModifiedDate":"2023-10-26"},{"lineNumber":190,"author":{"gitId":"onx001"},"content":" if (isUpright) {","lastModifiedDate":"2023-10-26"},{"lineNumber":191,"author":{"gitId":"onx001"},"content":" //finds board weight points of a friendly piece","lastModifiedDate":"2023-10-26"},{"lineNumber":192,"author":{"gitId":"onx001"},"content":" boardPoints \u003d boardWeight[position.getX()][position.getY()];","lastModifiedDate":"2023-10-26"},{"lineNumber":193,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":194,"author":{"gitId":"onx001"},"content":" //finds board weight points of an opponent piece","lastModifiedDate":"2023-10-26"},{"lineNumber":195,"author":{"gitId":"onx001"},"content":" boardPoints \u003d boardWeight[7 - position.getX()][position.getY()];","lastModifiedDate":"2023-10-26"},{"lineNumber":196,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":197,"author":{"gitId":"onx001"},"content":" //adds the board weight points to the piece\u0027s points","lastModifiedDate":"2023-10-26"},{"lineNumber":198,"author":{"gitId":"onx001"},"content":" int points \u003d this.points + boardPoints;","lastModifiedDate":"2023-10-26"},{"lineNumber":199,"author":{"gitId":"onx001"},"content":" return points;","lastModifiedDate":"2023-10-26"},{"lineNumber":200,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":201,"author":{"gitId":"onx001"},"content":" //@@author","lastModifiedDate":"2023-10-31"},{"lineNumber":202,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":203,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":204,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the ChessPiece object has the same color as a given color.","lastModifiedDate":"2023-10-22"},{"lineNumber":205,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":206,"author":{"gitId":"TongZhengHong"},"content":" * @param color The color to compare with the ChessPiece\u0027s color.","lastModifiedDate":"2023-10-22"},{"lineNumber":207,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the ChessPiece has the same color as the provided color; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":208,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":209,"author":{"gitId":"TongZhengHong"},"content":" public boolean isSameColorAs(Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":210,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":211,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":212,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":213,"author":{"gitId":"TongZhengHong"},"content":" return this.color \u003d\u003d color;","lastModifiedDate":"2023-10-22"},{"lineNumber":214,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":215,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":216,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":217,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the ChessPiece object is WHTIE.","lastModifiedDate":"2023-10-22"},{"lineNumber":218,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":219,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the ChessPiece is white; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":220,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":221,"author":{"gitId":"TongZhengHong"},"content":" public boolean isWhite() {","lastModifiedDate":"2023-10-22"},{"lineNumber":222,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":223,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":224,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":225,"author":{"gitId":"TongZhengHong"},"content":" return this.color \u003d\u003d Color.WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":226,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":227,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":228,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":229,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the ChessPiece object is BLACK.","lastModifiedDate":"2023-10-22"},{"lineNumber":230,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":231,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the ChessPiece is white; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":232,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":233,"author":{"gitId":"TongZhengHong"},"content":" public boolean isBlack() {","lastModifiedDate":"2023-10-22"},{"lineNumber":234,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":235,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":236,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":237,"author":{"gitId":"TongZhengHong"},"content":" return this.color \u003d\u003d Color.BLACK;","lastModifiedDate":"2023-10-22"},{"lineNumber":238,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":239,"author":{"gitId":"antrikshdhand"},"content":" ","lastModifiedDate":"2023-10-19"},{"lineNumber":240,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":241,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the provided ChessPiece object is friendly (has the same color) as the current ChessPiece.","lastModifiedDate":"2023-10-22"},{"lineNumber":242,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":243,"author":{"gitId":"TongZhengHong"},"content":" * @param chessPiece The ChessPiece to compare with.","lastModifiedDate":"2023-10-22"},{"lineNumber":244,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the provided ChessPiece is friendly; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":" public boolean isFriendly(ChessPiece chessPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece.color \u003d\u003d this.color;","lastModifiedDate":"2023-10-22"},{"lineNumber":251,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":252,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":253,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":254,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the provided ChessPiece is an opponent (has a different color) compared to the current ChessPiece.","lastModifiedDate":"2023-10-22"},{"lineNumber":255,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":256,"author":{"gitId":"TongZhengHong"},"content":" * @param chessPiece The ChessPiece to compare with.","lastModifiedDate":"2023-10-22"},{"lineNumber":257,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the provided ChessPiece is an opponent; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":258,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":259,"author":{"gitId":"TongZhengHong"},"content":" public boolean isOpponent(ChessPiece chessPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":260,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":261,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":262,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":263,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece.color !\u003d this.color;","lastModifiedDate":"2023-10-22"},{"lineNumber":264,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":265,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":266,"author":{"gitId":"TongZhengHong"},"content":" public boolean isEmptyPiece() {","lastModifiedDate":"2023-10-22"},{"lineNumber":267,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof EmptyPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":268,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":269,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":270,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPawn() {","lastModifiedDate":"2023-10-31"},{"lineNumber":271,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof Pawn;","lastModifiedDate":"2023-10-31"},{"lineNumber":272,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":273,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":274,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPromotionPiece() {","lastModifiedDate":"2023-10-22"},{"lineNumber":275,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof Queen || this instanceof Rook ","lastModifiedDate":"2023-10-22"},{"lineNumber":276,"author":{"gitId":"TongZhengHong"},"content":" || this instanceof Bishop || this instanceof Knight;","lastModifiedDate":"2023-10-22"},{"lineNumber":277,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":278,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":279,"author":{"gitId":"TongZhengHong"},"content":" public String getPieceName() {","lastModifiedDate":"2023-10-27"},{"lineNumber":280,"author":{"gitId":"TongZhengHong"},"content":" return this.getClass().getSimpleName();","lastModifiedDate":"2023-10-27"},{"lineNumber":281,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":282,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":283,"author":{"gitId":"onx001"},"content":" protected void setPoints(int points) {","lastModifiedDate":"2023-10-23"},{"lineNumber":284,"author":{"gitId":"onx001"},"content":" this.points \u003d points;","lastModifiedDate":"2023-10-23"},{"lineNumber":285,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":286,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":287,"author":{"gitId":"onx001"},"content":" protected void setBoardWeight(int[][] boardWeight) {","lastModifiedDate":"2023-10-26"},{"lineNumber":288,"author":{"gitId":"onx001"},"content":" this.boardWeight \u003d boardWeight;","lastModifiedDate":"2023-10-26"},{"lineNumber":289,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":290,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":35,"antrikshdhand":2,"TriciaBK":4,"onx001":117,"TongZhengHong":132}},{"path":"src/main/java/chessmaster/pieces/EmptyPiece.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-20"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"public class EmptyPiece extends ChessPiece {","lastModifiedDate":"2023-10-20"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String EMPTY_PIECE \u003d \".\";","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public EmptyPiece(int row, int col) {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, Color.EMPTY);","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" @Override","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" return new Coordinate[0][];","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" // An empty piece will never be moved","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" public boolean getHasMoved() {","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" //returns the string representation of the empty piece for cloning","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" return EMPTY_PIECE;","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"ken-ruster":15,"onx001":6,"TongZhengHong":10}},{"path":"src/main/java/chessmaster/pieces/King.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class King extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public static final String KING_WHITE \u003d \"k\"; // ♔","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String KING_BLACK \u003d \"K\"; // ♚","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" public static final int POINTS \u003d 1000;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" public static final int[][] BOARDWEIGHT \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" {{-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" {-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":" {-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" {-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" {-2,-3,-3,-4,-4,-3,-3,-2},","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" {-1,-2,-2,-2,-2,-2,-2,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" {2,2,0,0,0,0,2,2},","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {2,3,1,0,0,1,3,2}};","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" UP, DOWN, LEFT, RIGHT, UP_LEFT, UP_RIGHT, DOWN_LEFT, DOWN_RIGHT, CASTLE_LEFT, CASTLE_RIGHT","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" protected static int points \u003d 1000;","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public King(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(BOARDWEIGHT);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"King piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" if (!position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" continue; // Possible coordinate out of board","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoor \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(newCoor);","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" if (DIRECTIONS[dir] \u003d\u003d CASTLE_LEFT) {","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos1 \u003d position.addOffsetToCoordinate(-1, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":52,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos2 \u003d position.addOffsetToCoordinate(-2, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":53,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos3 \u003d position.addOffsetToCoordinate(-3, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" Coordinate rookPos \u003d position.addOffsetToCoordinate(-4, 0);","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" boolean hasRookMoved \u003d board.getPieceAtCoor(rookPos).hasMoved;","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" boolean isSidesEmpty \u003d board.getPieceAtCoor(pos1).isEmptyPiece() ","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 board.getPieceAtCoor(pos2).isEmptyPiece() ","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 board.getPieceAtCoor(pos3).isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" if (isSidesEmpty \u0026\u0026 !hasRookMoved \u0026\u0026 !hasMoved) {","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" } else if (DIRECTIONS[dir] \u003d\u003d CASTLE_RIGHT) {","lastModifiedDate":"2023-10-22"},{"lineNumber":66,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos1 \u003d position.addOffsetToCoordinate(+1, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":67,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos2 \u003d position.addOffsetToCoordinate(+2, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" Coordinate rookPos \u003d position.addOffsetToCoordinate(+3, 0);","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" boolean hasRookMoved \u003d board.getPieceAtCoor(rookPos).hasMoved;","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" boolean isSidesEmpty \u003d board.getPieceAtCoor(pos1).isEmptyPiece() ","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 board.getPieceAtCoor(pos2).isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" if (isSidesEmpty \u0026\u0026 !hasRookMoved \u0026\u0026 !hasMoved) {","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" } else { // Normal or capture move","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[] { position.addOffsetToCoordinate(offsetX, offsetY) };","lastModifiedDate":"2023-10-22"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? KING_BLACK : KING_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":15,"onx001":17,"TongZhengHong":61}},{"path":"src/main/java/chessmaster/pieces/Knight.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class Knight extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public static final String KNIGHT_WHITE \u003d \"n\"; // ♘","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String KNIGHT_BLACK \u003d \"N\"; // ♞","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" UP_UP_LEFT, UP_UP_RIGHT, DOWN_DOWN_LEFT, DOWN_DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" LEFT_UP_LEFT, LEFT_DOWN_LEFT, RIGHT_UP_RIGHT, RIGHT_DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 30;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" {{-5,-4,-3,-3,-3,-3,-4,-5},","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {-4,-2,0,0,0,0,-2,-4},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {-3,0,1,2,2,1,0,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-3,1,2,3,3,2,1,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-3,0,2,3,3,2,0,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-3,1,1,2,2,1,1,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-4,-2,0,1,1,0,-2,-4},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-5,-4,-3,-3,-3,-3,-4,-5}};","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" public Knight(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Knight piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? KNIGHT_BLACK : KNIGHT_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" if (!position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" continue; // Possible coordinate out of board","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoor \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(newCoor);","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":4,"onx001":17,"TongZhengHong":41}},{"path":"src/main/java/chessmaster/pieces/Pawn.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class Pawn extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public static final String PAWN_WHITE \u003d \"p\"; // ♙","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String PAWN_BLACK \u003d \"P\"; // ♟","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS_UP \u003d {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" UP_LEFT, UP_RIGHT, UP, UP_UP,","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS_DOWN \u003d {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" DOWN_LEFT, DOWN_RIGHT, DOWN, DOWN_DOWN,","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" };","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 10;","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {{0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {5,5,5,5,5,5,5,5},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {1,1,2,3,3,2,1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {1,1,1,4,4,1,1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {0,0,0,3,3,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {1,-1,-1,0,0,-1,-1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {1,1,1,-2,-2,1,1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0}};","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" protected boolean enPassed \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" public Pawn(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Pawn piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS_UP.length][0];","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int[][] directions \u003d board.isPieceFriendly(this) ? DIRECTIONS_UP : DIRECTIONS_DOWN;","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS_UP.length; dir++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" int offsetX \u003d directions[dir][0];","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" int offsetY \u003d directions[dir][1];","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" if (!position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" continue; // Possible coordinate out of board","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoor \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(newCoor);","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (directions[dir] \u003d\u003d UP_LEFT || directions[dir] \u003d\u003d UP_RIGHT || ","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" directions[dir] \u003d\u003d DOWN_LEFT || directions[dir] \u003d\u003d DOWN_RIGHT) {","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" // Diagonal move: Destination tile has opponent piece","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" if (!destPiece.isEmptyPiece() \u0026\u0026 isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" } else if (directions[dir] \u003d\u003d UP || directions[dir] \u003d\u003d DOWN) {","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" // Normal move: when destination tile is empty","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" } else if (directions[dir] \u003d\u003d UP_UP || directions[dir] \u003d\u003d DOWN_DOWN) {","lastModifiedDate":"2023-10-22"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" // Double move: first move AND when destination empty AND no blocking piece","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" Coordinate blockPos \u003d board.isPieceFriendly(this) ","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" ? position.addOffsetToCoordinate(UP[0], UP[1])","lastModifiedDate":"2023-10-22"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" : position.addOffsetToCoordinate(DOWN[0], DOWN[1]); ","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"ken-ruster"},"content":" ChessPiece blockPiece \u003d board.getPieceAtCoor(blockPos);","lastModifiedDate":"2023-10-20"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" if (!hasMoved \u0026\u0026 blockPiece.isEmptyPiece() \u0026\u0026 destPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":76,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":" return result;","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? PAWN_BLACK : PAWN_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":6,"onx001":26,"TongZhengHong":54}},{"path":"src/main/java/chessmaster/pieces/Queen.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"public class Queen extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String QUEEN_WHITE \u003d \"q\"; // ♕","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final String QUEEN_BLACK \u003d \"Q\"; // ♛","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" UP, DOWN, LEFT, RIGHT, UP_LEFT, UP_RIGHT, DOWN_LEFT, DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 90;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {{-2,-1,-1,-1,-1,-1,-1,-2},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {-2,-1,-1,-1,-1,-1,-1,-2}};","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public Queen(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Queen piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" int multiplier \u003d 1;","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" boolean isBlocked \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" ArrayList\u003cCoordinate\u003e possibleCoordInDirection \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" while (!isBlocked \u0026\u0026 multiplier \u003c ChessBoard.SIZE \u0026\u0026 position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" Coordinate possibleCoord \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(possibleCoord);","lastModifiedDate":"2023-10-20"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" isBlocked \u003d !destPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" possibleCoordInDirection.add(possibleCoord);","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" } ","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" multiplier++;","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" offsetX \u003d DIRECTIONS[dir][0] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" offsetY \u003d DIRECTIONS[dir][1] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" // Convert arraylist to array","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d possibleCoordInDirection.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? QUEEN_BLACK : QUEEN_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":2,"onx001":14,"TongZhengHong":57}},{"path":"src/main/java/chessmaster/pieces/Rook.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"public class Rook extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String ROOK_WHITE \u003d \"r\"; // ♖","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final String ROOK_BLACK \u003d \"R\"; // ♜","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" UP, DOWN, LEFT, RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 50;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {{0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {1,2,2,2,2,2,2,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {0,0,0,1,1,0,0,0}};","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public Rook(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Rook piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" int multiplier \u003d 1;","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" boolean isBlocked \u003d false;","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" ArrayList\u003cCoordinate\u003e possibleCoordInDirection \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" while (!isBlocked \u0026\u0026 multiplier \u003c ChessBoard.SIZE \u0026\u0026 position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" Coordinate possibleCoord \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(possibleCoord);","lastModifiedDate":"2023-10-20"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" isBlocked \u003d !destPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" possibleCoordInDirection.add(possibleCoord);","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" } ","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" multiplier++;","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" offsetX \u003d DIRECTIONS[dir][0] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" offsetY \u003d DIRECTIONS[dir][1] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" // Convert arraylist to array","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d possibleCoordInDirection.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? ROOK_BLACK : ROOK_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":2,"onx001":15,"TongZhengHong":56}},{"path":"src/main/java/chessmaster/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.storage;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.exceptions.LoadBoardException;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.exceptions.SaveBoardException;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"import java.io.File;","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":"public class Storage {","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" private String filePathString;","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" private File storageFile;","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" private int blackPieceNum;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" private int whitePieceNum;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" private boolean blackKingPresent;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" private boolean whiteKingPresent;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":" private Scanner fileScanner;","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":" public Storage(String filePath) {","lastModifiedDate":"2023-10-20"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" filePathString \u003d filePath;","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" storageFile \u003d new File(filePath);","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" assert !filePathString.isEmpty() \u0026\u0026 filePath !\u003d null : \"File path cannot be empty or null\";","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * Creates a ChessMaster program file to store game state, including necessary","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" * parent directories.","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" * @throws ChessMasterException If there is an error creating the file or parent","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" * directories.","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" private void createChessMasterFile() throws ChessMasterException {","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" // Create the necessary parent directories for new file","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" if (!storageFile.exists()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" storageFile.getParentFile().mkdirs();","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" // Create file if it does not exist","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" storageFile.createNewFile();","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" throw new ChessMasterException(\"Fatal: Error creating file: \" + filePathString);","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"TriciaBK"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"TriciaBK"},"content":" * Saves the state of the ChessBoard to a file. Writes the player\u0027s color to the","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"TriciaBK"},"content":" * first line","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"TriciaBK"},"content":" * and subsequently chess pieces in a 8 x 8 format.","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"TriciaBK"},"content":" *","lastModifiedDate":"2023-10-20"},{"lineNumber":64,"author":{"gitId":"TriciaBK"},"content":" * @param board The ChessBoard to save.","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"TriciaBK"},"content":" * @throws ChessMasterException If there is an error saving the board to a file.","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"TriciaBK"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"TriciaBK"},"content":" public void saveBoard(ChessBoard board, Color currentColor) throws ChessMasterException {","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"TriciaBK"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":70,"author":{"gitId":"TriciaBK"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"TriciaBK"},"content":" FileWriter fileWriter \u003d new FileWriter(storageFile);","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(board.getPlayerColor().name());","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(String.valueOf(board.getDifficulty()));","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(currentColor.name());","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"TriciaBK"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":82,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"TriciaBK"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(new Coordinate(col, row));","lastModifiedDate":"2023-10-20"},{"lineNumber":84,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(piece.toString());","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":89,"author":{"gitId":"TriciaBK"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"TriciaBK"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(new Coordinate(col, row));","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"TriciaBK"},"content":" String hasMovedString \u003d piece.getHasMoved() ? \"1\" : \"0\";","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(hasMovedString);","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"TriciaBK"},"content":" fileWriter.close();","lastModifiedDate":"2023-10-22"},{"lineNumber":99,"author":{"gitId":"TriciaBK"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":100,"author":{"gitId":"TriciaBK"},"content":" throw new SaveBoardException();","lastModifiedDate":"2023-10-17"},{"lineNumber":101,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":103,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" public void resetBoard() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-23"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" FileWriter fileWriter \u003d new FileWriter(storageFile);","lastModifiedDate":"2023-10-23"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" fileWriter.write(\"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" fileWriter.close();","lastModifiedDate":"2023-10-23"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" throw new SaveBoardException();","lastModifiedDate":"2023-10-23"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":117,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":118,"author":{"gitId":"TriciaBK"},"content":" /**","lastModifiedDate":"2023-10-20"},{"lineNumber":119,"author":{"gitId":"TriciaBK"},"content":" * Loads the state of the chessboard from a file.","lastModifiedDate":"2023-10-23"},{"lineNumber":120,"author":{"gitId":"TriciaBK"},"content":" * Ignores the first line player color information as it can be retrieved with","lastModifiedDate":"2023-10-23"},{"lineNumber":121,"author":{"gitId":"TriciaBK"},"content":" * loadPlayerColor() method","lastModifiedDate":"2023-10-23"},{"lineNumber":122,"author":{"gitId":"TriciaBK"},"content":" *","lastModifiedDate":"2023-10-20"},{"lineNumber":123,"author":{"gitId":"TriciaBK"},"content":" * @return A 2D array of ChessTile objects representing the loaded chessboard.","lastModifiedDate":"2023-10-23"},{"lineNumber":124,"author":{"gitId":"TriciaBK"},"content":" * @throws ChessMasterException If there is an error loading the board from the","lastModifiedDate":"2023-10-23"},{"lineNumber":125,"author":{"gitId":"TriciaBK"},"content":" * file.","lastModifiedDate":"2023-10-23"},{"lineNumber":126,"author":{"gitId":"TriciaBK"},"content":" */","lastModifiedDate":"2023-10-20"},{"lineNumber":127,"author":{"gitId":"TriciaBK"},"content":" public ChessTile[][] loadBoard() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":128,"author":{"gitId":"TriciaBK"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-22"},{"lineNumber":129,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":130,"author":{"gitId":"TriciaBK"},"content":" blackPieceNum \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"TriciaBK"},"content":" whitePieceNum \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"TriciaBK"},"content":" blackKingPresent \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"TriciaBK"},"content":" whiteKingPresent \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"TriciaBK"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":136,"author":{"gitId":"TriciaBK"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"TriciaBK"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-10-22"},{"lineNumber":138,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-10-22"},{"lineNumber":139,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":140,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":141,"author":{"gitId":"TriciaBK"},"content":" // Skip first three lines","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"TriciaBK"},"content":" for (int i \u003d 0; i \u003c 3; i++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"TriciaBK"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"TriciaBK"},"content":" int rowIndex \u003d 0;","lastModifiedDate":"2023-10-22"},{"lineNumber":149,"author":{"gitId":"TriciaBK"},"content":" ChessTile[][] boardTiles \u003d new ChessTile[ChessBoard.SIZE][ChessBoard.SIZE];","lastModifiedDate":"2023-10-22"},{"lineNumber":150,"author":{"gitId":"TriciaBK"},"content":" while (rowIndex \u003c ChessBoard.SIZE \u0026\u0026 fileScanner.hasNext()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":151,"author":{"gitId":"TriciaBK"},"content":" String chessRowLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-10-22"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":" if (chessRowLine.length() !\u003d ChessBoard.SIZE) {","lastModifiedDate":"2023-10-22"},{"lineNumber":153,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-10-17"},{"lineNumber":155,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":156,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":157,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":158,"author":{"gitId":"TriciaBK"},"content":" String chessPieceString \u003d String.valueOf(chessRowLine.charAt(col));","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"TriciaBK"},"content":" ChessPiece initialPiece \u003d Parser.parseChessPiece(chessPieceString, rowIndex, col);","lastModifiedDate":"2023-10-22"},{"lineNumber":160,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"onx001"},"content":" if (!this.isPieceValid(initialPiece)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"onx001"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"TriciaBK"},"content":" boardTiles[rowIndex][col] \u003d new ChessTile(initialPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":167,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"TriciaBK"},"content":" rowIndex++;","lastModifiedDate":"2023-10-22"},{"lineNumber":169,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":170,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":171,"author":{"gitId":"TriciaBK"},"content":" boolean hasBothKings \u003d blackKingPresent \u0026\u0026 whiteKingPresent;","lastModifiedDate":"2023-11-03"},{"lineNumber":172,"author":{"gitId":"TriciaBK"},"content":" if (!hasBothKings) {","lastModifiedDate":"2023-11-03"},{"lineNumber":173,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"TriciaBK"},"content":" rowIndex \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"TriciaBK"},"content":" while (rowIndex \u003c ChessBoard.SIZE \u0026\u0026 fileScanner.hasNext()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"TriciaBK"},"content":" String chessRowLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"TriciaBK"},"content":" if (chessRowLine.length() !\u003d ChessBoard.SIZE) {","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":184,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"TriciaBK"},"content":" boolean hasMoved \u003d Character.getNumericValue(chessRowLine.charAt(col)) \u003e 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"TriciaBK"},"content":" if (hasMoved) {","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"TriciaBK"},"content":" boardTiles[rowIndex][col].getChessPiece().setHasMoved();","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":192,"author":{"gitId":"TriciaBK"},"content":" rowIndex++;","lastModifiedDate":"2023-11-03"},{"lineNumber":193,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":194,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":195,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"TriciaBK"},"content":" return boardTiles;","lastModifiedDate":"2023-10-23"},{"lineNumber":197,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":198,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":199,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-03"},{"lineNumber":200,"author":{"gitId":"onx001"},"content":" private boolean isPieceValid (ChessPiece initialPiece) {","lastModifiedDate":"2023-11-03"},{"lineNumber":201,"author":{"gitId":"onx001"},"content":" if (initialPiece.isBlackKing()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"onx001"},"content":" if (blackKingPresent) {","lastModifiedDate":"2023-11-03"},{"lineNumber":203,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":204,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":205,"author":{"gitId":"onx001"},"content":" blackKingPresent \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":206,"author":{"gitId":"onx001"},"content":" blackPieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"onx001"},"content":" } else if (initialPiece.isWhiteKing()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"onx001"},"content":" if (whiteKingPresent) {","lastModifiedDate":"2023-11-03"},{"lineNumber":210,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":211,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":212,"author":{"gitId":"onx001"},"content":" whiteKingPresent \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":213,"author":{"gitId":"onx001"},"content":" whitePieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":215,"author":{"gitId":"onx001"},"content":" } else if (initialPiece.isBlack()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":216,"author":{"gitId":"onx001"},"content":" if (blackPieceNum \u003e\u003d ChessBoard.MAX_PIECES) {","lastModifiedDate":"2023-11-03"},{"lineNumber":217,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":218,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":219,"author":{"gitId":"onx001"},"content":" blackPieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":220,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"onx001"},"content":" } else if (initialPiece.isWhite()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"onx001"},"content":" if (whitePieceNum \u003e\u003d ChessBoard.MAX_PIECES) {","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":225,"author":{"gitId":"onx001"},"content":" whitePieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":226,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":227,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":228,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":229,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":230,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":231,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":232,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":233,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":234,"author":{"gitId":"TongZhengHong"},"content":" * Loads the player\u0027s color from a file.","lastModifiedDate":"2023-10-23"},{"lineNumber":235,"author":{"gitId":"TongZhengHong"},"content":" * Expects the player color information on the first line of text file.","lastModifiedDate":"2023-10-23"},{"lineNumber":236,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":237,"author":{"gitId":"TongZhengHong"},"content":" * @return The player\u0027s color as a Color enumeration.","lastModifiedDate":"2023-10-23"},{"lineNumber":238,"author":{"gitId":"TongZhengHong"},"content":" * @throws ChessMasterException If there is an error loading the player\u0027s color","lastModifiedDate":"2023-10-23"},{"lineNumber":239,"author":{"gitId":"TongZhengHong"},"content":" * from the file.","lastModifiedDate":"2023-10-23"},{"lineNumber":240,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":241,"author":{"gitId":"TongZhengHong"},"content":" public Color loadPlayerColor() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":242,"author":{"gitId":"TongZhengHong"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-23"},{"lineNumber":243,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":244,"author":{"gitId":"TongZhengHong"},"content":" Scanner fileScanner;","lastModifiedDate":"2023-10-23"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-10-23"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-10-23"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":251,"author":{"gitId":"TongZhengHong"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":252,"author":{"gitId":"TongZhengHong"},"content":" String colorLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-10-23"},{"lineNumber":253,"author":{"gitId":"TongZhengHong"},"content":" Color playerColor \u003d Parser.parsePlayerColor(colorLine);","lastModifiedDate":"2023-10-23"},{"lineNumber":254,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":255,"author":{"gitId":"TongZhengHong"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-23"},{"lineNumber":256,"author":{"gitId":"TongZhengHong"},"content":" return playerColor;","lastModifiedDate":"2023-10-23"},{"lineNumber":257,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":258,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":259,"author":{"gitId":"TongZhengHong"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-23"},{"lineNumber":260,"author":{"gitId":"TongZhengHong"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-10-23"},{"lineNumber":261,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":262,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"onx001"},"content":" * Loads the difficulty from a file.","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"onx001"},"content":" * Expects the difficulty information on the second line of text file.","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"onx001"},"content":" * @return The difficulty as an integer.","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":269,"author":{"gitId":"onx001"},"content":" public int loadDifficulty() throws ChessMasterException {","lastModifiedDate":"2023-11-01"},{"lineNumber":270,"author":{"gitId":"onx001"},"content":" createChessMasterFile();","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"onx001"},"content":" Scanner fileScanner;","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"onx001"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"onx001"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":279,"author":{"gitId":"onx001"},"content":" // Skip player color first line","lastModifiedDate":"2023-11-03"},{"lineNumber":280,"author":{"gitId":"onx001"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"onx001"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":282,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":283,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":284,"author":{"gitId":"onx001"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":285,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":286,"author":{"gitId":"onx001"},"content":" String difficultyLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"onx001"},"content":" int difficulty \u003d Parser.parseDifficulty(difficultyLine);","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"onx001"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"onx001"},"content":" if (difficulty \u003c 1 || difficulty \u003e 3) {","lastModifiedDate":"2023-11-03"},{"lineNumber":291,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-03"},{"lineNumber":292,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":293,"author":{"gitId":"onx001"},"content":" return difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"onx001"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"onx001"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-01"},{"lineNumber":300,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-01"},{"lineNumber":301,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":302,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":303,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":304,"author":{"gitId":"TriciaBK"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":305,"author":{"gitId":"TriciaBK"},"content":" * Loads the current turn player\u0027s","lastModifiedDate":"2023-11-02"},{"lineNumber":306,"author":{"gitId":"TriciaBK"},"content":" * @return The difficulty as an integer.","lastModifiedDate":"2023-11-02"},{"lineNumber":307,"author":{"gitId":"TriciaBK"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":308,"author":{"gitId":"TriciaBK"},"content":" public Color loadCurrentColor() throws ChessMasterException {","lastModifiedDate":"2023-11-02"},{"lineNumber":309,"author":{"gitId":"TriciaBK"},"content":" createChessMasterFile();","lastModifiedDate":"2023-11-02"},{"lineNumber":310,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":311,"author":{"gitId":"TriciaBK"},"content":" Scanner fileScanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":312,"author":{"gitId":"TriciaBK"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":313,"author":{"gitId":"TriciaBK"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-11-02"},{"lineNumber":314,"author":{"gitId":"TriciaBK"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":315,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-11-02"},{"lineNumber":316,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":317,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":318,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":319,"author":{"gitId":"TriciaBK"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":320,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":321,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":322,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":323,"author":{"gitId":"TriciaBK"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":324,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":325,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":326,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":327,"author":{"gitId":"TriciaBK"},"content":" String currentColorString \u003d fileScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":328,"author":{"gitId":"TriciaBK"},"content":" Color color \u003d Parser.parsePlayerColor(currentColorString);","lastModifiedDate":"2023-11-03"},{"lineNumber":329,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-03"},{"lineNumber":330,"author":{"gitId":"TriciaBK"},"content":" return color;","lastModifiedDate":"2023-11-03"},{"lineNumber":331,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":332,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":333,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":334,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-02"},{"lineNumber":335,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":336,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":337,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"TriciaBK":188,"onx001":78,"TongZhengHong":71}},{"path":"src/main/java/chessmaster/ui/ExceptionMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"public class ExceptionMessages {","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_PARSE_CHESS_PIECE_EXCEPTION \u003d \"Unable to parse chess piece!\";","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_PARSE_COORDINATE_EXCEPTION \u003d \"Unable to parse coordinate!\";","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":" public static final String MESSAGE_SAVE_BOARD_EXCEPTION \u003d \"Unable to save board!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":" public static final String MESSAGE_LOAD_BOARD_EXCEPTION \u003d \"Unable to load board!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":" public static final String MESSAGE_INVALID_MOVE_EXCEPTION \u003d \"Oops, that move isn\u0027t valid!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_NULL_PIECE_EXCEPTION \u003d \"No chess piece found at coordinate!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_MOVE_OPPONENT_EXCEPTION \u003d \"You have chosen an opponent piece! \"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" + \"Please choose your pieces!\";","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_PARSE_COLOR_EXCEPTION \u003d \"Unable to parse color!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":1,"TriciaBK":2,"TongZhengHong":10}},{"path":"src/main/java/chessmaster/ui/TextUI.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.CommandResult;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.Player;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"antrikshdhand"},"content":"public final class TextUI {","lastModifiedDate":"2023-10-19"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private static final String CHESS_BOARD_TAB \u003d \" \".repeat(4);","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" private static final String CHESS_BOARD_PADDING \u003d CHESS_BOARD_TAB.repeat(3);","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public static final String CHESS_BOARD_DIVIDER \u003d CHESS_BOARD_PADDING + CHESS_BOARD_TAB +","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" \"_\".repeat(4 * ChessBoard.SIZE + 1);","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" private static final String COLUMN_HEADER \u003d \"abcdefgh\";","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" /** A platform independent line separator. */","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" private static final String LS \u003d System.lineSeparator();","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" private static final String DIVIDER \u003d \"_\".repeat(65) + LS;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" * Format of a comment input line. Comment lines are silently consumed when","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" * reading user input.","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" private static final String COMMENT_LINE_FORMAT_REGEX \u003d \"#.*\";","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"antrikshdhand"},"content":" private static final Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"antrikshdhand"},"content":" private static final PrintStream out \u003d System.out;","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" * Prompts for the command and reads the text entered by the user.","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * Ignores empty, pure whitespace, and comment lines.","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" * @return user input string in LOWER case","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" public String getUserInput() {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" String fullInputLine \u003d scanner.nextLine().trim();","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" // silently consume all ignored lines","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" while (shouldIgnore(fullInputLine)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" fullInputLine \u003d scanner.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" return fullInputLine.toLowerCase();","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" * Returns true if the user input line should be ignored.","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" * Input should be ignored if it is parsed as a comment, is only whitespace, or","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" * is empty.","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" * @param rawInputLine full raw user input line.","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the entire user input line should be ignored.","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" private boolean shouldIgnore(String rawInputLine) {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" boolean isCommentLine \u003d rawInputLine.trim().matches(COMMENT_LINE_FORMAT_REGEX);","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" return rawInputLine.trim().isEmpty() || isCommentLine;","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" * Prints one or more lines of text, surrounded by a divider, to the user","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" * console.","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" * @param texts The lines of text to be printed.","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" public void printText(String... texts) {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" out.println(DIVIDER);","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" for (String text : texts) {","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" out.println(text);","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" out.println(DIVIDER);","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoard(ChessTile[][] tiles) {","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c tiles.length; i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[] row \u003d tiles[i];","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" StringBuilder rowString \u003d new StringBuilder();","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" for (ChessTile tile : row) {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(tile.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" int rowNum \u003d 8 - i;","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardRow(rowNum, rowString.toString());","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardWithMove(ChessTile[][] tiles, Move move) {","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardDivider();","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c tiles.length; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[] row \u003d tiles[i];","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" StringBuilder rowString \u003d new StringBuilder();","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" for (int j \u003d 0; j \u003c tiles.length; j++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" ChessTile tile \u003d row[j];","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coord \u003d new Coordinate(j, i);","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" boolean isPrevMove \u003d move.getFrom().equals(coord) || ","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" move.getTo().equals(coord);","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" String pieceString \u003d isPrevMove ? tile.toStringPrevMove() : tile.toString();","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(pieceString);","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":" int rowNum \u003d 8 - i;","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardRow(rowNum, rowString.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"ken-ruster"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"ken-ruster"},"content":" * Prints the chessboard along with highlighted moves for a specific chess piece.","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"ken-ruster"},"content":" * This method displays the chessboard, emphasizing available destination squares for a","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"ken-ruster"},"content":" * selected piece and marking the selected piece itself.","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"ken-ruster"},"content":" * @param tiles The 2D array of ChessTile objects representing the chessboard.","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"ken-ruster"},"content":" * @param piece The chess piece for which moves are highlighted.","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"ken-ruster"},"content":" * @param coordinates An array of coordinates representing available destination squares.","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"ken-ruster"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"ken-ruster"},"content":" public void printChessBoardAvailableMoves(ChessTile[][] tiles, ChessPiece piece, ","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"ken-ruster"},"content":" Coordinate[] coordinates) {","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"ken-ruster"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"ken-ruster"},"content":" printChessBoardDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"ken-ruster"},"content":" for (int i \u003d 0; i \u003c tiles.length; i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"ken-ruster"},"content":" ChessTile[] row \u003d tiles[i];","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"ken-ruster"},"content":" StringBuilder rowString \u003d new StringBuilder();","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"ken-ruster"},"content":" for (int j \u003d 0; j \u003c tiles.length; j++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"ken-ruster"},"content":" rowString.append(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"ken-ruster"},"content":" ChessTile tile \u003d row[j];","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"ken-ruster"},"content":" Coordinate coord \u003d new Coordinate(j, i);","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"ken-ruster"},"content":" String pieceString;","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"ken-ruster"},"content":" if (Arrays.asList(coordinates).contains(coord)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"ken-ruster"},"content":" pieceString \u003d tile.toStringAvailableDest();","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"ken-ruster"},"content":" } else if (piece.getPosition().equals(coord)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"ken-ruster"},"content":" pieceString \u003d tile.toStringSelected();","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"ken-ruster"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"ken-ruster"},"content":" pieceString \u003d tile.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"ken-ruster"},"content":" rowString.append(pieceString);","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"ken-ruster"},"content":" int rowNum \u003d 8 - i;","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"ken-ruster"},"content":" printChessBoardRow(rowNum, rowString.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"ken-ruster"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"ken-ruster"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"ken-ruster"},"content":" //@@author","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"TongZhengHong"},"content":" public void printWelcomeMessage() {","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" printText(UiMessages.WELCOME_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":179,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":" public void printLoadBoardError() {","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":" printText(UiMessages.LOAD_BOARD_ERROR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":183,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":184,"author":{"gitId":"TongZhengHong"},"content":" public void promptContinuePrevGame(boolean error) {","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"TongZhengHong"},"content":" if (error) {","lastModifiedDate":"2023-10-23"},{"lineNumber":186,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.CONTINUE_PREV_GAME_ERROR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":188,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.EXIST_PREV_GAME_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":189,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":190,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":191,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":192,"author":{"gitId":"onx001"},"content":" public void promptDifficulty(boolean error) {","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"onx001"},"content":" if (error) {","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"onx001"},"content":" out.print(UiMessages.CHOOSE_DIFFICULTY_ERROR_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"onx001"},"content":" out.print(UiMessages.CHOOSE_DIFFICULTY_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"TongZhengHong"},"content":" public void promptStartingColor(boolean error) {","lastModifiedDate":"2023-10-31"},{"lineNumber":201,"author":{"gitId":"TongZhengHong"},"content":" if (error) {","lastModifiedDate":"2023-10-23"},{"lineNumber":202,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.CHOOSE_PLAYER_COLOR_ERROR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":203,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":204,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.CHOOSE_PLAYER_COLOR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":205,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":206,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":207,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":208,"author":{"gitId":"TongZhengHong"},"content":" public void printStartNewGame(String colorString) {","lastModifiedDate":"2023-10-31"},{"lineNumber":209,"author":{"gitId":"TongZhengHong"},"content":" String displayText \u003d String.format(UiMessages.START_NEW_GAME_MESSAGE, colorString);","lastModifiedDate":"2023-10-23"},{"lineNumber":210,"author":{"gitId":"TongZhengHong"},"content":" printText(displayText);","lastModifiedDate":"2023-10-23"},{"lineNumber":211,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":212,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":213,"author":{"gitId":"TongZhengHong"},"content":" public void printContinuePrevGame(String colorString) {","lastModifiedDate":"2023-10-31"},{"lineNumber":214,"author":{"gitId":"TongZhengHong"},"content":" String displayText \u003d String.format(UiMessages.CONTINUE_PREV_GAME_MESSAGE, colorString);","lastModifiedDate":"2023-10-23"},{"lineNumber":215,"author":{"gitId":"TongZhengHong"},"content":" printText(displayText);","lastModifiedDate":"2023-10-23"},{"lineNumber":216,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":217,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":218,"author":{"gitId":"TongZhengHong"},"content":" public void printPromotePrompt(Coordinate coord) {","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"ken-ruster"},"content":" String message \u003d String.format(UiMessages.PROMPT_PROMOTE_MESSAGE, coord.toString());","lastModifiedDate":"2023-10-19"},{"lineNumber":220,"author":{"gitId":"TongZhengHong"},"content":" out.print(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":221,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":222,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":223,"author":{"gitId":"TongZhengHong"},"content":" public void printPromoteInvalidMessage() {","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.PROMPT_PROMOTE_INVALID_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":225,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":226,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":227,"author":{"gitId":"TongZhengHong"},"content":" public void printCPUMove(Move cpuMove) {","lastModifiedDate":"2023-10-31"},{"lineNumber":228,"author":{"gitId":"TongZhengHong"},"content":" String pieceString \u003d cpuMove.getPiece().getClass().getSimpleName();","lastModifiedDate":"2023-10-23"},{"lineNumber":229,"author":{"gitId":"TongZhengHong"},"content":" String displayString \u003d String.format(UiMessages.CPU_MOVE_MESSAGE, pieceString,","lastModifiedDate":"2023-10-23"},{"lineNumber":230,"author":{"gitId":"TongZhengHong"},"content":" cpuMove.getFrom(), cpuMove.getTo());","lastModifiedDate":"2023-10-23"},{"lineNumber":231,"author":{"gitId":"TongZhengHong"},"content":" printText(displayString);","lastModifiedDate":"2023-10-23"},{"lineNumber":232,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":233,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":234,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardDivider() {","lastModifiedDate":"2023-10-31"},{"lineNumber":235,"author":{"gitId":"TongZhengHong"},"content":" out.println(CHESS_BOARD_DIVIDER);","lastModifiedDate":"2023-10-15"},{"lineNumber":236,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":237,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":238,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardHeader() {","lastModifiedDate":"2023-10-31"},{"lineNumber":239,"author":{"gitId":"TongZhengHong"},"content":" out.print(CHESS_BOARD_PADDING + CHESS_BOARD_TAB);","lastModifiedDate":"2023-10-23"},{"lineNumber":240,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c COLUMN_HEADER.length(); i++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":241,"author":{"gitId":"TongZhengHong"},"content":" char col \u003d COLUMN_HEADER.charAt(i);","lastModifiedDate":"2023-10-15"},{"lineNumber":242,"author":{"gitId":"antrikshdhand"},"content":" out.printf(\" (%s)\", col);","lastModifiedDate":"2023-10-19"},{"lineNumber":243,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":244,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-15"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardRow(int rowNum, String chessBoardRow) {","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" out.print(CHESS_BOARD_PADDING);","lastModifiedDate":"2023-10-23"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" out.print(String.format(\"(%d) \", rowNum));","lastModifiedDate":"2023-10-23"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":" out.print(chessBoardRow);","lastModifiedDate":"2023-10-15"},{"lineNumber":251,"author":{"gitId":"TongZhengHong"},"content":" out.print(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-10-15"},{"lineNumber":252,"author":{"gitId":"TongZhengHong"},"content":" out.print(String.format(\" (%d)\", rowNum));","lastModifiedDate":"2023-10-15"},{"lineNumber":253,"author":{"gitId":"TongZhengHong"},"content":" out.print(System.lineSeparator() + CHESS_BOARD_DIVIDER);","lastModifiedDate":"2023-10-15"},{"lineNumber":254,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-15"},{"lineNumber":255,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":256,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":257,"author":{"gitId":"TongZhengHong"},"content":" public void printCommandResult(CommandResult result) {","lastModifiedDate":"2023-10-31"},{"lineNumber":258,"author":{"gitId":"TongZhengHong"},"content":" String[] resultStrings \u003d result.getMessageStrings();","lastModifiedDate":"2023-10-31"},{"lineNumber":259,"author":{"gitId":"TongZhengHong"},"content":" if (resultStrings !\u003d null \u0026\u0026 resultStrings.length \u003e 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":260,"author":{"gitId":"TongZhengHong"},"content":" printText(resultStrings);","lastModifiedDate":"2023-10-31"},{"lineNumber":261,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":263,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":264,"author":{"gitId":"TongZhengHong"},"content":" public void printErrorMessage(Exception e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":265,"author":{"gitId":"TongZhengHong"},"content":" printText(e.getMessage());","lastModifiedDate":"2023-10-23"},{"lineNumber":266,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":267,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"TongZhengHong"},"content":" public void printWinnerMessage(Player winner) {","lastModifiedDate":"2023-11-03"},{"lineNumber":269,"author":{"gitId":"TongZhengHong"},"content":" String winningColorString \u003d winner.getColour().name();","lastModifiedDate":"2023-11-03"},{"lineNumber":270,"author":{"gitId":"TongZhengHong"},"content":" if (winner.isHuman()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":271,"author":{"gitId":"TongZhengHong"},"content":" printText(String.format(UiMessages.HUMAN_WIN_STRING, winningColorString));","lastModifiedDate":"2023-11-03"},{"lineNumber":272,"author":{"gitId":"TongZhengHong"},"content":" } else if (winner.isCPU()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":273,"author":{"gitId":"TongZhengHong"},"content":" printText(String.format(UiMessages.CPU_WIN_STRING, winningColorString));","lastModifiedDate":"2023-11-03"},{"lineNumber":274,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":275,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":276,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":277,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":51,"antrikshdhand":4,"TriciaBK":3,"onx001":8,"TongZhengHong":211}},{"path":"src/main/java/chessmaster/ui/UiMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.ui;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"public class UiMessages {","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" public static final String[] WELCOME_MESSAGE \u003d { ","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" \"Hey there, chess geek! You have stumbled upon the one and only: \",","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" \" ________ __ ___ __ \",","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" \" / ____/ /_ ___ __________ / |/ /___ ______/ /____ _____\",","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" \" / / / __ \\\\/ _ \\\\/ ___/ ___/ / /|_/ / __ `/ ___/ __/ _ \\\\/ ___/\",","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" \" / /___/ / / / __(__ |__ ) / / / / /_/ (__ ) /_/ __/ / \",","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" \" \\\\____/_/ /_/\\\\___/____/____/ /_/ /_/\\\\__,_/____/\\\\__/\\\\___/_/ \", \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" \"where CHESS becomes an exciting journey of strategy and skill!\" };","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public static final String EXIST_PREV_GAME_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" \"You have an ongoing previous chess game. Continue game? [y/n] \";","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" public static final String CONTINUE_PREV_GAME_ERROR_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" \"Invalid input! Please enter either \u0027y\u0027 for yes or \u0027n\u0027 for no: \";","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" public static final String CONTINUE_PREV_GAME_MESSAGE \u003d \"Great! Continuing previous game as %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" public static final String CHOOSE_PLAYER_COLOR_MESSAGE \u003d \"Choose your starting color to start new game! [b/w] \";","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" public static final String CHOOSE_PLAYER_COLOR_ERROR_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" \"Invalid input! Please enter either \u0027b\u0027 for Black or \u0027w\u0027 for White: \";","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" public static final String START_NEW_GAME_MESSAGE \u003d \"Great! Starting new game as %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" public static final String LOAD_BOARD_ERROR_MESSAGE \u003d \"No valid previous game found. Starting new chess game...\";","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" public static final String CPU_MOVE_MESSAGE \u003d \"ChessMaster moved %s from %s to %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public static final String PROMPT_PROMOTE_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" \"Promote the pawn at %s! Choose piece to promote to [b/q/r/n]: \";","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" public static final String PROMPT_PROMOTE_INVALID_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" \"Invalid piece! Enter b(Bishop), q(Queen), r(Rook) or n(Knight): \";","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" public static final String CHOOSE_DIFFICULTY_MESSAGE \u003d ","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" \"Choose difficulty level [1/2/3]: \";","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" public static final String CHOOSE_DIFFICULTY_ERROR_MESSAGE \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" \"Invalid input! Please enter either \u00271\u0027, \u00272\u0027 or \u00273\u0027: \";","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" public static final String HUMAN_WIN_STRING \u003d \"Congratulations! You have won as %s! :)\";","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" public static final String CPU_WIN_STRING \u003d \"Oh no! You have lost as %s. Please try harder next time :(\";","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"ken-ruster":4,"onx001":5,"TongZhengHong":31}},{"path":"src/main/java/chessmaster/user/CPU.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"antrikshdhand"},"content":"package chessmaster.user;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-19"},{"lineNumber":6,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-19"},{"lineNumber":7,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"import chessmaster.game.MiniMax;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"antrikshdhand"},"content":"import java.util.Random;","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"antrikshdhand"},"content":"public class CPU extends Player {","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" private static final int MAX_LOOP_ITERATIONS \u003d 16;","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" private static final int RANDOM_SEED \u003d 100;","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private final Random rand \u003d new Random(RANDOM_SEED);","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public CPU(Color colour, ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" super(colour, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":22,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":23,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":24,"author":{"gitId":"antrikshdhand"},"content":" * The main function behind the CPU\u0027s logic, this function randomly selects an active (non-captured) piece","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"antrikshdhand"},"content":" * from the CPU\u0027s pieces which has possible valid moves.","lastModifiedDate":"2023-10-19"},{"lineNumber":26,"author":{"gitId":"antrikshdhand"},"content":" * @param board The board to extract the random move from.","lastModifiedDate":"2023-10-19"},{"lineNumber":27,"author":{"gitId":"antrikshdhand"},"content":" * @return A random move","lastModifiedDate":"2023-10-19"},{"lineNumber":28,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"antrikshdhand"},"content":" public Move getRandomMove(ChessBoard board) {","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"antrikshdhand"},"content":" // 1. Get a random piece that","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"antrikshdhand"},"content":" // - isn\u0027t captured","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"antrikshdhand"},"content":" // - has possible legal moves","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"antrikshdhand"},"content":" ChessPiece randomPiece \u003d getRandomPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"antrikshdhand"},"content":" // Need a cap on the number of pieces it checks to prevent an infinite loop when no moves are possible","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"antrikshdhand"},"content":" // on the CPUs side.","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"antrikshdhand"},"content":" int iter \u003d 0;","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"antrikshdhand"},"content":" while (iter \u003c MAX_LOOP_ITERATIONS","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 (randomPiece.getIsCaptured()","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" || randomPiece.getFlattenedCoordinates(board).length \u003d\u003d 0)) {","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"antrikshdhand"},"content":" randomPiece \u003d getRandomPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"antrikshdhand"},"content":" iter++;","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"antrikshdhand"},"content":" return getRandomMoveFromPiece(randomPiece, board);","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" public Move getBestMove(ChessBoard board, int maxDepth) {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" MiniMax miniMax \u003d new MiniMax(board, this.colour, maxDepth, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" Move bestMove \u003d miniMax.getBestMove();","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" Coordinate from \u003d bestMove.getFrom();","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(from);","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" bestMove.setPiece(piece);","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" return bestMove;","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" //@@author ","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"antrikshdhand"},"content":" private ChessPiece getRandomPiece() {","lastModifiedDate":"2023-10-19"},{"lineNumber":62,"author":{"gitId":"antrikshdhand"},"content":" return this.pieces.get(rand.nextInt(pieces.size()));","lastModifiedDate":"2023-10-19"},{"lineNumber":63,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":64,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":65,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"antrikshdhand"},"content":" * This function returns any random valid move that a given piece can make on a given board.","lastModifiedDate":"2023-10-19"},{"lineNumber":67,"author":{"gitId":"antrikshdhand"},"content":" * @param piece The piece to extract a random move from.","lastModifiedDate":"2023-10-19"},{"lineNumber":68,"author":{"gitId":"antrikshdhand"},"content":" * @param board The board the piece is currently on.","lastModifiedDate":"2023-10-19"},{"lineNumber":69,"author":{"gitId":"antrikshdhand"},"content":" * @return A random move the given piece can make on the given board.","lastModifiedDate":"2023-10-19"},{"lineNumber":70,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":71,"author":{"gitId":"antrikshdhand"},"content":" private Move getRandomMoveFromPiece(ChessPiece piece, ChessBoard board) {","lastModifiedDate":"2023-10-19"},{"lineNumber":72,"author":{"gitId":"ken-ruster"},"content":" Coordinate[] allPossibleMoves \u003d piece.getFlattenedCoordinates(board);","lastModifiedDate":"2023-10-20"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" int randIndex \u003d rand.nextInt(allPossibleMoves.length);","lastModifiedDate":"2023-10-20"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" Coordinate randomDestination \u003d allPossibleMoves[randIndex];","lastModifiedDate":"2023-10-20"},{"lineNumber":75,"author":{"gitId":"antrikshdhand"},"content":" return new Move(piece.getPosition(), randomDestination, piece);","lastModifiedDate":"2023-10-19"},{"lineNumber":76,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":77,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":78,"author":{"gitId":"antrikshdhand"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"ken-ruster":2,"antrikshdhand":52,"onx001":14,"TongZhengHong":10}},{"path":"src/main/java/chessmaster/user/Human.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"antrikshdhand"},"content":"package chessmaster.user;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"antrikshdhand"},"content":"public class Human extends Player {","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public Human(Color colour, ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" super(colour, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":" * Prompts the user to enter a type of piece to promote a pawn to. If the","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":" * promotion is not successful,","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" * the user is prompted again. If successful, the pawn is replaced with the new","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" * piece.","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" * @param board Chessboard that the game is being played on.","lastModifiedDate":"2023-10-22"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" * @param promoteMove The piece being promoted.","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" public void handlePromote(ChessBoard board, TextUI ui, Move promoteMove) {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" ChessPiece pawnPiece \u003d promoteMove.getPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" if (!pawnPiece.isPawn()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" return;","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":" Coordinate coord \u003d pawnPiece.getPosition();","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":" boolean promoteFailure \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":" ui.printPromotePrompt(coord);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":" String in \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":" do {","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" ChessPiece promotedPiece \u003d Parser.parsePromote(pawnPiece, in);","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":" promoteFailure \u003d promotedPiece.isPawn();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" if (promoteFailure) {","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" ui.printPromoteInvalidMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":" in \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" } else {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":" promotedPiece.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":" this.pieces.add(promotedPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":" this.pieces.remove(pawnPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" board.setPromotionPiece(coord, promotedPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"ken-ruster"},"content":" } while (promoteFailure);","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":54,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"ken-ruster":39,"antrikshdhand":4,"TongZhengHong":12}},{"path":"src/main/java/chessmaster/user/Player.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"antrikshdhand"},"content":"package chessmaster.user;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-19"},{"lineNumber":6,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-19"},{"lineNumber":7,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"antrikshdhand"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"antrikshdhand"},"content":"public abstract class Player {","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"antrikshdhand"},"content":" protected ArrayList\u003cMove\u003e moves;","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"antrikshdhand"},"content":" protected ArrayList\u003cChessPiece\u003e pieces;","lastModifiedDate":"2023-10-19"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" protected Color colour;","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" * A player is a dependency of the Game class. This class stores all move","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" * history, all current pieces, and colour of each player. ","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" * It also contains functions to request input from the user for the next ","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" * move and to execute that move.","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"antrikshdhand"},"content":" * @param colour The ChessPiece.Colour desired for this player.","lastModifiedDate":"2023-10-19"},{"lineNumber":24,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" public Player(Color colour, ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" this.moves \u003d new ArrayList\u003cMove\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" this.pieces \u003d new ArrayList\u003cChessPiece\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"antrikshdhand"},"content":" this.colour \u003d colour;","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" initialisePieces(board);","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"antrikshdhand"},"content":" * Adds a given move into the Player\u0027s move history.","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-20"},{"lineNumber":35,"author":{"gitId":"antrikshdhand"},"content":" * @param move The given move to be added to history.","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"antrikshdhand"},"content":" public void addMove(Move move) {","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"antrikshdhand"},"content":" this.moves.add(move);","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" public Color getColour() {","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" return this.colour;","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" * Adds all the player\u0027s pieces to their ChessPiece array ","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" * when Player is initialised.","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-20"},{"lineNumber":49,"author":{"gitId":"antrikshdhand"},"content":" * @param board The new ChessBoard containing all 32 chess pieces.","lastModifiedDate":"2023-10-19"},{"lineNumber":50,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" private void initialisePieces(ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"antrikshdhand"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(new Coordinate(col, row));","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" if (piece.isSameColorAs(this.colour)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"antrikshdhand"},"content":" this.pieces.add(piece);","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":58,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":59,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":62,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" * Prints out all the player\u0027s pieces including whether it has been captured or","lastModifiedDate":"2023-10-20"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" * not.","lastModifiedDate":"2023-10-20"},{"lineNumber":65,"author":{"gitId":"antrikshdhand"},"content":" * Used for debugging purposes only.","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":67,"author":{"gitId":"antrikshdhand"},"content":" public void printAllPieces() {","lastModifiedDate":"2023-10-19"},{"lineNumber":68,"author":{"gitId":"antrikshdhand"},"content":" for (ChessPiece p : pieces) {","lastModifiedDate":"2023-10-19"},{"lineNumber":69,"author":{"gitId":"antrikshdhand"},"content":" System.out.println(\"Piece: \" + p);","lastModifiedDate":"2023-10-19"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" System.out.println(\"Colour: \" + p.getColor().toString());","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" System.out.println(\"Is captured: \" + p.getIsCaptured());","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" public boolean isHuman() {","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof Human;","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" public boolean isCPU() {","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof CPU;","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"antrikshdhand"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"antrikshdhand":45,"TongZhengHong":37}},{"path":"src/test/java/chessmaster/ChessMasterTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"class ChessMasterTest {","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" public void sampleTest() {","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" assertFalse(false);","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"onx001":2,"TongZhengHong":2,"-":10}},{"path":"src/test/java/chessmaster/game/ChessBoardTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"public class ChessBoardTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" // @@author onx001","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" public void pointTest() {","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" TextUI ui \u003d new TextUI();","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":" ChessBoard board \u003d new ChessBoard(Color.WHITE);","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" int points \u003d board.getPoints(Color.WHITE);","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" assertEquals(0, points);","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" // @@author","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"onx001":19,"TongZhengHong":3}},{"path":"src/test/java/chessmaster/game/ColorTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"public class ColorTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public void testGetOppositeColour() {","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.BLACK, Color.WHITE.getOppositeColour());","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.WHITE, Color.BLACK.getOppositeColour());","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.EMPTY, Color.EMPTY.getOppositeColour());","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" public void testIsWhite() {","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(Color.WHITE.isWhite());","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.BLACK.isWhite());","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.EMPTY.isWhite());","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" public void testIsBlack() {","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(Color.BLACK.isBlack());","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.WHITE.isBlack());","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.EMPTY.isBlack());","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":30}},{"path":"src/test/java/chessmaster/game/CoordinateTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertNotEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"public class CoordinateTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" public void testIsOffsetWithinBoard() {","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d new Coordinate(3, 4);","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(coordinate.isOffsetWithinBoard(-1, 0));","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(coordinate.isOffsetWithinBoard(0, -1));","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(coordinate.isOffsetWithinBoard(1, 1));","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(coordinate.isOffsetWithinBoard(8, 0));","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(coordinate.isOffsetWithinBoard(0, 8));","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(coordinate.isOffsetWithinBoard(-4, 0));","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public void testAddOffsetToCoordinate() {","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoord1 \u003d coordinate.addOffsetToCoordinate(1, 2);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoord2 \u003d coordinate.addOffsetToCoordinate(-2, -3);","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoord3 \u003d coordinate.addOffsetToCoordinate(0, 0);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(new Coordinate(3, 5), newCoord1);","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(new Coordinate(0, 0), newCoord2);","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(coordinate, newCoord3); // Should be the same coordinate","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" public void testParseAlgebraicCoor() throws ParseCoordinateException {","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d Coordinate.parseAlgebraicCoor(\"d5\");","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(new Coordinate(3, 3), coordinate);","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" // Test invalid notations","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e Coordinate.parseAlgebraicCoor(\"x3\"));","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e Coordinate.parseAlgebraicCoor(\"h0\"));","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e Coordinate.parseAlgebraicCoor(\"a9\"));","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" public void testCalculateOffsetFrom() {","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate1 \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate2 \u003d new Coordinate(4, 1);","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" int[] offset \u003d coordinate1.calculateOffsetFrom(coordinate2);","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(-2, offset[0]);","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(2, offset[1]);","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" public void testToString() {","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d new Coordinate(1, 6);","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(\"b2\", coordinate.toString());","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" public void testEquals() {","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate1 \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate2 \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate3 \u003d new Coordinate(4, 1);","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(coordinate1, coordinate2);","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" assertNotEquals(coordinate1, coordinate3);","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":79}},{"path":"src/test/java/chessmaster/game/MiniMaxTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"package chessmaster.game;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"public class MiniMaxTest {","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":" public void testMiniMax() {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" ChessBoard board \u003d new ChessBoard(Color.BLACK);","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" MiniMax miniMax \u003d new MiniMax(board, Color.BLACK, 3, 0);","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" Move move \u003d miniMax.getBestMove();","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" assertEquals(move.getFrom(), new Coordinate(6, 7));","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" //ChessBoard board, Color color, int maxDepth, int score","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"onx001":17}},{"path":"src/test/java/chessmaster/parser/ParseMoveTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.MoveOpponentPieceException;","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.NullPieceException;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"public class ParseMoveTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" private static final String[][] STARTING_CHESSBOARD_BLACK \u003d { ","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" { \"r\", \"n\", \"b\", \"q\", \"k\", \"b\", \"n\", \"r\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" { \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" { \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" { \"R\", \"N\", \"B\", \"Q\", \"K\", \"B\", \"N\", \"R\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" private ChessBoard loadChessBoard() {","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[][] chessTiles \u003d new ChessTile[ChessBoard.SIZE][ChessBoard.SIZE];","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" String chessPieceString \u003d STARTING_CHESSBOARD_BLACK[row][col];","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece initialPiece \u003d Parser.parseChessPiece(chessPieceString, row, col);","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" chessTiles[row][col] \u003d new ChessTile(initialPiece);","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" assert (chessTiles[row][col] !\u003d null);","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" return new ChessBoard(Color.BLACK, chessTiles);","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputValidMove() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2 h4\";","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" Move move \u003d Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" Coordinate from \u003d new Coordinate(7, 6); // h2","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" Coordinate to \u003d new Coordinate(7, 4); // h4","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" Move expectedMove \u003d new Move(from, to, emptyBoard.getPieceAtCoor(from));","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(move, expectedMove);","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputCannotParseStart_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2dasd h4\";","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputCannotParseDest_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2 h4dafsd\";","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputMoreThan2Inputs_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2 h4 a3\";","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputOneInput_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2\";","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputEmptyPiece_expectNullPieceException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"d4 d5\";","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(NullPieceException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputNotFriendly_expectMoveOpponentException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"a7 a6\";","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(MoveOpponentPieceException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":110}},{"path":"src/test/java/chessmaster/parser/ParsePlayerColorTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseColorException;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"public class ParsePlayerColorTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputValidColor() throws ParseColorException {","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" String inputWhiteString \u003d \"WHITE\";","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" Color whiteColor \u003d Parser.parsePlayerColor(inputWhiteString);","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.WHITE, whiteColor);","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" String inputBlackString \u003d \"BLACK\";","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" Color blackColor \u003d Parser.parsePlayerColor(inputBlackString);","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.BLACK, blackColor);","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputEmpty_expectParseException() throws ParseColorException {","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" String inputEmptyString \u003d \"EMPTY\";","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputEmptyString);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputInvalid_expectParseException() {","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" String inputColorString \u003d \"dfljasdka\";","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputColorString);","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputLowerCase_expectParseException() {","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" String inputColorString \u003d \"white\";","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputColorString);","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputEmptyString_expectParseException() {","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" String inputColorString \u003d \"\";","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputColorString);","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":54}},{"path":"src/test/java/chessmaster/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"//@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-10-20"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-10-20"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":"public class ParserTest {","lastModifiedDate":"2023-10-20"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" @Test","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" public void promoteTest() {","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" ChessPiece promoted \u003d Parser.parsePromote(new Pawn(0, 0, Color.WHITE), \"q\");","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" assertEquals(promoted.toString(), Queen.QUEEN_WHITE);","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-20"}],"authorContributionMap":{"ken-ruster":20}}] +[{"path":"README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Duke project template","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"This is a project template for a greenfield Java project. It\u0027s named after Chess and Master. Given below are instructions on how to use it.","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"## Setting up in Intellij","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"Prerequisites: JDK 11 (use the exact version), update Intellij to the most recent version.","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"1. **Ensure Intellij JDK 11 is defined as an SDK**, as described [here](https://www.jetbrains.com/help/idea/sdk.html#set-up-jdk) -- this step is not needed if you have used JDK 11 in a previous Intellij project.","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"1. **Import the project _as a Gradle project_**, as described [here](https://se-education.org/guides/tutorials/intellijImportGradleProject.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"1. **Verify the set up**: After the importing is complete, locate the `src/main/java/seedu/duke/Duke.java` file, right-click it, and choose `Run Duke.main()`. If the setup is correct, you should see something like the below:","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" \u003e Task :compileJava","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":" \u003e Task :processResources NO-SOURCE","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":" \u003e Task :classes","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":" \u003e Task :Duke.main()","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":" Hello from","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" ____ _ ","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" | _ \\ _ _| | _____ ","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" | | | | | | | |/ / _ \\","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" | |_| | |_| | \u003c __/","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" |____/ \\__,_|_|\\_\\___|","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":25,"author":{"gitId":"-"},"content":" What is your name?","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"-"},"content":" ```","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" Type some word and press enter to let the execution proceed to the end.","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"## Build automation using Gradle","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"* This project uses Gradle for build automation and dependency management. It includes a basic build script as well (i.e. the `build.gradle` file).","lastModifiedDate":"2020-05-24"},{"lineNumber":32,"author":{"gitId":"-"},"content":"* If you are new to Gradle, refer to the [Gradle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/gradle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":34,"author":{"gitId":"-"},"content":"## Testing","lastModifiedDate":"2020-05-24"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"-"},"content":"### I/O redirection tests","lastModifiedDate":"2020-05-24"},{"lineNumber":37,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"* To run _I/O redirection_ tests (aka _Text UI tests_), navigate to the `text-ui-test` and run the `runtest(.bat/.sh)` script.","lastModifiedDate":"2020-05-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":40,"author":{"gitId":"-"},"content":"### JUnit tests","lastModifiedDate":"2020-05-24"},{"lineNumber":41,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":42,"author":{"gitId":"-"},"content":"* A skeleton JUnit test (`src/test/java/seedu/duke/DukeTest.java`) is provided with this project template. ","lastModifiedDate":"2020-05-24"},{"lineNumber":43,"author":{"gitId":"-"},"content":"* If you are new to JUnit, refer to the [JUnit Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/junit.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":45,"author":{"gitId":"-"},"content":"## Checkstyle","lastModifiedDate":"2020-05-24"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":47,"author":{"gitId":"-"},"content":"* A sample CheckStyle rule configuration is provided in this project.","lastModifiedDate":"2020-05-24"},{"lineNumber":48,"author":{"gitId":"-"},"content":"* If you are new to Checkstyle, refer to the [Checkstyle Tutorial at se-education.org/guides](https://se-education.org/guides/tutorials/checkstyle.html).","lastModifiedDate":"2020-05-24"},{"lineNumber":49,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":50,"author":{"gitId":"-"},"content":"## CI using GitHub Actions","lastModifiedDate":"2020-05-24"},{"lineNumber":51,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":52,"author":{"gitId":"-"},"content":"The project uses [GitHub actions](https://github.com/features/actions) for CI. When you push a commit to this repo or PR against it, GitHub actions will run automatically to build and verify the code as updated by the commit/PR.","lastModifiedDate":"2020-05-24"},{"lineNumber":53,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":54,"author":{"gitId":"-"},"content":"## Documentation","lastModifiedDate":"2020-05-24"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"-"},"content":"`/docs` folder contains a skeleton version of the project documentation.","lastModifiedDate":"2020-05-24"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"-"},"content":"Steps for publishing documentation to the public: ","lastModifiedDate":"2020-05-24"},{"lineNumber":59,"author":{"gitId":"-"},"content":"1. If you are using this project template for an individual project, go your fork on GitHub.\u003cbr\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":60,"author":{"gitId":"-"},"content":" If you are using this project template for a team project, go to the team fork on GitHub.","lastModifiedDate":"2020-05-24"},{"lineNumber":61,"author":{"gitId":"-"},"content":"1. Click on the `settings` tab.","lastModifiedDate":"2020-05-24"},{"lineNumber":62,"author":{"gitId":"-"},"content":"1. Scroll down to the `GitHub Pages` section.","lastModifiedDate":"2020-05-24"},{"lineNumber":63,"author":{"gitId":"-"},"content":"1. Set the `source` as `master branch /docs folder`.","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"-"},"content":"1. Optionally, use the `choose a theme` button to choose a theme for your documentation.","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"onx001":1,"-":63}},{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" mainClass.set(\"chessmaster.ChessMaster\")","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" archiveBaseName.set(\"chessmaster\")","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"compileJava.options.encoding \u003d \u0027UTF-8\u0027","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"tasks.withType(JavaCompile) {","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" options.encoding \u003d \u0027UTF-8\u0027","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"ken-ruster":1,"TongZhengHong":7,"-":45}},{"path":"build.xml","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"\u003cproject name\u003d\"ChessMaster\" basedir\u003d\".\" default\u003d\"main\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"src.dir\" value\u003d\"src/main/java\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"build.dir\" value\u003d\"build\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"classes.dir\" value\u003d\"${build.dir}/classes\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"jar.dir\" value\u003d\"${build.dir}/jar\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"main-class\" value\u003d\"chessmaster.ChessMaster\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"clean\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" \u003cdelete dir\u003d\"${build.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"compile\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" \u003cmkdir dir\u003d\"${classes.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" \u003cjavac includeantruntime\u003d\"false\" target\u003d\"11\" source\u003d\"11\" encoding\u003d\"utf8\" srcdir\u003d\"${src.dir}\" destdir\u003d\"${classes.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"jar\" depends\u003d\"compile\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" \u003cmkdir dir\u003d\"${jar.dir}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" \u003cjar destfile\u003d\"${jar.dir}/${ant.project.name}.jar\" basedir\u003d\"${classes.dir}\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" \u003cmanifest\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" \u003cattribute name\u003d\"Main-Class\" value\u003d\"${main-class}\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" \u003c/manifest\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" \u003c/jar\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"run\" depends\u003d\"jar\"\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" \u003cjava jar\u003d\"${jar.dir}/${ant.project.name}.jar\" fork\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" \u003c/target\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"clean-build\" depends\u003d\"clean,jar\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" \u003ctarget name\u003d\"main\" depends\u003d\"clean,run\"/\u003e","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"\u003c/project\u003e","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"TongZhengHong":35}},{"path":"config/checkstyle/checkstyle.xml","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"\u003c?xml version\u003d\"1.0\" encoding\u003d\"UTF-8\"?\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":2,"author":{"gitId":"-"},"content":"\u003c!DOCTYPE module PUBLIC","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":" \"-//Checkstyle//DTD Checkstyle Configuration 1.3//EN\"","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":" \"https://checkstyle.org/dtds/configuration_1_3.dtd\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"\u003c!--","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":" This configuration file enforces rules for the coding standard at","lastModifiedDate":"2022-05-29"},{"lineNumber":8,"author":{"gitId":"-"},"content":" https://se-education.org/guides/conventions/java/basic.html","lastModifiedDate":"2022-05-29"},{"lineNumber":9,"author":{"gitId":"-"},"content":"--\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":"\u003cmodule name\u003d\"Checker\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"FileTabCharacter\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":14,"author":{"gitId":"-"},"content":" \u003c!-- Checks that there are no tab characters in the file. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":15,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"NewlineAtEndOfFile\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":18,"author":{"gitId":"-"},"content":" \u003c!-- Accept LF, CR or CRLF to accomodate devs who prefer different line endings --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":19,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"lineSeparator\" value\u003d\"lf_cr_crlf\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":20,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":21,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":22,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"RegexpSingleline\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":23,"author":{"gitId":"-"},"content":" \u003c!-- Checks that FIXME is not used in comments. TODO is preferred. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":24,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"((//.*)|(\\*.*))FIXME\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":25,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"message\" value\u003d\u0027TODO is preferred to FIXME.\"\u0027 /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":26,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":27,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"SuppressionFilter\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":29,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"file\" value\u003d\"${config_loc}/suppressions.xml\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":30,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":32,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LineLength\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":33,"author":{"gitId":"-"},"content":" \u003c!-- Checks if a line is too long. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":34,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"max\" value\u003d\"120\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":35,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":36,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":37,"author":{"gitId":"-"},"content":" \u003c!-- All Java AST specific tests live under TreeWalker module. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":38,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"TreeWalker\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":40,"author":{"gitId":"-"},"content":" \u003c!-- Required to allow exceptions in code style --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":41,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"SuppressionCommentFilter\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"offCommentFormat\" value\u003d\"CHECKSTYLE.OFF\\: ([\\w\\|]+)\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"onCommentFormat\" value\u003d\"CHECKSTYLE.ON\\: ([\\w\\|]+)\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":44,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"checkFormat\" value\u003d\"$1\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":45,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":47,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":48,"author":{"gitId":"-"},"content":" IMPORT CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":49,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":50,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":51,"author":{"gitId":"-"},"content":" \u003c!-- Checks for redundant import statements.","lastModifiedDate":"2022-04-29"},{"lineNumber":52,"author":{"gitId":"-"},"content":" An import statement is redundant if:","lastModifiedDate":"2022-04-29"},{"lineNumber":53,"author":{"gitId":"-"},"content":" * It is a duplicate of another import. This is, when a class is imported more than once.","lastModifiedDate":"2022-04-29"},{"lineNumber":54,"author":{"gitId":"-"},"content":" * The class non-statically imported is from the java.lang package, e.g. importing java.lang.String.","lastModifiedDate":"2022-04-29"},{"lineNumber":55,"author":{"gitId":"-"},"content":" * The class non-statically imported is from the same package as the current package.","lastModifiedDate":"2022-04-29"},{"lineNumber":56,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":57,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"RedundantImport\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":58,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":59,"author":{"gitId":"-"},"content":" \u003c!-- Checks for unused import statements.","lastModifiedDate":"2022-04-29"},{"lineNumber":60,"author":{"gitId":"-"},"content":" An import statement is unused if:","lastModifiedDate":"2022-04-29"},{"lineNumber":61,"author":{"gitId":"-"},"content":" It\u0027s not referenced in the file.","lastModifiedDate":"2022-04-29"},{"lineNumber":62,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":63,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"UnusedImports\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":64,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":65,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"AvoidStarImport\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":66,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":67,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":68,"author":{"gitId":"-"},"content":" NAMING CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":69,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":70,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":71,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"PackageName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":72,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for package names against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":73,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z]+(\\.[a-z][a-z0-9]{1,})*$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":74,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":75,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":76,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":77,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"TypeName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":78,"author":{"gitId":"-"},"content":" \u003c!-- Validates static, final fields against the expression \"^[A-Z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":79,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"TypeName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":80,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":81,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":82,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":83,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ConstantName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":84,"author":{"gitId":"-"},"content":" \u003c!-- Validates non-private, static, final fields against the expression \"^[A-Z][A-Z0-9]*(_[A-Z0-9]+)*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":85,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"ConstantName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":86,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"applyToPrivate\" value\u003d\"false\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":87,"author":{"gitId":"-"},"content":" \u003cmessage key\u003d\"name.invalidPattern\"","lastModifiedDate":"2020-05-24"},{"lineNumber":88,"author":{"gitId":"-"},"content":" value\u003d\"Variable \u0027\u0027{0}\u0027\u0027 should be in ALL_CAPS (if it is a constant) or be private (otherwise).\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":89,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":90,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":91,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":92,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"StaticVariableName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":93,"author":{"gitId":"-"},"content":" \u003c!-- Validates static, non-final fields against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":94,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"StaticVariableName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":95,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z][a-zA-Z0-9]*_?$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":96,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":97,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":98,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":99,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MemberName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":100,"author":{"gitId":"-"},"content":" \u003c!-- Validates non-static members against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":101,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"MemberName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":102,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z][a-zA-Z0-9]*$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":103,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":104,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":105,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":106,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MethodName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":107,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for method names against the supplied expression. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":108,"author":{"gitId":"-"},"content":" \u003cmetadata name\u003d\"altname\" value\u003d\"MethodName\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":109,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"format\" value\u003d\"^[a-z][a-zA-Z0-9]*(_[a-z][a-zA-Z0-9]+){0,2}$\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":110,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":111,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":112,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ParameterName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":113,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for method parameters against the expression \"^[a-z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":114,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":115,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":116,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":117,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LocalFinalVariableName\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":118,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for local final variables against the expression \"^[a-z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":119,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":120,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":121,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":122,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LocalVariableName\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":123,"author":{"gitId":"-"},"content":" \u003c!-- Validates identifiers for local variables against the expression \"^[a-z][a-zA-Z0-9]*$\". --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":124,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":125,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":126,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":127,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":128,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":129,"author":{"gitId":"-"},"content":" LENGTH and CODING CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":130,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":131,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":132,"author":{"gitId":"-"},"content":" \u003c!-- Checks that array type declarations follow Java Style","lastModifiedDate":"2022-04-29"},{"lineNumber":133,"author":{"gitId":"-"},"content":" Java style: public static void main(String[] args) // Allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":134,"author":{"gitId":"-"},"content":" C style: public static void main(String args[]) // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":135,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":136,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ArrayTypeStyle\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":137,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":138,"author":{"gitId":"-"},"content":" \u003c!-- Checks if a catch block is empty and does not contain any comments. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":139,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"EmptyCatchBlock\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":140,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":141,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"LeftCurly\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":142,"author":{"gitId":"-"},"content":" \u003c!-- Checks for placement of the left curly brace (\u0027{\u0027). --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":143,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":144,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":145,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":146,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"RightCurly\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":147,"author":{"gitId":"-"},"content":" \u003c!-- Checks right curlies on CATCH, ELSE, and TRY blocks are on","lastModifiedDate":"2022-04-29"},{"lineNumber":148,"author":{"gitId":"-"},"content":" the same line. e.g., the following example is fine:","lastModifiedDate":"2022-04-29"},{"lineNumber":149,"author":{"gitId":"-"},"content":" \u003cpre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":150,"author":{"gitId":"-"},"content":" if {","lastModifiedDate":"2022-04-29"},{"lineNumber":151,"author":{"gitId":"-"},"content":" ...","lastModifiedDate":"2022-04-29"},{"lineNumber":152,"author":{"gitId":"-"},"content":" } else","lastModifiedDate":"2022-04-29"},{"lineNumber":153,"author":{"gitId":"-"},"content":" \u003c/pre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":154,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":155,"author":{"gitId":"-"},"content":" \u003c!-- This next example is not fine:","lastModifiedDate":"2022-04-29"},{"lineNumber":156,"author":{"gitId":"-"},"content":" \u003cpre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":157,"author":{"gitId":"-"},"content":" if {","lastModifiedDate":"2022-04-29"},{"lineNumber":158,"author":{"gitId":"-"},"content":" ...","lastModifiedDate":"2022-04-29"},{"lineNumber":159,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2022-04-29"},{"lineNumber":160,"author":{"gitId":"-"},"content":" else","lastModifiedDate":"2022-04-29"},{"lineNumber":161,"author":{"gitId":"-"},"content":" \u003c/pre\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":162,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":163,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"severity\" value\u003d\"warning\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":164,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":165,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":166,"author":{"gitId":"-"},"content":" \u003c!-- Checks for braces around loop blocks --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":167,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"NeedBraces\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":168,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":169,"author":{"gitId":"-"},"content":" if (true) return 1; // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":171,"author":{"gitId":"-"},"content":" if (true) { return 1; } // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":173,"author":{"gitId":"-"},"content":" else if {","lastModifiedDate":"2022-04-29"},{"lineNumber":174,"author":{"gitId":"-"},"content":" return 1; // else if should always be multi line","lastModifiedDate":"2022-04-29"},{"lineNumber":175,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2022-04-29"},{"lineNumber":176,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":177,"author":{"gitId":"-"},"content":" if (true)","lastModifiedDate":"2022-04-29"},{"lineNumber":178,"author":{"gitId":"-"},"content":" return 1; // Not allowed","lastModifiedDate":"2022-04-29"},{"lineNumber":179,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":180,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowEmptyLoopBody\" value\u003d\"true\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":181,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":182,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":183,"author":{"gitId":"-"},"content":" \u003c!-- Checks that each variable declaration is in its own statement and on its own line. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":184,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MultipleVariableDeclarations\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":185,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":186,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"OneStatementPerLine\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":187,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":188,"author":{"gitId":"-"},"content":" \u003c!-- Checks that long constants are defined with an upper ell.--\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":189,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"UpperEll\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":190,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":191,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"FallThrough\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":192,"author":{"gitId":"-"},"content":" \u003c!-- Warn about falling through to the next case statement. Similar to","lastModifiedDate":"2022-04-29"},{"lineNumber":193,"author":{"gitId":"-"},"content":" javac -Xlint:fallthrough, but the check is suppressed if a single-line comment","lastModifiedDate":"2022-04-29"},{"lineNumber":194,"author":{"gitId":"-"},"content":" on the last non-blank line preceding the fallen-into case contains \u0027fall through\u0027 (or","lastModifiedDate":"2022-04-29"},{"lineNumber":195,"author":{"gitId":"-"},"content":" some other variants which we don\u0027t publicized to promote consistency).","lastModifiedDate":"2022-04-29"},{"lineNumber":196,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":197,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"reliefPattern\"","lastModifiedDate":"2022-04-29"},{"lineNumber":198,"author":{"gitId":"-"},"content":" value\u003d\"fall through|Fall through|fallthru|Fallthru|falls through|Falls through|fallthrough|Fallthrough|No break|NO break|no break|continue on\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":199,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":200,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":201,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"MissingSwitchDefault\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":202,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":203,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":204,"author":{"gitId":"-"},"content":" ORDER CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":205,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":206,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":207,"author":{"gitId":"-"},"content":" \u003c!-- Checks that the order of at-clauses follows the tagOrder default property value order.","lastModifiedDate":"2022-04-29"},{"lineNumber":208,"author":{"gitId":"-"},"content":" @author, @version, @param, @return, @throws, @exception, @see, @since, @serial, @serialField, @serialData, @deprecated","lastModifiedDate":"2022-04-29"},{"lineNumber":209,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":210,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"AtclauseOrder\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":211,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":212,"author":{"gitId":"-"},"content":" \u003c!-- Checks if the Class and Interface declarations is organized in this order","lastModifiedDate":"2022-04-29"},{"lineNumber":213,"author":{"gitId":"-"},"content":" 1. Class (static) variables. Order: public, protected, package level (no access modifier), private.","lastModifiedDate":"2022-04-29"},{"lineNumber":214,"author":{"gitId":"-"},"content":" 2. Instance variables. Order: public, protected, package level (no access modifier), private.","lastModifiedDate":"2022-04-29"},{"lineNumber":215,"author":{"gitId":"-"},"content":" 3. Constructors","lastModifiedDate":"2022-04-29"},{"lineNumber":216,"author":{"gitId":"-"},"content":" 4. Methods","lastModifiedDate":"2022-04-29"},{"lineNumber":217,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":218,"author":{"gitId":"-"},"content":" \u003cmodule name \u003d\"DeclarationOrder\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":219,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":220,"author":{"gitId":"-"},"content":" \u003c!-- Checks that default is after all cases in a switch statement --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":221,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"DefaultComesLast\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":222,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":223,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"ModifierOrder\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":224,"author":{"gitId":"-"},"content":" \u003c!-- Warn if modifier order is inconsistent with JLS3 8.1.1, 8.3.1, and","lastModifiedDate":"2022-04-29"},{"lineNumber":225,"author":{"gitId":"-"},"content":" 8.4.3. The prescribed order is:","lastModifiedDate":"2022-04-29"},{"lineNumber":226,"author":{"gitId":"-"},"content":" public, protected, private, abstract, static, final, transient, volatile,","lastModifiedDate":"2022-04-29"},{"lineNumber":227,"author":{"gitId":"-"},"content":" synchronized, native, strictfp","lastModifiedDate":"2022-04-29"},{"lineNumber":228,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":229,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":230,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":231,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"OverloadMethodsDeclarationOrder\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":233,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":234,"author":{"gitId":"-"},"content":" WHITESPACE CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":235,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":236,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":237,"author":{"gitId":"-"},"content":" \u003c!-- Checks that comments are indented relative to their position in the code --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":238,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"CommentsIndentation\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":239,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":240,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"Indentation\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":241,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"caseIndent\" value\u003d\"0\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":242,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"throwsIndent\" value\u003d\"8\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":243,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":244,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" \u003cmodule name\u003d\"WhitespaceAround\"\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"allowEmptyLambdas\" value\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"allowEmptyTypes\" value\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" \u003cproperty name\u003d\"allowEmptyMethods\" value\u003d\"true\"/\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" \u003c/module\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":251,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"NoWhitespaceBeforeCaseDefaultColon\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":252,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":253,"author":{"gitId":"-"},"content":" \u003c!--","lastModifiedDate":"2022-04-29"},{"lineNumber":254,"author":{"gitId":"-"},"content":" JAVADOC CHECKS","lastModifiedDate":"2022-04-29"},{"lineNumber":255,"author":{"gitId":"-"},"content":" --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":256,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":257,"author":{"gitId":"-"},"content":" \u003c!-- Checks that all block-tags are ordered correctly. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":258,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"AtclauseOrder\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":259,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":260,"author":{"gitId":"-"},"content":" \u003c!-- Checks that Javadoc block tags appear only at the beginning of the line. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":261,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocBlockTagLocation\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":262,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":263,"author":{"gitId":"-"},"content":" \u003c!-- Checks that all Javadoc comments start from the second line. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":264,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocContentLocationCheck\" /\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":265,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":266,"author":{"gitId":"-"},"content":" \u003c!-- Checks that each line in Javadoc has leading asterisks. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":267,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocMissingLeadingAsterisk\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":268,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":269,"author":{"gitId":"-"},"content":" \u003c!-- Checks that each non-empty line in Javadoc has whitespace after leading asterisk. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":270,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocMissingWhitespaceAfterAsterisk\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":271,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":272,"author":{"gitId":"-"},"content":" \u003c!-- Checks that for block tags, indentation of continuation lines is at least 4 spaces. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":273,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocTagContinuationIndentation\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":274,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":275,"author":{"gitId":"-"},"content":" \u003c!-- Checks the Javadoc\u0027s format for every class, enumeration and interface. --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":276,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocType\"\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":277,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowMissingParamTags\" value\u003d\"true\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":278,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":279,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":280,"author":{"gitId":"-"},"content":" \u003c!-- Checks the Javadoc\u0027s format for every method (excluding getters, setters and constructors). --\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":281,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"JavadocMethod\"\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":282,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowedAnnotations\" value\u003d\"Override, Test, BeforeAll, BeforeEach, AfterAll, AfterEach, Subscribe\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":283,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"accessModifiers\" value\u003d\"public\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":284,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"validateThrows\" value\u003d\"false\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":285,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowMissingParamTags\" value\u003d\"true\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":286,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"allowMissingReturnTag\" value\u003d\"true\"/\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":287,"author":{"gitId":"-"},"content":" \u003cproperty name\u003d\"tokens\" value\u003d\"METHOD_DEF, ANNOTATION_FIELD_DEF\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":288,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":289,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":290,"author":{"gitId":"-"},"content":" \u003cmodule name\u003d\"InvalidJavadocPosition\"/\u003e","lastModifiedDate":"2022-04-29"},{"lineNumber":291,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2022-04-29"},{"lineNumber":292,"author":{"gitId":"-"},"content":" \u003c/module\u003e","lastModifiedDate":"2020-05-24"},{"lineNumber":293,"author":{"gitId":"-"},"content":"\u003c/module\u003e","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"TongZhengHong":6,"-":287}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"antrikshdhand"},"content":"| Name | ID | Github |","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"antrikshdhand"},"content":"|-----------------|-----------|---------------|","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"antrikshdhand"},"content":"| Antriksh Dhand | A0278458J | antrikshdhand |","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"antrikshdhand"},"content":"| Oh Ken Wei | A0251850J | ken-ruster |","lastModifiedDate":"2023-10-05"},{"lineNumber":7,"author":{"gitId":"antrikshdhand"},"content":"| Ou Ningxiang | A0249445W | onx001 |","lastModifiedDate":"2023-10-05"},{"lineNumber":8,"author":{"gitId":"antrikshdhand"},"content":"| Tong Zheng Hong | A0251819Y | TongZhengHong |","lastModifiedDate":"2023-10-05"},{"lineNumber":9,"author":{"gitId":"antrikshdhand"},"content":"| Tricia Boo Koh | A0264665U | TriciaBK |","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"antrikshdhand":7,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"## Design \u0026 implementation","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"![](images/OverallArchitecture.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"### Architecture","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"The Architecture Diagram given above explains the high-level design of the application. Given below is a quick overview of main components and how they interact with each other.","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"#### Main components of the architecture","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"`ChessMaster` is the main invocation of the application. It handles the loading of previous chess games from the storage file and running of the chess `Game` instance. ","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"The remaining logic is handled by the following components:","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"- **UI**: The User Interface of the application","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"- **Game**: Executes user commands in game and CPU moves","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"- **Storage**: Reads and write chess game information to the hard disk","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"- **ChessBoard**: Holds the current chess board state in memory","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"- **Parser**: Parses string representations into relevant classes (`Command`, `Move`, `ChessPiece`, etc)","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"Our application also uses other classes to store information about the chess game and provide utility functions for the main components to function. This include: `Command`, `Move`, `Coordinate`, `Color`, `Player`, `ChessTile` and `ChessPiece(s).`","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":"### ChessMaster component","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"\u003c!-- Here is a partial class diagram of ChessMaster. --\u003e","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"The sequence diagram below illustrates the interactions within the ChessMaster component, when they launch the program. ","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"![](images/ChessMasterSequence.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"How does ChessMaster component work:","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"1. Attempts to load previously stored game in storage","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"2. If previous game exists, asks the user if a new game or the previous game should be loaded. ","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"3. If a new game is selected, the user will be prompted for the color to start. ","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":"4. Start running the new or previous game instance. ","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"### Game component","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"The sequence diagram below illustrates the interactions within the Game component, taking a move of \"a2 a3\" as example.","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"![](images/GameSequence.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"How does the Game component work:","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"1. Solicits input from user. Users can provide game commands, if not recognised, it will parsed as a `MoveCommand`.","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"2. The returned command will be executed.","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"3. If user entered a game command (not MoveCommand), the next user input will be solicited.","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"4. If a MoveCommand is identified, the user\u0027s input will be parsed as a Move object with checks to ensure it is a valid move on the chessboard.","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"5. The user\u0027s validated Move will be executed on the chess board. This move will then be saved in the storage file.","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"6. Next, it will be the CPU\u0027s turn to play. The best move will be calculated by the CPU object and it will be executed on the chess board. This move will also be saved in the storage file.","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"7. Once both the user and CPU has made their moves, the game state will be checked where the number of kings on the board and the winner will be determined.","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"TriciaBK"},"content":"### Architecture","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"ken-ruster"},"content":"### User Input Handling - `Parser` and `Command`","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"ken-ruster"},"content":"Below is a class diagram representing the Command and Parser classes.","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"![](images/ParserCommandDiagram.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"ken-ruster"},"content":"In order to handle user input into the program during the game, the `Parser` class was implemented.","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"ken-ruster"},"content":"Below is a sequence diagram describing the process of handling user input passed from `Game`:","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"![](images/ParseCommandSequence.png)","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"ken-ruster"},"content":"`Parser` works to resolve a player\u0027s input in the following manner:","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"ken-ruster"},"content":"1. When `Parser` is called to parse a command, it returns the relevant `Command` object (More precisely,","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"ken-ruster"},"content":"one of its subclasses e.g. `MoveCommand`), which is then executed by `Game`.","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"ken-ruster"},"content":"2. Depending on the type of `Command` returned, the following may occur: ","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"ken-ruster"},"content":" 1. If it is a `MoveCommand`, the Command calls `parseMove` to instantiate the `Move`,","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"ken-ruster"},"content":" which is passed back to `Game` to be executed in the main logic.","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"ken-ruster"},"content":" 2. If it is a `ShowMovesCommand`, `parseAlgebraicCoor` is called to obtain the position of the piece as a ","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"ken-ruster"},"content":" `Coordinate` object. The available coordinates are printed using `showAvailableCoordinates`, then stored as a String","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"ken-ruster"},"content":" by `getAvailableCoordinatesString()`.","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"ken-ruster"},"content":"3. The result is then encapsulated in a `CommandResult` and returned to `Game` to be handled.","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"ken-ruster"},"content":"4. If the player made a move resulting in a promotion, `parsePromote` is called.","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"ken-ruster"},"content":"5. `Parser` calls `getColor` and `getPosition` to retrieve relevant data from the `ChessPiece` ","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"ken-ruster"},"content":"the player wants to promote.","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"ken-ruster"},"content":"6. The user\u0027s input is parsed and a new `ChessPiece` is returned.","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"ken-ruster"},"content":"`Parser` also contains methods to fulfil parsing needs in other parts of the program, for instance `parseChessPiece`, ","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"ken-ruster"},"content":"which is called while loading the .txt file containing save data, called for each character representing a ","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"ken-ruster"},"content":"singular chess piece. Using a Case statement, it returns the relevant `ChessPiece` object depending on the character","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"ken-ruster"},"content":"(representing the type of piece), and whether it is capitalised (representing colour).","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"ken-ruster"},"content":"How the parsing works:","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"ken-ruster"},"content":"- When called upon to parse a user command, the `Parser` class returns a relevant subclass of the `Command` class","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"ken-ruster"},"content":" (i.e. entering a valid command \"XYZ\" will cause `Parser` to return an `XYZCommand` object)","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"ken-ruster"},"content":"- Each `Command` subclass contains the relevant methods to execute the specified command","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"ken-ruster"},"content":"(AbortCommand, ShowCommand, etc.) and inherit from the abstract `Command` class.","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":"### Minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"The minimax algorithm is used to determine the best move for the AI to make. It is a recursive algorithm that works by alternatingly minimising opponent scores and maximising CPU scores. The algorithm is implemented in the `Minimax` class.","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":"![](images/MiniMaxSequenceDiagram.png)","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":"How the minimax algorithm works:","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":"1. The `Minimax` class is called by the `Game` class to determine the best move for the CPU to make.","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":"2. The `Minimax` class calls the `getPossibleMoves` method in the `ChessBoard` class to get all possible moves for the CPU.","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":"3. The `Minimax` class then calls the `getBestMove` method to determine the best move for the CPU to make by maximising CPU score and minimizing the player score.","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":"4. The `getBestMove` method calls the `getBestMove` method recursively to populate the child scores.","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":"5. The `getBestMove` method returns the best move for the CPU to make.","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TriciaBK"},"content":"### Storage Component","lastModifiedDate":"2023-10-27"},{"lineNumber":112,"author":{"gitId":"TriciaBK"},"content":"**API:**","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"TriciaBK"},"content":"Below is a class diagram representing the Storage class.","lastModifiedDate":"2023-10-27"},{"lineNumber":115,"author":{"gitId":"TriciaBK"},"content":"The Storage component is responsible for handling the storage and retrieval of chess game state.","lastModifiedDate":"2023-10-27"},{"lineNumber":116,"author":{"gitId":"TriciaBK"},"content":"![](images/StorageClass.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":117,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":118,"author":{"gitId":"TriciaBK"},"content":"![](images/StorageSequence.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":120,"author":{"gitId":"TriciaBK"},"content":"* Creates the necessary parent directories for the file and the file itself if they don\u0027t exist ","lastModifiedDate":"2023-10-27"},{"lineNumber":121,"author":{"gitId":"TriciaBK"},"content":"* Saves the current state of the ChessBoard to the file. It includes the player\u0027s color information and current player\u0027s turn as the first line and the state of the chessboard in an 8x8 format.","lastModifiedDate":"2023-10-27"},{"lineNumber":122,"author":{"gitId":"TriciaBK"},"content":"* Allows resetting the game by clearing the contents of the file.","lastModifiedDate":"2023-10-27"},{"lineNumber":123,"author":{"gitId":"TriciaBK"},"content":"* Loads the state of the chessboard from the file by constructing a 2D array of ChessTile objects.","lastModifiedDate":"2023-10-27"},{"lineNumber":124,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":125,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":126,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":127,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":128,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":129,"author":{"gitId":"TriciaBK"},"content":"1. Novice players trying to practice chess and play chess offline without a chess set. ","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"TriciaBK"},"content":"2. Time-poor users looking for a very simple, clean, gimmick-free chess application.","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":132,"author":{"gitId":"TriciaBK"},"content":"- Chess novices can use ChessMaster CLI to learn the game\u0027s rules and practice their skills.","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"TriciaBK"},"content":"- Busy students can open the application up in their terminal easily for a quick game of chess.","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"TriciaBK"},"content":"- The CLI interface is intuitive, making it easy for beginners to understand moves and strategies","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":136,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":137,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":138,"author":{"gitId":"-"},"content":"| Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2020-05-24"},{"lineNumber":139,"author":{"gitId":"TriciaBK"},"content":"|---------|------------|--------------------------------------------------------|--------------------------------------------------------|","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"-"},"content":"| v1.0 | new user | see usage instructions | refer to them when I forget how to use the application |","lastModifiedDate":"2020-05-24"},{"lineNumber":141,"author":{"gitId":"TriciaBK"},"content":"| v1.0 | player | do only valid moves | play chess properly |","lastModifiedDate":"2023-11-02"},{"lineNumber":142,"author":{"gitId":"TriciaBK"},"content":"| v1.0 | player | start a new game | play chess multiple times |","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"onx001"},"content":"| v1.0 | player | see the current state of the chess board on every turn | think about what move to play |","lastModifiedDate":"2023-10-26"},{"lineNumber":144,"author":{"gitId":"onx001"},"content":"| v1.0 | player | tell which symbol represents which piece | know what is where |","lastModifiedDate":"2023-10-26"},{"lineNumber":145,"author":{"gitId":"onx001"},"content":"| v1.0 | player | specify move coordinates | move the piece I want how I want it |","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"onx001"},"content":"| v1.0 | player | promote pieces when the option is available | play extended games properly |","lastModifiedDate":"2023-10-26"},{"lineNumber":147,"author":{"gitId":"onx001"},"content":"| v1.0 | player | have the option to abort the game | leave the game when I no longer want to play |","lastModifiedDate":"2023-10-26"},{"lineNumber":148,"author":{"gitId":"TriciaBK"},"content":"| v1.0 | player | save and get back to a game | leave when I am busy and resume a game when I am free |","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"TriciaBK"},"content":"| v2.0 | new player | see available moves for a piece | learn the rules of chess and valid moves |","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"TriciaBK"},"content":"| v2.0 | new player | refresh the rules of chess anytime | recap and learn the rules of chess |","lastModifiedDate":"2023-11-02"},{"lineNumber":151,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":"{more to be added}","lastModifiedDate":"2023-10-27"},{"lineNumber":153,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":157,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":158,"author":{"gitId":"TriciaBK"},"content":"1. Should work on any mainstream OS as long as it has Java 11 or above installed. ","lastModifiedDate":"2023-10-27"},{"lineNumber":159,"author":{"gitId":"TriciaBK"},"content":"2. A user with a basic understanding of chess should be able to navigate the game without difficulty. ","lastModifiedDate":"2023-10-27"},{"lineNumber":160,"author":{"gitId":"TriciaBK"},"content":"{More to be added}","lastModifiedDate":"2023-10-27"},{"lineNumber":161,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":162,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":163,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":164,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":165,"author":{"gitId":"-"},"content":"* *glossary item* - Definition","lastModifiedDate":"2020-05-24"},{"lineNumber":166,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":167,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":168,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":169,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"ken-ruster":34,"TriciaBK":31,"onx001":24,"TongZhengHong":50,"-":31}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"# ChessMaster","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"ChessMasterCLI is a command-line interface (CLI) chess game designed to make learning and training accessible for beginners while offering an engaging experience for all skill levels. This sleek and user-friendly chess simulator provides a platform for novice players to build their skills and understanding of the game.","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"For more information: ","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"ken-ruster":1,"TongZhengHong":2,"-":5}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"# ChessMaster User Guide","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"ChessMasterCLI is a command-line interface (CLI) chess game designed to make learning and training accessible for beginners while offering an engaging experience for all skill levels. This sleek and user-friendly chess simulator provides a platform for novice players to build their skills and understanding of the game.","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"- [Quick Start](#quick-start)","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"- [Starting a game](#starting-a-game)","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"- [Gameplay]()","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"- [Features](#features)","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" - Gameplay features","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" - [Make a move](#make-a-move)","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" - [Show available moves: `moves`](#show-available-moves-moves)","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" - [Show current chess board: `show`](#show-current-chess-board-show)","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" - Getting help","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" - [Show chess rules: `rules`](#show-chess-rules-rules)","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" - [Show commands: `help`](#show-commands-help)","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" - [Legend: `legend`](#view-pieces-representation-legend)","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" - [Aborting game: `abort`](#aborting-game-abort)","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"- [Command Summary](#command-summary)","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":22,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"1. Ensure you have **Java 11 or above** installed in your system.","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"2. Download the latest version of `ChessMaster.jar` from [here](https://github.com/AY2324S1-CS2113-T18-1/tp/releases).","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":"3. Open a terminal instance and navigate into the folder that contains the downloaded ChessMaster.jar file.","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"```bash","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"cd PATH_TO_JAR_FILE","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"4. Run the jar application with the following command:","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"```bash","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"java -jar ChessMaster.jar","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"You should be greeted by a welcome message from ChessMaster:","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"Hey there, chess geek! You have stumbled upon the one and only:","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" ________ __ ___ __","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" / ____/ /_ ___ __________ / |/ /___ ______/ /____ _____","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" / / / __ \\/ _ \\/ ___/ ___/ / /|_/ / __ `/ ___/ __/ _ \\/ ___/","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" / /___/ / / / __(__ |__ ) / / / / /_/ (__ ) /_/ __/ /","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" \\____/_/ /_/\\___/____/____/ /_/ /_/\\__,_/____/\\__/\\___/_/","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"where CHESS becomes an exciting journey of strategy and skill!","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"## Starting a game","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":"Upon launching the application, ChessMaster checks if there is a previous game in progress. If a previous game exists, you\u0027ll be presented with the option to continue from where you left off. Please enter `y` for **yes** and `n` for **no**.","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":"You have an ongoing previous chess game. Continue game? [y/n]","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":"However, if you prefer to **start a fresh game** or if **no previous game is found**, ChessMaster will prompt you to select your preferred color—whether it\u0027s \"White\" or \"Black.\" Please enter `b` for **black** and `w` for **white**.","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"Choose your starting color to start new game! [b/w]","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":"Next, you can choose the difficulty of the AI you will be pitched against! The current supported difficulty levels range from 1 to 4. Please enter the number corresponding to your preferred difficulty level.","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":"Choose your difficulty level! [1/2/3/4]","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":"Now, you\u0027ll be off to a rewarding journey of enhancing your chess skills and enjoying the timeless game of strategy and tactics with ChessMaster!","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":"## Gameplay","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":"The gameplay system of ChessMaster provides you with the flexibility to enter either a **command** or a **move** during your turn. ","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":"- If you opt for a **command**, the system will promptly solicit your next action, allowing you to access various [features](#features) seamlessly. However, when you decide to make a move, the system will evaluate your input for validity. ","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":"- Only when you enter a **valid move** will your turn be passed to the CPU, enabling it to respond with its strategic move. ","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":"Additionally, every time a move is executed, ChessMaster provides a comprehensive view of the chessboard, displaying the state of the game following the previous move.","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"\u003ctable\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":"\u003ctr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" \u003cth\u003eUser Move\u003c/th\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" \u003cth\u003eCPU move\u003c/th\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"\u003c/tr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":"\u003ctr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"\u003ctd\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":"\u003cpre\u003e\u003ccode\u003e","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":"d2 d4","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":"You moved Pawn from d2 to d4","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" (8) | R | N | B | Q | K | B | N | R | (8)","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" (7) | P | P | P | P | P | P | P | P | (7)","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" (6) | | | | | | | | | (6)","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" (5) | | | | | | | | | (5)","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" (4) | | | |(p)| | | | | (4)","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" (3) | | | | | | | | | (3)","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" (2) | p | p | p |( )| p | p | p | p | (2)","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" (1) | r | n | b | q | k | b | n | r | (1)","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":"\u003c/code\u003e\u003c/pre\u003e","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":"\u003c/td\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":"\u003ctd\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":"\u003cpre\u003e\u003ccode\u003e","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":"ChessMaster moved Pawn from e7 to e5","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"TongZhengHong"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"TongZhengHong"},"content":" (8) | R | N | B | Q | K | B | N | R | (8)","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"TongZhengHong"},"content":" (7) | P | P | P | P |( )| P | P | P | (7)","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"TongZhengHong"},"content":" (6) | | | | | | | | | (6)","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"TongZhengHong"},"content":" (5) | | | | |(P)| | | | (5)","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"TongZhengHong"},"content":" (4) | | | | p | | | | | (4)","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"TongZhengHong"},"content":" (3) | | | | | | | | | (3)","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"TongZhengHong"},"content":" (2) | p | p | p | | p | p | p | p | (2)","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"TongZhengHong"},"content":" (1) | r | n | b | q | k | b | n | r | (1)","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"TongZhengHong"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"TongZhengHong"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"TongZhengHong"},"content":"\u003c/code\u003e\u003c/pre\u003e","lastModifiedDate":"2023-11-04"},{"lineNumber":152,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"TongZhengHong"},"content":"\u003c/td\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"TongZhengHong"},"content":"\u003c/tr\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"TongZhengHong"},"content":"\u003c/table\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":157,"author":{"gitId":"ken-ruster"},"content":"## Ending the game","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"ken-ruster"},"content":"The game will automatically end and a victor be declared when one side has been checkmated (i.e. their king is in check, ","lastModifiedDate":"2023-11-01"},{"lineNumber":160,"author":{"gitId":"ken-ruster"},"content":"and there is no possible escape), or if their king has been captured.","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"-"},"content":"## Features ","lastModifiedDate":"2020-05-24"},{"lineNumber":163,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":"### Make a move","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"ken-ruster"},"content":"To make a move, simply enter the coordinate of the piece to be moved, followed by the coordinates it is to be moved to.","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"ken-ruster"},"content":"Format: `[column][row] [column][row]`","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"ken-ruster"},"content":"Examples: ","lastModifiedDate":"2023-11-01"},{"lineNumber":171,"author":{"gitId":"ken-ruster"},"content":"- `a2 a4`","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"ken-ruster"},"content":"- `b3 g6`","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"ken-ruster"},"content":"ChessMaster also automatically checks if the move was valid and legal before it is executed, and shows the following error","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"ken-ruster"},"content":"message in the case of an invalid move:","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"ken-ruster"},"content":"`Oops, that move isn\u0027t valid!`","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":"### Show available moves: `moves`","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"ken-ruster"},"content":"Shows the available moves for a piece on the board. This command can be used for both yours and the enemy\u0027s pieces.","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"ken-ruster"},"content":"Format: `moves [column][row]`","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":186,"author":{"gitId":"ken-ruster"},"content":"Example: ","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"ken-ruster"},"content":"moves e5","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"ken-ruster"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"ken-ruster"},"content":" (8) | R | N | B | Q | K | B | N | R | (8)","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"ken-ruster"},"content":" (7) | P | P | P |[ ]| |[P]| P | P | (7)","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"ken-ruster"},"content":" (6) | | |[ ]| P | | |[ ]| | (6)","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"ken-ruster"},"content":" (5) | | | | |{n}| | | | (5)","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"ken-ruster"},"content":" (4) | | |[ ]| | | |[ ]| | (4)","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"ken-ruster"},"content":" (3) | | | |[ ]| |[ ]| | | (3)","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"ken-ruster"},"content":" (2) | p | p | p | p | p | p | p | p | (2)","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"ken-ruster"},"content":" (1) | r | n | b | q | k | b | | r | (1)","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"ken-ruster"},"content":" _________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"ken-ruster"},"content":" (a) (b) (c) (d) (e) (f) (g) (h)","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"ken-ruster"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"ken-ruster"},"content":"Available coordinates for Knight at e5: ","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"ken-ruster"},"content":"f7 d7 f3 d3 g6 g4 c6 c4 ","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"ken-ruster"},"content":"_________________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"ken-ruster"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"TongZhengHong"},"content":"### Show current chess board: `show`","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"ken-ruster"},"content":"Shows the current state of the chess board.","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"ken-ruster"},"content":"Format: `show`","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"TongZhengHong"},"content":"### Show chess rules: `rules`","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"ken-ruster"},"content":"Obtain a quick refresher on the rules of chess","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"ken-ruster"},"content":"Format: `rules`","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"ken-ruster"},"content":"### Show commands: `help`","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"ken-ruster"},"content":"Show a list of commands and what they do","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"ken-ruster"},"content":"Format: `help`","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":234,"author":{"gitId":"TriciaBK"},"content":"### View pieces representation: `legend` ","lastModifiedDate":"2023-11-02"},{"lineNumber":235,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":236,"author":{"gitId":"TriciaBK"},"content":"Display a legend that explains the piece representations","lastModifiedDate":"2023-11-02"},{"lineNumber":237,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":238,"author":{"gitId":"TriciaBK"},"content":"Format: `legend`","lastModifiedDate":"2023-11-02"},{"lineNumber":239,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":240,"author":{"gitId":"ken-ruster"},"content":"### Saving and loading games","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":242,"author":{"gitId":"ken-ruster"},"content":"Every time a turn ends, ChessMaster will save the current state of the game. When ChessMaster is restarted, the","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"ken-ruster"},"content":"user will be prompted to choose whether to load the saved game or begin a new one. ChessMaster only supports a single","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"ken-ruster"},"content":"saved game, and starting a new one will delete the existing save file.","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":246,"author":{"gitId":"ken-ruster"},"content":"### Aborting game: `abort`","lastModifiedDate":"2023-11-01"},{"lineNumber":247,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":248,"author":{"gitId":"ken-ruster"},"content":"Exit the ChessMaster application.","lastModifiedDate":"2023-11-01"},{"lineNumber":249,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":250,"author":{"gitId":"ken-ruster"},"content":"Format: `abort`","lastModifiedDate":"2023-11-01"},{"lineNumber":251,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":252,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":253,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":254,"author":{"gitId":"-"},"content":"**Q**: How do I transfer my data to another computer? ","lastModifiedDate":"2020-05-24"},{"lineNumber":255,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":256,"author":{"gitId":"ken-ruster"},"content":"**A**: You can navigate to your root folder, and find the file `data/ChessMaster.txt`. Transfer the file to your other computer,","lastModifiedDate":"2023-11-01"},{"lineNumber":257,"author":{"gitId":"ken-ruster"},"content":"and find the `data` folder in the ChessMaster install folder in the other computer. Copy the file into the folder. Start ChessMaster,","lastModifiedDate":"2023-11-01"},{"lineNumber":258,"author":{"gitId":"ken-ruster"},"content":"and type `y` when prompted to load a saved game.","lastModifiedDate":"2023-11-01"},{"lineNumber":259,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":260,"author":{"gitId":"ken-ruster"},"content":"**Q**: How do I play with another person?","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"ken-ruster"},"content":"**A**: Currently, ChessMaster does not support multiplayer. ","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"ken-ruster"},"content":"**Q**: Can we play timed games?","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"ken-ruster"},"content":"**A**: ChessMaster does not come with an internal timer. However, you are able to use your own chess timer or stopwatch ","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"ken-ruster"},"content":"to simulate timed games.","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":269,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":270,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":271,"author":{"gitId":"TongZhengHong"},"content":"| Action | Format |","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"TriciaBK"},"content":"|---------------|-------------------------------|","lastModifiedDate":"2023-11-02"},{"lineNumber":273,"author":{"gitId":"ken-ruster"},"content":"| Move | `[column][row] [column][row]` |","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"ken-ruster"},"content":"| Show moves | `moves [column][row]` |","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"ken-ruster"},"content":"| Show board | `show` |","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"TriciaBK"},"content":"| Rules | `rules` |","lastModifiedDate":"2023-11-02"},{"lineNumber":277,"author":{"gitId":"ken-ruster"},"content":"| Help | `help` |","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"TriciaBK"},"content":"| Pieces legend | `legend` |","lastModifiedDate":"2023-11-02"},{"lineNumber":279,"author":{"gitId":"TongZhengHong"},"content":"| Abort | `abort` |","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"ken-ruster":81,"TriciaBK":9,"onx001":6,"TongZhengHong":151,"-":33}},{"path":"docs/diagrams/ChessMasterSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"@startuml ChessMasterSequence","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"actor User as user #BlanchedAlmond","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"participant \":UI\" as ui #IndianRed","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"participant \":ChessMaster\" as chessMaster #LightPink","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"participant \":Game\" as game #Orange","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"participant \":Storage\" as storage #DeepSkyBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"user -\u003e chessMaster : start","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"activate chessMaster","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -\u003e storage : loadBoard()","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"activate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"storage --\u003e chessMaster : prevBoard:ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"deactivate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"alt [. Previous board exists]","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" chessMaster -\u003e ui : shouldStartNewGame()","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"yes/no\"","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e chessMaster : :boolean","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" opt [startNewGame]","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" chessMaster -\u003e ui : chooseColor","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"black/white\"","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e chessMaster : playerColor:Color","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"else [. No previous board]","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" chessMaster -\u003e ui : chooseColor","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"black/white\"","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e chessMaster : playerColor:Color","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"create game","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"activate game","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -\u003e game : run()","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"game --\u003e chessMaster","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"destroy game","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"chessMaster --\u003e user","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"deactivate chessMaster","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TongZhengHong":56}},{"path":"docs/diagrams/GameSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"@startuml GameSequence","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"actor User as user #BlanchedAlmond","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"participant \":UI\" as ui #IndianRed","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"participant \":Parser\" as parser #LightPink","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"participant \":Game\" as game #Orchid","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"participant \":ChessBoard\" as board #Orange","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"participant \":CPU\" as cpu #SkyBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"participant \":Storage\" as storage #PaleTurquoise","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"activate game #AliceBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"loop [hasGameEnded]","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e ui : getUserCommand()","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" activate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" user -\u003e ui : \"a2 a3\"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" ui --\u003e game : :String","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" deactivate ui","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e parser : parseCommand(\"a2 a3\")","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" activate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" parser --\u003e game : :Command","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" deactivate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" opt [isMoveCommand]","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e parser : parseMove(\"a2 a3\")","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" activate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" parser --\u003e game : humanMove:Move","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" deactivate parser","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e board : executeMove(humanMove)","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" activate board","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" board --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" deactivate board","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e storage : saveBoard()","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" activate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" storage --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" deactivate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e cpu : getBestMove()","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" activate cpu","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" cpu --\u003e game : cpuMove:Move","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" deactivate cpu","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e board : executeMove(cpuMove)","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" activate board","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" board --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" deactivate board","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e storage : saveBoard()","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" activate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" storage --\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" deactivate storage","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" game -\u003e board : checkEndState()","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" activate board","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" board --\u003e game : hasGameEnded:bool","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" deactivate board","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"game --\u003e user","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"destroy game","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TongZhengHong":70}},{"path":"docs/diagrams/MiniMaxSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"@startuml MiniMaxSequenceDiagram","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"actor CPU as user #BlanchedAlmond","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"participant \":MiniMax\" as MM #IndianRed","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"participant \"Board :ChessBoard\" as CB #LightPink","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":"participant \":Move\" as M #Orange","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"participant \":BoardScoreTuple\" as BST #SkyBlue","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"participant \":ChessMasterException\" as E #PaleTurquoise","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":"create MM","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":"activate MM #AliceBlue","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":"user -\u003e MM : getBestMove()","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":"MM -\u003e MM : mostPoints()","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":"loop [\"depth \u003c maxDepth\"]","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" MM -\u003e CB : getBoard()","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" deactivate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" CB --\u003e MM : ChessBoard","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" activate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Initialize variables","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" MM -\u003e CB : getPoints()","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" deactivate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" CB --\u003e MM : points","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" activate MM","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" MM -\u003e CB : Clone board","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" CB --\u003e CB : board.clone()","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" activate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" CB -\u003e M** : setPiece()","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":" activate M","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"onx001"},"content":" M -\u003e CB : Execute move","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"onx001"},"content":" deactivate M","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":" CB -\u003e CB : Calculate new score","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" CB -\u003e BST** : Create BoardScoreTuple","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":" activate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":" BST --\u003e BST : BoardScoreTuple","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" deactivate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" CB -\u003e E : Handle exception (if any)","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" CB -\u003e MM : Continue loop","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" deactivate CB","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" loop [\"depth \u003c maxDepth\"]","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" activate MM","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Recursively call mostPoints() while incrementing depth","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" MM --\u003e MM : bestTuple","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" deactivate MM","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" end","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Update bestScore based on player turn","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" MM -\u003e MM : Update bestTuple with bestScore and bestMove","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"onx001"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":"MM -\u003e BST : getBestMove()","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":"activate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"onx001"},"content":"BST --\u003e MM : bestMove","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"onx001"},"content":"deactivate BST","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":"MM -\u003e user : Return bestMove","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":"deactivate MM","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":"destroy MM","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":"destroy CB","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":"destroy M","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":"destroy BST","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"onx001":75}},{"path":"docs/diagrams/OverallArchitecture.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"@startuml OverallArchitecture","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"rectangle ChessMaster as chessMaster #LightPink","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"rectangle Parser as parser #AliceBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"rectangle Game as game #Orchid","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"rectangle UI as ui #IndianRed","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"rectangle Storage as storage #SkyBlue","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"rectangle ChessBoard as board #Orange","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"actor User as user #BlanchedAlmond","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"user -d-\u003e ui","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -r-\u003e ui","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -d-\u003e game","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -u-\u003e storage","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"chessMaster -u-\u003e board","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"game -\u003e storage","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"game -u-\u003e board","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"game -u-\u003e ui","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"storage .up.\u003e board","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TongZhengHong":24}},{"path":"docs/diagrams/ParseCommandSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"participant \":Game\" as Game","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"participant \":Parser\" as Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"participant \":Command\" as Command","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"participant \":CommandResult\" as CommandResult","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"participant \"coord:Coordinate\" as Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"participant \"board:ChessBoard\" as ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"participant \"promoteFrom: ChessPiece\" as ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":"Game -\u003e Parser: parseCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"activate Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":"create Command","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":"Parser -\u003e Command ++","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":"Command --\u003e Parser --: Command","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":"Game \u003c-- Parser --: Command","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":"Game -\u003e Command ++: execute","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":"alt MoveCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e Parser ++: parseMove","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" Parser --\u003e Command --: Move","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":"else ShowMoveCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" create Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e Coordinate ++: parseAlgebraicCoor","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" Coordinate --\u003e Command --: coord","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e ChessBoard ++: showAvailableCoordinates","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" ChessBoard --","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" Command -\u003e ChessBoard ++: getAvailableCoordinatesString","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" ChessBoard --\u003e Command --: String","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" destroy Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":"Command -\u003e CommandResult**","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":"activate CommandResult","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":"CommandResult --\u003e Command--","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":"Game \u003c-- Command --: CommandResult","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":"opt canPromote","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":"Game -\u003e Parser ++: parsePromote","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"Parser -\u003e ChessPiece ++: getColour","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":"ChessPiece --\u003e Parser --: Color","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"Parser -\u003e ChessPiece ++: getPosition","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":"ChessPiece --\u003e Parser --: Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":"Game \u003c-- Parser --: ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"ken-ruster":48}},{"path":"docs/diagrams/ParserCommandDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"\u0027https://plantuml.com/class-diagram","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"package command{","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":" abstract class Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":" +execute()","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":" +isMoveCommand()","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":" class MoveCommand {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":" -userInput: String","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":" -move: Move","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":" +getMove(): Move","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":" class ShowMovesCommand {","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" -userInput: String","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" -piece: ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" +getPiece(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" class XYZCommand","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":" note top: Includes subclasses AbortCommand, HelpCommand, etc.","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" XYZCommand -|\u003e Command","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" ShowMovesCommand --|\u003e Command","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" MoveCommand --|\u003e Command","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":"package parser{","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" class Parser {","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" +{static} parsePromote(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" +{static} parseMove(): Move","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" +{static} parseChessPiece(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" +{static} parseCommand(): Command","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" +{static} parsePlayerColor(): Color","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":"class Storage","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":"class Game","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":"class Human","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":"command.MoveCommand ..\u003e parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":"command.ShowMovesCommand ..\u003e parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"command.XYZCommand ..\u003e parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"Game \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":"Storage \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":"Human \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":"ChessBoard \u003c... parser.Parser","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"ken-ruster":47}},{"path":"docs/diagrams/StorageClass.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"class Storage {","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":" - filePathString: String","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":" + Storage(filePath: String)","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":" + saveBoard(board: ChessBoard, playerColor: Color): void","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":" + resetBoard(): void","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":" + loadBoard(): ChessTile[][]","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" + loadPlayerColor(): Color","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":" - createChessMasterFile(): void","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"class ChessBoard {","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" - SIZE: int","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":"class ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":"class Color","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e File","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":"Storage --|\u003e Color","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TriciaBK":26}},{"path":"docs/diagrams/StorageSequence.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"@startuml","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"actor User","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"participant \":Storage\" as Storage","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"participant \":File\" as File","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"participant \":FileWriter\" as FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"participant \":Scanner\" as Scanner","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"participant \":ChessTile\" as ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"participant \":String\" as String","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"create Storage","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : new Storage(): String","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"create File","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e File++ : new File()","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"File --\u003e Storage-- : storageFile:File","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e File++ : exists()","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":"File --\u003e Storage-- : boolean","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":"alt File: !exists()","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" File -\u003e File++ : createParentDirectories()","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" File --\u003e File--","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" File -\u003e File++ : createNewFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" File --\u003e File--","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : saveBoard(): ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":"create FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++ : new FileWriter(): File","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage-- : fileWriter: FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++: fileWriter.write(): playerColor.name()","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e ChessBoard++ : getPlayerColor()","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"TriciaBK"},"content":"ChessBoard --\u003e FileWriter-- : Color","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e FileWriter++ : write(): Color","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e FileWriter++ : fileWriter.write(): System.lineSeparator()","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"TriciaBK"},"content":"loop for row from 0 to ChessBoard.SIZE-1","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"TriciaBK"},"content":" alt row loop","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"TriciaBK"},"content":" FileWriter -\u003e FileWriter++ : .write(): System.lineSeparator()","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"TriciaBK"},"content":" FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"TriciaBK"},"content":" loop for col from 0 to ChessBoard.SIZE-1","lastModifiedDate":"2023-10-27"},{"lineNumber":52,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e ChessBoard++ : getPieceAtCoor(): Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":53,"author":{"gitId":"TriciaBK"},"content":" create Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":54,"author":{"gitId":"TriciaBK"},"content":" ChessBoard -\u003e Coordinate++","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"TriciaBK"},"content":" Coordinate --\u003e ChessBoard-- : Coordinate","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"TriciaBK"},"content":" ChessBoard --\u003e Storage-- : piece","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"TriciaBK"},"content":" FileWriter -\u003e FileWriter++ : write(): ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"TriciaBK"},"content":" FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"TriciaBK"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"TriciaBK"},"content":" end","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"TriciaBK"},"content":"FileWriter -\u003e FileWriter++ : close()","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e FileWriter--","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : resetBoard(): ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"TriciaBK"},"content":"create FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++ : new FileWriter(): File","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage-- : fileWriter: FileWriter","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++: .write(): String","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e FileWriter++: .close()","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"TriciaBK"},"content":"FileWriter --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User--","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"TriciaBK"},"content":"User -\u003e Storage++ : loadBoard(): ChessBoard","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage++ : createChessMasterFile()","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"TriciaBK"},"content":"create Scanner","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Scanner++ : new Scanner(): File","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"TriciaBK"},"content":"Scanner --\u003e Storage-- : fileScanner: Scanner","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"TriciaBK"},"content":"alt FileScanner: hasNext()","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Scanner++: nextLine()","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"TriciaBK"},"content":" Scanner --\u003e Storage --","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Storage: Initialize rowIndex, boardTiles","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"TriciaBK"},"content":"create ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e ChessTile++","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"TriciaBK"},"content":"ChessTile --\u003e Storage-- : boardTiles: ChessTile[][]","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"TriciaBK"},"content":"loop (rowIndex \u003c ChessBoard.SIZE \u0026\u0026 fileScanner.hasNext())","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Scanner++ : nextLine()","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"TriciaBK"},"content":" Scanner --\u003e Storage-- : chessRowLine: String","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"TriciaBK"},"content":" alt chessRowLine.length() !\u003d ChessBoard.SIZE","lastModifiedDate":"2023-10-27"},{"lineNumber":99,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Scanner++: close()","lastModifiedDate":"2023-10-27"},{"lineNumber":100,"author":{"gitId":"TriciaBK"},"content":" Scanner --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"TriciaBK"},"content":" end alt","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"TriciaBK"},"content":" loop for col from 0 to ChessBoard.SIZE-1","lastModifiedDate":"2023-10-27"},{"lineNumber":103,"author":{"gitId":"TriciaBK"},"content":" create String","lastModifiedDate":"2023-10-27"},{"lineNumber":104,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e String++ : valueOf(): chessRowLine.charAt(col)","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"TriciaBK"},"content":" String --\u003e Storage-- : chessPieceString: String","lastModifiedDate":"2023-10-27"},{"lineNumber":106,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e Parser++ : chessPieceString","lastModifiedDate":"2023-10-27"},{"lineNumber":107,"author":{"gitId":"TriciaBK"},"content":" Parser --\u003e Storage -- : initialPiece: ChessPiece","lastModifiedDate":"2023-10-27"},{"lineNumber":108,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":109,"author":{"gitId":"TriciaBK"},"content":" create ChessTile","lastModifiedDate":"2023-10-27"},{"lineNumber":110,"author":{"gitId":"TriciaBK"},"content":" Storage -\u003e ChessTile++","lastModifiedDate":"2023-10-27"},{"lineNumber":111,"author":{"gitId":"TriciaBK"},"content":" ChessTile --\u003e Storage-- : boardTiles: ChessTile[][]","lastModifiedDate":"2023-10-27"},{"lineNumber":112,"author":{"gitId":"TriciaBK"},"content":" end loop","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"TriciaBK"},"content":"end","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"TriciaBK"},"content":"Storage -\u003e Scanner++: close","lastModifiedDate":"2023-10-27"},{"lineNumber":115,"author":{"gitId":"TriciaBK"},"content":"Scanner --\u003e Storage--","lastModifiedDate":"2023-10-27"},{"lineNumber":116,"author":{"gitId":"TriciaBK"},"content":"Storage --\u003e User: boardTiles","lastModifiedDate":"2023-10-27"},{"lineNumber":117,"author":{"gitId":"TriciaBK"},"content":"@enduml","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"TriciaBK":117}},{"path":"src/main/java/chessmaster/ChessMaster.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster;","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Game;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.storage.Storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"/**","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" * Main entry-point for ChessMaster application.","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"public class ChessMaster {","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private static final String FILE_PATH_STRING \u003d \"data/ChessMaster.txt\";","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" private TextUI ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" private ChessBoard board;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" private Storage storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" private int difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" private Color playerColor;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" private Color currentTurnColor \u003d Color.WHITE;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" private ChessMaster() {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" ui \u003d new TextUI();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" storage \u003d new Storage(FILE_PATH_STRING);","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" ui.printWelcomeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" playerColor \u003d storage.loadPlayerColor();","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" difficulty \u003d storage.loadDifficulty();","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" currentTurnColor \u003d storage.loadCurrentColor();","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[][] existingBoard \u003d storage.loadBoard();","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" board \u003d new ChessBoard(playerColor, existingBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" board.setDifficulty(difficulty);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" if (shouldStartNewGame()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" loadNewGame();","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" } catch (ChessMasterException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" ui.printLoadBoardError();","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" loadNewGame();","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" private boolean shouldStartNewGame() {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" ui.promptContinuePrevGame(false);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" String input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" while (!input.equals(\"y\") \u0026\u0026 !input.equals(\"n\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" ui.promptContinuePrevGame(true);","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" if (input.equals(\"y\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" ui.printContinuePrevGame(playerColor.name());","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" return true;","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" private void loadNewGame() {","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" ui.promptStartingColor(false);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" String input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" while (!input.equals(\"b\") \u0026\u0026 !input.equals(\"w\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" ui.promptStartingColor(true);","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" playerColor \u003d input.equals(\"b\") ? Color.BLACK : Color.WHITE;","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" board \u003d new ChessBoard(playerColor);","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" ui.printStartNewGame(playerColor.name());","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":" ui.promptDifficulty(false);","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" while (!input.equals(\"1\") \u0026\u0026 !input.equals(\"2\") ","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" \u0026\u0026 !input.equals(\"3\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" ui.promptDifficulty(true);","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" input \u003d ui.getUserInput();","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" difficulty \u003d Integer.parseInt(input);","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" board.setDifficulty(difficulty);","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":" currentTurnColor \u003d Color.WHITE;","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" private void run() { ","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" Game game \u003d new Game(playerColor, currentTurnColor, board, storage, ui, difficulty);","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" game.run();","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" public static void main(String[] args) {","lastModifiedDate":"2019-07-29"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":" new ChessMaster().run();","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"onx001":22,"TongZhengHong":80}},{"path":"src/main/java/chessmaster/commands/AbortCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class AbortCommand extends Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String ABORT_COMAMND_STRING \u003d \"abort\";","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" private static final String ABORT_MESSAGE \u003d \"Exiting program... Thanks for playing!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" return new CommandResult(ABORT_MESSAGE);","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" public static boolean isAbortCommand(Command command) {","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" return command instanceof AbortCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":22}},{"path":"src/main/java/chessmaster/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public abstract CommandResult execute(ChessBoard board, TextUI ui) throws ChessMasterException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public boolean isMoveCommand() {","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof MoveCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/commands/CommandResult.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"/**","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" * Represents the result of a command execution.","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class CommandResult {","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" * The feedback message to be shown to the user. Contains a description of the","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" * execution result","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" private final String[] message;","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" public CommandResult(String... message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" this.message \u003d message;","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public String[] getMessageStrings() {","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" return this.message;","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"TongZhengHong":23}},{"path":"src/main/java/chessmaster/commands/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" public static final String HELP_COMAMND_STRING \u003d \"help\";","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":" private static final String[] HELP_STRINGS \u003d { ","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":" \"Seems like you need some help!\",","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":" \"Here are the following commands to play:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" \"Move piece - Input coordinate of piece, followed by coordinate to move to\",","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" \" Format: [column][row] [column][row]\",","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":" \" E.g. a2 a3\",","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" \"Show available moves - Lists all the available moves for a piece\",","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" \" Format: moves [column][row]\",","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" \" E.g. moves a2\",","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":" \"Show board - Shows the current state of the chess board\",","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" \" Format: show\",","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" \"Obtain rules - Obtain a quick refresher on the rules of chess\",","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" \" Format: rules\",","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" \"View pieces representation - Display a legend that explains the piece representations\",","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" \" Format: legend\",","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" \"Abort game - Exit programme\",","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" \" Format: abort\",","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult(HELP_STRINGS);","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TriciaBK":36}},{"path":"src/main/java/chessmaster/commands/LegendCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Bishop;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Knight;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Rook;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"public class LegendCommand extends Command {","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" public static final String LEGEND_COMMAND_STRING \u003d \"legend\";","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" private static final String[] LEGEND_STRINGS \u003d {","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" \"Black pieces:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black rook.\", Rook.ROOK_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black knight.\", Knight.KNIGHT_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black bishop.\", Bishop.BISHOP_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black queen.\", Queen.QUEEN_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black king.\", King.KING_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a black pawn.\", Pawn.PAWN_BLACK),","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" \" \",","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" \"White pieces:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white rook.\", Rook.ROOK_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white knight.\", Knight.KNIGHT_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white bishop.\", Bishop.BISHOP_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white queen.\", Queen.QUEEN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white king.\", King.KING_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" String.format(\"\\\"%s\\\" represents a white pawn.\", Pawn.PAWN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" };","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult(LEGEND_STRINGS);","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"TriciaBK":40}},{"path":"src/main/java/chessmaster/commands/MoveCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.InvalidMoveException;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"public class MoveCommand extends Command {","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final String MOVE_COMAMND_STRING \u003d \"move\";","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" private static final String MOVE_PIECE_MESSAGE \u003d \"You moved %s from %s to %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" private String userInput;","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private Move move;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public MoveCommand(String inputString) {","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" this.userInput \u003d inputString;","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" * Executes the command based on user input, which is expected to consist of two","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" * algebraic coordinate strings separated by whitespace.","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" * @return A CommandResult object containing the result of the command.","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" * @throws ChessMasterException If the user input cannot be parsed into two","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" * coordinate objects.","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) throws ChessMasterException {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" move \u003d Parser.parseMove(userInput, board);","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" if (!move.isValid(board)) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" throw new InvalidMoveException();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" String pieceString \u003d move.getPiece().getClass().getSimpleName();","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" String displayString \u003d String.format(MOVE_PIECE_MESSAGE, pieceString, move.getFrom(), move.getTo());","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" return new CommandResult(displayString);","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" public Move getMove() throws InvalidMoveException {","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" if (move \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" throw new InvalidMoveException();","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" return move;","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":50}},{"path":"src/main/java/chessmaster/commands/RulesCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Bishop;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Knight;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.Rook;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"public class RulesCommand extends Command {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" public static final String RULES_COMAMND_STRING \u003d \"rules\";","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" private static final String[] RULES_STRINGS \u003d {","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" \"Here are simple chess rules to get you started:\",","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":" \"Piece movement:\",","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Pawn (\\\"%s\\\") move forward one square but capture diagonally.\", Pawn.PAWN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Rooks (\\\"%s\\\") move horizontally and vertically any number of squares.\", Rook.ROOK_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Knights (\\\"%s\\\") move in an L-shape.\", Knight.KNIGHT_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Bishops (\\\"%s\\\") move diagonally any number of squares.\", Bishop.BISHOP_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Queens (\\\"%s\\\") move any number of squares in any direction.\", Queen.QUEEN_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" String.format(\" Kings (\\\"%s\\\") move one square in any direction.\", King.KING_WHITE),","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":" \"Special Rules:\",","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":" \" Castling - King and rook move simultaneously to safeguard the king.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":" \" En Passant - Pawn capturing when moving two squares from starting position.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" \" Pawn Promotion - Promote a pawn to another piece (except king) upon reaching the back rank.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" \"Objective:\",","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":" \" Game ends when one player\u0027s king is in checkmate, under attack and can\u0027t escape capture.\",","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":" \" The delivering player wins the game.\"","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"TriciaBK"},"content":" };","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult(RULES_STRINGS);","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"TriciaBK":44}},{"path":"src/main/java/chessmaster/commands/ShowCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"public class ShowCommand extends Command {","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" public static final String SHOW_COMAMND_STRING \u003d \"show\";","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":" private static final String SHOW_STRING \u003d \"Here is the current board state:\";","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":" ui.printText(SHOW_STRING);","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":" return new CommandResult();","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"TriciaBK":20}},{"path":"src/main/java/chessmaster/commands/ShowMovesCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"//@@author ken-ruster","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.commands;","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.NullPieceException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":"public class ShowMovesCommand extends Command {","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":" public static final String SHOW_MOVES_COMMAND_STRING \u003d \"moves\";","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" public static final String NO_COORDINATE_FOUND_STRING \u003d ","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" \"Oops! Looks like you forgot to specify a coordinate!\";","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" public static final String SHOW_MOVES_FORMAT_STRING \u003d \"Format: moves [column][row]\";","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" public static final String SHOW_MOVES_EXAMPLE_STRING \u003d \"Example: moves a2\";","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":" private String userInput;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":" private ChessPiece piece;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" public ShowMovesCommand(String userInput) {","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" this.userInput \u003d userInput;","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" public CommandResult execute(ChessBoard board, TextUI ui) throws ChessMasterException {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" if (userInput.isBlank()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" return new CommandResult(NO_COORDINATE_FOUND_STRING, ","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" SHOW_MOVES_FORMAT_STRING, SHOW_MOVES_EXAMPLE_STRING);","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" Coordinate coord \u003d Coordinate.parseAlgebraicCoor(userInput);","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":" piece \u003d board.getPieceAtCoor(coord);","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":" if (piece.isEmptyPiece()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" throw new NullPieceException();","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":" Coordinate[] possibleCoordinates \u003d piece.getFlattenedCoordinates(board);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" ui.printChessBoardAvailableMoves(board.getBoard(), piece, possibleCoordinates);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":" String[] displayString \u003d piece.getAvailableCoordinatesString(board);","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" return new CommandResult(displayString);","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" public ChessPiece getPiece() {","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":" return this.piece;","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"ken-ruster":49}},{"path":"src/main/java/chessmaster/exceptions/ChessMasterException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"public class ChessMasterException extends Exception {","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" public ChessMasterException(String message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"TongZhengHong":8}},{"path":"src/main/java/chessmaster/exceptions/InvalidMoveException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class InvalidMoveException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public InvalidMoveException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_INVALID_MOVE_EXCEPTION);","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public InvalidMoveException(String message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/LoadBoardException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"public class LoadBoardException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":" public LoadBoardException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" super(ExceptionMessages.MESSAGE_LOAD_BOARD_EXCEPTION);","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":" public LoadBoardException(String message) {","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":" super(message);","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"TriciaBK":17}},{"path":"src/main/java/chessmaster/exceptions/MoveOpponentPieceException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class MoveOpponentPieceException extends ChessMasterException {","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public MoveOpponentPieceException() {","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_MOVE_OPPONENT_EXCEPTION);","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public MoveOpponentPieceException(String message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/NullPieceException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class NullPieceException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public NullPieceException() {","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_NULL_PIECE_EXCEPTION);","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public NullPieceException(String message) {","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/ParseChessPieceException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ParseChessPieceException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public ParseChessPieceException() {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_PARSE_CHESS_PIECE_EXCEPTION);","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public ParseChessPieceException(String message) {","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"TongZhengHong":16}},{"path":"src/main/java/chessmaster/exceptions/ParseColorException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ParseColorException extends ChessMasterException {","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public ParseColorException() {","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_PARSE_COLOR_EXCEPTION);","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public ParseColorException(String message) {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"TongZhengHong":14}},{"path":"src/main/java/chessmaster/exceptions/ParseCoordinateException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ParseCoordinateException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public ParseCoordinateException() {","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" super(ExceptionMessages.MESSAGE_PARSE_COORDINATE_EXCEPTION);","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public ParseCoordinateException(String message) {","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" super(message);","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"TongZhengHong":16}},{"path":"src/main/java/chessmaster/exceptions/SaveBoardException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"//@@author TriciaBK","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.exceptions;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.ui.ExceptionMessages;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"public class SaveBoardException extends ChessMasterException {","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":" public SaveBoardException() {","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":" super(ExceptionMessages.MESSAGE_SAVE_BOARD_EXCEPTION);","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":" public SaveBoardException(String message) {","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":" super(message);","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"TriciaBK":17}},{"path":"src/main/java/chessmaster/game/BoardScoreTuple.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"public class BoardScoreTuple implements Comparable\u003cBoardScoreTuple\u003e {","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":" private ChessBoard board;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":" private int score;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":" private Move move;","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":" public BoardScoreTuple(ChessBoard board, int score, Move move) {","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" this.board \u003d board;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" this.score \u003d score;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" this.move \u003d move;","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" public ChessBoard getBoard() {","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" return board;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" public int getScore() {","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" return score;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" public Move getMove() {","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" return move;","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" public int compareTo(BoardScoreTuple tuple) {","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" if (this.score \u003e tuple.getScore()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" return 1;","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" } else if (this.score \u003c tuple.getScore()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" return -1;","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" return 0;","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"onx001":37}},{"path":"src/main/java/chessmaster/game/ChessBoard.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.InvalidMoveException;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"public class ChessBoard {","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public static final int SIZE \u003d 8;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int TOP_ROW_INDEX \u003d 0;","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public static final int BOTTOM_ROW_INDEX \u003d 7;","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" public static final int MAX_PIECES \u003d 16;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private static final String[][] STARTING_CHESSBOARD_BLACK \u003d { ","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" { \"r\", \"n\", \"b\", \"q\", \"k\", \"b\", \"n\", \"r\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" { \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" { \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" { \"R\", \"N\", \"B\", \"Q\", \"K\", \"B\", \"N\", \"R\" }, ","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" private static final String[][] STARTING_CHESSBOARD_WHITE \u003d { ","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" { \"R\", \"N\", \"B\", \"Q\", \"K\", \"B\", \"N\", \"R\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" { \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\" },","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" { \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\" },","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" { \"r\", \"n\", \"b\", \"q\", \"k\", \"b\", \"n\", \"r\" }, ","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-22"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" private Color playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" private boolean isWhiteKingAlive \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" private boolean isBlackKingAlive \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" private int difficulty \u003d 4;","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"antrikshdhand"},"content":" private final ChessTile[][] board \u003d new ChessTile[SIZE][SIZE];","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" public ChessBoard(Color playerColor) {","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" this.playerColor \u003d playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c SIZE; row++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c SIZE; col++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" String chessPieceString \u003d playerColor.isBlack()","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" ? STARTING_CHESSBOARD_BLACK[row][col]","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" : STARTING_CHESSBOARD_WHITE[row][col];","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece initialPiece \u003d Parser.parseChessPiece(chessPieceString, row, col);","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" board[row][col] \u003d new ChessTile(initialPiece);","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"ken-ruster"},"content":" assert (board[row][col] !\u003d null);","lastModifiedDate":"2023-10-20"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" this.playerColor \u003d playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" public ChessBoard(Color playerColor, ChessTile[][] boardTiles) {","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" this.playerColor \u003d playerColor;","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c SIZE; row++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c SIZE; col++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" board[row][col] \u003d boardTiles[row][col];","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" * Gets a copy of the current chessboard as a 2D array of ChessTile objects.","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" * This method creates a deep copy of the chessboard, allowing for the independent","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" * examination of the board\u0027s state without modifying the original chessboard.","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" * @return A 2D array copy of ChessTile objects representing the current state of the chessboard.","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" public ChessTile[][] getBoard() {","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[][] copy \u003d new ChessTile[SIZE][SIZE];","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c SIZE; i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" copy[i] \u003d board[i].clone();","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" return copy;","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" public Color getPlayerColor() {","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" return this.playerColor;","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" public void setDifficulty(int difficulty) {","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" this.difficulty \u003d difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" public int getDifficulty() {","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":" return this.difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" public boolean isChecked() {","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":" Move[] moves \u003d getAllMoves(playerColor.getOppositeColour());","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":" for (Move move : moves) {","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":" Coordinate to \u003d move.getTo();","lastModifiedDate":"2023-11-03"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":" if (this.getPieceAtCoor(to) instanceof King) {","lastModifiedDate":"2023-11-03"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"onx001"},"content":" public boolean isCheckmated() {","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"onx001"},"content":" Move[] moves \u003d getAllMoves(playerColor);","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"onx001"},"content":" for (Move move : moves) {","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"onx001"},"content":" ChessBoard newBoard \u003d this.clone();","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":" newBoard.executeMove(move);","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":" } catch (InvalidMoveException e) {","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"onx001"},"content":" continue;","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"onx001"},"content":" if (!newBoard.isChecked()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"onx001"},"content":" public Move[] getAllMoves(Color color) {","lastModifiedDate":"2023-10-23"},{"lineNumber":130,"author":{"gitId":"onx001"},"content":" //Declare arraylist of moves as allMoves","lastModifiedDate":"2023-10-23"},{"lineNumber":131,"author":{"gitId":"onx001"},"content":" ArrayList\u003cMove\u003e allMoves \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":132,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":133,"author":{"gitId":"onx001"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":134,"author":{"gitId":"onx001"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":135,"author":{"gitId":"onx001"},"content":" Coordinate coor \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-23"},{"lineNumber":136,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d getPieceAtCoor(coor);","lastModifiedDate":"2023-10-23"},{"lineNumber":137,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":138,"author":{"gitId":"onx001"},"content":" if (piece.isSameColorAs(color)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":139,"author":{"gitId":"onx001"},"content":" Coordinate[] possibleCoordinates \u003d piece.getFlattenedCoordinates(this);","lastModifiedDate":"2023-10-23"},{"lineNumber":140,"author":{"gitId":"onx001"},"content":" for (Coordinate possible: possibleCoordinates) {","lastModifiedDate":"2023-10-23"},{"lineNumber":141,"author":{"gitId":"onx001"},"content":" Move move \u003d new Move(coor, possible, piece);","lastModifiedDate":"2023-10-23"},{"lineNumber":142,"author":{"gitId":"onx001"},"content":" allMoves.add(move);","lastModifiedDate":"2023-10-23"},{"lineNumber":143,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":144,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":145,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":146,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":147,"author":{"gitId":"onx001"},"content":" return allMoves.toArray(new Move[0]);","lastModifiedDate":"2023-10-23"},{"lineNumber":148,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":149,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":150,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":151,"author":{"gitId":"TongZhengHong"},"content":" public void setPromotionPiece(Coordinate coord, ChessPiece promotedPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":152,"author":{"gitId":"TongZhengHong"},"content":" getTileAtCoor(coord).updateTileChessPiece(promotedPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":153,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":155,"author":{"gitId":"TongZhengHong"},"content":" public void setTile(int row, int col, ChessTile tile) {","lastModifiedDate":"2023-10-22"},{"lineNumber":156,"author":{"gitId":"TongZhengHong"},"content":" board[row][col] \u003d tile;","lastModifiedDate":"2023-10-22"},{"lineNumber":157,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":158,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":160,"author":{"gitId":"TongZhengHong"},"content":" * Gets the ChessTile object located at the specified coordinate on the","lastModifiedDate":"2023-10-22"},{"lineNumber":161,"author":{"gitId":"TongZhengHong"},"content":" * chessboard.","lastModifiedDate":"2023-10-22"},{"lineNumber":162,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":163,"author":{"gitId":"TongZhengHong"},"content":" * @param coor The coordinate of the position to retrieve the tile for.","lastModifiedDate":"2023-10-22"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":" * @return The ChessTile object at the specified coordinate.","lastModifiedDate":"2023-10-22"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":166,"author":{"gitId":"TongZhengHong"},"content":" private ChessTile getTileAtCoor(Coordinate coor) {","lastModifiedDate":"2023-10-18"},{"lineNumber":167,"author":{"gitId":"TongZhengHong"},"content":" return board[coor.getY()][coor.getX()];","lastModifiedDate":"2023-10-18"},{"lineNumber":168,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":169,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":170,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":171,"author":{"gitId":"TongZhengHong"},"content":" * Gets the chess piece located at the specified coordinate on the chessboard.","lastModifiedDate":"2023-10-22"},{"lineNumber":172,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":173,"author":{"gitId":"TongZhengHong"},"content":" * @param coor The coordinate of the position to check.","lastModifiedDate":"2023-10-22"},{"lineNumber":174,"author":{"gitId":"TongZhengHong"},"content":" * @return The ChessPiece object at the specified coordinate. If empty piece at","lastModifiedDate":"2023-10-22"},{"lineNumber":175,"author":{"gitId":"TongZhengHong"},"content":" * coordinate, returns EmptyPiece object","lastModifiedDate":"2023-10-22"},{"lineNumber":176,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" public ChessPiece getPieceAtCoor(Coordinate coor) {","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" ChessTile tile \u003d getTileAtCoor(coor);","lastModifiedDate":"2023-10-18"},{"lineNumber":179,"author":{"gitId":"TongZhengHong"},"content":" return tile.getChessPiece();","lastModifiedDate":"2023-10-16"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":183,"author":{"gitId":"TongZhengHong"},"content":" * Executes a chess move on the chessboard.","lastModifiedDate":"2023-10-18"},{"lineNumber":184,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":185,"author":{"gitId":"TongZhengHong"},"content":" * @param move The Move object representing the move to be executed.","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"TongZhengHong"},"content":" * @throws InvalidMoveException If the move is not valid according to the game","lastModifiedDate":"2023-10-22"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":" * rules.","lastModifiedDate":"2023-10-22"},{"lineNumber":188,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":189,"author":{"gitId":"TongZhengHong"},"content":" public void executeMove(Move move) throws InvalidMoveException {","lastModifiedDate":"2023-10-18"},{"lineNumber":190,"author":{"gitId":"TongZhengHong"},"content":" Coordinate startCoor \u003d move.getFrom();","lastModifiedDate":"2023-10-18"},{"lineNumber":191,"author":{"gitId":"TongZhengHong"},"content":" Coordinate destCoor \u003d move.getTo();","lastModifiedDate":"2023-10-18"},{"lineNumber":192,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece chessPiece \u003d move.getPiece();","lastModifiedDate":"2023-10-18"},{"lineNumber":193,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":194,"author":{"gitId":"TongZhengHong"},"content":" if (!move.isValid(this)) {","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"TongZhengHong"},"content":" throw new InvalidMoveException();","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":197,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"TongZhengHong"},"content":" chessPiece.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":199,"author":{"gitId":"TongZhengHong"},"content":" chessPiece.updatePosition(destCoor);","lastModifiedDate":"2023-10-19"},{"lineNumber":200,"author":{"gitId":"TongZhengHong"},"content":" getTileAtCoor(startCoor).setTileEmpty(startCoor);","lastModifiedDate":"2023-10-20"},{"lineNumber":201,"author":{"gitId":"TongZhengHong"},"content":" getTileAtCoor(destCoor).updateTileChessPiece(chessPiece);","lastModifiedDate":"2023-10-18"},{"lineNumber":202,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":203,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":204,"author":{"gitId":"onx001"},"content":" if (move.isLeftCastling() \u0026\u0026 startCoor.isOffsetWithinBoard(-4, 0)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"onx001"},"content":" Coordinate rookStartCoor \u003d startCoor.addOffsetToCoordinate(-4, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"onx001"},"content":" Coordinate rookDestCoor \u003d startCoor.addOffsetToCoordinate(-1, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"onx001"},"content":" ChessPiece rook \u003d getTileAtCoor(rookStartCoor).getChessPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":208,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":209,"author":{"gitId":"onx001"},"content":" rook.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":210,"author":{"gitId":"onx001"},"content":" rook.updatePosition(rookDestCoor);","lastModifiedDate":"2023-10-19"},{"lineNumber":211,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":212,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookStartCoor).setTileEmpty(rookStartCoor);","lastModifiedDate":"2023-10-20"},{"lineNumber":213,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookDestCoor).updateTileChessPiece(rook);","lastModifiedDate":"2023-10-19"},{"lineNumber":214,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":215,"author":{"gitId":"onx001"},"content":" } else if (move.isRightCastling() \u0026\u0026 startCoor.isOffsetWithinBoard(3, 0)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"onx001"},"content":" Coordinate rookStartCoor \u003d startCoor.addOffsetToCoordinate(3, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"onx001"},"content":" Coordinate rookDestCoor \u003d startCoor.addOffsetToCoordinate(1, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"onx001"},"content":" ChessPiece rook \u003d getTileAtCoor(rookStartCoor).getChessPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":219,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":220,"author":{"gitId":"onx001"},"content":" rook.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":221,"author":{"gitId":"onx001"},"content":" rook.updatePosition(rookDestCoor);","lastModifiedDate":"2023-10-19"},{"lineNumber":222,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":223,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookStartCoor).setTileEmpty(rookStartCoor);","lastModifiedDate":"2023-10-20"},{"lineNumber":224,"author":{"gitId":"onx001"},"content":" getTileAtCoor(rookDestCoor).updateTileChessPiece(rook);","lastModifiedDate":"2023-10-19"},{"lineNumber":225,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":226,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":227,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":228,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-27"},{"lineNumber":229,"author":{"gitId":"ken-ruster"},"content":" public boolean canPromote(Move move) {","lastModifiedDate":"2023-10-19"},{"lineNumber":230,"author":{"gitId":"ken-ruster"},"content":" ChessPiece piece \u003d move.getPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":231,"author":{"gitId":"ken-ruster"},"content":" Coordinate endCoord \u003d move.getTo();","lastModifiedDate":"2023-10-19"},{"lineNumber":232,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":233,"author":{"gitId":"ken-ruster"},"content":" if (!piece.isPawn()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":234,"author":{"gitId":"ken-ruster"},"content":" return false;","lastModifiedDate":"2023-10-19"},{"lineNumber":235,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":236,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":237,"author":{"gitId":"ken-ruster"},"content":" if (isPieceFriendly(piece)) {","lastModifiedDate":"2023-10-26"},{"lineNumber":238,"author":{"gitId":"ken-ruster"},"content":" return endCoord.getY() \u003d\u003d TOP_ROW_INDEX;","lastModifiedDate":"2023-10-22"},{"lineNumber":239,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":240,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":241,"author":{"gitId":"ken-ruster"},"content":" if (isPieceOpponent(piece)) {","lastModifiedDate":"2023-10-26"},{"lineNumber":242,"author":{"gitId":"ken-ruster"},"content":" return endCoord.getY() \u003d\u003d BOTTOM_ROW_INDEX;","lastModifiedDate":"2023-10-22"},{"lineNumber":243,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":244,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":245,"author":{"gitId":"ken-ruster"},"content":" return false;","lastModifiedDate":"2023-10-19"},{"lineNumber":246,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":247,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":248,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":249,"author":{"gitId":"TriciaBK"},"content":" public boolean isEndGame() {","lastModifiedDate":"2023-10-20"},{"lineNumber":250,"author":{"gitId":"TriciaBK"},"content":" isWhiteKingAlive \u003d false; ","lastModifiedDate":"2023-10-22"},{"lineNumber":251,"author":{"gitId":"TriciaBK"},"content":" isBlackKingAlive \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":252,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":253,"author":{"gitId":"TriciaBK"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-20"},{"lineNumber":254,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-20"},{"lineNumber":255,"author":{"gitId":"TriciaBK"},"content":" Coordinate coor \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-20"},{"lineNumber":256,"author":{"gitId":"TriciaBK"},"content":" ChessPiece piece \u003d getPieceAtCoor(coor);","lastModifiedDate":"2023-10-20"},{"lineNumber":257,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":258,"author":{"gitId":"TriciaBK"},"content":" if (piece instanceof King) {","lastModifiedDate":"2023-10-22"},{"lineNumber":259,"author":{"gitId":"TriciaBK"},"content":" if (piece.isWhite()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":260,"author":{"gitId":"TriciaBK"},"content":" isWhiteKingAlive \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":261,"author":{"gitId":"TriciaBK"},"content":" } else if (piece.isBlack()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":262,"author":{"gitId":"TriciaBK"},"content":" isBlackKingAlive \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":263,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":264,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":265,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":266,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":267,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":268,"author":{"gitId":"TriciaBK"},"content":" return !isBlackKingAlive || !isWhiteKingAlive;","lastModifiedDate":"2023-10-22"},{"lineNumber":269,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":270,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":271,"author":{"gitId":"TriciaBK"},"content":" public Color getWinningColor() {","lastModifiedDate":"2023-10-22"},{"lineNumber":272,"author":{"gitId":"TriciaBK"},"content":" boolean whiteWin \u003d isWhiteKingAlive \u0026\u0026 !isBlackKingAlive;","lastModifiedDate":"2023-10-22"},{"lineNumber":273,"author":{"gitId":"TriciaBK"},"content":" boolean blackWin \u003d isBlackKingAlive \u0026\u0026 !isWhiteKingAlive;","lastModifiedDate":"2023-10-22"},{"lineNumber":274,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":275,"author":{"gitId":"TriciaBK"},"content":" if (whiteWin) {","lastModifiedDate":"2023-10-22"},{"lineNumber":276,"author":{"gitId":"TriciaBK"},"content":" return Color.WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":277,"author":{"gitId":"TriciaBK"},"content":" } else if (blackWin) {","lastModifiedDate":"2023-10-22"},{"lineNumber":278,"author":{"gitId":"TriciaBK"},"content":" return Color.BLACK;","lastModifiedDate":"2023-10-22"},{"lineNumber":279,"author":{"gitId":"TriciaBK"},"content":" } else {","lastModifiedDate":"2023-10-20"},{"lineNumber":280,"author":{"gitId":"TriciaBK"},"content":" return Color.EMPTY;","lastModifiedDate":"2023-10-22"},{"lineNumber":281,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":282,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":283,"author":{"gitId":"TriciaBK"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":284,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":285,"author":{"gitId":"onx001"},"content":" public int getPoints(Color color) {","lastModifiedDate":"2023-10-23"},{"lineNumber":286,"author":{"gitId":"onx001"},"content":" int points \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":287,"author":{"gitId":"onx001"},"content":" int enemyPoints \u003d 0;","lastModifiedDate":"2023-10-24"},{"lineNumber":288,"author":{"gitId":"onx001"},"content":" boolean isUpright;","lastModifiedDate":"2023-10-26"},{"lineNumber":289,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":290,"author":{"gitId":"onx001"},"content":" if (this.playerColor \u003d\u003d color) {","lastModifiedDate":"2023-10-26"},{"lineNumber":291,"author":{"gitId":"onx001"},"content":" isUpright \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":292,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":293,"author":{"gitId":"onx001"},"content":" isUpright \u003d false;","lastModifiedDate":"2023-10-26"},{"lineNumber":294,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":295,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":296,"author":{"gitId":"onx001"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":297,"author":{"gitId":"onx001"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":298,"author":{"gitId":"onx001"},"content":" Coordinate coor \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-23"},{"lineNumber":299,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d this.getPieceAtCoor(coor);","lastModifiedDate":"2023-10-23"},{"lineNumber":300,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":301,"author":{"gitId":"onx001"},"content":" if (piece.isSameColorAs(color)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":302,"author":{"gitId":"onx001"},"content":" points +\u003d piece.getPoints(isUpright);","lastModifiedDate":"2023-10-26"},{"lineNumber":303,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-24"},{"lineNumber":304,"author":{"gitId":"onx001"},"content":" enemyPoints +\u003d piece.getPoints(isUpright);","lastModifiedDate":"2023-10-26"},{"lineNumber":305,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":306,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":307,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":308,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":309,"author":{"gitId":"onx001"},"content":" return points - enemyPoints;","lastModifiedDate":"2023-10-24"},{"lineNumber":310,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":311,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":312,"author":{"gitId":"onx001"},"content":" public ChessBoard clone() {","lastModifiedDate":"2023-10-23"},{"lineNumber":313,"author":{"gitId":"onx001"},"content":" String stringRep \u003d this.toString();","lastModifiedDate":"2023-10-23"},{"lineNumber":314,"author":{"gitId":"onx001"},"content":" return toBoard(stringRep);","lastModifiedDate":"2023-10-23"},{"lineNumber":315,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":316,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":317,"author":{"gitId":"onx001"},"content":" public ChessBoard toBoard(String board) {","lastModifiedDate":"2023-10-23"},{"lineNumber":318,"author":{"gitId":"onx001"},"content":" ChessTile[][] boardTiles \u003d new ChessTile[SIZE][SIZE];","lastModifiedDate":"2023-10-23"},{"lineNumber":319,"author":{"gitId":"onx001"},"content":" int row \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":320,"author":{"gitId":"onx001"},"content":" int col \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":321,"author":{"gitId":"onx001"},"content":" for (int i \u003d 0; i \u003c board.length(); i++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":322,"author":{"gitId":"onx001"},"content":" String pieceString \u003d board.substring(i, i + 1);","lastModifiedDate":"2023-10-23"},{"lineNumber":323,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d Parser.parseChessPiece(pieceString, row, col);","lastModifiedDate":"2023-10-23"},{"lineNumber":324,"author":{"gitId":"onx001"},"content":" assert (row \u003c SIZE);","lastModifiedDate":"2023-10-24"},{"lineNumber":325,"author":{"gitId":"onx001"},"content":" assert (col \u003c SIZE);","lastModifiedDate":"2023-10-24"},{"lineNumber":326,"author":{"gitId":"onx001"},"content":" boardTiles[row][col] \u003d new ChessTile(piece);","lastModifiedDate":"2023-10-23"},{"lineNumber":327,"author":{"gitId":"onx001"},"content":" col++;","lastModifiedDate":"2023-10-23"},{"lineNumber":328,"author":{"gitId":"onx001"},"content":" if (col \u003d\u003d SIZE) {","lastModifiedDate":"2023-10-23"},{"lineNumber":329,"author":{"gitId":"onx001"},"content":" col \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":330,"author":{"gitId":"onx001"},"content":" row++;","lastModifiedDate":"2023-10-23"},{"lineNumber":331,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":332,"author":{"gitId":"onx001"},"content":" if (row \u003d\u003d SIZE) {","lastModifiedDate":"2023-10-24"},{"lineNumber":333,"author":{"gitId":"onx001"},"content":" break;","lastModifiedDate":"2023-10-24"},{"lineNumber":334,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":335,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":336,"author":{"gitId":"onx001"},"content":" return new ChessBoard(this.playerColor, boardTiles);","lastModifiedDate":"2023-10-26"},{"lineNumber":337,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":338,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":339,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-23"},{"lineNumber":340,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":341,"author":{"gitId":"onx001"},"content":" StringBuilder boardString \u003d new StringBuilder();","lastModifiedDate":"2023-10-23"},{"lineNumber":342,"author":{"gitId":"onx001"},"content":" for (ChessTile[] row : board) {","lastModifiedDate":"2023-10-23"},{"lineNumber":343,"author":{"gitId":"onx001"},"content":" for (ChessTile tile : row) {","lastModifiedDate":"2023-10-23"},{"lineNumber":344,"author":{"gitId":"onx001"},"content":" boardString.append(tile.toFileString());","lastModifiedDate":"2023-10-24"},{"lineNumber":345,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":346,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":347,"author":{"gitId":"onx001"},"content":" return boardString.toString();","lastModifiedDate":"2023-10-23"},{"lineNumber":348,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":349,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":350,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":351,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPieceFriendly(ChessPiece otherPiece) {","lastModifiedDate":"2023-10-26"},{"lineNumber":352,"author":{"gitId":"TongZhengHong"},"content":" return this.playerColor \u003d\u003d otherPiece.getColor();","lastModifiedDate":"2023-10-26"},{"lineNumber":353,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":354,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":355,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPieceOpponent(ChessPiece otherPiece) {","lastModifiedDate":"2023-10-26"},{"lineNumber":356,"author":{"gitId":"TongZhengHong"},"content":" return this.playerColor !\u003d otherPiece.getColor();","lastModifiedDate":"2023-10-26"},{"lineNumber":357,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":358,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":22,"antrikshdhand":1,"TriciaBK":37,"onx001":160,"TongZhengHong":138}},{"path":"src/main/java/chessmaster/game/ChessTile.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.EmptyPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class ChessTile {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" public static final String TILE_DIVIDER \u003d \"|\";","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" private static final String EMPTY_TILE_STRING \u003d \" \";","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" private static final String EMPTY_TILE_MOVES_STRING \u003d \".\";","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":" private static final String BACKGROUND_RESET \u003d \"\\u001B[0m\";","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":" private static final String CAPTURABLE_BACKGROUND \u003d \"\\u001B[43m\";","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" /** Nullable ChessPiece object. Null signifies that this tile is empty */","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" private ChessPiece chessPiece;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" public ChessTile(Coordinate coor) {","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d new EmptyPiece(coor.getX(), coor.getY());","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" public ChessTile(ChessPiece piece) {","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d piece;","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" public ChessPiece getChessPiece() {","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece;","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public boolean isEmpty() {","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" public void setTileEmpty(Coordinate coor) {","lastModifiedDate":"2023-10-20"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d new EmptyPiece(coor.getX(),coor.getY());","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" * Updates the ChessTile with a new ChessPiece, considering piece interactions. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * 1. Replace the new piece on an EMPTY tile. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" * 2. Cannot capture a friendly piece; no change is made UNLESS it is for promotion. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" * 3. If new piece captures the opponent piece, mark the opponent piece as captured and replace it. \u003cBR\u003e","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" * @param newPiece The new ChessPiece to place on the tile.","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" public void updateTileChessPiece(ChessPiece newPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" if (chessPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" // Move newPiece to empty tile","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d newPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" return;","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" } ","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" if (newPiece.isFriendly(chessPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" // Only update if friendly pawn piece is promoting","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (chessPiece.isPawn() \u0026\u0026 newPiece.isPromotionPiece()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d newPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" return; // Cannot capture friendly piece","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" } ","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" if (newPiece.isOpponent(chessPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" // Mark opponent piece as captured","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" chessPiece.setIsCaptured();","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" chessPiece \u003d newPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_STRING : chessPiece.toString();","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" return String.format(\" %s \", tileContent);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" public String toStringSelected() {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_STRING : chessPiece.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" return CAPTURABLE_BACKGROUND + String.format(\"{%s}\", tileContent) + BACKGROUND_RESET;","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" public String toStringPrevMove() {","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_STRING : chessPiece.toString();","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" return CAPTURABLE_BACKGROUND + String.format(\"(%s)\", tileContent) + BACKGROUND_RESET;","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"ken-ruster"},"content":" public String toStringAvailableDest() {","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"ken-ruster"},"content":" String tileContent \u003d isEmpty() ? EMPTY_TILE_MOVES_STRING : chessPiece.toString();","lastModifiedDate":"2023-11-03"},{"lineNumber":85,"author":{"gitId":"ken-ruster"},"content":" String addBrackets \u003d String.format(\"[%s]\", tileContent);","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"ken-ruster"},"content":" if (!isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"ken-ruster"},"content":" return CAPTURABLE_BACKGROUND + addBrackets + BACKGROUND_RESET;","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"ken-ruster"},"content":" return addBrackets;","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" public String toFileString() {","lastModifiedDate":"2023-10-24"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" return chessPiece.toString();","lastModifiedDate":"2023-10-24"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":17,"onx001":5,"TongZhengHong":75}},{"path":"src/main/java/chessmaster/game/Color.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"public enum Color {","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" WHITE, BLACK, EMPTY;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" * Get the opposite color given the player\u0027s color.","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" * Used to identify the color for CPU player.","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" * @return The opposite color.","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public Color getOppositeColour() {","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" if (this \u003d\u003d Color.WHITE) {","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" return Color.BLACK;","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" } else if (this \u003d\u003d Color.BLACK) {","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" return Color.WHITE;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" return Color.EMPTY;","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" * Checks if a given color is white. ","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the color is white; false otherwise.","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public boolean isWhite() {","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" return this \u003d\u003d Color.WHITE;","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" * Checks if a given color is black. ","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the color is black; false otherwise.","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" public boolean isBlack() {","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" return this \u003d\u003d Color.BLACK;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" * Checks if a given color is empty.","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the color is empty; false otherwise.","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" public boolean isEmpty() {","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" return this \u003d\u003d Color.EMPTY;","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"TongZhengHong":49}},{"path":"src/main/java/chessmaster/game/Coordinate.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"public class Coordinate {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" private static final String BOARD_COLUMNS \u003d \"abcdefgh\";","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" private int x;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" private int y;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public Coordinate(int x, int y) {","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" this.x \u003d x;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" this.y \u003d y;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" assert !isCoorOutofBoard(x, y) : \"Coordinates (x,y) should NOT be out of chessboard (8x8 size)!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public int getX() {","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" return x;","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" public int getY() {","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" return y;","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" public static boolean isCoorOutofBoard(int x, int y) {","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" return (x \u003c 0 || x \u003e\u003d ChessBoard.SIZE) || (y \u003c 0 || y \u003e\u003d ChessBoard.SIZE);","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" * Checks if applying a given offset from the current position stays within the","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" * bounds of the chessboard.","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetX The horizontal offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetY The vertical offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the resulting position is within the board boundaries;","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * otherwise, false.","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" public boolean isOffsetWithinBoard(int offsetX, int offsetY) {","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int newX \u003d x + offsetX;","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" int newY \u003d y + offsetY;","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" return (newX \u003e\u003d 0 \u0026\u0026 newX \u003c ChessBoard.SIZE) \u0026\u0026","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" (newY \u003e\u003d 0 \u0026\u0026 newY \u003c ChessBoard.SIZE);","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" * Adds the given offsets to the current coordinate and returns the new","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" * coordinate.","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetX The horizontal offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" * @param offsetY The vertical offset to apply.","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" * @return A new coordinate after applying the offsets, or the current","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" * coordinate","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" * if the new position is out of the board boundaries.","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" public Coordinate addOffsetToCoordinate(int offsetX, int offsetY) {","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" int newX \u003d x + offsetX;","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" int newY \u003d y + offsetY;","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" if (isCoorOutofBoard(newX, newY)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" return new Coordinate(x, y);","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" return new Coordinate(newX, newY);","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" * Parses an algebraic chess coordinate notation (e.g., \"a1\") and returns a","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" * Coordinate object.","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" * @param notation The algebraic coordinate notation to parse.","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" * @return A Coordinate object representing the parsed chess coordinate.","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" * @throws ParseCoordinateException If the input notation is invalid or out of","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" * bounds.","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" public static Coordinate parseAlgebraicCoor(String notation) throws ParseCoordinateException {","lastModifiedDate":"2023-10-15"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" notation \u003d notation.toLowerCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" if (notation.length() !\u003d 2) {","lastModifiedDate":"2023-10-15"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-15"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" String colString \u003d Character.toString(notation.charAt(0));","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" boolean isColValid \u003d BOARD_COLUMNS.contains(colString);","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" String rowString \u003d String.valueOf(notation.charAt(1));","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" int rowInt \u003d Integer.parseInt(String.valueOf(rowString));","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" if (rowInt \u003c 1 || rowInt \u003e ChessBoard.SIZE || !isColValid) {","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" int indexX \u003d BOARD_COLUMNS.indexOf(colString); ","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" int indexY \u003d (rowInt - 8) * -1;","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" return new Coordinate(indexX, indexY);","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-15"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" public int[] calculateOffsetFrom(Coordinate otherCoordinate) {","lastModifiedDate":"2023-10-22"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d this.x - otherCoordinate.getX();","lastModifiedDate":"2023-10-22"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d this.y - otherCoordinate.getY();","lastModifiedDate":"2023-10-22"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" return new int[]{ offsetX, offsetY };","lastModifiedDate":"2023-10-22"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-16"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" return String.format(\"%s%d\", BOARD_COLUMNS.charAt(x), (ChessBoard.SIZE - y));","lastModifiedDate":"2023-10-17"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":" public boolean equals(Object obj) {","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"onx001"},"content":" if (obj instanceof Coordinate) {","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"onx001"},"content":" Coordinate other \u003d (Coordinate) obj;","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"onx001"},"content":" return x \u003d\u003d other.x \u0026\u0026 y \u003d\u003d other.y;","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-16"},{"lineNumber":124,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":125,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":126,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"onx001":11,"TongZhengHong":115}},{"path":"src/main/java/chessmaster/game/Game.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"//@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.AbortCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.Command;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.CommandResult;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.MoveCommand;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.storage.Storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.CPU;","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.Human;","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.Player;","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"public class Game {","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" private static final String[] START_HELP_STRINGS \u003d {","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" \"Thank you for choosing ChessMaster! Here are the commands that you can use:\",","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" \"Move piece - Input coordinate of piece, followed by coordinate to move to\",","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" \" Format: [column][row] [column][row]\",","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" \" E.g. a2 a3\",","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" \"Show board - Shows the current state of the chess board\",","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" \" Format: show\",","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" \"Show available moves - Lists all the available moves for a piece at a coordinate\",","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" \" Format: moves [column][row]\",","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" \" E.g. moves a2\",","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" \"Abort game - Exit programme\",","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" \" Format: abort\",","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" \"Obtain rules - Obtain a quick refresher on the rules of chess\",","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" \" Format: rules\",","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" \"Obtain help - Show a list of commands and what they do\",","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" \" Format: help\"","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" private CPU cpu;","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" private Human human;","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" private Player currentPlayer;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" private TextUI ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" private ChessBoard board;","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" private Storage storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" private int difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" private Command command;","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" private boolean hasEnded;","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" public Game(Color playerColour, Color currentTurnColor, ChessBoard board, ","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" Storage storage, TextUI ui, int difficulty) {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" this.board \u003d board;","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" this.storage \u003d storage;","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" this.difficulty \u003d difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" this.human \u003d new Human(playerColour, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" Color cpuColor \u003d playerColour.getOppositeColour();","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" this.cpu \u003d new CPU(cpuColor, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" // Choose which player goes first","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" currentPlayer \u003d currentTurnColor \u003d\u003d playerColour ? human : cpu;","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" assert playerColour !\u003d Color.EMPTY : \"Human player color should not be EMPTY!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" assert cpuColor !\u003d Color.EMPTY : \"CPU player color should not be EMPTY!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" assert currentPlayer !\u003d null : \"A player should always exist in a game!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" assert (0 \u003c difficulty) \u0026\u0026 (difficulty \u003c 5) : \"Difficulty should be between 1 and 4!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" public void run() {","lastModifiedDate":"2023-10-19"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" ui.printText(START_HELP_STRINGS);","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" while (!hasEnded \u0026\u0026 !AbortCommand.isAbortCommand(command)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" assert currentPlayer.isCPU() || currentPlayer.isHuman() : ","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" \"Player should only either be human or CPU!\";","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" if (currentPlayer.isHuman()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" command \u003d getUserCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" if (!command.isMoveCommand()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" continue; // Get next command","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" Move playedMove \u003d handleHumanMove();","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" ui.printChessBoardWithMove(board.getBoard(), playedMove);","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" } else if (currentPlayer.isCPU()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" Move playedMove \u003d handleCPUMove();","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" ui.printChessBoardWithMove(board.getBoard(), playedMove);","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" } ","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" currentPlayer \u003d togglePlayerTurn();","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":" storage.saveBoard(board, currentPlayer.getColour());","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" hasEnded \u003d checkEndState(); // Resets board if end","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" } catch (ChessMasterException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" ui.printErrorMessage(e);","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" private Command getUserCommand() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" String userInputString \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" command \u003d Parser.parseCommand(userInputString);","lastModifiedDate":"2023-10-22"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" CommandResult result \u003d command.execute(board, ui);","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" ui.printCommandResult(result);","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" return command;","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" private Move handleHumanMove() throws ChessMasterException {","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" Move humanMove \u003d ((MoveCommand) command).getMove();","lastModifiedDate":"2023-10-23"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" board.executeMove(humanMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" human.addMove(humanMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" // Handle human promotion","lastModifiedDate":"2023-10-23"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" if (!board.isEndGame()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" if (board.canPromote(humanMove)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":" human.handlePromote(board, ui, humanMove);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":" return humanMove;","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":" private Move handleCPUMove() throws ChessMasterException {","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":" Move cpuMove \u003d cpu.getBestMove(board, difficulty);","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":" ui.printCPUMove(cpuMove);","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":" board.executeMove(cpuMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":" cpu.addMove(cpuMove);","lastModifiedDate":"2023-10-23"},{"lineNumber":130,"author":{"gitId":"TongZhengHong"},"content":" return cpuMove;","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":132,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":133,"author":{"gitId":"TongZhengHong"},"content":" private boolean checkEndState() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":134,"author":{"gitId":"TongZhengHong"},"content":" boolean end \u003d board.isEndGame();","lastModifiedDate":"2023-10-22"},{"lineNumber":135,"author":{"gitId":"TongZhengHong"},"content":" if (end) {","lastModifiedDate":"2023-10-22"},{"lineNumber":136,"author":{"gitId":"TongZhengHong"},"content":" Color winningColor \u003d board.getWinningColor();","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"TongZhengHong"},"content":" Player winnerPlayer \u003d human.getColour() \u003d\u003d winningColor ? human : cpu;","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"TongZhengHong"},"content":" ui.printEndMessage(winnerPlayer);","lastModifiedDate":"2023-11-04"},{"lineNumber":139,"author":{"gitId":"TongZhengHong"},"content":" storage.resetBoard();","lastModifiedDate":"2023-10-23"},{"lineNumber":140,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":141,"author":{"gitId":"TongZhengHong"},"content":" return end;","lastModifiedDate":"2023-10-22"},{"lineNumber":142,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":143,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":144,"author":{"gitId":"TongZhengHong"},"content":" private Player togglePlayerTurn() {","lastModifiedDate":"2023-10-23"},{"lineNumber":145,"author":{"gitId":"TongZhengHong"},"content":" return currentPlayer.isHuman() ? cpu : human;","lastModifiedDate":"2023-10-23"},{"lineNumber":146,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":147,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"TongZhengHong":147}},{"path":"src/main/java/chessmaster/game/MiniMax.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"//@@author onx001","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"public class MiniMax {","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":" protected int depth;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":" protected int maxDepth;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" protected int score;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" protected Move bestMove;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" protected ChessBoard board;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" protected Color color;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":" protected Color opponentColor;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" protected BoardScoreTuple tuple;","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" //declares all variables needed for the minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" public MiniMax(ChessBoard board, Color color, int maxDepth, int score) {","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" this.board \u003d board;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" this.color \u003d color;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" this.opponentColor \u003d color.getOppositeColour();","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" this.maxDepth \u003d maxDepth;","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" this.score \u003d score;","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" this.tuple \u003d new BoardScoreTuple(board, score, null);","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" * returns the best move tuple for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" * @author onx001","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" * @param tuple the BoardScoreTuple to be weighed","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" * @param color the color of the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" * @param depth the current depth of the minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" * @param score the score of the current board","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" * @param isMax whether the current player is the CPU or the player","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" * @param maxDepth the maximum depth of the minimax algorithm","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" * @return the best move tuple for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":" public static BoardScoreTuple mostPoints(BoardScoreTuple tuple, Color color, int depth, ","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" int score, boolean isMax, int maxDepth) {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"onx001"},"content":" //gets all the moves for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"onx001"},"content":" ChessBoard board \u003d tuple.getBoard();","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":" Color playerColor \u003d isMax ? color : color.getOppositeColour();","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" Move[] moves \u003d board.getAllMoves(playerColor);","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":" assert moves.length \u003e 0 : \"No moves available for \" + color + \" at depth \" + depth;","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":" BoardScoreTuple[] boards \u003d new BoardScoreTuple[moves.length];","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" int bestScore \u003d isMax ? Integer.MIN_VALUE : Integer.MAX_VALUE;","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" BoardScoreTuple bestTuple \u003d null;","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" //if the depth is the max depth, return the score of the board as base case","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" if (depth \u003d\u003d maxDepth) {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" int newscore \u003d board.getPoints(color);","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" return new BoardScoreTuple(board,newscore, null);","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" //for each move, clone the board and execute the move as a possibility","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" for (int i \u003d 0; i \u003c moves.length; i++) {","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" assert moves[i] !\u003d null : \"moves[i] is null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" ChessBoard newBoard \u003d board.clone();","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" Move move \u003d moves[i];","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"onx001"},"content":" Coordinate from \u003d move.getFrom();","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d newBoard.getPieceAtCoor(from);","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":" move.setPiece(piece);","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"onx001"},"content":" newBoard.executeMove(move);","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"onx001"},"content":" //get the score of the board after the move","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"onx001"},"content":" int newScore \u003d newBoard.getPoints(color);","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":" boards[i] \u003d new BoardScoreTuple(newBoard, newScore, move);","lastModifiedDate":"2023-10-24"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":" } catch (ChessMasterException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":" continue;","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":" //go through boards and find one with best points","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" for (int i \u003d 0; i \u003c boards.length; i++) {","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" BoardScoreTuple iterTuple \u003d boards[i];","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" assert iterTuple !\u003d null : \"iterTuple is null\";","lastModifiedDate":"2023-10-24"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":" assert iterTuple.getMove() !\u003d null : \"iterTuple move is null\";","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" //recursively call mostPoints to find the best move for current board","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" BoardScoreTuple tuple1 \u003d mostPoints(iterTuple, color, depth + 1, score, !isMax, maxDepth);","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":" //prints score as branch","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" //System.out.println(\"|\" + \"---\".repeat(depth) + \" \" + tuple1.getScore() + tuple.getMove());","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" //Sets new score to current child score","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" int newScore \u003d tuple1.getScore();","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" if (isMax) {","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" //maximises child score if CPU turn","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":" if (newScore \u003e bestScore) {","lastModifiedDate":"2023-10-24"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" bestScore \u003d newScore;","lastModifiedDate":"2023-10-24"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" //minimises child score if player turn","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" if (newScore \u003c bestScore) {","lastModifiedDate":"2023-10-24"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" bestScore \u003d newScore;","lastModifiedDate":"2023-10-25"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" //set current tuple based on best child score","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":" bestTuple \u003d bestScore \u003d\u003d newScore ? iterTuple : bestTuple;","lastModifiedDate":"2023-10-25"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":" return bestTuple;","lastModifiedDate":"2023-10-24"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":" /** ","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":" * Kicks off minimax algorithm and returns the best move for the current player","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":111,"author":{"gitId":"onx001"},"content":" public Move getBestMove() {","lastModifiedDate":"2023-10-24"},{"lineNumber":112,"author":{"gitId":"onx001"},"content":" BoardScoreTuple bestTuple \u003d mostPoints(tuple, color, 0, score, true, maxDepth);","lastModifiedDate":"2023-10-26"},{"lineNumber":113,"author":{"gitId":"onx001"},"content":" Move bestMove \u003d bestTuple.getMove();","lastModifiedDate":"2023-10-24"},{"lineNumber":114,"author":{"gitId":"onx001"},"content":" return bestMove;","lastModifiedDate":"2023-10-24"},{"lineNumber":115,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"onx001":118}},{"path":"src/main/java/chessmaster/game/Move.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"// @author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"public class Move {","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":" private Coordinate from;","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":" private Coordinate to;","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":" private ChessPiece piece;","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" public Move(Coordinate from, Coordinate to, ChessPiece piece) {","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" this.from \u003d from;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" this.to \u003d to;","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" this.piece \u003d piece;","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" assert from !\u003d null \u0026\u0026 to !\u003d null : \"Coordinates in Move should not be null!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assert piece !\u003d null \u0026\u0026 !piece.isEmptyPiece() : \"Chess piece in Move should not be null or empty!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" public Coordinate getFrom() {","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" return from;","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" public Coordinate getTo() {","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" return to;","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" public ChessPiece getPiece() {","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" return piece;","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"antrikshdhand"},"content":" public void setFrom(Coordinate from) {","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"antrikshdhand"},"content":" this.from \u003d from;","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"antrikshdhand"},"content":" public void setTo(Coordinate to) {","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"antrikshdhand"},"content":" this.to \u003d to;","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"antrikshdhand"},"content":" public void setPiece(ChessPiece piece) {","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"antrikshdhand"},"content":" this.piece \u003d piece;","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" * Checks if the move is valid by checking if the to coordinate is in the","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" * possibleCoordinates 2d array","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" * @param board","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" * @return","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" public boolean isValid(ChessBoard board) {","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" Coordinate[][] coordinates \u003d piece.getAvailableCoordinates(board);","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" for (Coordinate[] direction : coordinates) {","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" for (Coordinate coor : direction) {","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" if (coor.equals(to)) {","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"onx001"},"content":" public boolean isLeftCastling() {","lastModifiedDate":"2023-10-19"},{"lineNumber":67,"author":{"gitId":"onx001"},"content":" if (!(piece instanceof King)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":70,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":" int[] offset \u003d to.calculateOffsetFrom(from);","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":" return Arrays.equals(offset, ChessPiece.CASTLE_LEFT);","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" public boolean isRightCastling() {","lastModifiedDate":"2023-10-19"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" if (!(piece instanceof King)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" int[] offset \u003d to.calculateOffsetFrom(from);","lastModifiedDate":"2023-10-22"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" return Arrays.equals(offset, ChessPiece.CASTLE_RIGHT);","lastModifiedDate":"2023-10-22"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-24"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" return \"Move [from\u003d\" + from + \", to\u003d\" + to + \", piece\u003d\" + piece + \"]\";","lastModifiedDate":"2023-10-24"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" // @author TongZhengHong","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":" public boolean equals(Object obj) {","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" if (obj !\u003d null \u0026\u0026 obj instanceof Move) {","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" final Move other \u003d (Move) obj;","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":" return from.equals(other.getFrom()) \u0026\u0026 to.equals(other.getTo()) \u0026\u0026 piece.equals(other.getPiece());","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"ken-ruster":26,"antrikshdhand":12,"onx001":52,"TongZhengHong":8}},{"path":"src/main/java/chessmaster/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.AbortCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.Command;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.HelpCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.MoveCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.RulesCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.ShowCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.ShowMovesCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.commands.LegendCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.MoveOpponentPieceException;","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.NullPieceException;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseColorException;","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Bishop;","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.EmptyPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.King;","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Knight;","lastModifiedDate":"2023-10-20"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-10-20"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-10-20"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.Rook;","lastModifiedDate":"2023-10-20"},{"lineNumber":27,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":"public class Parser {","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":" * Parses a string telling which chess piece the user wants to promote his piece","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" * to, and promotes the relevant piece","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":" * @param promoteFrom Chess piece to be promoted.","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" * @param promoteTo String representing the type of piece to be promoted to.","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":" * @return Promoted chess piece.","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":" public static ChessPiece parsePromote(ChessPiece promoteFrom, String promoteTo) {","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" Color color \u003d promoteFrom.getColor();","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":" Coordinate position \u003d promoteFrom.getPosition();","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" switch (promoteTo) {","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" case Bishop.BISHOP_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":" return new Bishop(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" case Queen.QUEEN_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":" return new Queen(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":" case Knight.KNIGHT_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":" return new Knight(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" case Rook.ROOK_WHITE:","lastModifiedDate":"2023-10-19"},{"lineNumber":51,"author":{"gitId":"ken-ruster"},"content":" return new Rook(position.getY(), position.getX(), color);","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"ken-ruster"},"content":" default:","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"ken-ruster"},"content":" return promoteFrom;","lastModifiedDate":"2023-10-19"},{"lineNumber":54,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" * Parses a chess move from user input and creates a Move object. Used to read","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" * user inputs during the chess game.","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" * @param in The user input string with 2 algebraic coordinate notations","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" * (e.g., \"e2 e4\").","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" * @param board The ChessBoard where the move is taking place.","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" * @return Move object containing information about the move to be made.","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" * @throws ParseCoordinateException If the string entered is not in the","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" * algebraic coordinate notation.","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" * @throws NullPieceException","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" * @throws MoveOpponentPieceException","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" public static Move parseMove(String in, ChessBoard board) throws ParseCoordinateException,","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" NullPieceException, MoveOpponentPieceException {","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" String[] parseArray \u003d in.split(\"\\\\s+\", 2);","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" if (parseArray.length \u003c 2) {","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseCoordinateException();","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" Coordinate from \u003d Coordinate.parseAlgebraicCoor(parseArray[0]);","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" Coordinate to \u003d Coordinate.parseAlgebraicCoor(parseArray[1]);","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece relevantPiece \u003d board.getPieceAtCoor(from);","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" if (relevantPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" throw new NullPieceException();","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" } else if (board.isPieceOpponent(relevantPiece)) {","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" throw new MoveOpponentPieceException();","lastModifiedDate":"2023-10-22"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":" return new Move(from, to, relevantPiece);","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":" * Parses an input string and creates a ChessPiece object at the specified row","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" * and column. Used for loading ChessPiece(s) from storage file or loading","lastModifiedDate":"2023-10-22"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" * starting ChessBoard. Returns null for recognised input string to signify that","lastModifiedDate":"2023-10-22"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" * piece is empty (for ChessTile)","lastModifiedDate":"2023-10-22"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" * @param pieceString The string representation of the chess piece, e.g., \"bB\"","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" * for black bishop.","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" * @param row The row where the piece is located.","lastModifiedDate":"2023-10-16"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" * @param col The column where the piece is located.","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" * @return A ChessPiece object representing the parsed chess piece, or null if","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" * the pieceString is not recognized.","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" public static ChessPiece parseChessPiece(String pieceString, int row, int col) {","lastModifiedDate":"2023-10-15"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" switch (pieceString) {","lastModifiedDate":"2023-10-15"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" case Bishop.BISHOP_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" return new Bishop(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" case Bishop.BISHOP_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" return new Bishop(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" case King.KING_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" return new King(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" case King.KING_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" return new King(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" case Queen.QUEEN_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" return new Queen(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":" case Queen.QUEEN_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" return new Queen(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":" case Knight.KNIGHT_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":" return new Knight(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":" case Knight.KNIGHT_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":" return new Knight(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":" case Pawn.PAWN_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":" return new Pawn(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":" case Pawn.PAWN_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":" return new Pawn(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":" case Rook.ROOK_BLACK:","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":" return new Rook(row, col, Color.BLACK);","lastModifiedDate":"2023-10-22"},{"lineNumber":130,"author":{"gitId":"TongZhengHong"},"content":" case Rook.ROOK_WHITE:","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"TongZhengHong"},"content":" return new Rook(row, col, Color.WHITE);","lastModifiedDate":"2023-10-22"},{"lineNumber":132,"author":{"gitId":"TongZhengHong"},"content":" default:","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"TongZhengHong"},"content":" return new EmptyPiece(row, col);","lastModifiedDate":"2023-10-22"},{"lineNumber":134,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"TongZhengHong"},"content":" //@@author","lastModifiedDate":"2023-10-27"},{"lineNumber":137,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":138,"author":{"gitId":"TongZhengHong"},"content":" public static Command parseCommand(String in) {","lastModifiedDate":"2023-10-22"},{"lineNumber":139,"author":{"gitId":"TongZhengHong"},"content":" String[] splitInputStrings \u003d in.split(\"\\\\s+\", 2);","lastModifiedDate":"2023-10-22"},{"lineNumber":140,"author":{"gitId":"TongZhengHong"},"content":" String commandString \u003d splitInputStrings[0];","lastModifiedDate":"2023-10-22"},{"lineNumber":141,"author":{"gitId":"TongZhengHong"},"content":" String payload \u003d splitInputStrings.length \u003e 1 ? splitInputStrings[1] : \"\"; // Remaining input text","lastModifiedDate":"2023-11-04"},{"lineNumber":142,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":143,"author":{"gitId":"TongZhengHong"},"content":" switch (commandString) {","lastModifiedDate":"2023-10-22"},{"lineNumber":144,"author":{"gitId":"TongZhengHong"},"content":" case ShowMovesCommand.SHOW_MOVES_COMMAND_STRING:","lastModifiedDate":"2023-11-04"},{"lineNumber":145,"author":{"gitId":"TongZhengHong"},"content":" return new ShowMovesCommand(payload);","lastModifiedDate":"2023-11-04"},{"lineNumber":146,"author":{"gitId":"TriciaBK"},"content":" case ShowCommand.SHOW_COMAMND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"TriciaBK"},"content":" return new ShowCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"TriciaBK"},"content":" case RulesCommand.RULES_COMAMND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"TriciaBK"},"content":" return new RulesCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"TongZhengHong"},"content":" case HelpCommand.HELP_COMAMND_STRING:","lastModifiedDate":"2023-10-22"},{"lineNumber":151,"author":{"gitId":"onx001"},"content":" return new HelpCommand();","lastModifiedDate":"2023-10-19"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":" case LegendCommand.LEGEND_COMMAND_STRING:","lastModifiedDate":"2023-11-02"},{"lineNumber":153,"author":{"gitId":"TriciaBK"},"content":" return new LegendCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"TongZhengHong"},"content":" case AbortCommand.ABORT_COMAMND_STRING:","lastModifiedDate":"2023-10-22"},{"lineNumber":155,"author":{"gitId":"onx001"},"content":" return new AbortCommand();","lastModifiedDate":"2023-10-19"},{"lineNumber":156,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":157,"author":{"gitId":"onx001"},"content":" default:","lastModifiedDate":"2023-10-19"},{"lineNumber":158,"author":{"gitId":"TongZhengHong"},"content":" return new MoveCommand(in);","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":160,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":161,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":162,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":163,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":164,"author":{"gitId":"TongZhengHong"},"content":" * Parses a player\u0027s color from a provided string and returns the corresponding Color enumeration.","lastModifiedDate":"2023-11-03"},{"lineNumber":165,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":166,"author":{"gitId":"TongZhengHong"},"content":" * This method takes an input color string and converts it into the appropriate Color enumeration value, ","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"TongZhengHong"},"content":" * which can be either \u0027WHITE\u0027 or \u0027BLACK\u0027. ","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-11-03"},{"lineNumber":169,"author":{"gitId":"TongZhengHong"},"content":" * It ensures that the provided color is valid and not \u0027EMPTY\u0027 since a player color can only be black or white.","lastModifiedDate":"2023-11-03"},{"lineNumber":170,"author":{"gitId":"TongZhengHong"},"content":" * If the input does not match any valid color, a ParseColorException is thrown.","lastModifiedDate":"2023-11-03"},{"lineNumber":171,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":172,"author":{"gitId":"TongZhengHong"},"content":" * @param inputColorString A string representing the player\u0027s color (\u0027WHITE\u0027 or \u0027BLACK\u0027).","lastModifiedDate":"2023-11-03"},{"lineNumber":173,"author":{"gitId":"TongZhengHong"},"content":" * @return The Color enumeration corresponding to the parsed color.","lastModifiedDate":"2023-11-03"},{"lineNumber":174,"author":{"gitId":"TongZhengHong"},"content":" * @throws ParseColorException If the input color is not valid or if it is \u0027EMPTY\u0027.","lastModifiedDate":"2023-11-03"},{"lineNumber":175,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":176,"author":{"gitId":"TongZhengHong"},"content":" public static Color parsePlayerColor(String inputColorString) throws ParseColorException {","lastModifiedDate":"2023-10-23"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" Color color \u003d Color.valueOf(inputColorString);","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"TongZhengHong"},"content":" if (color.isEmpty()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseColorException();","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" return color;","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"TongZhengHong"},"content":" } catch (IllegalArgumentException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":184,"author":{"gitId":"TongZhengHong"},"content":" throw new ParseColorException();","lastModifiedDate":"2023-10-22"},{"lineNumber":185,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":186,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"onx001"},"content":" public static int parseDifficulty(String inputDifficultyString) throws NumberFormatException {","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"onx001"},"content":" return Integer.parseInt(inputDifficultyString);","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"onx001"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"onx001"},"content":" throw new NumberFormatException();","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":32,"antrikshdhand":1,"TriciaBK":15,"onx001":16,"TongZhengHong":132}},{"path":"src/main/java/chessmaster/pieces/Bishop.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"public class Bishop extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String BISHOP_WHITE \u003d \"b\"; // ♗","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final String BISHOP_BLACK \u003d \"B\"; // ♝","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" UP_LEFT, UP_RIGHT, DOWN_LEFT, DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 30;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {{-2,-1,-1,-1,-1,-1,-1,-2},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {-2,-1,-1,-1,-1,-1,-1,-2}};","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public Bishop(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Bishop piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" * Returns available coordinates in multiple diagonal directions from the current position. ","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" * @param board the current board","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":" * @return available coordinates in a 2D array. The first index is of the direction and the second","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"onx001"},"content":" * is of the coordinates in that direction.","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" int multiplier \u003d 1;","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" boolean isBlocked \u003d false;","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" ArrayList\u003cCoordinate\u003e possibleCoordInDirection \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" while (!isBlocked \u0026\u0026 multiplier \u003c ChessBoard.SIZE \u0026\u0026 position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" Coordinate possibleCoord \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(possibleCoord);","lastModifiedDate":"2023-10-20"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" isBlocked \u003d !destPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" possibleCoordInDirection.add(possibleCoord);","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":" } ","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" multiplier++;","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" offsetX \u003d DIRECTIONS[dir][0] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" offsetY \u003d DIRECTIONS[dir][1] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" // Convert arraylist to array","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d possibleCoordInDirection.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? BISHOP_BLACK : BISHOP_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":2,"onx001":21,"TongZhengHong":55}},{"path":"src/main/java/chessmaster/pieces/ChessPiece.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"public abstract class ChessPiece {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public static final int[] CASTLE_LEFT \u003d {-2, 0};","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[] CASTLE_RIGHT \u003d {2, 0};","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_UP_LEFT \u003d {1, -2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_UP_RIGHT \u003d {-1, -2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_DOWN_LEFT \u003d {1, 2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_DOWN_RIGHT \u003d {-1, 2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] LEFT_UP_LEFT \u003d {2, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] LEFT_DOWN_LEFT \u003d {2, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] RIGHT_UP_RIGHT \u003d {-2, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] RIGHT_DOWN_RIGHT \u003d {-2, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_UP \u003d {0, -2}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" protected static final int[] DOWN_DOWN \u003d {0, 2};","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP \u003d {0, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN \u003d {0, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] LEFT \u003d {1, 0};","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] RIGHT \u003d {-1, 0};","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_LEFT \u003d {1, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] UP_RIGHT \u003d {-1, -1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_LEFT \u003d {1, 1}; ","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" protected static final int[] DOWN_RIGHT \u003d {-1, 1};","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" protected static final String NO_AVAILABLE_MOVES_STRING \u003d ","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" \"There aren\u0027t any moves available for %s at %s!\";","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" protected static final String AVAILABLE_MOVES_STRING \u003d ","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" \"Available coordinates for %s at %s: \";","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" protected Color color;","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" protected Coordinate position;","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"onx001"},"content":" protected boolean hasMoved \u003d false;","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" protected boolean isCaptured \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"onx001"},"content":" protected int points \u003d 0;","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"onx001"},"content":" //initialise empty boardweights of 0 for parent class to be used for the AI","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" private int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" {{0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0}};","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" public ChessPiece(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" this.position \u003d new Coordinate(col, row);","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" this.color \u003d color;","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" * Returns available coordinates in multiple directions from the current position. ","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" * The directions are dependent on the chess piece type. Each inner array stores the coordinates that is","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" * in the direction the current chess piece can move to.","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" * @return A 2D array of Coordinate arrays representing available coordinates in different directions.","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"ken-ruster"},"content":" public abstract Coordinate[][] getAvailableCoordinates(ChessBoard board);","lastModifiedDate":"2023-10-20"},{"lineNumber":71,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"onx001"},"content":" * Get a flattened array of valid coordinates for the chess piece\u0027s moves based on its available coordinates ","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" * and the current state of the ChessBoard.","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" * @param board The ChessBoard representing the current game state.","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":" * @return A 1D array of valid coordinates for the piece\u0027s legal moves.","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" public Coordinate[] getFlattenedCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" Coordinate[][] availableCoordinates \u003d getAvailableCoordinates(board);","lastModifiedDate":"2023-10-19"},{"lineNumber":82,"author":{"gitId":"onx001"},"content":" ArrayList\u003cCoordinate\u003e flattenedCoordinates \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-19"},{"lineNumber":83,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":84,"author":{"gitId":"onx001"},"content":" for (Coordinate[] direction : availableCoordinates) {","lastModifiedDate":"2023-10-19"},{"lineNumber":85,"author":{"gitId":"onx001"},"content":" for (Coordinate possibleCoord : direction) {","lastModifiedDate":"2023-10-19"},{"lineNumber":86,"author":{"gitId":"onx001"},"content":" if (this.isMoveValid(possibleCoord, board)) {","lastModifiedDate":"2023-10-19"},{"lineNumber":87,"author":{"gitId":"onx001"},"content":" flattenedCoordinates.add(possibleCoord);","lastModifiedDate":"2023-10-19"},{"lineNumber":88,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":89,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":90,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":91,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":92,"author":{"gitId":"onx001"},"content":" return flattenedCoordinates.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-19"},{"lineNumber":93,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":94,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":95,"author":{"gitId":"onx001"},"content":" public boolean isWhiteKing() {","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"onx001"},"content":" return this instanceof King \u0026\u0026 this.isWhite();","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"onx001"},"content":" public boolean isBlackKing() {","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"onx001"},"content":" return this instanceof King \u0026\u0026 this.isBlack();","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"onx001"},"content":" * Returns the validity of the move to the destination coordinate.","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"onx001"},"content":" * @param destination","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"onx001"},"content":" * @param board","lastModifiedDate":"2023-10-16"},{"lineNumber":107,"author":{"gitId":"onx001"},"content":" * @return","lastModifiedDate":"2023-10-16"},{"lineNumber":108,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":109,"author":{"gitId":"onx001"},"content":" public boolean isMoveValid(Coordinate destination, ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":110,"author":{"gitId":"onx001"},"content":" Coordinate[][] availableCoordinates \u003d getAvailableCoordinates(board);","lastModifiedDate":"2023-10-17"},{"lineNumber":111,"author":{"gitId":"onx001"},"content":" for (Coordinate[] direction : availableCoordinates) {","lastModifiedDate":"2023-10-16"},{"lineNumber":112,"author":{"gitId":"onx001"},"content":" for (Coordinate possibleCoord : direction) {","lastModifiedDate":"2023-10-16"},{"lineNumber":113,"author":{"gitId":"onx001"},"content":" if (possibleCoord.equals(destination)) {","lastModifiedDate":"2023-10-16"},{"lineNumber":114,"author":{"gitId":"onx001"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(destination);","lastModifiedDate":"2023-10-20"},{"lineNumber":115,"author":{"gitId":"onx001"},"content":" if (destPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":116,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-10-16"},{"lineNumber":117,"author":{"gitId":"onx001"},"content":" } else if (destPiece.isOpponent(this)) {","lastModifiedDate":"2023-10-24"},{"lineNumber":118,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-10-16"},{"lineNumber":124,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":125,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":126,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"ken-ruster"},"content":" public String[] getAvailableCoordinatesString(ChessBoard board) {","lastModifiedDate":"2023-10-27"},{"lineNumber":128,"author":{"gitId":"ken-ruster"},"content":" StringBuilder out \u003d new StringBuilder();","lastModifiedDate":"2023-10-27"},{"lineNumber":129,"author":{"gitId":"ken-ruster"},"content":" Coordinate[][] availableCoordinates \u003d getAvailableCoordinates(board);","lastModifiedDate":"2023-10-17"},{"lineNumber":130,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"ken-ruster"},"content":" boolean isEmpty \u003d Arrays.stream(availableCoordinates).allMatch(x -\u003e x.length \u003d\u003d 0);","lastModifiedDate":"2023-11-04"},{"lineNumber":132,"author":{"gitId":"ken-ruster"},"content":" if (isEmpty) {","lastModifiedDate":"2023-11-04"},{"lineNumber":133,"author":{"gitId":"ken-ruster"},"content":" return new String[] {","lastModifiedDate":"2023-11-04"},{"lineNumber":134,"author":{"gitId":"ken-ruster"},"content":" String.format(NO_AVAILABLE_MOVES_STRING, getPieceName(), this.position)","lastModifiedDate":"2023-11-04"},{"lineNumber":135,"author":{"gitId":"ken-ruster"},"content":" };","lastModifiedDate":"2023-11-04"},{"lineNumber":136,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"ken-ruster"},"content":" for (Coordinate[] direction : availableCoordinates) {","lastModifiedDate":"2023-10-16"},{"lineNumber":139,"author":{"gitId":"ken-ruster"},"content":" for (Coordinate possibleCoord : direction) {","lastModifiedDate":"2023-10-16"},{"lineNumber":140,"author":{"gitId":"ken-ruster"},"content":" out.append(possibleCoord + \" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":141,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":142,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":143,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":144,"author":{"gitId":"ken-ruster"},"content":" return new String[] {","lastModifiedDate":"2023-10-27"},{"lineNumber":145,"author":{"gitId":"ken-ruster"},"content":" String.format(AVAILABLE_MOVES_STRING, getPieceName(), this.position),","lastModifiedDate":"2023-11-04"},{"lineNumber":146,"author":{"gitId":"ken-ruster"},"content":" out.toString()","lastModifiedDate":"2023-10-27"},{"lineNumber":147,"author":{"gitId":"ken-ruster"},"content":" };","lastModifiedDate":"2023-10-27"},{"lineNumber":148,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":149,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":150,"author":{"gitId":"ken-ruster"},"content":" //@@author","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":152,"author":{"gitId":"ken-ruster"},"content":" public Coordinate getPosition() {","lastModifiedDate":"2023-10-17"},{"lineNumber":153,"author":{"gitId":"ken-ruster"},"content":" return this.position;","lastModifiedDate":"2023-10-17"},{"lineNumber":154,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":155,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":156,"author":{"gitId":"TriciaBK"},"content":" public void updatePosition(Coordinate newCoordinate) {","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"TriciaBK"},"content":" this.position \u003d newCoordinate;","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"TongZhengHong"},"content":" public void setHasMoved() {","lastModifiedDate":"2023-10-22"},{"lineNumber":161,"author":{"gitId":"TongZhengHong"},"content":" this.hasMoved \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":162,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":163,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":164,"author":{"gitId":"onx001"},"content":" public boolean getHasMoved() {","lastModifiedDate":"2023-10-19"},{"lineNumber":165,"author":{"gitId":"onx001"},"content":" return this.hasMoved;","lastModifiedDate":"2023-10-19"},{"lineNumber":166,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":167,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":168,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-22"},{"lineNumber":169,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-22"},{"lineNumber":170,"author":{"gitId":"TongZhengHong"},"content":" return \"ChessPiece [color\u003d\" + color + \", position\u003d\" + position + \"]\";","lastModifiedDate":"2023-10-22"},{"lineNumber":171,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":172,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":173,"author":{"gitId":"TongZhengHong"},"content":" public Color getColor() {","lastModifiedDate":"2023-10-22"},{"lineNumber":174,"author":{"gitId":"TongZhengHong"},"content":" return color;","lastModifiedDate":"2023-10-22"},{"lineNumber":175,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":176,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" public boolean getIsCaptured() {","lastModifiedDate":"2023-10-22"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" return this.isCaptured;","lastModifiedDate":"2023-10-22"},{"lineNumber":179,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":180,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":" public void setIsCaptured() {","lastModifiedDate":"2023-10-22"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" this.isCaptured \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":183,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":184,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":185,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":187,"author":{"gitId":"onx001"},"content":" * Returns the points of the ChessPiece object. ","lastModifiedDate":"2023-10-26"},{"lineNumber":188,"author":{"gitId":"onx001"},"content":" * The points are calculated based on the ChessPiece\u0027s position","lastModifiedDate":"2023-10-26"},{"lineNumber":189,"author":{"gitId":"onx001"},"content":" * @param isUpright Whether the chess board is aligned to the player it is processed for.","lastModifiedDate":"2023-10-26"},{"lineNumber":190,"author":{"gitId":"onx001"},"content":" * @return The points of the ChessPiece object.","lastModifiedDate":"2023-10-26"},{"lineNumber":191,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":192,"author":{"gitId":"onx001"},"content":" public int getPoints(boolean isUpright) {","lastModifiedDate":"2023-10-26"},{"lineNumber":193,"author":{"gitId":"onx001"},"content":" int boardPoints;","lastModifiedDate":"2023-10-26"},{"lineNumber":194,"author":{"gitId":"onx001"},"content":" if (isUpright) {","lastModifiedDate":"2023-10-26"},{"lineNumber":195,"author":{"gitId":"onx001"},"content":" //finds board weight points of a friendly piece","lastModifiedDate":"2023-10-26"},{"lineNumber":196,"author":{"gitId":"onx001"},"content":" boardPoints \u003d boardWeight[position.getX()][position.getY()];","lastModifiedDate":"2023-10-26"},{"lineNumber":197,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":198,"author":{"gitId":"onx001"},"content":" //finds board weight points of an opponent piece","lastModifiedDate":"2023-10-26"},{"lineNumber":199,"author":{"gitId":"onx001"},"content":" boardPoints \u003d boardWeight[7 - position.getX()][position.getY()];","lastModifiedDate":"2023-10-26"},{"lineNumber":200,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":201,"author":{"gitId":"onx001"},"content":" //adds the board weight points to the piece\u0027s points","lastModifiedDate":"2023-10-26"},{"lineNumber":202,"author":{"gitId":"onx001"},"content":" int points \u003d this.points + boardPoints;","lastModifiedDate":"2023-10-26"},{"lineNumber":203,"author":{"gitId":"onx001"},"content":" return points;","lastModifiedDate":"2023-10-26"},{"lineNumber":204,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":205,"author":{"gitId":"onx001"},"content":" //@@author","lastModifiedDate":"2023-10-31"},{"lineNumber":206,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":207,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":208,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the ChessPiece object has the same color as a given color.","lastModifiedDate":"2023-10-22"},{"lineNumber":209,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":210,"author":{"gitId":"TongZhengHong"},"content":" * @param color The color to compare with the ChessPiece\u0027s color.","lastModifiedDate":"2023-10-22"},{"lineNumber":211,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the ChessPiece has the same color as the provided color; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":212,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":213,"author":{"gitId":"TongZhengHong"},"content":" public boolean isSameColorAs(Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":214,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":215,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":216,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":217,"author":{"gitId":"TongZhengHong"},"content":" return this.color \u003d\u003d color;","lastModifiedDate":"2023-10-22"},{"lineNumber":218,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":219,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":220,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":221,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the ChessPiece object is WHTIE.","lastModifiedDate":"2023-10-22"},{"lineNumber":222,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":223,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the ChessPiece is white; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":224,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":225,"author":{"gitId":"TongZhengHong"},"content":" public boolean isWhite() {","lastModifiedDate":"2023-10-22"},{"lineNumber":226,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":227,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":228,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":229,"author":{"gitId":"TongZhengHong"},"content":" return this.color \u003d\u003d Color.WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":230,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":231,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":232,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":233,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the ChessPiece object is BLACK.","lastModifiedDate":"2023-10-22"},{"lineNumber":234,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":235,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the ChessPiece is white; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":236,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":237,"author":{"gitId":"TongZhengHong"},"content":" public boolean isBlack() {","lastModifiedDate":"2023-10-22"},{"lineNumber":238,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":239,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":240,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":241,"author":{"gitId":"TongZhengHong"},"content":" return this.color \u003d\u003d Color.BLACK;","lastModifiedDate":"2023-10-22"},{"lineNumber":242,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":243,"author":{"gitId":"antrikshdhand"},"content":" ","lastModifiedDate":"2023-10-19"},{"lineNumber":244,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the provided ChessPiece object is friendly (has the same color) as the current ChessPiece.","lastModifiedDate":"2023-10-22"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" * @param chessPiece The ChessPiece to compare with.","lastModifiedDate":"2023-10-22"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the provided ChessPiece is friendly; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":" public boolean isFriendly(ChessPiece chessPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":251,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":252,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":253,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":254,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece.color \u003d\u003d this.color;","lastModifiedDate":"2023-10-22"},{"lineNumber":255,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":256,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":257,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":258,"author":{"gitId":"TongZhengHong"},"content":" * Checks if the provided ChessPiece is an opponent (has a different color) compared to the current ChessPiece.","lastModifiedDate":"2023-10-22"},{"lineNumber":259,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":260,"author":{"gitId":"TongZhengHong"},"content":" * @param chessPiece The ChessPiece to compare with.","lastModifiedDate":"2023-10-22"},{"lineNumber":261,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the provided ChessPiece is an opponent; false otherwise.","lastModifiedDate":"2023-10-22"},{"lineNumber":262,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":263,"author":{"gitId":"TongZhengHong"},"content":" public boolean isOpponent(ChessPiece chessPiece) {","lastModifiedDate":"2023-10-22"},{"lineNumber":264,"author":{"gitId":"TongZhengHong"},"content":" if (isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":265,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-10-22"},{"lineNumber":266,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":267,"author":{"gitId":"TongZhengHong"},"content":" return chessPiece.color !\u003d this.color;","lastModifiedDate":"2023-10-22"},{"lineNumber":268,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":269,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":270,"author":{"gitId":"TongZhengHong"},"content":" public boolean isEmptyPiece() {","lastModifiedDate":"2023-10-22"},{"lineNumber":271,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof EmptyPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":272,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":273,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":274,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPawn() {","lastModifiedDate":"2023-10-31"},{"lineNumber":275,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof Pawn;","lastModifiedDate":"2023-10-31"},{"lineNumber":276,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":277,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":278,"author":{"gitId":"TongZhengHong"},"content":" public boolean isPromotionPiece() {","lastModifiedDate":"2023-10-22"},{"lineNumber":279,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof Queen || this instanceof Rook ","lastModifiedDate":"2023-10-22"},{"lineNumber":280,"author":{"gitId":"TongZhengHong"},"content":" || this instanceof Bishop || this instanceof Knight;","lastModifiedDate":"2023-10-22"},{"lineNumber":281,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":282,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":283,"author":{"gitId":"TongZhengHong"},"content":" public String getPieceName() {","lastModifiedDate":"2023-10-27"},{"lineNumber":284,"author":{"gitId":"TongZhengHong"},"content":" return this.getClass().getSimpleName();","lastModifiedDate":"2023-10-27"},{"lineNumber":285,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":286,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":287,"author":{"gitId":"onx001"},"content":" protected void setPoints(int points) {","lastModifiedDate":"2023-10-23"},{"lineNumber":288,"author":{"gitId":"onx001"},"content":" this.points \u003d points;","lastModifiedDate":"2023-10-23"},{"lineNumber":289,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":290,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":291,"author":{"gitId":"onx001"},"content":" protected void setBoardWeight(int[][] boardWeight) {","lastModifiedDate":"2023-10-26"},{"lineNumber":292,"author":{"gitId":"onx001"},"content":" this.boardWeight \u003d boardWeight;","lastModifiedDate":"2023-10-26"},{"lineNumber":293,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":294,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":35,"antrikshdhand":2,"TriciaBK":4,"onx001":117,"TongZhengHong":136}},{"path":"src/main/java/chessmaster/pieces/EmptyPiece.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-20"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"public class EmptyPiece extends ChessPiece {","lastModifiedDate":"2023-10-20"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String EMPTY_PIECE \u003d \".\";","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public EmptyPiece(int row, int col) {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, Color.EMPTY);","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" @Override","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" return new Coordinate[0][];","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" // An empty piece will never be moved","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" public boolean getHasMoved() {","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" //returns the string representation of the empty piece for cloning","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" return EMPTY_PIECE;","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"ken-ruster":15,"onx001":6,"TongZhengHong":10}},{"path":"src/main/java/chessmaster/pieces/King.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class King extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public static final String KING_WHITE \u003d \"k\"; // ♔","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String KING_BLACK \u003d \"K\"; // ♚","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" public static final int POINTS \u003d 1000;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" public static final int[][] BOARDWEIGHT \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" {{-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" {-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":" {-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" {-3,-4,-4,-5,-5,-4,-4,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" {-2,-3,-3,-4,-4,-3,-3,-2},","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" {-1,-2,-2,-2,-2,-2,-2,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" {2,2,0,0,0,0,2,2},","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {2,3,1,0,0,1,3,2}};","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" UP, DOWN, LEFT, RIGHT, UP_LEFT, UP_RIGHT, DOWN_LEFT, DOWN_RIGHT, CASTLE_LEFT, CASTLE_RIGHT","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" protected static int points \u003d 1000;","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public King(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(BOARDWEIGHT);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"King piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" if (!position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" continue; // Possible coordinate out of board","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoor \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(newCoor);","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" if (DIRECTIONS[dir] \u003d\u003d CASTLE_LEFT) {","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos1 \u003d position.addOffsetToCoordinate(-1, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":52,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos2 \u003d position.addOffsetToCoordinate(-2, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":53,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos3 \u003d position.addOffsetToCoordinate(-3, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" Coordinate rookPos \u003d position.addOffsetToCoordinate(-4, 0);","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" boolean hasRookMoved \u003d board.getPieceAtCoor(rookPos).hasMoved;","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" boolean isSidesEmpty \u003d board.getPieceAtCoor(pos1).isEmptyPiece() ","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 board.getPieceAtCoor(pos2).isEmptyPiece() ","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 board.getPieceAtCoor(pos3).isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" if (isSidesEmpty \u0026\u0026 !hasRookMoved \u0026\u0026 !hasMoved) {","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" } else if (DIRECTIONS[dir] \u003d\u003d CASTLE_RIGHT) {","lastModifiedDate":"2023-10-22"},{"lineNumber":66,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos1 \u003d position.addOffsetToCoordinate(+1, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":67,"author":{"gitId":"ken-ruster"},"content":" Coordinate pos2 \u003d position.addOffsetToCoordinate(+2, 0);","lastModifiedDate":"2023-10-20"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" Coordinate rookPos \u003d position.addOffsetToCoordinate(+3, 0);","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" boolean hasRookMoved \u003d board.getPieceAtCoor(rookPos).hasMoved;","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" boolean isSidesEmpty \u003d board.getPieceAtCoor(pos1).isEmptyPiece() ","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 board.getPieceAtCoor(pos2).isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" if (isSidesEmpty \u0026\u0026 !hasRookMoved \u0026\u0026 !hasMoved) {","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":76,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" } else { // Normal or capture move","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[] { position.addOffsetToCoordinate(offsetX, offsetY) };","lastModifiedDate":"2023-10-22"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? KING_BLACK : KING_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":15,"onx001":17,"TongZhengHong":61}},{"path":"src/main/java/chessmaster/pieces/Knight.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class Knight extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public static final String KNIGHT_WHITE \u003d \"n\"; // ♘","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String KNIGHT_BLACK \u003d \"N\"; // ♞","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" UP_UP_LEFT, UP_UP_RIGHT, DOWN_DOWN_LEFT, DOWN_DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" LEFT_UP_LEFT, LEFT_DOWN_LEFT, RIGHT_UP_RIGHT, RIGHT_DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 30;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" {{-5,-4,-3,-3,-3,-3,-4,-5},","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {-4,-2,0,0,0,0,-2,-4},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {-3,0,1,2,2,1,0,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-3,1,2,3,3,2,1,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-3,0,2,3,3,2,0,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-3,1,1,2,2,1,1,-3},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-4,-2,0,1,1,0,-2,-4},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-5,-4,-3,-3,-3,-3,-4,-5}};","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" public Knight(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Knight piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" public String toString() {","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? KNIGHT_BLACK : KNIGHT_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" if (!position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" continue; // Possible coordinate out of board","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoor \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(newCoor);","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":4,"onx001":17,"TongZhengHong":41}},{"path":"src/main/java/chessmaster/pieces/Pawn.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"public class Pawn extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" public static final String PAWN_WHITE \u003d \"p\"; // ♙","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String PAWN_BLACK \u003d \"P\"; // ♟","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS_UP \u003d {","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" UP_LEFT, UP_RIGHT, UP, UP_UP,","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS_DOWN \u003d {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" DOWN_LEFT, DOWN_RIGHT, DOWN, DOWN_DOWN,","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" };","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 10;","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {{0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {5,5,5,5,5,5,5,5},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {1,1,2,3,3,2,1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {1,1,1,4,4,1,1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {0,0,0,3,3,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {1,-1,-1,0,0,-1,-1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {1,1,1,-2,-2,1,1,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"onx001"},"content":" {0,0,0,0,0,0,0,0}};","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" protected boolean enPassed \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" public Pawn(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Pawn piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS_UP.length][0];","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int[][] directions \u003d board.isPieceFriendly(this) ? DIRECTIONS_UP : DIRECTIONS_DOWN;","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS_UP.length; dir++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" int offsetX \u003d directions[dir][0];","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" int offsetY \u003d directions[dir][1];","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" if (!position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" continue; // Possible coordinate out of board","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoor \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(newCoor);","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (directions[dir] \u003d\u003d UP_LEFT || directions[dir] \u003d\u003d UP_RIGHT || ","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" directions[dir] \u003d\u003d DOWN_LEFT || directions[dir] \u003d\u003d DOWN_RIGHT) {","lastModifiedDate":"2023-10-22"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" // Diagonal move: Destination tile has opponent piece","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" if (!destPiece.isEmptyPiece() \u0026\u0026 isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" } else if (directions[dir] \u003d\u003d UP || directions[dir] \u003d\u003d DOWN) {","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" // Normal move: when destination tile is empty","lastModifiedDate":"2023-10-22"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":64,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" } else if (directions[dir] \u003d\u003d UP_UP || directions[dir] \u003d\u003d DOWN_DOWN) {","lastModifiedDate":"2023-10-22"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" // Double move: first move AND when destination empty AND no blocking piece","lastModifiedDate":"2023-10-22"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" Coordinate blockPos \u003d board.isPieceFriendly(this) ","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" ? position.addOffsetToCoordinate(UP[0], UP[1])","lastModifiedDate":"2023-10-22"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" : position.addOffsetToCoordinate(DOWN[0], DOWN[1]); ","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"ken-ruster"},"content":" ChessPiece blockPiece \u003d board.getPieceAtCoor(blockPos);","lastModifiedDate":"2023-10-20"},{"lineNumber":72,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" if (!hasMoved \u0026\u0026 blockPiece.isEmptyPiece() \u0026\u0026 destPiece.isEmptyPiece()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d new Coordinate[]{ newCoor };","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":76,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":77,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"onx001"},"content":" return result;","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":81,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? PAWN_BLACK : PAWN_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":6,"onx001":26,"TongZhengHong":54}},{"path":"src/main/java/chessmaster/pieces/Queen.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"public class Queen extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String QUEEN_WHITE \u003d \"q\"; // ♕","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final String QUEEN_BLACK \u003d \"Q\"; // ♛","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" UP, DOWN, LEFT, RIGHT, UP_LEFT, UP_RIGHT, DOWN_LEFT, DOWN_RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 90;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d ","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {{-2,-1,-1,-1,-1,-1,-1,-2},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-1,0,1,1,1,1,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {-2,-1,-1,-1,-1,-1,-1,-2}};","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public Queen(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Queen piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" int multiplier \u003d 1;","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" boolean isBlocked \u003d false;","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" ArrayList\u003cCoordinate\u003e possibleCoordInDirection \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" while (!isBlocked \u0026\u0026 multiplier \u003c ChessBoard.SIZE \u0026\u0026 position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" Coordinate possibleCoord \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(possibleCoord);","lastModifiedDate":"2023-10-20"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" isBlocked \u003d !destPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" possibleCoordInDirection.add(possibleCoord);","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" } ","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" multiplier++;","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" offsetX \u003d DIRECTIONS[dir][0] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" offsetY \u003d DIRECTIONS[dir][1] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" // Convert arraylist to array","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d possibleCoordInDirection.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? QUEEN_BLACK : QUEEN_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":2,"onx001":14,"TongZhengHong":57}},{"path":"src/main/java/chessmaster/pieces/Rook.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.pieces;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"public class Rook extends ChessPiece {","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String ROOK_WHITE \u003d \"r\"; // ♖","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public static final String ROOK_BLACK \u003d \"R\"; // ♜","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public static final int[][] DIRECTIONS \u003d {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" UP, DOWN, LEFT, RIGHT,","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" protected static int points \u003d 50;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" protected static int[][] boardWeight \u003d","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" {{0,0,0,0,0,0,0,0},","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" {1,2,2,2,2,2,2,1},","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"onx001"},"content":" {-1,0,0,0,0,0,0,-1},","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"onx001"},"content":" {0,0,0,1,1,0,0,0}};","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public Rook(int row, int col, Color color) {","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" super(row, col, color);","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"onx001"},"content":" this.setPoints(points);","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"onx001"},"content":" this.setBoardWeight(boardWeight);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" assert color !\u003d Color.EMPTY : \"Rook piece should have either black or white color\";","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":" public Coordinate[][] getAvailableCoordinates(ChessBoard board) {","lastModifiedDate":"2023-10-20"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" Coordinate[][] result \u003d new Coordinate[DIRECTIONS.length][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" for (int dir \u003d 0; dir \u003c DIRECTIONS.length; dir++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" int offsetX \u003d DIRECTIONS[dir][0];","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" int offsetY \u003d DIRECTIONS[dir][1];","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" int multiplier \u003d 1;","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"onx001"},"content":" boolean isBlocked \u003d false;","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" ArrayList\u003cCoordinate\u003e possibleCoordInDirection \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" while (!isBlocked \u0026\u0026 multiplier \u003c ChessBoard.SIZE \u0026\u0026 position.isOffsetWithinBoard(offsetX, offsetY)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" Coordinate possibleCoord \u003d position.addOffsetToCoordinate(offsetX, offsetY);","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" ChessPiece destPiece \u003d board.getPieceAtCoor(possibleCoord);","lastModifiedDate":"2023-10-20"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" isBlocked \u003d !destPiece.isEmptyPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" if (destPiece.isEmptyPiece() || isOpponent(destPiece)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" possibleCoordInDirection.add(possibleCoord);","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" } ","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" multiplier++;","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" offsetX \u003d DIRECTIONS[dir][0] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" offsetY \u003d DIRECTIONS[dir][1] * multiplier;","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" // Convert arraylist to array","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" result[dir] \u003d possibleCoordInDirection.toArray(new Coordinate[0]);","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" return result;","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" return color \u003d\u003d Color.BLACK ? ROOK_BLACK : ROOK_WHITE;","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":2,"onx001":15,"TongZhengHong":56}},{"path":"src/main/java/chessmaster/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TriciaBK"},"content":"package chessmaster.storage;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.exceptions.LoadBoardException;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.exceptions.SaveBoardException;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TriciaBK"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"TriciaBK"},"content":"import java.io.File;","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"TriciaBK"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"TriciaBK"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"TriciaBK"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"TriciaBK"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"TriciaBK"},"content":"public class Storage {","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"TriciaBK"},"content":" private String filePathString;","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"TriciaBK"},"content":" private File storageFile;","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"TriciaBK"},"content":" private int blackPieceNum;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TriciaBK"},"content":" private int whitePieceNum;","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"TriciaBK"},"content":" private boolean blackKingPresent;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"TriciaBK"},"content":" private boolean whiteKingPresent;","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"TriciaBK"},"content":" private Scanner fileScanner;","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"TriciaBK"},"content":" public Storage(String filePath) {","lastModifiedDate":"2023-10-20"},{"lineNumber":31,"author":{"gitId":"TriciaBK"},"content":" filePathString \u003d filePath;","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"TriciaBK"},"content":" storageFile \u003d new File(filePath);","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"TriciaBK"},"content":" assert !filePathString.isEmpty() \u0026\u0026 filePath !\u003d null : \"File path cannot be empty or null\";","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * Creates a ChessMaster program file to store game state, including necessary","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" * parent directories.","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" * @throws ChessMasterException If there is an error creating the file or parent","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" * directories.","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" private void createChessMasterFile() throws ChessMasterException {","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" // Create the necessary parent directories for new file","lastModifiedDate":"2023-10-22"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" if (!storageFile.exists()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" storageFile.getParentFile().mkdirs();","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" // Create file if it does not exist","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" storageFile.createNewFile();","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" throw new ChessMasterException(\"Fatal: Error creating file: \" + filePathString);","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"TriciaBK"},"content":" /**","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"TriciaBK"},"content":" * Saves the state of the ChessBoard to a file. Writes the player\u0027s color to the","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"TriciaBK"},"content":" * first line","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"TriciaBK"},"content":" * and subsequently chess pieces in a 8 x 8 format.","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"TriciaBK"},"content":" *","lastModifiedDate":"2023-10-20"},{"lineNumber":64,"author":{"gitId":"TriciaBK"},"content":" * @param board The ChessBoard to save.","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"TriciaBK"},"content":" * @throws ChessMasterException If there is an error saving the board to a file.","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"TriciaBK"},"content":" */","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"TriciaBK"},"content":" public void saveBoard(ChessBoard board, Color currentColor) throws ChessMasterException {","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"TriciaBK"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-22"},{"lineNumber":69,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":70,"author":{"gitId":"TriciaBK"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"TriciaBK"},"content":" FileWriter fileWriter \u003d new FileWriter(storageFile);","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(board.getPlayerColor().name());","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(String.valueOf(board.getDifficulty()));","lastModifiedDate":"2023-11-01"},{"lineNumber":76,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":77,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":78,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(currentColor.name());","lastModifiedDate":"2023-11-03"},{"lineNumber":79,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"TriciaBK"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":82,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":83,"author":{"gitId":"TriciaBK"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(new Coordinate(col, row));","lastModifiedDate":"2023-10-20"},{"lineNumber":84,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(piece.toString());","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":89,"author":{"gitId":"TriciaBK"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":90,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"TriciaBK"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(new Coordinate(col, row));","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"TriciaBK"},"content":" String hasMovedString \u003d piece.getHasMoved() ? \"1\" : \"0\";","lastModifiedDate":"2023-11-03"},{"lineNumber":93,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(hasMovedString);","lastModifiedDate":"2023-11-03"},{"lineNumber":94,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":95,"author":{"gitId":"TriciaBK"},"content":" fileWriter.write(System.lineSeparator());","lastModifiedDate":"2023-11-03"},{"lineNumber":96,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":97,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":98,"author":{"gitId":"TriciaBK"},"content":" fileWriter.close();","lastModifiedDate":"2023-10-22"},{"lineNumber":99,"author":{"gitId":"TriciaBK"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":100,"author":{"gitId":"TriciaBK"},"content":" throw new SaveBoardException();","lastModifiedDate":"2023-10-17"},{"lineNumber":101,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":103,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" public void resetBoard() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-23"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" FileWriter fileWriter \u003d new FileWriter(storageFile);","lastModifiedDate":"2023-10-23"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" fileWriter.write(\"\");","lastModifiedDate":"2023-10-23"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":" fileWriter.close();","lastModifiedDate":"2023-10-23"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":" throw new SaveBoardException();","lastModifiedDate":"2023-10-23"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":117,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-10-27"},{"lineNumber":118,"author":{"gitId":"TriciaBK"},"content":" /**","lastModifiedDate":"2023-10-20"},{"lineNumber":119,"author":{"gitId":"TriciaBK"},"content":" * Loads the state of the chessboard from a file.","lastModifiedDate":"2023-10-23"},{"lineNumber":120,"author":{"gitId":"TriciaBK"},"content":" * Ignores the first line player color information as it can be retrieved with","lastModifiedDate":"2023-10-23"},{"lineNumber":121,"author":{"gitId":"TriciaBK"},"content":" * loadPlayerColor() method","lastModifiedDate":"2023-10-23"},{"lineNumber":122,"author":{"gitId":"TriciaBK"},"content":" *","lastModifiedDate":"2023-10-20"},{"lineNumber":123,"author":{"gitId":"TriciaBK"},"content":" * @return A 2D array of ChessTile objects representing the loaded chessboard.","lastModifiedDate":"2023-10-23"},{"lineNumber":124,"author":{"gitId":"TriciaBK"},"content":" * @throws ChessMasterException If there is an error loading the board from the","lastModifiedDate":"2023-10-23"},{"lineNumber":125,"author":{"gitId":"TriciaBK"},"content":" * file.","lastModifiedDate":"2023-10-23"},{"lineNumber":126,"author":{"gitId":"TriciaBK"},"content":" */","lastModifiedDate":"2023-10-20"},{"lineNumber":127,"author":{"gitId":"TriciaBK"},"content":" public ChessTile[][] loadBoard() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":128,"author":{"gitId":"TriciaBK"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-22"},{"lineNumber":129,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":130,"author":{"gitId":"TriciaBK"},"content":" blackPieceNum \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"TriciaBK"},"content":" whitePieceNum \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"TriciaBK"},"content":" blackKingPresent \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"TriciaBK"},"content":" whiteKingPresent \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"TriciaBK"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":136,"author":{"gitId":"TriciaBK"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-10-22"},{"lineNumber":137,"author":{"gitId":"TriciaBK"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-10-22"},{"lineNumber":138,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-10-22"},{"lineNumber":139,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":140,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":141,"author":{"gitId":"TriciaBK"},"content":" // Skip first three lines","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"TriciaBK"},"content":" for (int i \u003d 0; i \u003c 3; i++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"TriciaBK"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"TriciaBK"},"content":" int rowIndex \u003d 0;","lastModifiedDate":"2023-10-22"},{"lineNumber":149,"author":{"gitId":"TriciaBK"},"content":" ChessTile[][] boardTiles \u003d new ChessTile[ChessBoard.SIZE][ChessBoard.SIZE];","lastModifiedDate":"2023-10-22"},{"lineNumber":150,"author":{"gitId":"TriciaBK"},"content":" while (rowIndex \u003c ChessBoard.SIZE \u0026\u0026 fileScanner.hasNext()) {","lastModifiedDate":"2023-10-22"},{"lineNumber":151,"author":{"gitId":"TriciaBK"},"content":" String chessRowLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-10-22"},{"lineNumber":152,"author":{"gitId":"TriciaBK"},"content":" if (chessRowLine.length() !\u003d ChessBoard.SIZE) {","lastModifiedDate":"2023-10-22"},{"lineNumber":153,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-22"},{"lineNumber":154,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-10-17"},{"lineNumber":155,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":156,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":157,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":158,"author":{"gitId":"TriciaBK"},"content":" String chessPieceString \u003d String.valueOf(chessRowLine.charAt(col));","lastModifiedDate":"2023-10-22"},{"lineNumber":159,"author":{"gitId":"TriciaBK"},"content":" ChessPiece initialPiece \u003d Parser.parseChessPiece(chessPieceString, rowIndex, col);","lastModifiedDate":"2023-10-22"},{"lineNumber":160,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"onx001"},"content":" if (!this.isPieceValid(initialPiece)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"onx001"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"TriciaBK"},"content":" boardTiles[rowIndex][col] \u003d new ChessTile(initialPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":167,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"TriciaBK"},"content":" rowIndex++;","lastModifiedDate":"2023-10-22"},{"lineNumber":169,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":170,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":171,"author":{"gitId":"TriciaBK"},"content":" boolean hasBothKings \u003d blackKingPresent \u0026\u0026 whiteKingPresent;","lastModifiedDate":"2023-11-03"},{"lineNumber":172,"author":{"gitId":"TriciaBK"},"content":" if (!hasBothKings) {","lastModifiedDate":"2023-11-03"},{"lineNumber":173,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"TriciaBK"},"content":" rowIndex \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":178,"author":{"gitId":"TriciaBK"},"content":" while (rowIndex \u003c ChessBoard.SIZE \u0026\u0026 fileScanner.hasNext()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":179,"author":{"gitId":"TriciaBK"},"content":" String chessRowLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":180,"author":{"gitId":"TriciaBK"},"content":" if (chessRowLine.length() !\u003d ChessBoard.SIZE) {","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-03"},{"lineNumber":183,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":184,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":185,"author":{"gitId":"TriciaBK"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-11-03"},{"lineNumber":186,"author":{"gitId":"TriciaBK"},"content":" boolean hasMoved \u003d Character.getNumericValue(chessRowLine.charAt(col)) \u003e 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":187,"author":{"gitId":"TriciaBK"},"content":" if (hasMoved) {","lastModifiedDate":"2023-11-03"},{"lineNumber":188,"author":{"gitId":"TriciaBK"},"content":" boardTiles[rowIndex][col].getChessPiece().setHasMoved();","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":192,"author":{"gitId":"TriciaBK"},"content":" rowIndex++;","lastModifiedDate":"2023-11-03"},{"lineNumber":193,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":194,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":195,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"TriciaBK"},"content":" return boardTiles;","lastModifiedDate":"2023-10-23"},{"lineNumber":197,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":198,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":199,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-03"},{"lineNumber":200,"author":{"gitId":"onx001"},"content":" private boolean isPieceValid (ChessPiece initialPiece) {","lastModifiedDate":"2023-11-03"},{"lineNumber":201,"author":{"gitId":"onx001"},"content":" if (initialPiece.isBlackKing()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":202,"author":{"gitId":"onx001"},"content":" if (blackKingPresent) {","lastModifiedDate":"2023-11-03"},{"lineNumber":203,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":204,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":205,"author":{"gitId":"onx001"},"content":" blackKingPresent \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":206,"author":{"gitId":"onx001"},"content":" blackPieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"onx001"},"content":" } else if (initialPiece.isWhiteKing()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"onx001"},"content":" if (whiteKingPresent) {","lastModifiedDate":"2023-11-03"},{"lineNumber":210,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":211,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":212,"author":{"gitId":"onx001"},"content":" whiteKingPresent \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":213,"author":{"gitId":"onx001"},"content":" whitePieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":215,"author":{"gitId":"onx001"},"content":" } else if (initialPiece.isBlack()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":216,"author":{"gitId":"onx001"},"content":" if (blackPieceNum \u003e\u003d ChessBoard.MAX_PIECES) {","lastModifiedDate":"2023-11-03"},{"lineNumber":217,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":218,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":219,"author":{"gitId":"onx001"},"content":" blackPieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":220,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"onx001"},"content":" } else if (initialPiece.isWhite()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"onx001"},"content":" if (whitePieceNum \u003e\u003d ChessBoard.MAX_PIECES) {","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"onx001"},"content":" return false;","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-03"},{"lineNumber":225,"author":{"gitId":"onx001"},"content":" whitePieceNum++;","lastModifiedDate":"2023-11-03"},{"lineNumber":226,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":227,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":228,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":229,"author":{"gitId":"onx001"},"content":" return true;","lastModifiedDate":"2023-11-03"},{"lineNumber":230,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":231,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":232,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-10-27"},{"lineNumber":233,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":234,"author":{"gitId":"TongZhengHong"},"content":" * Loads the player\u0027s color from a file.","lastModifiedDate":"2023-10-23"},{"lineNumber":235,"author":{"gitId":"TongZhengHong"},"content":" * Expects the player color information on the first line of text file.","lastModifiedDate":"2023-10-23"},{"lineNumber":236,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":237,"author":{"gitId":"TongZhengHong"},"content":" * @return The player\u0027s color as a Color enumeration.","lastModifiedDate":"2023-10-23"},{"lineNumber":238,"author":{"gitId":"TongZhengHong"},"content":" * @throws ChessMasterException If there is an error loading the player\u0027s color","lastModifiedDate":"2023-10-23"},{"lineNumber":239,"author":{"gitId":"TongZhengHong"},"content":" * from the file.","lastModifiedDate":"2023-10-23"},{"lineNumber":240,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":241,"author":{"gitId":"TongZhengHong"},"content":" public Color loadPlayerColor() throws ChessMasterException {","lastModifiedDate":"2023-10-23"},{"lineNumber":242,"author":{"gitId":"TongZhengHong"},"content":" createChessMasterFile();","lastModifiedDate":"2023-10-23"},{"lineNumber":243,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":244,"author":{"gitId":"TongZhengHong"},"content":" Scanner fileScanner;","lastModifiedDate":"2023-10-23"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-10-23"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-10-23"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-10-23"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":251,"author":{"gitId":"TongZhengHong"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":252,"author":{"gitId":"TongZhengHong"},"content":" String colorLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-10-23"},{"lineNumber":253,"author":{"gitId":"TongZhengHong"},"content":" Color playerColor \u003d Parser.parsePlayerColor(colorLine);","lastModifiedDate":"2023-10-23"},{"lineNumber":254,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":255,"author":{"gitId":"TongZhengHong"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-23"},{"lineNumber":256,"author":{"gitId":"TongZhengHong"},"content":" return playerColor;","lastModifiedDate":"2023-10-23"},{"lineNumber":257,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":258,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":259,"author":{"gitId":"TongZhengHong"},"content":" fileScanner.close();","lastModifiedDate":"2023-10-23"},{"lineNumber":260,"author":{"gitId":"TongZhengHong"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-10-23"},{"lineNumber":261,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":262,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"onx001"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"onx001"},"content":" * Loads the difficulty from a file.","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"onx001"},"content":" * Expects the difficulty information on the second line of text file.","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"onx001"},"content":" * @return The difficulty as an integer.","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"onx001"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":269,"author":{"gitId":"onx001"},"content":" public int loadDifficulty() throws ChessMasterException {","lastModifiedDate":"2023-11-01"},{"lineNumber":270,"author":{"gitId":"onx001"},"content":" createChessMasterFile();","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"onx001"},"content":" Scanner fileScanner;","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"onx001"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"onx001"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":279,"author":{"gitId":"onx001"},"content":" // Skip player color first line","lastModifiedDate":"2023-11-03"},{"lineNumber":280,"author":{"gitId":"onx001"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"onx001"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":282,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":283,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":284,"author":{"gitId":"onx001"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":285,"author":{"gitId":"onx001"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":286,"author":{"gitId":"onx001"},"content":" String difficultyLine \u003d fileScanner.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"onx001"},"content":" int difficulty \u003d Parser.parseDifficulty(difficultyLine);","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"onx001"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"onx001"},"content":" if (difficulty \u003c 1 || difficulty \u003e 3) {","lastModifiedDate":"2023-11-03"},{"lineNumber":291,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-03"},{"lineNumber":292,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":293,"author":{"gitId":"onx001"},"content":" return difficulty;","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"onx001"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"onx001"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-01"},{"lineNumber":300,"author":{"gitId":"onx001"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-01"},{"lineNumber":301,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":302,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":303,"author":{"gitId":"TriciaBK"},"content":" //@@author TriciaBK","lastModifiedDate":"2023-11-02"},{"lineNumber":304,"author":{"gitId":"TriciaBK"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":305,"author":{"gitId":"TriciaBK"},"content":" * Loads the current turn player\u0027s","lastModifiedDate":"2023-11-02"},{"lineNumber":306,"author":{"gitId":"TriciaBK"},"content":" * @return The difficulty as an integer.","lastModifiedDate":"2023-11-02"},{"lineNumber":307,"author":{"gitId":"TriciaBK"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":308,"author":{"gitId":"TriciaBK"},"content":" public Color loadCurrentColor() throws ChessMasterException {","lastModifiedDate":"2023-11-02"},{"lineNumber":309,"author":{"gitId":"TriciaBK"},"content":" createChessMasterFile();","lastModifiedDate":"2023-11-02"},{"lineNumber":310,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":311,"author":{"gitId":"TriciaBK"},"content":" Scanner fileScanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":312,"author":{"gitId":"TriciaBK"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":313,"author":{"gitId":"TriciaBK"},"content":" fileScanner \u003d new Scanner(storageFile);","lastModifiedDate":"2023-11-02"},{"lineNumber":314,"author":{"gitId":"TriciaBK"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":315,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException(\"Invalid file path: \" + filePathString);","lastModifiedDate":"2023-11-02"},{"lineNumber":316,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":317,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":318,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":319,"author":{"gitId":"TriciaBK"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":320,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":321,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":322,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":323,"author":{"gitId":"TriciaBK"},"content":" fileScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":324,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":325,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":326,"author":{"gitId":"TriciaBK"},"content":" if (fileScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":327,"author":{"gitId":"TriciaBK"},"content":" String currentColorString \u003d fileScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":328,"author":{"gitId":"TriciaBK"},"content":" Color color \u003d Parser.parsePlayerColor(currentColorString);","lastModifiedDate":"2023-11-03"},{"lineNumber":329,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-03"},{"lineNumber":330,"author":{"gitId":"TriciaBK"},"content":" return color;","lastModifiedDate":"2023-11-03"},{"lineNumber":331,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":332,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":333,"author":{"gitId":"TriciaBK"},"content":" fileScanner.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":334,"author":{"gitId":"TriciaBK"},"content":" throw new LoadBoardException();","lastModifiedDate":"2023-11-02"},{"lineNumber":335,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":336,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":337,"author":{"gitId":"TriciaBK"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"TriciaBK":188,"onx001":78,"TongZhengHong":71}},{"path":"src/main/java/chessmaster/ui/ExceptionMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"public class ExceptionMessages {","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_PARSE_CHESS_PIECE_EXCEPTION \u003d \"Unable to parse chess piece!\";","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_PARSE_COORDINATE_EXCEPTION \u003d \"Unable to parse coordinate!\";","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TriciaBK"},"content":" public static final String MESSAGE_SAVE_BOARD_EXCEPTION \u003d \"Unable to save board!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"TriciaBK"},"content":" public static final String MESSAGE_LOAD_BOARD_EXCEPTION \u003d \"Unable to load board!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":" public static final String MESSAGE_INVALID_MOVE_EXCEPTION \u003d \"Oops, that move isn\u0027t valid!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_NULL_PIECE_EXCEPTION \u003d \"No chess piece found at coordinate!\";","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_MOVE_OPPONENT_EXCEPTION \u003d \"You have chosen an opponent piece! \"","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" + \"Please choose your pieces!\";","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" public static final String MESSAGE_PARSE_COLOR_EXCEPTION \u003d \"Unable to parse color!\";","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":1,"TriciaBK":2,"TongZhengHong":10}},{"path":"src/main/java/chessmaster/ui/TextUI.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.commands.CommandResult;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.user.Player;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"antrikshdhand"},"content":"public final class TextUI {","lastModifiedDate":"2023-10-19"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private static final String CHESS_BOARD_TAB \u003d \" \".repeat(4);","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" private static final String CHESS_BOARD_PADDING \u003d CHESS_BOARD_TAB.repeat(3);","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public static final String CHESS_BOARD_DIVIDER \u003d CHESS_BOARD_PADDING + CHESS_BOARD_TAB +","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" \"_\".repeat(4 * ChessBoard.SIZE + 1);","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" private static final String COLUMN_HEADER \u003d \"abcdefgh\";","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" /** A platform independent line separator. */","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" private static final String LS \u003d System.lineSeparator();","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" private static final String DIVIDER \u003d \"_\".repeat(65) + LS;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" * Format of a comment input line. Comment lines are silently consumed when","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" * reading user input.","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" private static final String COMMENT_LINE_FORMAT_REGEX \u003d \"#.*\";","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"antrikshdhand"},"content":" private static final Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"antrikshdhand"},"content":" private static final PrintStream out \u003d System.out;","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" * Prompts for the command and reads the text entered by the user.","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" * Ignores empty, pure whitespace, and comment lines.","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" * @return user input string in LOWER case","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" public String getUserInput() {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" String fullInputLine \u003d scanner.nextLine().trim();","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" // silently consume all ignored lines","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" while (shouldIgnore(fullInputLine)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" fullInputLine \u003d scanner.nextLine();","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" return fullInputLine.toLowerCase();","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" * Returns true if the user input line should be ignored.","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" * Input should be ignored if it is parsed as a comment, is only whitespace, or","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":" * is empty.","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" * @param rawInputLine full raw user input line.","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" * @return true if the entire user input line should be ignored.","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" private boolean shouldIgnore(String rawInputLine) {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" boolean isCommentLine \u003d rawInputLine.trim().matches(COMMENT_LINE_FORMAT_REGEX);","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" return rawInputLine.trim().isEmpty() || isCommentLine;","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" * Prints one or more lines of text, surrounded by a divider, to the user","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" * console.","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" * @param texts The lines of text to be printed.","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" public void printText(String... texts) {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" out.println(DIVIDER);","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" for (String text : texts) {","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" out.println(text);","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" out.println(DIVIDER);","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" //@@author TongZhengHong","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoard(ChessTile[][] tiles) {","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c tiles.length; i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[] row \u003d tiles[i];","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" StringBuilder rowString \u003d new StringBuilder();","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" for (ChessTile tile : row) {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(tile.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" int rowNum \u003d 8 - i;","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardRow(rowNum, rowString.toString());","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardWithMove(ChessTile[][] tiles, Move move) {","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardDivider();","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c tiles.length; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[] row \u003d tiles[i];","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" StringBuilder rowString \u003d new StringBuilder();","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"TongZhengHong"},"content":" for (int j \u003d 0; j \u003c tiles.length; j++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"TongZhengHong"},"content":" ChessTile tile \u003d row[j];","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coord \u003d new Coordinate(j, i);","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"TongZhengHong"},"content":" boolean isPrevMove \u003d move.getFrom().equals(coord) || ","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"TongZhengHong"},"content":" move.getTo().equals(coord);","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"TongZhengHong"},"content":" String pieceString \u003d isPrevMove ? tile.toStringPrevMove() : tile.toString();","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"TongZhengHong"},"content":" rowString.append(pieceString);","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"TongZhengHong"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"TongZhengHong"},"content":" int rowNum \u003d 8 - i;","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardRow(rowNum, rowString.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"TongZhengHong"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"ken-ruster"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"ken-ruster"},"content":" * Prints the chessboard along with highlighted moves for a specific chess piece.","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"ken-ruster"},"content":" * This method displays the chessboard, emphasizing available destination squares for a","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"ken-ruster"},"content":" * selected piece and marking the selected piece itself.","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"ken-ruster"},"content":" * @param tiles The 2D array of ChessTile objects representing the chessboard.","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"ken-ruster"},"content":" * @param piece The chess piece for which moves are highlighted.","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"ken-ruster"},"content":" * @param coordinates An array of coordinates representing available destination squares.","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"ken-ruster"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"ken-ruster"},"content":" public void printChessBoardAvailableMoves(ChessTile[][] tiles, ChessPiece piece, ","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"ken-ruster"},"content":" Coordinate[] coordinates) {","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"ken-ruster"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"ken-ruster"},"content":" printChessBoardDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"ken-ruster"},"content":" for (int i \u003d 0; i \u003c tiles.length; i++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"ken-ruster"},"content":" ChessTile[] row \u003d tiles[i];","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"ken-ruster"},"content":" StringBuilder rowString \u003d new StringBuilder();","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"ken-ruster"},"content":" for (int j \u003d 0; j \u003c tiles.length; j++) {","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"ken-ruster"},"content":" rowString.append(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"ken-ruster"},"content":" ChessTile tile \u003d row[j];","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"ken-ruster"},"content":" Coordinate coord \u003d new Coordinate(j, i);","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"ken-ruster"},"content":" String pieceString;","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"ken-ruster"},"content":" if (Arrays.asList(coordinates).contains(coord)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"ken-ruster"},"content":" pieceString \u003d tile.toStringAvailableDest();","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"ken-ruster"},"content":" } else if (piece.getPosition().equals(coord)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"ken-ruster"},"content":" pieceString \u003d tile.toStringSelected();","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"ken-ruster"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"ken-ruster"},"content":" pieceString \u003d tile.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"ken-ruster"},"content":" rowString.append(pieceString);","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"ken-ruster"},"content":" int rowNum \u003d 8 - i;","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"ken-ruster"},"content":" printChessBoardRow(rowNum, rowString.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"ken-ruster"},"content":" printChessBoardHeader();","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"ken-ruster"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"ken-ruster"},"content":" //@@author","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"TongZhengHong"},"content":" public void printWelcomeMessage() {","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"TongZhengHong"},"content":" printText(UiMessages.WELCOME_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":178,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":179,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":180,"author":{"gitId":"TongZhengHong"},"content":" public void printLoadBoardError() {","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"TongZhengHong"},"content":" printText(UiMessages.LOAD_BOARD_ERROR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":182,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":183,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":184,"author":{"gitId":"TongZhengHong"},"content":" public void promptContinuePrevGame(boolean error) {","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"TongZhengHong"},"content":" if (error) {","lastModifiedDate":"2023-10-23"},{"lineNumber":186,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.CONTINUE_PREV_GAME_ERROR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":187,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":188,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.EXIST_PREV_GAME_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":189,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":190,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":191,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":192,"author":{"gitId":"onx001"},"content":" public void promptDifficulty(boolean error) {","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"onx001"},"content":" if (error) {","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"onx001"},"content":" out.print(UiMessages.CHOOSE_DIFFICULTY_ERROR_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"onx001"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"onx001"},"content":" out.print(UiMessages.CHOOSE_DIFFICULTY_MESSAGE);","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"TongZhengHong"},"content":" public void promptStartingColor(boolean error) {","lastModifiedDate":"2023-10-31"},{"lineNumber":201,"author":{"gitId":"TongZhengHong"},"content":" if (error) {","lastModifiedDate":"2023-10-23"},{"lineNumber":202,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.CHOOSE_PLAYER_COLOR_ERROR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":203,"author":{"gitId":"TongZhengHong"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":204,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.CHOOSE_PLAYER_COLOR_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":205,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":206,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":207,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":208,"author":{"gitId":"TongZhengHong"},"content":" public void printStartNewGame(String colorString) {","lastModifiedDate":"2023-10-31"},{"lineNumber":209,"author":{"gitId":"TongZhengHong"},"content":" String displayText \u003d String.format(UiMessages.START_NEW_GAME_MESSAGE, colorString);","lastModifiedDate":"2023-10-23"},{"lineNumber":210,"author":{"gitId":"TongZhengHong"},"content":" printText(displayText);","lastModifiedDate":"2023-10-23"},{"lineNumber":211,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":212,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":213,"author":{"gitId":"TongZhengHong"},"content":" public void printContinuePrevGame(String colorString) {","lastModifiedDate":"2023-10-31"},{"lineNumber":214,"author":{"gitId":"TongZhengHong"},"content":" String displayText \u003d String.format(UiMessages.CONTINUE_PREV_GAME_MESSAGE, colorString);","lastModifiedDate":"2023-10-23"},{"lineNumber":215,"author":{"gitId":"TongZhengHong"},"content":" printText(displayText);","lastModifiedDate":"2023-10-23"},{"lineNumber":216,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":217,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":218,"author":{"gitId":"TongZhengHong"},"content":" public void printPromotePrompt(Coordinate coord) {","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"ken-ruster"},"content":" String message \u003d String.format(UiMessages.PROMPT_PROMOTE_MESSAGE, coord.toString());","lastModifiedDate":"2023-10-19"},{"lineNumber":220,"author":{"gitId":"TongZhengHong"},"content":" out.print(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":221,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":222,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":223,"author":{"gitId":"TongZhengHong"},"content":" public void printPromoteInvalidMessage() {","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"TongZhengHong"},"content":" out.print(UiMessages.PROMPT_PROMOTE_INVALID_MESSAGE);","lastModifiedDate":"2023-10-23"},{"lineNumber":225,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":226,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":227,"author":{"gitId":"TongZhengHong"},"content":" public void printCPUMove(Move cpuMove) {","lastModifiedDate":"2023-10-31"},{"lineNumber":228,"author":{"gitId":"TongZhengHong"},"content":" String pieceString \u003d cpuMove.getPiece().getClass().getSimpleName();","lastModifiedDate":"2023-10-23"},{"lineNumber":229,"author":{"gitId":"TongZhengHong"},"content":" String displayString \u003d String.format(UiMessages.CPU_MOVE_MESSAGE, pieceString,","lastModifiedDate":"2023-10-23"},{"lineNumber":230,"author":{"gitId":"TongZhengHong"},"content":" cpuMove.getFrom(), cpuMove.getTo());","lastModifiedDate":"2023-10-23"},{"lineNumber":231,"author":{"gitId":"TongZhengHong"},"content":" printText(displayString);","lastModifiedDate":"2023-10-23"},{"lineNumber":232,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":233,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":234,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardDivider() {","lastModifiedDate":"2023-10-31"},{"lineNumber":235,"author":{"gitId":"TongZhengHong"},"content":" out.println(CHESS_BOARD_DIVIDER);","lastModifiedDate":"2023-10-15"},{"lineNumber":236,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":237,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":238,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardHeader() {","lastModifiedDate":"2023-10-31"},{"lineNumber":239,"author":{"gitId":"TongZhengHong"},"content":" out.print(CHESS_BOARD_PADDING + CHESS_BOARD_TAB);","lastModifiedDate":"2023-10-23"},{"lineNumber":240,"author":{"gitId":"TongZhengHong"},"content":" for (int i \u003d 0; i \u003c COLUMN_HEADER.length(); i++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":241,"author":{"gitId":"TongZhengHong"},"content":" char col \u003d COLUMN_HEADER.charAt(i);","lastModifiedDate":"2023-10-15"},{"lineNumber":242,"author":{"gitId":"antrikshdhand"},"content":" out.printf(\" (%s)\", col);","lastModifiedDate":"2023-10-19"},{"lineNumber":243,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":244,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-15"},{"lineNumber":245,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":246,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":247,"author":{"gitId":"TongZhengHong"},"content":" public void printChessBoardRow(int rowNum, String chessBoardRow) {","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"TongZhengHong"},"content":" out.print(CHESS_BOARD_PADDING);","lastModifiedDate":"2023-10-23"},{"lineNumber":249,"author":{"gitId":"TongZhengHong"},"content":" out.print(String.format(\"(%d) \", rowNum));","lastModifiedDate":"2023-10-23"},{"lineNumber":250,"author":{"gitId":"TongZhengHong"},"content":" out.print(chessBoardRow);","lastModifiedDate":"2023-10-15"},{"lineNumber":251,"author":{"gitId":"TongZhengHong"},"content":" out.print(ChessTile.TILE_DIVIDER);","lastModifiedDate":"2023-10-15"},{"lineNumber":252,"author":{"gitId":"TongZhengHong"},"content":" out.print(String.format(\" (%d)\", rowNum));","lastModifiedDate":"2023-10-15"},{"lineNumber":253,"author":{"gitId":"TongZhengHong"},"content":" out.print(System.lineSeparator() + CHESS_BOARD_DIVIDER);","lastModifiedDate":"2023-10-15"},{"lineNumber":254,"author":{"gitId":"TongZhengHong"},"content":" out.println(\"\");","lastModifiedDate":"2023-10-15"},{"lineNumber":255,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":256,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":257,"author":{"gitId":"TongZhengHong"},"content":" public void printCommandResult(CommandResult result) {","lastModifiedDate":"2023-10-31"},{"lineNumber":258,"author":{"gitId":"TongZhengHong"},"content":" String[] resultStrings \u003d result.getMessageStrings();","lastModifiedDate":"2023-10-31"},{"lineNumber":259,"author":{"gitId":"TongZhengHong"},"content":" if (resultStrings !\u003d null \u0026\u0026 resultStrings.length \u003e 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":260,"author":{"gitId":"TongZhengHong"},"content":" printText(resultStrings);","lastModifiedDate":"2023-10-31"},{"lineNumber":261,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":262,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":263,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":264,"author":{"gitId":"TongZhengHong"},"content":" public void printErrorMessage(Exception e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":265,"author":{"gitId":"TongZhengHong"},"content":" printText(e.getMessage());","lastModifiedDate":"2023-10-23"},{"lineNumber":266,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":267,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":268,"author":{"gitId":"TongZhengHong"},"content":" public void printEndMessage(Player winner) {","lastModifiedDate":"2023-11-04"},{"lineNumber":269,"author":{"gitId":"TongZhengHong"},"content":" String winningColorString \u003d winner.getColour().name();","lastModifiedDate":"2023-11-03"},{"lineNumber":270,"author":{"gitId":"TongZhengHong"},"content":" if (winner.isHuman()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":271,"author":{"gitId":"TongZhengHong"},"content":" printText(String.format(UiMessages.HUMAN_WIN_STRING, winningColorString));","lastModifiedDate":"2023-11-03"},{"lineNumber":272,"author":{"gitId":"TongZhengHong"},"content":" } else if (winner.isCPU()) { // Human lost","lastModifiedDate":"2023-11-04"},{"lineNumber":273,"author":{"gitId":"TongZhengHong"},"content":" String playerColorString \u003d winner.getColour().getOppositeColour().name();","lastModifiedDate":"2023-11-04"},{"lineNumber":274,"author":{"gitId":"TongZhengHong"},"content":" printText(String.format(UiMessages.CPU_WIN_STRING, playerColorString));","lastModifiedDate":"2023-11-04"},{"lineNumber":275,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":276,"author":{"gitId":"TriciaBK"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":277,"author":{"gitId":"TriciaBK"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":278,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"ken-ruster":51,"antrikshdhand":4,"TriciaBK":3,"onx001":8,"TongZhengHong":212}},{"path":"src/main/java/chessmaster/ui/UiMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.ui;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"public class UiMessages {","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":" public static final String[] WELCOME_MESSAGE \u003d { ","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":" \"Hey there, chess geek! You have stumbled upon the one and only: \",","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":" \" ________ __ ___ __ \",","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":" \" / ____/ /_ ___ __________ / |/ /___ ______/ /____ _____\",","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":" \" / / / __ \\\\/ _ \\\\/ ___/ ___/ / /|_/ / __ `/ ___/ __/ _ \\\\/ ___/\",","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" \" / /___/ / / / __(__ |__ ) / / / / /_/ (__ ) /_/ __/ / \",","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" \" \\\\____/_/ /_/\\\\___/____/____/ /_/ /_/\\\\__,_/____/\\\\__/\\\\___/_/ \", \"\",","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" \"where CHESS becomes an exciting journey of strategy and skill!\" };","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" public static final String EXIST_PREV_GAME_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" \"You have an ongoing previous chess game. Continue game? [y/n] \";","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" public static final String CONTINUE_PREV_GAME_ERROR_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" \"Invalid input! Please enter either \u0027y\u0027 for yes or \u0027n\u0027 for no: \";","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" public static final String CONTINUE_PREV_GAME_MESSAGE \u003d \"Great! Continuing previous game as %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" public static final String CHOOSE_PLAYER_COLOR_MESSAGE \u003d \"Choose your starting color to start new game! [b/w] \";","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" public static final String CHOOSE_PLAYER_COLOR_ERROR_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" \"Invalid input! Please enter either \u0027b\u0027 for Black or \u0027w\u0027 for White: \";","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" public static final String START_NEW_GAME_MESSAGE \u003d \"Great! Starting new game as %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" public static final String LOAD_BOARD_ERROR_MESSAGE \u003d \"No valid previous game found. Starting new chess game...\";","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" public static final String CPU_MOVE_MESSAGE \u003d \"ChessMaster moved %s from %s to %s\";","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public static final String PROMPT_PROMOTE_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" \"Promote the pawn at %s! Choose piece to promote to [b/q/r/n]: \";","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":" public static final String PROMPT_PROMOTE_INVALID_MESSAGE \u003d ","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" \"Invalid piece! Enter b(Bishop), q(Queen), r(Rook) or n(Knight): \";","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"onx001"},"content":" public static final String CHOOSE_DIFFICULTY_MESSAGE \u003d ","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"onx001"},"content":" \"Choose difficulty level [1/2/3]: \";","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"onx001"},"content":" public static final String CHOOSE_DIFFICULTY_ERROR_MESSAGE \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"onx001"},"content":" \"Invalid input! Please enter either \u00271\u0027, \u00272\u0027 or \u00273\u0027: \";","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" public static final String HUMAN_WIN_STRING \u003d \"Congratulations! You have won as %s! :)\";","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" public static final String CPU_WIN_STRING \u003d \"Oh no! You have lost as %s. Please try harder next time :(\";","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"ken-ruster":4,"onx001":5,"TongZhengHong":31}},{"path":"src/main/java/chessmaster/user/CPU.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"antrikshdhand"},"content":"package chessmaster.user;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-19"},{"lineNumber":6,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-19"},{"lineNumber":7,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"import chessmaster.game.MiniMax;","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"antrikshdhand"},"content":"import java.util.Random;","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"antrikshdhand"},"content":"public class CPU extends Player {","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" private static final int MAX_LOOP_ITERATIONS \u003d 16;","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" private static final int RANDOM_SEED \u003d 100;","lastModifiedDate":"2023-10-20"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" private final Random rand \u003d new Random(RANDOM_SEED);","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" public CPU(Color colour, ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" super(colour, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":22,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":23,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":24,"author":{"gitId":"antrikshdhand"},"content":" * The main function behind the CPU\u0027s logic, this function randomly selects an active (non-captured) piece","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"antrikshdhand"},"content":" * from the CPU\u0027s pieces which has possible valid moves.","lastModifiedDate":"2023-10-19"},{"lineNumber":26,"author":{"gitId":"antrikshdhand"},"content":" * @param board The board to extract the random move from.","lastModifiedDate":"2023-10-19"},{"lineNumber":27,"author":{"gitId":"antrikshdhand"},"content":" * @return A random move","lastModifiedDate":"2023-10-19"},{"lineNumber":28,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"antrikshdhand"},"content":" public Move getRandomMove(ChessBoard board) {","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"antrikshdhand"},"content":" // 1. Get a random piece that","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"antrikshdhand"},"content":" // - isn\u0027t captured","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"antrikshdhand"},"content":" // - has possible legal moves","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"antrikshdhand"},"content":" ChessPiece randomPiece \u003d getRandomPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"antrikshdhand"},"content":" // Need a cap on the number of pieces it checks to prevent an infinite loop when no moves are possible","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"antrikshdhand"},"content":" // on the CPUs side.","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"antrikshdhand"},"content":" int iter \u003d 0;","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"antrikshdhand"},"content":" while (iter \u003c MAX_LOOP_ITERATIONS","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" \u0026\u0026 (randomPiece.getIsCaptured()","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" || randomPiece.getFlattenedCoordinates(board).length \u003d\u003d 0)) {","lastModifiedDate":"2023-10-20"},{"lineNumber":41,"author":{"gitId":"antrikshdhand"},"content":" randomPiece \u003d getRandomPiece();","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"antrikshdhand"},"content":" iter++;","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"antrikshdhand"},"content":" return getRandomMoveFromPiece(randomPiece, board);","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":48,"author":{"gitId":"onx001"},"content":" //@@author onx001","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"onx001"},"content":" public Move getBestMove(ChessBoard board, int maxDepth) {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"onx001"},"content":" MiniMax miniMax \u003d new MiniMax(board, this.colour, maxDepth, 0);","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"onx001"},"content":" Move bestMove \u003d miniMax.getBestMove();","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"onx001"},"content":" Coordinate from \u003d bestMove.getFrom();","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"onx001"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(from);","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"onx001"},"content":" bestMove.setPiece(piece);","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"onx001"},"content":" return bestMove;","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"onx001"},"content":" //@@author ","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"antrikshdhand"},"content":" private ChessPiece getRandomPiece() {","lastModifiedDate":"2023-10-19"},{"lineNumber":62,"author":{"gitId":"antrikshdhand"},"content":" return this.pieces.get(rand.nextInt(pieces.size()));","lastModifiedDate":"2023-10-19"},{"lineNumber":63,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":64,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":65,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"antrikshdhand"},"content":" * This function returns any random valid move that a given piece can make on a given board.","lastModifiedDate":"2023-10-19"},{"lineNumber":67,"author":{"gitId":"antrikshdhand"},"content":" * @param piece The piece to extract a random move from.","lastModifiedDate":"2023-10-19"},{"lineNumber":68,"author":{"gitId":"antrikshdhand"},"content":" * @param board The board the piece is currently on.","lastModifiedDate":"2023-10-19"},{"lineNumber":69,"author":{"gitId":"antrikshdhand"},"content":" * @return A random move the given piece can make on the given board.","lastModifiedDate":"2023-10-19"},{"lineNumber":70,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":71,"author":{"gitId":"antrikshdhand"},"content":" private Move getRandomMoveFromPiece(ChessPiece piece, ChessBoard board) {","lastModifiedDate":"2023-10-19"},{"lineNumber":72,"author":{"gitId":"ken-ruster"},"content":" Coordinate[] allPossibleMoves \u003d piece.getFlattenedCoordinates(board);","lastModifiedDate":"2023-10-20"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" int randIndex \u003d rand.nextInt(allPossibleMoves.length);","lastModifiedDate":"2023-10-20"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" Coordinate randomDestination \u003d allPossibleMoves[randIndex];","lastModifiedDate":"2023-10-20"},{"lineNumber":75,"author":{"gitId":"antrikshdhand"},"content":" return new Move(piece.getPosition(), randomDestination, piece);","lastModifiedDate":"2023-10-19"},{"lineNumber":76,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":77,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":78,"author":{"gitId":"antrikshdhand"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"ken-ruster":2,"antrikshdhand":52,"onx001":14,"TongZhengHong":10}},{"path":"src/main/java/chessmaster/user/Human.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"antrikshdhand"},"content":"package chessmaster.user;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.parser.Parser;","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-22"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"antrikshdhand"},"content":"public class Human extends Player {","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public Human(Color colour, ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" super(colour, board);","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" //@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" /**","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":" * Prompts the user to enter a type of piece to promote a pawn to. If the","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":" * promotion is not successful,","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"ken-ruster"},"content":" * the user is prompted again. If successful, the pawn is replaced with the new","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"ken-ruster"},"content":" * piece.","lastModifiedDate":"2023-10-22"},{"lineNumber":23,"author":{"gitId":"ken-ruster"},"content":" *","lastModifiedDate":"2023-10-22"},{"lineNumber":24,"author":{"gitId":"ken-ruster"},"content":" * @param board Chessboard that the game is being played on.","lastModifiedDate":"2023-10-22"},{"lineNumber":25,"author":{"gitId":"ken-ruster"},"content":" * @param promoteMove The piece being promoted.","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"ken-ruster"},"content":" */","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"ken-ruster"},"content":" public void handlePromote(ChessBoard board, TextUI ui, Move promoteMove) {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"ken-ruster"},"content":" ChessPiece pawnPiece \u003d promoteMove.getPiece();","lastModifiedDate":"2023-10-22"},{"lineNumber":29,"author":{"gitId":"ken-ruster"},"content":" if (!pawnPiece.isPawn()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"ken-ruster"},"content":" return;","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"ken-ruster"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"ken-ruster"},"content":" Coordinate coord \u003d pawnPiece.getPosition();","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"ken-ruster"},"content":" boolean promoteFailure \u003d true;","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":37,"author":{"gitId":"ken-ruster"},"content":" ui.printPromotePrompt(coord);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"ken-ruster"},"content":" String in \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"ken-ruster"},"content":" do {","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"ken-ruster"},"content":" ChessPiece promotedPiece \u003d Parser.parsePromote(pawnPiece, in);","lastModifiedDate":"2023-10-22"},{"lineNumber":41,"author":{"gitId":"ken-ruster"},"content":" promoteFailure \u003d promotedPiece.isPawn();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"ken-ruster"},"content":" if (promoteFailure) {","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"ken-ruster"},"content":" ui.printPromoteInvalidMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"ken-ruster"},"content":" in \u003d ui.getUserInput();","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"ken-ruster"},"content":" } else {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"ken-ruster"},"content":" promotedPiece.setHasMoved();","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"ken-ruster"},"content":" this.pieces.add(promotedPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":49,"author":{"gitId":"ken-ruster"},"content":" this.pieces.remove(pawnPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"ken-ruster"},"content":" board.setPromotionPiece(coord, promotedPiece);","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"ken-ruster"},"content":" } while (promoteFailure);","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":54,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"ken-ruster":39,"antrikshdhand":4,"TongZhengHong":12}},{"path":"src/main/java/chessmaster/user/Player.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"antrikshdhand"},"content":"package chessmaster.user;","lastModifiedDate":"2023-10-19"},{"lineNumber":2,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":3,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-19"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-19"},{"lineNumber":6,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-19"},{"lineNumber":7,"author":{"gitId":"antrikshdhand"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"antrikshdhand"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"antrikshdhand"},"content":"public abstract class Player {","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":13,"author":{"gitId":"antrikshdhand"},"content":" protected ArrayList\u003cMove\u003e moves;","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"antrikshdhand"},"content":" protected ArrayList\u003cChessPiece\u003e pieces;","lastModifiedDate":"2023-10-19"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" protected Color colour;","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" * A player is a dependency of the Game class. This class stores all move","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" * history, all current pieces, and colour of each player. ","lastModifiedDate":"2023-10-22"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" * It also contains functions to request input from the user for the next ","lastModifiedDate":"2023-10-22"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" * move and to execute that move.","lastModifiedDate":"2023-10-22"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-20"},{"lineNumber":23,"author":{"gitId":"antrikshdhand"},"content":" * @param colour The ChessPiece.Colour desired for this player.","lastModifiedDate":"2023-10-19"},{"lineNumber":24,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" public Player(Color colour, ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" this.moves \u003d new ArrayList\u003cMove\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" this.pieces \u003d new ArrayList\u003cChessPiece\u003e();","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"antrikshdhand"},"content":" this.colour \u003d colour;","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" initialisePieces(board);","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"antrikshdhand"},"content":" * Adds a given move into the Player\u0027s move history.","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-20"},{"lineNumber":35,"author":{"gitId":"antrikshdhand"},"content":" * @param move The given move to be added to history.","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"antrikshdhand"},"content":" public void addMove(Move move) {","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"antrikshdhand"},"content":" this.moves.add(move);","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" public Color getColour() {","lastModifiedDate":"2023-10-22"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" return this.colour;","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":45,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" * Adds all the player\u0027s pieces to their ChessPiece array ","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" * when Player is initialised.","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" * ","lastModifiedDate":"2023-10-20"},{"lineNumber":49,"author":{"gitId":"antrikshdhand"},"content":" * @param board The new ChessBoard containing all 32 chess pieces.","lastModifiedDate":"2023-10-19"},{"lineNumber":50,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" private void initialisePieces(ChessBoard board) {","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-22"},{"lineNumber":54,"author":{"gitId":"antrikshdhand"},"content":" ChessPiece piece \u003d board.getPieceAtCoor(new Coordinate(col, row));","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" if (piece.isSameColorAs(this.colour)) {","lastModifiedDate":"2023-10-22"},{"lineNumber":56,"author":{"gitId":"antrikshdhand"},"content":" this.pieces.add(piece);","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":58,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":59,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"antrikshdhand"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"antrikshdhand"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":62,"author":{"gitId":"antrikshdhand"},"content":" /**","lastModifiedDate":"2023-10-19"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" * Prints out all the player\u0027s pieces including whether it has been captured or","lastModifiedDate":"2023-10-20"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" * not.","lastModifiedDate":"2023-10-20"},{"lineNumber":65,"author":{"gitId":"antrikshdhand"},"content":" * Used for debugging purposes only.","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"antrikshdhand"},"content":" */","lastModifiedDate":"2023-10-19"},{"lineNumber":67,"author":{"gitId":"antrikshdhand"},"content":" public void printAllPieces() {","lastModifiedDate":"2023-10-19"},{"lineNumber":68,"author":{"gitId":"antrikshdhand"},"content":" for (ChessPiece p : pieces) {","lastModifiedDate":"2023-10-19"},{"lineNumber":69,"author":{"gitId":"antrikshdhand"},"content":" System.out.println(\"Piece: \" + p);","lastModifiedDate":"2023-10-19"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" System.out.println(\"Colour: \" + p.getColor().toString());","lastModifiedDate":"2023-10-22"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" System.out.println(\"Is captured: \" + p.getIsCaptured());","lastModifiedDate":"2023-10-22"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" public boolean isHuman() {","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof Human;","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" public boolean isCPU() {","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" return this instanceof CPU;","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"antrikshdhand"},"content":"}","lastModifiedDate":"2023-10-19"}],"authorContributionMap":{"antrikshdhand":45,"TongZhengHong":37}},{"path":"src/test/java/chessmaster/ChessMasterTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"class ChessMasterTest {","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" public void sampleTest() {","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" assertFalse(false);","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"onx001":2,"TongZhengHong":2,"-":10}},{"path":"src/test/java/chessmaster/game/ChessBoardTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.ui.TextUI;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":"public class ChessBoardTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" // @@author onx001","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" public void pointTest() {","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" TextUI ui \u003d new TextUI();","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":" ChessBoard board \u003d new ChessBoard(Color.WHITE);","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" ui.printChessBoard(board.getBoard());","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":" int points \u003d board.getPoints(Color.WHITE);","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"onx001"},"content":" assertEquals(0, points);","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"onx001"},"content":" // @@author","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"onx001"},"content":" ","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"onx001":19,"TongZhengHong":3}},{"path":"src/test/java/chessmaster/game/ColorTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"public class ColorTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":" public void testGetOppositeColour() {","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.BLACK, Color.WHITE.getOppositeColour());","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.WHITE, Color.BLACK.getOppositeColour());","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.EMPTY, Color.EMPTY.getOppositeColour());","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" public void testIsWhite() {","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(Color.WHITE.isWhite());","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.BLACK.isWhite());","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.EMPTY.isWhite());","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" public void testIsBlack() {","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(Color.BLACK.isBlack());","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.WHITE.isBlack());","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(Color.EMPTY.isBlack());","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":30}},{"path":"src/test/java/chessmaster/game/CoordinateTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.game;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertNotEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"public class CoordinateTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" public void testIsOffsetWithinBoard() {","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d new Coordinate(3, 4);","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(coordinate.isOffsetWithinBoard(-1, 0));","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(coordinate.isOffsetWithinBoard(0, -1));","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assertTrue(coordinate.isOffsetWithinBoard(1, 1));","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(coordinate.isOffsetWithinBoard(8, 0));","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(coordinate.isOffsetWithinBoard(0, 8));","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" assertFalse(coordinate.isOffsetWithinBoard(-4, 0));","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" public void testAddOffsetToCoordinate() {","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoord1 \u003d coordinate.addOffsetToCoordinate(1, 2);","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoord2 \u003d coordinate.addOffsetToCoordinate(-2, -3);","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" Coordinate newCoord3 \u003d coordinate.addOffsetToCoordinate(0, 0);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(new Coordinate(3, 5), newCoord1);","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(new Coordinate(0, 0), newCoord2);","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(coordinate, newCoord3); // Should be the same coordinate","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" public void testParseAlgebraicCoor() throws ParseCoordinateException {","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d Coordinate.parseAlgebraicCoor(\"d5\");","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(new Coordinate(3, 3), coordinate);","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" // Test invalid notations","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e Coordinate.parseAlgebraicCoor(\"x3\"));","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e Coordinate.parseAlgebraicCoor(\"h0\"));","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e Coordinate.parseAlgebraicCoor(\"a9\"));","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" public void testCalculateOffsetFrom() {","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate1 \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate2 \u003d new Coordinate(4, 1);","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" int[] offset \u003d coordinate1.calculateOffsetFrom(coordinate2);","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(-2, offset[0]);","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(2, offset[1]);","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" public void testToString() {","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate \u003d new Coordinate(1, 6);","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(\"b2\", coordinate.toString());","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" public void testEquals() {","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate1 \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate2 \u003d new Coordinate(2, 3);","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":" Coordinate coordinate3 \u003d new Coordinate(4, 1);","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(coordinate1, coordinate2);","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" assertNotEquals(coordinate1, coordinate3);","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":79}},{"path":"src/test/java/chessmaster/game/MiniMaxTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"onx001"},"content":"package chessmaster.game;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"onx001"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"onx001"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"onx001"},"content":"public class MiniMaxTest {","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"onx001"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"onx001"},"content":" public void testMiniMax() {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"onx001"},"content":" ChessBoard board \u003d new ChessBoard(Color.BLACK);","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"onx001"},"content":" MiniMax miniMax \u003d new MiniMax(board, Color.BLACK, 3, 0);","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"onx001"},"content":" Move move \u003d miniMax.getBestMove();","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"onx001"},"content":" assertEquals(move.getFrom(), new Coordinate(6, 7));","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"onx001"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"onx001"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"onx001"},"content":" //ChessBoard board, Color color, int maxDepth, int score","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"onx001"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"onx001":17}},{"path":"src/test/java/chessmaster/parser/ParseMoveTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ChessMasterException;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.MoveOpponentPieceException;","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.NullPieceException;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseCoordinateException;","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessBoard;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.ChessTile;","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Coordinate;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Move;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":"public class ParseMoveTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" private static final String[][] STARTING_CHESSBOARD_BLACK \u003d { ","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" { \"r\", \"n\", \"b\", \"q\", \"k\", \"b\", \"n\", \"r\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":" { \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\", \"p\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" { \".\", \".\", \".\", \".\", \".\", \".\", \".\", \".\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" { \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\", \"P\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" { \"R\", \"N\", \"B\", \"Q\", \"K\", \"B\", \"N\", \"R\" }, ","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" };","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" private ChessBoard loadChessBoard() {","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" ChessTile[][] chessTiles \u003d new ChessTile[ChessBoard.SIZE][ChessBoard.SIZE];","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" for (int row \u003d 0; row \u003c ChessBoard.SIZE; row++) {","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" for (int col \u003d 0; col \u003c ChessBoard.SIZE; col++) {","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" String chessPieceString \u003d STARTING_CHESSBOARD_BLACK[row][col];","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" ChessPiece initialPiece \u003d Parser.parseChessPiece(chessPieceString, row, col);","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" chessTiles[row][col] \u003d new ChessTile(initialPiece);","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":" assert (chessTiles[row][col] !\u003d null);","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" return new ChessBoard(Color.BLACK, chessTiles);","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputValidMove() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2 h4\";","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" Move move \u003d Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" Coordinate from \u003d new Coordinate(7, 6); // h2","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" Coordinate to \u003d new Coordinate(7, 4); // h4","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" Move expectedMove \u003d new Move(from, to, emptyBoard.getPieceAtCoor(from));","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(move, expectedMove);","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputCannotParseStart_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2dasd h4\";","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputCannotParseDest_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2 h4dafsd\";","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputMoreThan2Inputs_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2 h4 a3\";","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputOneInput_expectParseException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"h2\";","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":88,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseCoordinateException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":90,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputEmptyPiece_expectNullPieceException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"d4 d5\";","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(NullPieceException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"TongZhengHong"},"content":" public void testParseMove_inputNotFriendly_expectMoveOpponentException() throws ChessMasterException {","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"TongZhengHong"},"content":" String inputString \u003d \"a7 a6\";","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"TongZhengHong"},"content":" ChessBoard emptyBoard \u003d loadChessBoard();","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(MoveOpponentPieceException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":107,"author":{"gitId":"TongZhengHong"},"content":" Parser.parseMove(inputString, emptyBoard);","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":110}},{"path":"src/test/java/chessmaster/parser/ParsePlayerColorTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"TongZhengHong"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.exceptions.ParseColorException;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"TongZhengHong"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"TongZhengHong"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"TongZhengHong"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"TongZhengHong"},"content":"public class ParsePlayerColorTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputValidColor() throws ParseColorException {","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"TongZhengHong"},"content":" String inputWhiteString \u003d \"WHITE\";","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"TongZhengHong"},"content":" Color whiteColor \u003d Parser.parsePlayerColor(inputWhiteString);","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.WHITE, whiteColor);","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"TongZhengHong"},"content":" String inputBlackString \u003d \"BLACK\";","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"TongZhengHong"},"content":" Color blackColor \u003d Parser.parsePlayerColor(inputBlackString);","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"TongZhengHong"},"content":" assertEquals(Color.BLACK, blackColor);","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputEmpty_expectParseException() throws ParseColorException {","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"TongZhengHong"},"content":" String inputEmptyString \u003d \"EMPTY\";","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputEmptyString);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputInvalid_expectParseException() {","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"TongZhengHong"},"content":" String inputColorString \u003d \"dfljasdka\";","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputColorString);","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputLowerCase_expectParseException() {","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"TongZhengHong"},"content":" String inputColorString \u003d \"white\";","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputColorString);","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"TongZhengHong"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"TongZhengHong"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"TongZhengHong"},"content":" public void testParsePlayerColor_inputEmptyString_expectParseException() {","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"TongZhengHong"},"content":" String inputColorString \u003d \"\";","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"TongZhengHong"},"content":" assertThrows(ParseColorException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"TongZhengHong"},"content":" Parser.parsePlayerColor(inputColorString);","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"TongZhengHong"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"TongZhengHong"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"TongZhengHong"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"TongZhengHong":54}},{"path":"src/test/java/chessmaster/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"ken-ruster"},"content":"//@@author ken-ruster","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"ken-ruster"},"content":"package chessmaster.parser;","lastModifiedDate":"2023-10-20"},{"lineNumber":3,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":4,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.game.Color;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.ChessPiece;","lastModifiedDate":"2023-10-20"},{"lineNumber":6,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.Pawn;","lastModifiedDate":"2023-10-20"},{"lineNumber":7,"author":{"gitId":"ken-ruster"},"content":"import chessmaster.pieces.Queen;","lastModifiedDate":"2023-10-20"},{"lineNumber":8,"author":{"gitId":"ken-ruster"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-20"},{"lineNumber":9,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":10,"author":{"gitId":"ken-ruster"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-20"},{"lineNumber":11,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":12,"author":{"gitId":"ken-ruster"},"content":"public class ParserTest {","lastModifiedDate":"2023-10-20"},{"lineNumber":13,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":14,"author":{"gitId":"ken-ruster"},"content":" @Test","lastModifiedDate":"2023-10-20"},{"lineNumber":15,"author":{"gitId":"ken-ruster"},"content":" public void promoteTest() {","lastModifiedDate":"2023-10-20"},{"lineNumber":16,"author":{"gitId":"ken-ruster"},"content":" ChessPiece promoted \u003d Parser.parsePromote(new Pawn(0, 0, Color.WHITE), \"q\");","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"ken-ruster"},"content":" assertEquals(promoted.toString(), Queen.QUEEN_WHITE);","lastModifiedDate":"2023-10-20"},{"lineNumber":18,"author":{"gitId":"ken-ruster"},"content":" }","lastModifiedDate":"2023-10-20"},{"lineNumber":19,"author":{"gitId":"ken-ruster"},"content":"","lastModifiedDate":"2023-10-20"},{"lineNumber":20,"author":{"gitId":"ken-ruster"},"content":"}","lastModifiedDate":"2023-10-20"}],"authorContributionMap":{"ken-ruster":20}}] diff --git a/AY2324S1-CS2113-T18-1_tp_master/commits.json b/AY2324S1-CS2113-T18-1_tp_master/commits.json index e360026..50b9ef0 100644 --- a/AY2324S1-CS2113-T18-1_tp_master/commits.json +++ b/AY2324S1-CS2113-T18-1_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"ken-ruster":[{"date":"2023-10-05","commitResults":[{"hash":"faf542c932dc8c668aff0ec933dabdff06d14b84","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6e59d9b754ad45058c2079c92e49c7e3018eabd4","isMergeCommit":false,"messageTitle":"Add question mark","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"8a501b95c2b2abe506ad139c3c31aebceb2fb205","isMergeCommit":true,"messageTitle":"Merge pull request #1 from ken-ruster/branch-test","messageBody":"Add question mark","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"f1ff0f7411762e6f7165868f47bc046d3c53ef57","isMergeCommit":true,"messageTitle":"Merge pull request #1 from AY2324S1-CS2113-T18-1/master","messageBody":"Merge template commits","fileTypesAndContributionMap":{}},{"hash":"65189450fa76a75657d7196b52644045e1a5cd0b","isMergeCommit":false,"messageTitle":"Add Move class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":0}}},{"hash":"c26acb544fbc894759c3fa25710b2309afbb3112","isMergeCommit":false,"messageTitle":"Add getPieceAtCoor for ChessBoard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"f25704646d91a0357e8feba59d6930ae51fe34f4","isMergeCommit":false,"messageTitle":"Add parseMove to Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":0}}},{"hash":"b6a41564720327fc4a2f4918e8ffab6d85bf61f6","isMergeCommit":true,"messageTitle":"Merge pull request #9 from ken-ruster/master","messageBody":"Add Move, parseMove, getPieceAtCoor","fileTypesAndContributionMap":{}},{"hash":"7bce486c240254f0df114f0b7c98550c07fd87e3","isMergeCommit":false,"messageTitle":"Add exception to handle invalid moves","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":0}}},{"hash":"adf441fe87620d6c32a057bd929bf5649861a7ee","isMergeCommit":false,"messageTitle":"Add placeholder movePiece() function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"36b657b73341f5386dcbddde151d1cd8b417590e","isMergeCommit":false,"messageTitle":"Parser.java: Add ParseCommand function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":10}}},{"hash":"5c3dcaac28b2874d45e7b11eca8bc53914f195dd","isMergeCommit":false,"messageTitle":"Update message for InvalidMoveException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"aad8c9191d3d81e12fc1a3d26a0e90353127740c","isMergeCommit":false,"messageTitle":"Update documentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":7}}},{"hash":"c01a71e62fea28af6635422189d4179e321ae0dc","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"be3d08b56f3db7bab6e6dd2c0d07610386e5733e","isMergeCommit":true,"messageTitle":"Merge pull request #12 from ken-ruster/master","messageBody":"Add parseCommand","fileTypesAndContributionMap":{}},{"hash":"0733fc344115ccba632803263803c4e51e00ab8f","isMergeCommit":false,"messageTitle":"Update Parser to work with executeMove","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5}}},{"hash":"cc4d6742f26ea5ee50dd98a646bc948f7614dff7","isMergeCommit":true,"messageTitle":"Merge pull request #13 from ken-ruster/master","messageBody":"Update Parser to work with executeMove","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"cc1de14b8dbd21ae323f79c66791d60fba907572","isMergeCommit":true,"messageTitle":"Merge pull request #2 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"2f537195a96090920c3263243b6d72f2571a61e5","isMergeCommit":false,"messageTitle":"Add parsePromote","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":0}}},{"hash":"e8af2c24700f59a9ea4243a776584a100d4e2cdd","isMergeCommit":true,"messageTitle":"Merge pull request #22 from ken-ruster/parse-promote","messageBody":"Add parsePromote","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"1b8f09fa06caa73c93ceaf4bd7325f96e830d188","isMergeCommit":false,"messageTitle":"Optimise parseMove","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":4}}},{"hash":"abb3d1280718214199edb41df98078071f0b9f44","isMergeCommit":false,"messageTitle":"Modify Move to expose only piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":7}}},{"hash":"8c2e65cd475e0074d35b12b4e5b2ad8e99c9d21f","isMergeCommit":true,"messageTitle":"Merge pull request #23 from ken-ruster/parse-promote","messageBody":"Modify Move class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"8bcff2098b9526763e0cc36ec2391aa7d764de7b","isMergeCommit":true,"messageTitle":"Merge pull request #3 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"d17246f0048e71e2293e8174fc5b557e3a5a021a","isMergeCommit":true,"messageTitle":"Merge pull request #4 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"fe5200d7c19a4cd9021b625b6b8ab83bb56a4385","isMergeCommit":false,"messageTitle":"Add promotion function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":111,"deletions":36}}},{"hash":"aee0fdb2217b2711ece98c83d9c3f359cd57cd35","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into promote","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9b929ea7cccd3f42ef18b9938cf55287e7743840","isMergeCommit":true,"messageTitle":"Merge pull request #35 from ken-ruster/promote","messageBody":"Add promote","fileTypesAndContributionMap":{}},{"hash":"130c73447825d8722992d68eb30ae1a6554b72a4","isMergeCommit":true,"messageTitle":"Merge pull request #5 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"10aa63e2dcaaeb83ac98cb5a2c8307f2137ac15c","isMergeCommit":false,"messageTitle":"Refactor to replace ChessTile[][] with ChessBoard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":236,"deletions":165}}},{"hash":"180b17f79b261c4f3e88a68b6e76b2a754973308","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into inputChange","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b3e2b227dc0be3412277f0edd95d51ffe3636940","isMergeCommit":true,"messageTitle":"Merge pull request #41 from ken-ruster/inputChange","messageBody":"Convert ChessTile 2D Array to ChessBoard Objects within getAvailableCoordinates method of ChessPiece objects","fileTypesAndContributionMap":{}},{"hash":"e0234d99755f86ccd0fefd92c524df38f63bb1f5","isMergeCommit":true,"messageTitle":"Merge pull request #6 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"8b8a824082cf7a375a459b10a01ad0afec07369c","isMergeCommit":false,"messageTitle":"Fix bug in executeMove","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"71a9826f5af8b9a526398f92ab08efce1eaf57e1","isMergeCommit":true,"messageTitle":"Merge pull request #43 from ken-ruster/castling-fix","messageBody":"Fix bug from merge","fileTypesAndContributionMap":{}},{"hash":"4c4abc0175d821e56e9ad6ff226c3f6af6d1d02f","isMergeCommit":true,"messageTitle":"Merge pull request #7 from AY2324S1-CS2113-T18-1/master","messageBody":"update","fileTypesAndContributionMap":{}},{"hash":"950cd9421835d5d7cffe4f5ab388778553c5b704","isMergeCommit":false,"messageTitle":"Fix bug causing all moves to evaluate invalid","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":7}}},{"hash":"9719431bb9cc2c798dc3ad1d940641c09262591f","isMergeCommit":false,"messageTitle":"Fix checkStyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":67,"deletions":70}}},{"hash":"c799155550c6b18fe27328d60f294b5d7f5c0c29","isMergeCommit":true,"messageTitle":"Merge pull request #46 from ken-ruster/bugfix","messageBody":"Bugfix","fileTypesAndContributionMap":{}},{"hash":"6d82fdd693fb388a57751b397bbde643d804babd","isMergeCommit":true,"messageTitle":"Merge pull request #8 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"124550cac18d24dbdbc47af118d2a8084dc352bb","isMergeCommit":false,"messageTitle":"Add jUnit test for parsePromote","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":18,"deletions":0}}},{"hash":"74fa224b6e6a52bf56f565b20b8c4b556bb88211","isMergeCommit":false,"messageTitle":"Add assertion","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"cb91b595ac7c796524153f17787277b76c5d83f0","isMergeCommit":true,"messageTitle":"Merge pull request #47 from ken-ruster/jUnit-assert","messageBody":"Add jUnit and assertion","tags":["v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"849a9445c8c9b4f08f86b7be22904a2c213d12e8","isMergeCommit":true,"messageTitle":"Merge pull request #9 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"77d79bf75a86782bfe4b53cbce65a6a3701e382c","isMergeCommit":false,"messageTitle":"Add fn to show available moves for a piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":88,"deletions":5}}},{"hash":"db74989da863f7cc36f7540733676a617b46f37e","isMergeCommit":false,"messageTitle":"Fix checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":3}}},{"hash":"18393a590c44c6cf96e4841a37b6ecf814075c93","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into showAvailableMoves","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"605514ee0b1f6c6fe4f3d6d86732382422b67aba","isMergeCommit":false,"messageTitle":"Address review comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":26}}},{"hash":"39dba37db67348b1e3ab05dbc8803ead13bb7bf8","isMergeCommit":false,"messageTitle":"Fix CheckStyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":4}}},{"hash":"b25ef97f1e84834b6cc62fc1a28977004d91afe2","isMergeCommit":false,"messageTitle":"Fix CI tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"f30bce1d149e5821e72e906029dfc3b1721fe367","isMergeCommit":false,"messageTitle":"Move message displaying available coord","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"b1aa7a9f4c4af98b33eefff39b41c0218fb00e62","isMergeCommit":false,"messageTitle":"Move message displaying available coord","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":4}}},{"hash":"18d3d136b9a0ae86f204d2f9a23efa541765bdf4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into showAvailableMoves","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5832b80bc3d13ccc24575533b0e4de9785e01170","isMergeCommit":true,"messageTitle":"Merge pull request #68 from ken-ruster/showAvailableMoves","messageBody":"Add function to show available moves","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"4594004f36864b213727d4b6c157c37da6696c36","isMergeCommit":true,"messageTitle":"Merge pull request #10 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"821658aebd0a3c9175df8f5674ac821b3ade7ff0","isMergeCommit":true,"messageTitle":"Merge pull request #79 from onx001/chessmasterai3","messageBody":"Implement board points and fix style checks","fileTypesAndContributionMap":{}},{"hash":"cefe15b6b81f45f76431209d9328384a78ec0008","isMergeCommit":false,"messageTitle":"Enable assertions","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-27","commitResults":[{"hash":"b4aadfb4faa57b329769af55b8fa1b7f5a17ad58","isMergeCommit":false,"messageTitle":"Add documentation for `Parser`","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":75,"deletions":0}}},{"hash":"33087366ca8fb5387e63aa249444b7a66edd28a8","isMergeCommit":false,"messageTitle":"Add class diagram for `Parser` and `Command`","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":60,"deletions":4}}},{"hash":"34d73b3c62929ccff345d978c0db31cc1f5773f5","isMergeCommit":true,"messageTitle":"Merge pull request #87 from TongZhengHong/branch-chessmaster-game-docs","messageBody":"Add documentation for `ChessMaster` and `Game`","fileTypesAndContributionMap":{}},{"hash":"8e3a157320a2d4bbc4c107d6a94ce8ccd06804b2","isMergeCommit":true,"messageTitle":"Merge pull request #86 from TriciaBK/tricia","messageBody":"Add Documentation for Storage ","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"785563562b942d5a764cd9e455208263e1060744","isMergeCommit":false,"messageTitle":"Modify getAvailableCoordinatesString()","messageBody":"Add a custom message for when there are no moves available for the piece chosen\n","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":2}}},{"hash":"d559284193d923c12f32de49b30cb98ff8e2a80d","isMergeCommit":true,"messageTitle":"Merge pull request #11 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"830c708f19d3f5c0367a1d75b685b1ea7df1633f","isMergeCommit":false,"messageTitle":"Fix CheckStyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"6569c8a0cf9d6b33801061fbf7efb8c81b555697","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into no-available-moves-message","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"aba0a9c401a093d478c1cb0e003bf1831cf6279c","isMergeCommit":false,"messageTitle":"Add help message at start of game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0}}},{"hash":"6a570cae9452da871b8528e58c8fb2cb9b960320","isMergeCommit":false,"messageTitle":"Add `moves` to list of commands in help","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}}]},{"date":"2023-10-31","commitResults":[{"hash":"4fc3a9d59d2c8b18fb2ccc534af76c9875732350","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into no-available-moves-message","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"4b2c0d0dd9049296eb88462fb65684b77c5632e5","isMergeCommit":false,"messageTitle":"Fix CI Tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"3f77fea303733594d649e2e947ca9ea27cf46a74","isMergeCommit":true,"messageTitle":"Merge pull request #98 from TongZhengHong/branch-show-board-with-prev-move","messageBody":"Show board with previous move","fileTypesAndContributionMap":{}},{"hash":"6ff8a8eb367c7d9d02af378e9437bcc6fd664996","isMergeCommit":true,"messageTitle":"Merge pull request #95 from TriciaBK/tricia","messageBody":"Update command strings to fit char constraint","fileTypesAndContributionMap":{}},{"hash":"0229bb2a68782acebb6449cbf8b488aa9072c62e","isMergeCommit":true,"messageTitle":"Merge pull request #100 from TongZhengHong/branch-draft-ug","messageBody":"User guide first draft template","fileTypesAndContributionMap":{}},{"hash":"5cc3981960d2dc85267082dff93348f91f2ad65d","isMergeCommit":true,"messageTitle":"Merge pull request #12 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"8d91920f33d58713060290c596e042c042b291ab","isMergeCommit":false,"messageTitle":"Update user guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":72,"deletions":24}}},{"hash":"87915a49e9db62c6313abd56897822c5a88a656a","isMergeCommit":false,"messageTitle":"Add guide on end of game","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":0}}},{"hash":"680dfb1f3bd97d1b6e0dca47711237c8f8f99671","isMergeCommit":false,"messageTitle":"Add FAQ","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":1}}},{"hash":"5b9c7ce2b061baaf255293df38fb91953cafa9a5","isMergeCommit":true,"messageTitle":"Merge pull request #102 from onx001/DifficultySave","messageBody":"Add Difficulty and Bugfix","fileTypesAndContributionMap":{}}]}],"antrikshdhand":[{"date":"2023-10-05","commitResults":[{"hash":"b0a61b4e5ecda5db94f4ad8a08c8a11dca11e77b","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"7d48b22f326388f2eca1ddaa4894dac5c51d2485","isMergeCommit":true,"messageTitle":"Merge pull request #5 from antrikshdhand/antriksh-AboutUs","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"c801ea42692d588d4378a889cd284d324c242eea","isMergeCommit":false,"messageTitle":"Add basic Game and Player classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":96,"deletions":40}}},{"hash":"72e15c80654b8b9c589b6910a662a8c367315064","isMergeCommit":true,"messageTitle":"Expand Player and Game classes","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c623d03e5e2e13851592c85ae7f02d81590e5be3","isMergeCommit":false,"messageTitle":"Add template code for CPU","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":14}}},{"hash":"1f6a9e688b08833476b8db4b75441bb397e3382c","isMergeCommit":false,"messageTitle":"Make Player class abstract","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"1ee70b10c3755d2b766943710434006ab8a38d1b","isMergeCommit":true,"messageTitle":"Merge pull request #29 from antrikshdhand/master","messageBody":"Add Game and Player classes","fileTypesAndContributionMap":{}},{"hash":"69699348f9c5b5e995bee0120cc502ba2de3edef","isMergeCommit":false,"messageTitle":"Add randomised-move CPU","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":27}}},{"hash":"4fbf4f7b2a03be0a9a627c687b1d520bc2a6cf4b","isMergeCommit":true,"messageTitle":"Merge pull request #34 from antrikshdhand/master","messageBody":"Add randomised-move CPU","fileTypesAndContributionMap":{}},{"hash":"57557e1600d7cec0f7c99201f5668cff55c3ca3d","isMergeCommit":false,"messageTitle":"Add Javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":56,"deletions":9}}},{"hash":"e0c748497d6b7dae036fc751f024a702a1acbd09","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f39a2582f107c613370f40b1bce494547625f726","isMergeCommit":false,"messageTitle":"Fix game launcher class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":51}}},{"hash":"a03f6672f37537c87e2d823a682385d33f404366","isMergeCommit":true,"messageTitle":"Merge pull request #38 from antrikshdhand/master","messageBody":"Fix conflict between Game and ChessMaster classes","fileTypesAndContributionMap":{}}]}],"TriciaBK":[{"date":"2023-10-05","commitResults":[{"hash":"fc7c1bd4091ee83c6df0616f710bf7ab3651b856","isMergeCommit":false,"messageTitle":"?????","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"58e114c5917e81e436287764309e5165576cc4aa","isMergeCommit":true,"messageTitle":"Merge pull request #3 from TriciaBK/tricia","messageBody":"?????","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"f0541ec8fa6d99300896d53ff19d40d67c7ab2c4","isMergeCommit":false,"messageTitle":"added temporary method for executeMove method to access","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}},{"hash":"1ca4a431744c9f133d36d60d4808b2b72b3d9fb1","isMergeCommit":false,"messageTitle":"added temporary method for executeMove method to access","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":2}}},{"hash":"760456c7df5d6f6e094e4e65df781b09e632fa9c","isMergeCommit":false,"messageTitle":"Add executeMove method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":5}}},{"hash":"75807ce2a7deb81cb42415befcf264333f2bd42e","isMergeCommit":false,"messageTitle":"Removed move history","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":18}}},{"hash":"ef9786cafa2dc81bb582195af35e46f26008ac72","isMergeCommit":true,"messageTitle":"Merge pull request #11 from TriciaBK/chessboard-state","messageBody":"Chessboard state","fileTypesAndContributionMap":{}},{"hash":"eddf4457de673699da57131e019856e79e27339d","isMergeCommit":false,"messageTitle":"Add exception handling for saving board","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":0}}},{"hash":"b2fac1f5d326c2c39029ac7c3a388557ef3ac9c7","isMergeCommit":false,"messageTitle":"Add exception handling for loading board","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":0}}}]},{"date":"2023-10-17","commitResults":[{"hash":"d26a09bde262783d3a3312df1ac069dd2ef138a6","isMergeCommit":false,"messageTitle":"Add saveBoard and loadBoard methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":111,"deletions":1}}},{"hash":"432e0ca40922330edc0b0bd8e2f530f5c2a45ad3","isMergeCommit":false,"messageTitle":"Add setTile method for loadBoard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5}}},{"hash":"1197ab36e28a828f2ee61300cbbc07018b20b2f8","isMergeCommit":false,"messageTitle":"Update method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}},{"hash":"bd47e5d8ee0916a3164ae5c0c3f4fcf6defc164b","isMergeCommit":false,"messageTitle":"Update Save and Load method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"7ef957bdcd5debc1c7fb7af31a51a8ce8acb76f3","isMergeCommit":true,"messageTitle":"Merge branch \u0027storage\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"43b8f674c63120a95a4365894df2f54ae716833e","isMergeCommit":false,"messageTitle":"Add updatePosition method after move excution","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"adf3af69b9d133a9cd3b18393397d55a0032c64b","isMergeCommit":false,"messageTitle":"Add exception handling in executeMove method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":5}}},{"hash":"3d9ed6eda7e0a1c8e97d40fc2af25d562c8423d2","isMergeCommit":true,"messageTitle":"Merge pull request #24 from TriciaBK/chessboard-state","messageBody":"Update executeMove","fileTypesAndContributionMap":{}},{"hash":"962a3055847617e6ab3689d473755dd44a688e28","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into storage","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bf7f156df16b8da47a8fb666b93670e0186befdc","isMergeCommit":false,"messageTitle":"Fixed checkstyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":27}}},{"hash":"94b32dbefed7b8c9ba74a83454871c957e4e3866","isMergeCommit":true,"messageTitle":"Merge pull request #25 from TriciaBK/storage","messageBody":"Resolved Storage checkstyle violations","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"5a0364a5abe5bb30d994cf2bc70ade619328002b","isMergeCommit":false,"messageTitle":"Add method to check for end game and winning colour","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":55,"deletions":5}}},{"hash":"be8099ab0ada8f58ecbd2c527171d052f1516477","isMergeCommit":true,"messageTitle":"Merge pull request #44 from TriciaBK/tricia","messageBody":"Add method to check for end game and winning colour","fileTypesAndContributionMap":{}},{"hash":"405ae94c37c42748cf1bd5ac27107ffc1ca10e65","isMergeCommit":false,"messageTitle":"Add load method into game class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":6}}},{"hash":"af00691e10775886437e525b1933e910713da92d","isMergeCommit":false,"messageTitle":"Add assertions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"2d29393dfa418b76ac5ffd025468a68dc3298302","isMergeCommit":true,"messageTitle":"Merge pull request #45 from TriciaBK/tricia","messageBody":"Add load method into game class and add assertions","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"7ca4c096e8a554e18a9bf59027a308b16adf5c4b","isMergeCommit":false,"messageTitle":"Added CPUFirstMove if playerColour is black","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":4}}},{"hash":"548e89850c1b79c57bfb5d3ad401356c1ade444a","isMergeCommit":true,"messageTitle":"Merge pull request #58 from TriciaBK/tricia","messageBody":"Added CPUFirstMove if playerColour is black","fileTypesAndContributionMap":{}},{"hash":"dd2257fb6cb082dbaf2175e58c66298bc43a0d71","isMergeCommit":false,"messageTitle":"Update Help Command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":1}}},{"hash":"70e64b55c5b725952af36c259c49a78b98a74358","isMergeCommit":false,"messageTitle":"Add RulesCommand and update HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":5}}},{"hash":"5cb6a76ebc89bfc88f68ec924f2dbf762535d17e","isMergeCommit":true,"messageTitle":"Merge pull request #59 from TriciaBK/tricia","messageBody":"Add RulesCommand and update HelpCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"1d15c2b26c03f1726de6f01947d026cccbab1160","isMergeCommit":false,"messageTitle":"Add ShowCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":5}}},{"hash":"06483415b35f057262101d7b05a6cc74d8ff8e4d","isMergeCommit":false,"messageTitle":"Fixed checkstlye","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":3}}},{"hash":"36a59b41f4c7b7bf9daeba45d7dcebfa10bddfd0","isMergeCommit":true,"messageTitle":"Merge pull request #65 from TriciaBK/tricia","messageBody":"Add ShowCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"d9d54711b5e6c6b7a46fb05f8c3731778683bea4","isMergeCommit":true,"messageTitle":"Merge pull request #84 from TongZhengHong/branch-junit-assert","messageBody":"Branch junit assert","fileTypesAndContributionMap":{}},{"hash":"7ee4c2cbc63b522c470538c1913a7d02cc382ef4","isMergeCommit":false,"messageTitle":"Update Developer Guide for storage class","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":38,"deletions":6}}},{"hash":"55728cacf7bc7be03eaaf762cbd0dcd6be2ac7e9","isMergeCommit":false,"messageTitle":"Update Developer Guide for storage class","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":152,"deletions":28}}},{"hash":"1bb9026a886788acbf115db4ff7b72717514a5cb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into tricia","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"61cc6492f4f3ca4f0c9652ef3d68bd8abd0ca2a2","isMergeCommit":false,"messageTitle":"Addressed reviewer comments","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"e9a257881b0fb6d741d6ce2dd310d6857908d22d","isMergeCommit":true,"messageTitle":"Merge branch \u0027tricia\u0027 of https://github.com/TriciaBK/tp into tricia","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"116aa70f1d31987b9ed33337655b72d763a18219","isMergeCommit":false,"messageTitle":"Update command string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":11}}},{"hash":"9b2c17f8f9a8801f00d1ebe88c75ca03196f3dab","isMergeCommit":false,"messageTitle":"Update execute to show board after string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}}]},{"date":"2023-11-01","commitResults":[{"hash":"e94e7187e2ba513ad0518efdf927f3c97e32ec70","isMergeCommit":false,"messageTitle":"edit ShowCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"964bcea9a14c78ed45f173a49b7f23e724db1ded","isMergeCommit":true,"messageTitle":"Resolved conflict","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"35716a17905f60ad3359017de5ea26861cacade1","isMergeCommit":false,"messageTitle":"Moved storage uml and png into diagram and image folder","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":4},"docs":{"insertions":3,"deletions":2}}},{"hash":"9d514da9798a0875f5c16f89463e86b5c0b43c9d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":16}}},{"hash":"ebb46ecae0cc9304fa2598857020e81c35744fd7","isMergeCommit":false,"messageTitle":"Update UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":8}}},{"hash":"987ae2e15f927e277cc369d0b1e42f77e41dd9b8","isMergeCommit":false,"messageTitle":"Add ViewLegendCommand and update relevant classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":55,"deletions":21}}},{"hash":"8aab2ebc4c8f660ab1c80234e5e1865380d6de67","isMergeCommit":false,"messageTitle":"Fix checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":17}}},{"hash":"6ef26e9b8969914a48c5144b18f2e303d41289b4","isMergeCommit":false,"messageTitle":"Add storing and loading of currentPlayer","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":5}}},{"hash":"5764c5b12d20c38431e2e7c60aacccc25c02747d","isMergeCommit":false,"messageTitle":"Update ViewLegendCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":12}}},{"hash":"5ed0f5902e90c2741fc00a07b15c0192d77080c7","isMergeCommit":false,"messageTitle":"Update and rename LegendCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":38}}},{"hash":"3c73eacdf8f8b1fc88fbf1eb2a608a1b564b4896","isMergeCommit":false,"messageTitle":"Update Rules to use exact pieces representation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":7}}},{"hash":"509521f4ee843af5da5d446ced79c0e64d949f9b","isMergeCommit":false,"messageTitle":"Update Rules string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"ac05f9ab44060ede7f5171c0b67873ea290783dc","isMergeCommit":false,"messageTitle":"Add tracking of current player colour","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":17}}},{"hash":"40fe47e42db430d93a0d1f5caa305f9d3a61d0a2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into player-color","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ee83ae30acd3dc83c614e71685ff334cddccedd3","isMergeCommit":false,"messageTitle":"Fixed checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":4}}}]},{"date":"2023-11-03","commitResults":[{"hash":"4094e74bfbe1ea20d3e48fe1cefcdf95032420ba","isMergeCommit":false,"messageTitle":"Exception handling in loadCurrentcolor","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":15}}}]}],"onx001":[{"date":"2023-10-05","commitResults":[{"hash":"3f292064f69048663493770d480744c23b56b6c4","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"5fa1cf229e9d7354ebd4e848ca46411c10ecbd5d","isMergeCommit":true,"messageTitle":"Merge pull request #2 from onx001/onx-AboutUs","messageBody":"Update README.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-11","commitResults":[{"hash":"67b268ef9145aba4ebf24e7d07d328c13b18ed03","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/onx-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8753fbaa6e312c71a7e121ce566ee779e2a032a7","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"e2d445f2146c5512f3fbe96952c356004d7679b8","isMergeCommit":false,"messageTitle":"Display valid moves","messageBody":"Implementation of valid moves in progress.\n\nLet\u0027s have a function to display valid moves.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":78,"deletions":13}}},{"hash":"dfe81161128ae9c8510d3facc98671f4e24b04f5","isMergeCommit":true,"messageTitle":"Merge pull request #14 from onx001/ValidMoveDisplay","messageBody":"Display valid moves","fileTypesAndContributionMap":{}},{"hash":"c71ad2eaad3f4461ad84502c91a3530b5e325503","isMergeCommit":false,"messageTitle":"Update ChessPiece.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":53,"deletions":1}}},{"hash":"8dcb170f321be50a71ff77c18bcf80de9138253a","isMergeCommit":true,"messageTitle":"Merge pull request #15 from onx001/ValidMoveDisplay","messageBody":"Update ChessPiece.java","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"b0b7f5e2fdb988cbe187c8ce83fd7849263540fb","isMergeCommit":false,"messageTitle":"Implement Move Validation","messageBody":"Knowing whether a move is valid is important for gameplay, especially for future implementations of solving algorithms.\n\nLet\u0027s implement a generic available move and validity checker as well as basic UI additions for debugging.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":120,"deletions":51}}},{"hash":"7dcec1be03acca1a7f2c1d1c1f78d9b737c847eb","isMergeCommit":true,"messageTitle":"Merge pull request #17 from onx001/ValidMove","messageBody":"Implement Move Validation","fileTypesAndContributionMap":{}},{"hash":"d3893b200ef00ed734b42572a0f273fcf8919bb7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into storage","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"183d7f5d6905d378d6020cd098c1d048b32fb058","isMergeCommit":true,"messageTitle":"Merge pull request #16 from TriciaBK/storage","messageBody":"Storage","fileTypesAndContributionMap":{}},{"hash":"3d3ab4435289b7652113feb39f5e5330e0e77859","isMergeCommit":false,"messageTitle":"Edit JUnit test and add assert statement","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":0}}},{"hash":"69452968a4da01aeb4af72ca6a920b6a93bf11b7","isMergeCommit":true,"messageTitle":"Merge pull request #18 from onx001/JUnitAssert","messageBody":"Edit JUnit test and add assert statement","fileTypesAndContributionMap":{}},{"hash":"fd0cd7c36fa63644a017cbb77f06c9604a2be3b1","isMergeCommit":false,"messageTitle":"Fix coding standard for gradle style checks","messageBody":"Let\u0027s standardise coding styles for easier management across different programmers\n","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":34}}},{"hash":"aa2fb919ec3a346f4248ee74c8df431892942e57","isMergeCommit":true,"messageTitle":"Merge pull request #19 from onx001/Style-Fix-1","messageBody":"Fix coding standard for gradle style checks","fileTypesAndContributionMap":{}},{"hash":"d5b4508a9b9a8818e88eb0787e3e404d3429ba25","isMergeCommit":false,"messageTitle":"Add function for colour change","messageBody":"Swapping board axii every turn change is troublesome and resource-wasteful.\n\nLet\u0027s add valid function checking depending on board colour and orientation.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":2}}},{"hash":"bf4d6fc7abcfa8fec49b7a19a7b9991320c971f6","isMergeCommit":true,"messageTitle":"Merge pull request #20 from onx001/AddBlackPawnCheck","messageBody":"Add function for colour change","fileTypesAndContributionMap":{}},{"hash":"3dd93d8e677e892818307cb61a1a5105737b53e6","isMergeCommit":true,"messageTitle":"Merge pull request #21 from onx001/JUnitTest-1","messageBody":"Update EXPECTED.TXT","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"e1640df62e18fdbe1d3de90c17c1e0f21291953d","isMergeCommit":false,"messageTitle":"Implement Flatten Coordinate","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":0}}},{"hash":"7359a5d798ba0583174408e8b800f299d2b13377","isMergeCommit":true,"messageTitle":"Merge pull request #30 from onx001/flatten-coord","messageBody":"Flatten coord","fileTypesAndContributionMap":{}},{"hash":"9d23107cff35717d80ae6f52dfe1c333392cca88","isMergeCommit":false,"messageTitle":"Abstract Command Class","messageBody":"Having the parser handle all inputs results in messy and convoluted class files.\n\nLet\u0027s abstract out the command class to be handled separately.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":98,"deletions":6}}},{"hash":"f03e1b317732d8279bd6911d7b923d7f61858b72","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into AbstractCommandClass","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cc9aaecfd81fead5ecd23f0c2b0f9148fc3012fc","isMergeCommit":true,"messageTitle":"Merge pull request #37 from onx001/AbstractCommandClass","messageBody":"Abstract Command Class","fileTypesAndContributionMap":{}},{"hash":"0bc26ac88df85e06f0a3536103d65328eefcad15","isMergeCommit":false,"messageTitle":"Integrate command classes into game class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":12}}},{"hash":"231125b6a729e8416852c2942e88be3798eb5035","isMergeCommit":true,"messageTitle":"Merge pull request #39 from onx001/integratecommandgame","messageBody":"Integrate command classes into game class","fileTypesAndContributionMap":{}},{"hash":"3f2c7175536a406dd46bdbd29af467ff16c4e8cc","isMergeCommit":false,"messageTitle":"Add Castling Function","messageBody":"Castling is an important move in chess. Let\u0027s add the ability to do so.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":0}}},{"hash":"e23635bcc1abf7119eb3cb555194f461f9219a72","isMergeCommit":true,"messageTitle":"Merge pull request #40 from onx001/AddCastling","messageBody":"Add Castling Function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-21","commitResults":[{"hash":"47aec5c69ae9b3fe1402b7cfcfd23af951fb64a6","isMergeCommit":false,"messageTitle":"Abstract Command Exceptions","messageBody":"Abstract exception handling outside of command objects\n","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":6}}},{"hash":"7a8f63944552e64dbc8a4a644d2a2e36ae384b49","isMergeCommit":true,"messageTitle":"Merge pull request #49 from onx001/AbstractCommand","messageBody":"Abstract Command Exceptions","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"1c21298c9483f64cf3fd104245eecdcac9dbce5c","isMergeCommit":false,"messageTitle":"Add Point System","messageBody":"Point systems are important for chess pieces in the minimax algorithm. Let\u0027s assign points to chess pieces for later implementation.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":0},"test-code":{"insertions":21,"deletions":0}}},{"hash":"60126b4b0adcba8fdd28357d746e3997ea06aae2","isMergeCommit":true,"messageTitle":"Merge pull request #60 from onx001/points","messageBody":"Add Point System","fileTypesAndContributionMap":{}},{"hash":"788919bf75b60cca636a21110d84defbb20a0548","isMergeCommit":false,"messageTitle":"Add Minimax Function","messageBody":"Add basic minimax function for AI.\n\nTo-dos include returning a move and adding alpha-beta pruning, as well as difficulty selection.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":157,"deletions":0}}},{"hash":"ccba7cd34bf2a4fe3174226eff5b8f924460b603","isMergeCommit":true,"messageTitle":"Merge pull request #62 from onx001/minimax1","messageBody":"Add Minimax Function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"e29e6176dd302de0e4d938ea5b1f2d44b46e4145","isMergeCommit":false,"messageTitle":"Add move to minimax","messageBody":"Todo: Fix move changing error\n","fileTypesAndContributionMap":{"functional-code":{"insertions":94,"deletions":14}}},{"hash":"524828778d07bebd7681fe5b06c577527cd06687","isMergeCommit":true,"messageTitle":"Merge pull request #66 from onx001/move-minimax","messageBody":"Add move to minimax","fileTypesAndContributionMap":{}},{"hash":"84c39b46fc27e851c5c8ea01dfdcaa9d6112bcbd","isMergeCommit":false,"messageTitle":"Finish basic chessmaster logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"e05577a9d2517463c37dd95e8d6204d293e98537","isMergeCommit":true,"messageTitle":"Merge pull request #67 from onx001/chessmasterai1","messageBody":"Finish basic chessmaster logic","fileTypesAndContributionMap":{}},{"hash":"d3240ce55eecf45e23be9f8728e823f0e11f223a","isMergeCommit":false,"messageTitle":"Score Bug Hunting 1","messageBody":"Scores are not updating properly. Am in the process of finding the bug\n","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":7}}},{"hash":"ffa80a73b9f451294433b0196bb97ceb4ee0640f","isMergeCommit":true,"messageTitle":"Merge pull request #69 from onx001/chessmasterai1","messageBody":"Score Bug Hunting 1","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"bdf516f0afbbf54b5e57fa5b2056c28608aa7e19","isMergeCommit":false,"messageTitle":"SolveBugDiffPiece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":29}}},{"hash":"e5827f2a4239e43d0d50ad21e1f57b722c254867","isMergeCommit":true,"messageTitle":"Merge pull request #70 from onx001/chessmasterai1","messageBody":"SolveBugDiffPiece","fileTypesAndContributionMap":{}},{"hash":"fc7f3068828f8068002a709bf9d332ba2b36f085","isMergeCommit":false,"messageTitle":"Fix bug with cannibal code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":14}}},{"hash":"0771cd45a2d7e6a0253cf6f56fdfa7c847796d4b","isMergeCommit":true,"messageTitle":"Merge pull request #71 from onx001/chessmasterai1","messageBody":"Fix bug with cannibal code","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"ec076a39d09139babadbad8aa6ff0b5c4c8c0554","isMergeCommit":false,"messageTitle":"Implement board points and fix style checks","messageBody":"Also added a few comments for the algorithm\n\nTodo: Add comprehensive comments and testing\n","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":0}}},{"hash":"6da70024882468322789a89ae5734caa87c93b76","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into chessmasterai3","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"946c63e2c4467721d775f59d8e5ca6f47bf2cf4b","isMergeCommit":false,"messageTitle":"Resolve merge conflicts","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"09c58d80de779b1748c7e9358f5084395896a2f6","isMergeCommit":false,"messageTitle":"Add board weights","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":5}}},{"hash":"585a4fe97f4b4868b50d7644d5e636f1afbb534b","isMergeCommit":false,"messageTitle":"fix merges and update ui tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":17},"test-code":{"insertions":1,"deletions":1}}},{"hash":"29f3cf4eb8133dff60b85c7a320b78e57b95eb41","isMergeCommit":false,"messageTitle":"fix checkstyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"8a7066df090d46fd362d8fc25eb96441314d51a8","isMergeCommit":false,"messageTitle":"Add more description","messageBody":"Javadocs and comments are important for readability and cross-developer coordination. Let\u0027s add more.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":8}}},{"hash":"e78e1198480b5d5a30c581a72e859295bd836e90","isMergeCommit":false,"messageTitle":"Add v1 requirements to developer guide","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0},"docs":{"insertions":10,"deletions":0}}},{"hash":"7145ccccc6bf36fceff4f05f8deb736ff273d94d","isMergeCommit":false,"messageTitle":"Minimax fine tuning","messageBody":"Fine tuned minimax algorithm and updated developer guide\n","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4},"docs":{"insertions":6,"deletions":0}}},{"hash":"6bbb9a0c2ec11c08e53e511ffec62f6363403d99","isMergeCommit":true,"messageTitle":"Merge pull request #83 from ken-ruster/enable-Assert","messageBody":"Enable assert in gradle","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"af3aa0f88314fca926bdab1f867022a18746bccf","isMergeCommit":true,"messageTitle":"Merge pull request #94 from TongZhengHong/branch-nonstatic-textui","messageBody":"Make `TextUI` methods non-static","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"a94bbd6891733d423ab9986221732d9341a850d6","isMergeCommit":false,"messageTitle":"Add Difficulty and Bugfix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":114,"deletions":12},"docs":{"insertions":84,"deletions":0}}},{"hash":"47c5a32927ba0b7fc92202e58fa255c21b93a270","isMergeCommit":false,"messageTitle":"Update UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":4}}}]},{"date":"2023-11-02","commitResults":[{"hash":"fd6419a97c5723dc4a0b2017956ecb09e2c0a873","isMergeCommit":true,"messageTitle":"Merge pull request #103 from onx001/DifficultySave","messageBody":"Update MiniMax UML Sequence Diagram","tags":["v2.0"],"fileTypesAndContributionMap":{}},{"hash":"42ffd0f99fbca73257716acda02c83cc7b5ec675","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":4}}},{"hash":"ec1f0f818638260f70d6df5fc8ee7a33401b4289","isMergeCommit":false,"messageTitle":"Update PUML1","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":5}}},{"hash":"55c1feca4bea8fc38aa1662984b762b8c1ff3d0e","isMergeCommit":false,"messageTitle":"Update PUML2","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"d190c4157a8d9db8ef5eee78dc95d4dbf8e109b8","isMergeCommit":false,"messageTitle":"Fix bug for savefile manipulation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":0},"docs":{"insertions":11,"deletions":6}}}]},{"date":"2023-11-03","commitResults":[{"hash":"3f5ec119366ea3c7e4170abd160cb6b03a673e6a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into bugFixLoad","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9f7a1daa120f26057cfa2045f42d0496565b79b8","isMergeCommit":false,"messageTitle":"PR Review Fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":37}}},{"hash":"cdf3ef8d282e0b2cd1d286a056887f9d657dc829","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into bugFixLoad","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2a3bfeb06fa1a245208ec04bdaf2a84341e4bcb8","isMergeCommit":true,"messageTitle":"Merge pull request #114 from TongZhengHong/branch-storage-hasMoved","messageBody":"Store `hasMoved` flag for each ChessPiece","fileTypesAndContributionMap":{}},{"hash":"0401b9ef9bd5a298e3650fe166ad380ff7e23615","isMergeCommit":false,"messageTitle":"Fix Startcolor bug and add minimax test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0},"test-code":{"insertions":17,"deletions":0}}},{"hash":"f87fe025a37c31520e4c753e1144557236fb4dea","isMergeCommit":false,"messageTitle":"Fix stylecheck errors","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"853f43af018aad46f40aa4c9b6e0ca5d21673c97","isMergeCommit":false,"messageTitle":"Update test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"08f1efd01c936c4bcb77e288182c15dd42cb78a7","isMergeCommit":false,"messageTitle":"Update difficulty loading bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"0b8cf2d2817f4d1a80732be6343c1023e8beff66","isMergeCommit":false,"messageTitle":"Add check functionality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":0}}}]},{"date":"2023-11-04","commitResults":[{"hash":"70b700349f3404e942cd96f28a39542295845d75","isMergeCommit":false,"messageTitle":"Fix minimax aggro","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"e0159f0b9fb249ca72b0475f168fba3494ca89e6","isMergeCommit":false,"messageTitle":"Update MiniMax.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]}],"TongZhengHong":[{"date":"2023-10-05","commitResults":[{"hash":"62922ff6fccb29e15f6a330af40a4242b1addf1c","isMergeCommit":false,"messageTitle":"Close scanner","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"2b99e2930c4d2001569261848c570906d5a7fdfa","isMergeCommit":true,"messageTitle":"Merge pull request #4 from TongZhengHong/ZhengHong","messageBody":"Close scanner","fileTypesAndContributionMap":{}}]},{"date":"2023-10-08","commitResults":[{"hash":"c839a08a725946522e2ac0485e7c2fdf3267a493","isMergeCommit":false,"messageTitle":"Remove questions marks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"f5030d7118f9839cf6f7166b7f7fa8631d6bb98d","isMergeCommit":true,"messageTitle":"Merge pull request #6 from TongZhengHong/fix_cd_test","messageBody":"Remove questions marks","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"65df1cb11da47e7062fdfcad883dfc1aa3ad03a4","isMergeCommit":false,"messageTitle":"Change Duke to ChessMaster","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-15","commitResults":[{"hash":"6abb6778d5f773debb94bb877b519d9948c5464d","isMergeCommit":false,"messageTitle":"Basic skeleton classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":109,"deletions":5}}},{"hash":"c4f69a258ac8c205eef9450c9a6e7f18ba445e24","isMergeCommit":false,"messageTitle":"Change package board to package game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":74,"deletions":34}}},{"hash":"7f57dba052fa9a6e7d53ad264a6f46479d66634f","isMergeCommit":false,"messageTitle":"Add row, col and color to chessPieces","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":97,"deletions":9}}},{"hash":"65ae9d850d9aba82c149050ee4caf45918f4d25c","isMergeCommit":false,"messageTitle":"Update utility classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":8}}},{"hash":"29d972ea154a415ba986a02be82b5a4b67fe67a3","isMergeCommit":false,"messageTitle":"Change chess pieces from unicode to letter","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":13}}},{"hash":"264f8cb40e5caca637d71b091d4fdcc88923f99d","isMergeCommit":false,"messageTitle":"Update printing code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":24}}},{"hash":"df10c20c4ad72b22b262a879ebaaf5ff91f1962c","isMergeCommit":false,"messageTitle":"Remove key string and standardise color","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":34}}},{"hash":"a47b7be89bf74c89a7aaa0ef21170a27b87ee748","isMergeCommit":false,"messageTitle":"Update chess piece color initialisation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":17}}},{"hash":"75a416c5acfbe1ad67323668dac625a535b0be8a","isMergeCommit":false,"messageTitle":"Create basic exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":0}}},{"hash":"ae6ad89bcd9c3f3db05d2cccc9641e839b1954db","isMergeCommit":false,"messageTitle":"Create Coordinate class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":79,"deletions":0}}},{"hash":"dd431c7ff48227541dd9a409b77e093ef28e5a1d","isMergeCommit":false,"messageTitle":"Add getAvailableCoordinate for each chess piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":204,"deletions":4}}},{"hash":"1565b161990f065ab146cd9b0d607171b4b4a846","isMergeCommit":false,"messageTitle":"Minor changes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":5}}},{"hash":"ae54b6e50ee89ea5bd9516ee8745948bbf9cdc15","isMergeCommit":false,"messageTitle":"Update printChessBoard to show coordinate beside","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":3}}}]},{"date":"2023-10-16","commitResults":[{"hash":"049349fd79bcd94348ebdc4ed225b4223ec9beab","isMergeCommit":false,"messageTitle":"Add javadoc comments for important methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":2}}},{"hash":"a89e57499a273dffb13562c97b38aa1ff7de1cd0","isMergeCommit":false,"messageTitle":"Update checkstyle draft","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":85,"deletions":73}}},{"hash":"df797156621c80d93c4647ca00daa74290a42db7","isMergeCommit":false,"messageTitle":"Address checkstyles","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":24}}},{"hash":"c1cad31c65a0396670d913dee75b41918f2f7bdb","isMergeCommit":false,"messageTitle":"Fix IO redirection test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":21},"other":{"insertions":8,"deletions":2}}},{"hash":"88ba9a509231ff35aa0bdd960f330719e8b03182","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":19}}},{"hash":"ea5ecbfa6267d890a8aab3ae4e3beb8d2a0515c3","isMergeCommit":true,"messageTitle":"Merge pull request #8 from TongZhengHong/branch-setup-template","messageBody":"Branch setup template","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"c78ff2c464137518d661559179236062e0b33a33","isMergeCommit":false,"messageTitle":"Add ChessMasterException parent exception class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":5}}},{"hash":"a925d01c5ea210767e562f71f5fc10fed0036d3f","isMergeCommit":false,"messageTitle":"Create NullPieceException for empty piece at tile retrieval","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":3}}},{"hash":"fe912e66c55c2d129616ec0ccb0e5f4196a7fa46","isMergeCommit":false,"messageTitle":"Remove redundant MoveValidator class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":14}}},{"hash":"3c2e74665a7c6300f390ff3481c6243349179843","isMergeCommit":false,"messageTitle":"Add/Update utility access function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":29}}},{"hash":"59ebda2d24dbc3be6cfc1504988b92f86b2e35cd","isMergeCommit":false,"messageTitle":"Fix parseAlgebraicCoor method bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e99af55f311bf0441ee59cb852db6f984098c525","isMergeCommit":false,"messageTitle":"Implement main chess game engine","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":33}}},{"hash":"68f90d785ce97bb364e92287d8aa3b27b8418781","isMergeCommit":false,"messageTitle":"Clean up code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"7a91674b6218114e072cb688bf929bf358e1c995","isMergeCommit":false,"messageTitle":"Fix CI tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":52}}},{"hash":"595ce058d9f7bdd7ccb74c684a732d9e7147b220","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-setup-chessmaster-engine","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"52218d65a20ae4e67ab80a87a4c0d465b9185443","isMergeCommit":false,"messageTitle":"Test CI gradle build","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"78565daefec3130476e01ed3f7a53d44b41bdd4a","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-setup-chessmaster-engine\u0027 of https://github.com/TongZhengHong/tp into branch-setup-chessmaster-engine","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bf12a91560598d566b3de5f872e60f2100c4f5fa","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5}}},{"hash":"8fb02e14aae84b7dba8f2d5fa5b6c08dbd92fae3","isMergeCommit":true,"messageTitle":"Merge pull request #26 from TongZhengHong/branch-setup-chessmaster-engine","messageBody":"Branch setup chessmaster engine","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"324bfb986eae77c3b4320681e737853fe54f86cc","isMergeCommit":false,"messageTitle":"Add random seed to CPU class for predictable moves","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3}}},{"hash":"02382a331c6ae7955bc9b8638a79e7a2e9524ec3","isMergeCommit":false,"messageTitle":"Disable loading chessboard from file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":10}}},{"hash":"49ac9a8ef5dac96d765e666ac3568955bd0a97b6","isMergeCommit":false,"messageTitle":"Remove unnecessary imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":8}}},{"hash":"684d03d43560c18eb09ac0741feba9440d747c82","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":95,"deletions":76}}}]},{"date":"2023-10-21","commitResults":[{"hash":"9206bedfacec06759286c5583eddd93460a83211","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"149c72293e41b61c832dccdefe2b4124bf349a88","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7bc96700214cbc3f3ab9e639c47e55e8c6e48200","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-random-seed\u0027 of https://github.com/TongZhengHong/tp into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"820dd8faab666fa676edb155ab3718e0fefc38fa","isMergeCommit":false,"messageTitle":"Disable logo display","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":14}}},{"hash":"2f50638243d2749ddb5e9ec730c4736334d65b73","isMergeCommit":false,"messageTitle":"Fix abort function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":14}}},{"hash":"99d7bc00cdab2ab7e4a8c2c18d3758f4c14ad2c9","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-random-seed\u0027 of https://github.com/TongZhengHong/tp into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9461a089c5cc50fa80e4364aab7ab8e78d58f48d","isMergeCommit":true,"messageTitle":"Merge pull request #48 from TongZhengHong/branch-random-seed","messageBody":"Add random seed to CPU class for predictable moves","fileTypesAndContributionMap":{}}]},{"date":"2023-10-22","commitResults":[{"hash":"ab98dd0d4e1f1e039e592fc724411497641373b8","isMergeCommit":false,"messageTitle":"Add CommandResult to store result of command execution","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":0}}},{"hash":"cb66ab4f5ffc05ae44f71298f88e293a68d9dc28","isMergeCommit":false,"messageTitle":"Add new exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":0}}},{"hash":"76a3ad44c9f47aebd2e353c063376a2897f70d35","isMergeCommit":false,"messageTitle":"Remove getMove and update commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":56}}},{"hash":"bd0030634aae5a1a53832adad552fe4ff2ca00d0","isMergeCommit":false,"messageTitle":"Remove castling flags and add new utility methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":42}}},{"hash":"ca42df96c7d0a5d408886f4a23c4ef633cbcba0f","isMergeCommit":false,"messageTitle":"Clean up getAvailableCoor methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":112,"deletions":208}}},{"hash":"16904a75ccc4eaccbcf87f3446528d3b4ff0b1fa","isMergeCommit":false,"messageTitle":"Add captured and promotion checking when updating ChessTile","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":3}}},{"hash":"66041493be64a3bfeef58db574c54128dd9c4351","isMergeCommit":false,"messageTitle":"Add more utility methods in Coordinate and TextUI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":6}}},{"hash":"c6ff0391eeddc01d7fa84a44b2c9e5f73fdce71d","isMergeCommit":false,"messageTitle":"Update castling checking code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":9}}},{"hash":"f44e4d347f39ab93a7146787c671ec3462ab0787","isMergeCommit":false,"messageTitle":"Abstract methods from Player class to ChessMaster","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":120}}},{"hash":"681ba2dacf170b4f3b1c931547396ab58d88933b","isMergeCommit":false,"messageTitle":"Update main control flow in Game class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":218,"deletions":177}}},{"hash":"ec03db5e0cfb6dc0662257cc8506441cbc55affa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of tp into branch-more-oop","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b542a666ee82943b60342bf88d0622175ac10c11","isMergeCommit":false,"messageTitle":"Minor fix to storage to pass CI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"0a125a950de7455328a54205caa3c8995c2ca376","isMergeCommit":true,"messageTitle":"Merge pull request #53 from TongZhengHong/branch-more-oop","messageBody":"Branch more OOP","fileTypesAndContributionMap":{}},{"hash":"3bccc222482f5aaf807551620367b77d298b8682","isMergeCommit":false,"messageTitle":"Add createFile method before loading and saving","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":63,"deletions":58}}},{"hash":"0d1d6d2cc6bc3a457775b7dc10321bde6590452e","isMergeCommit":false,"messageTitle":"Add Color enum \u0026 javadoc to color utility methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":85,"deletions":25}}},{"hash":"8e97434da7c932e0b9175ef5f527967daf08b16e","isMergeCommit":false,"messageTitle":"Update ChessPiece classes to use Color enum","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":15}}},{"hash":"8722a95c98a28cf93fe73eba0a0f70330cd1415f","isMergeCommit":false,"messageTitle":"Update Player classes to use Color enum","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":6}}},{"hash":"28e2bfc05da8e6311e33bae03b98040cbadd83c0","isMergeCommit":false,"messageTitle":"Update remaining classes to use Color enum","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":38},"test-code":{"insertions":2,"deletions":1}}},{"hash":"1cb5d04a4441175f6089d232312c0391c9f8e0ee","isMergeCommit":true,"messageTitle":"Merge pull request #54 from TongZhengHong/branch-standardise-color","messageBody":"Branch standardise color","fileTypesAndContributionMap":{}},{"hash":"f72a760331a1b8add5ddbeda4dc93f056440619d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-fix-storage","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"ad1a4fbb5ab765ccfbb22144569c39dcf0f6cad0","isMergeCommit":false,"messageTitle":"Create Color enum and abstract utility functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0}}},{"hash":"af1cfb79b3c2d4461d15784b706553c98080e871","isMergeCommit":false,"messageTitle":"Update classes with new Color enum class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":48},"test-code":{"insertions":1,"deletions":1}}},{"hash":"c6481859d17f8d39ab14de72dd20c28107c15a69","isMergeCommit":false,"messageTitle":"Update parse color function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":4}}},{"hash":"f8b093e01f799186bae92ff143f2a8ed5cdd6ae5","isMergeCommit":false,"messageTitle":"Add loadPlayerColor method to storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":11}}},{"hash":"d3c5763ecc8c09726028c212b83093df0d3065f1","isMergeCommit":false,"messageTitle":"Add new prompt messages in TextUI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":3}}},{"hash":"145579e2cfe2c8d42eb4bcdd31a15cf18eaec483","isMergeCommit":false,"messageTitle":"Add basic menu screen to incorporate storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":70,"deletions":5}}},{"hash":"405004cdcbd17a84b09651c91f74991c97b81429","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"06b4dfa6c0483278c474b09fd616ed73c70a299a","isMergeCommit":true,"messageTitle":"Merge pull request #55 from TongZhengHong/branch-fix-storage","messageBody":"Branch fix storage","fileTypesAndContributionMap":{}},{"hash":"368c3e0edc140b481ed9138db0af0cdf952f1de0","isMergeCommit":false,"messageTitle":"Add display prompts to ChessMaster when loading game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":80,"deletions":31}}},{"hash":"df760f8839fd4776b219a1f23fe319a0d0d908a8","isMergeCommit":false,"messageTitle":"Change minor format","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":4}}},{"hash":"5b09eef974fb106ded255114a355f98463a07be9","isMergeCommit":false,"messageTitle":"Add new exception for moving empty piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":52}}},{"hash":"417b80043947aa1788366f6b5381d104a96f22e0","isMergeCommit":false,"messageTitle":"Update MoveCommand to parse move in execute","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":22}}},{"hash":"9210900781e250acccccea531d5ecfa473aa4255","isMergeCommit":false,"messageTitle":"Reset storage file after end of game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":10}}},{"hash":"7795994c9da29cf8bade97a9f4b191a40ae34258","isMergeCommit":false,"messageTitle":"Update new display format of Chess Board","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":25}}},{"hash":"661eb2af274f956d09a7d70368efb9ca9c608ffa","isMergeCommit":false,"messageTitle":"Update Game class with new function implementation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"8fbdcaad36233bd9b10d2cba74ab813643446967","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-beautify-textUI","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"05353d08b67f19829e02157c3d06a406750d7a1c","isMergeCommit":false,"messageTitle":"Minor formatting changes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":20}}},{"hash":"9e1848b1a18fa75c185ad4282c0090a683183356","isMergeCommit":false,"messageTitle":"Minor changes to CPU first move","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":8}}},{"hash":"cebf92a411866dfac8b6986b7fa6067014cb3758","isMergeCommit":false,"messageTitle":"Add ant build config file for jar generation","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":35,"deletions":0}}},{"hash":"488a640bf673fad73526eb4568c244d96eb45241","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":26}}},{"hash":"ee7ab7e5d203d1eecddea51455428492b014d9c0","isMergeCommit":false,"messageTitle":"Add ant build config file for jar generation","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":35,"deletions":0}}},{"hash":"e9aeca72e4b8b494d9e56273a91dbb3436e66141","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":26},"test-code":{"insertions":2,"deletions":5}}},{"hash":"54c3377b719f551241501b8bc182d0751ff6ebd5","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-beautify-textUI\u0027 of https://github.com/TongZhengHong/tp into branch-beautify-textUI","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e9decd346e72260702f9498f0d549ac86cfb2b43","isMergeCommit":true,"messageTitle":"Merge pull request #61 from TongZhengHong/branch-beautify-textUI","messageBody":"Branch beautify text UI","fileTypesAndContributionMap":{}},{"hash":"3b77bd3c1503b15c4094d5915d6f0a461e68b01e","isMergeCommit":false,"messageTitle":"Update human promotion text UI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":8}}},{"hash":"2aaa4b500ff41e6df2a114ab896570c7a5b154a2","isMergeCommit":false,"messageTitle":"Add MoveCommand and Player type checking methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":46}}},{"hash":"bfe394e40a9d946eaae91ae87684e529cc947086","isMergeCommit":false,"messageTitle":"Update main control logic to be turn based","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":51,"deletions":30}}},{"hash":"f208755af8b44abd8524f7f4125af7fe6806ed4f","isMergeCommit":true,"messageTitle":"Merge pull request #63 from TongZhengHong/branch-refactor-game","messageBody":"Branch refactor game","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"fd37c963ecab66fd0dc488a16503be88f2854b9c","isMergeCommit":false,"messageTitle":"Remove MoveEmptyPieceException replaced with NullPieceException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":29}}},{"hash":"fc51d27abe2870ddf88e528def55dee6b0b3f435","isMergeCommit":false,"messageTitle":"Pass playerColor into ChessBoard object instead of Game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":28}}},{"hash":"a41b9f74ff067e4652f4074fd001b6814f0972e8","isMergeCommit":false,"messageTitle":"Add assertions where necessary","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":12}}},{"hash":"a3380a5541d4109ccabbd4c1fe2257244adbe3da","isMergeCommit":false,"messageTitle":"Rename chessmaster package to game package","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":3,"deletions":3}}},{"hash":"d7a6f346661aab400170ebe331b3c12a95a9281a","isMergeCommit":false,"messageTitle":"Add new junit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":269,"deletions":0}}}]},{"date":"2023-10-27","commitResults":[{"hash":"17d41bb39c2cf9db61e4bf4a2ff31cb2290f6ca5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into doc-promote","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f853d9e68d745fd78e94e46ad197d7bc51edd465","isMergeCommit":true,"messageTitle":"Merge pull request #85 from ken-ruster/doc-promote","messageBody":"Add documentation for `Parser` and `Command`","fileTypesAndContributionMap":{}},{"hash":"cb268266a25d2a1fe83ac4c8fde6f5a6a9c1b8f7","isMergeCommit":false,"messageTitle":"Developer guide for ChessMaster and Game","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":200,"deletions":3}}},{"hash":"9c14af88cf4e0323e343b2133ff00e4d4bb4e640","isMergeCommit":false,"messageTitle":"Add Documentation for ChessMaster and Game","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":200,"deletions":3}}},{"hash":"67ebaed0ee6dbca50bad9eb67cb9a66af4252b58","isMergeCommit":false,"messageTitle":"Remove unnecessary commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":53}}},{"hash":"c6c6e2c440b93aa70517bce077fa995158214203","isMergeCommit":false,"messageTitle":"Add repo sense @author tags where necessary","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":16}}},{"hash":"9b6e910466d24058de8e3dbb70363e9d89b66ecf","isMergeCommit":false,"messageTitle":"Change @author to @@author","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":38}}}]},{"date":"2023-10-29","commitResults":[{"hash":"30c6f15afd82f040617aa32cf07dd2a7a9aa610a","isMergeCommit":false,"messageTitle":"Update Move isValid method to take ChessBoard as arg","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"a825c4ec8796a233e4378ffbed0cb42b198aeda6","isMergeCommit":false,"messageTitle":"Check move validity in MoveCommand execute()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"7906eb0770108d9177d32669a02a0d70b2af00d8","isMergeCommit":true,"messageTitle":"Merge pull request #88 from TongZhengHong/branch-repo-sense","messageBody":"Update individual code contribution with repo sense @@author tags","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"5ee5c74ccae5d67085749e547ecbb516d0d52446","isMergeCommit":true,"messageTitle":"Merge pull request #91 from ken-ruster/start-help","messageBody":"Add help message at start","fileTypesAndContributionMap":{}},{"hash":"07c42614d1fe2f2408bb4703e5c78b23fef7a39d","isMergeCommit":false,"messageTitle":"Move static ExceptionMessages class to UI package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0},"other":{"insertions":1,"deletions":1}}},{"hash":"3af0fe8cf12d90ee9474692107f38811fce673df","isMergeCommit":true,"messageTitle":"Merge pull request #92 from TongZhengHong/branch-fix-move-validity","messageBody":"Branch fix move validity","fileTypesAndContributionMap":{}},{"hash":"35a7affaf4fff8bc962176a052c9426377845e7e","isMergeCommit":false,"messageTitle":"Add @@author tag for Exception classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}},{"hash":"70dbf1c6ffff949188b42329b8738b2167f6ab1d","isMergeCommit":false,"messageTitle":"Add isPawn method to check pawn object","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0}}},{"hash":"2ff8c015ca0166931a1dc9562be7fafb49bf8e86","isMergeCommit":false,"messageTitle":"Make TextUI non-static \u0026 move showChessBoard()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":97,"deletions":112},"test-code":{"insertions":6,"deletions":2}}},{"hash":"ab72878747032985c724afae1dff382924795e1e","isMergeCommit":false,"messageTitle":"Add TextUI to Command execute method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":7}}},{"hash":"2955134d8a0f503a43ac7b3a5a6d04bf7c795d95","isMergeCommit":false,"messageTitle":"Update showMoveCommand with new representation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":74,"deletions":13}}},{"hash":"d55dd8a502636b0ec5a7e157dcef3da3c297a3b3","isMergeCommit":false,"messageTitle":"Add whitespace around check in checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":27},"other":{"insertions":6,"deletions":0}}},{"hash":"32d148983e0fad987fcad755f9c4e4d333d36183","isMergeCommit":false,"messageTitle":"Update ShowCommand to show prompt first","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"e0936947c897ccb74d2c83e52afc901ee31df9ad","isMergeCommit":false,"messageTitle":"Fix checkstyle in ParserTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"52f68f227988d5f5d0c82bbcd60d01710062acdc","isMergeCommit":false,"messageTitle":"Remove unused import in MoveCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"c25b4df580cfa180e698ff4393e78ab4d31d2a17","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-nonstatic-textui","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"939d169550d1f73aa5ee9be3758cb9067da0ac43","isMergeCommit":true,"messageTitle":"Merge pull request #90 from ken-ruster/no-available-moves-message","messageBody":"Modify getAvailableCoordinatesString()","fileTypesAndContributionMap":{}},{"hash":"04d6400be685eb19bdc605570269fc7f77562da0","isMergeCommit":false,"messageTitle":"Remove print cpu best move","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"c43cff3a57536b8dfa766f255d3340888c6d6b0d","isMergeCommit":false,"messageTitle":"Add print chessboard with previous move","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":10}}},{"hash":"f89f8a612ac188875878075bd5bbe4a2224a703d","isMergeCommit":false,"messageTitle":"Add basic user guide draft template outline","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":170,"deletions":11}}},{"hash":"1400ca2d7fca8637ebd3dca58c772dc75387f2c0","isMergeCommit":true,"messageTitle":"Merge pull request #101 from ken-ruster/ug-commands","messageBody":"Update User Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"dcf78f9901c9034e63845749d585570591eac03a","isMergeCommit":true,"messageTitle":"Merge pull request #104 from TriciaBK/tricia","messageBody":"Add ViewLegendCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"db9f74aa4330e8d29ca11b4808d785a88d4a0def","isMergeCommit":true,"messageTitle":"Merge pull request #112 from TriciaBK/player-color","messageBody":"Implement currentColour in ChessMaster","fileTypesAndContributionMap":{}},{"hash":"8e6bf7e207aca558201c8d2c2d8824cb9e5d9a23","isMergeCommit":false,"messageTitle":"Remove json tag in code blocks in user guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"e7652bbd4429a01488aa2a495c0f8b6fac4ad839","isMergeCommit":false,"messageTitle":"Update parse color method to include empty color check","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":12}}},{"hash":"b53e0da3c0ff85b8312dca47001b02742f5d7214","isMergeCommit":false,"messageTitle":"Update first move player checking","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":30}}},{"hash":"bca88623803ed3214658b5a69b89b7b55d5adca5","isMergeCommit":true,"messageTitle":"Merge pull request #111 from onx001/bugFixLoad","messageBody":"Check for presence of 2 kings when loading board and count number of pieces for both sides","fileTypesAndContributionMap":{}},{"hash":"222220bd6f92465521bc9fd41f9ad1a5ec1ca2f7","isMergeCommit":false,"messageTitle":"Update winning player ui message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":9}}},{"hash":"924a483adc27c704bed3ff9787055548f8df7214","isMergeCommit":false,"messageTitle":"Change minor text ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3}}},{"hash":"751e64a3c7e5647c8ef2de414e3a6321652562fe","isMergeCommit":false,"messageTitle":"Store hasMoved flag for each ChessPiece in text file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":15}}},{"hash":"bf251538a1352aafb68c213fe4412b5400fe66e0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-storage-hasMoved","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b247f11ff249e41c9bec7bed2af9d2085980ccfc","isMergeCommit":false,"messageTitle":"Update parseColor test to throw exception when empty","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":6,"deletions":2}}},{"hash":"9fc8c134bfe7a14c4dabe0ca9438437b8658da81","isMergeCommit":true,"messageTitle":"Merge pull request #115 from onx001/StartBug","messageBody":"Start bug fix","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"f2e82359269df869737f4a384b4961378feea45c","isMergeCommit":true,"messageTitle":"Merge pull request #116 from onx001/Check","messageBody":"Add `isChecked` and `isCheckMated` features","fileTypesAndContributionMap":{}},{"hash":"10847a16e7f77143d6e7977af68c17b625c2bf7d","isMergeCommit":true,"messageTitle":"Merge pull request #149 from onx001/MinimaxAggro","messageBody":"Fix minimax aggro","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"ken-ruster":{"docs":211,"functional-code":313,"test-code":20,"other":1},"antrikshdhand":{"docs":7,"functional-code":121,"test-code":0},"TriciaBK":{"docs":184,"functional-code":425,"test-code":0},"onx001":{"docs":106,"functional-code":759,"test-code":38},"TongZhengHong":{"docs":352,"functional-code":1794,"test-code":278,"other":48}},"authorContributionVariance":{"ken-ruster":8623.499,"antrikshdhand":3206.0898,"TriciaBK":5739.9644,"onx001":6565.1997,"TongZhengHong":112135.51},"authorDisplayNameMap":{"ken-ruster":"CS2113-T18-1 OH K.. WEI","antrikshdhand":"CS2113-T18-1 DHAN..IKSH","TriciaBK":"CS2113-T18-1 TRIC..PING","onx001":"CS2113-T18-1 OU N..IANG","TongZhengHong":"CS2113-T18-1 TONG..HONG"}} +{"authorDailyContributionsMap":{"ken-ruster":[{"date":"2023-10-05","commitResults":[{"hash":"faf542c932dc8c668aff0ec933dabdff06d14b84","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6e59d9b754ad45058c2079c92e49c7e3018eabd4","isMergeCommit":false,"messageTitle":"Add question mark","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"8a501b95c2b2abe506ad139c3c31aebceb2fb205","isMergeCommit":true,"messageTitle":"Merge pull request #1 from ken-ruster/branch-test","messageBody":"Add question mark","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"f1ff0f7411762e6f7165868f47bc046d3c53ef57","isMergeCommit":true,"messageTitle":"Merge pull request #1 from AY2324S1-CS2113-T18-1/master","messageBody":"Merge template commits","fileTypesAndContributionMap":{}},{"hash":"65189450fa76a75657d7196b52644045e1a5cd0b","isMergeCommit":false,"messageTitle":"Add Move class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":0}}},{"hash":"c26acb544fbc894759c3fa25710b2309afbb3112","isMergeCommit":false,"messageTitle":"Add getPieceAtCoor for ChessBoard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"f25704646d91a0357e8feba59d6930ae51fe34f4","isMergeCommit":false,"messageTitle":"Add parseMove to Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":0}}},{"hash":"b6a41564720327fc4a2f4918e8ffab6d85bf61f6","isMergeCommit":true,"messageTitle":"Merge pull request #9 from ken-ruster/master","messageBody":"Add Move, parseMove, getPieceAtCoor","fileTypesAndContributionMap":{}},{"hash":"7bce486c240254f0df114f0b7c98550c07fd87e3","isMergeCommit":false,"messageTitle":"Add exception to handle invalid moves","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":0}}},{"hash":"adf441fe87620d6c32a057bd929bf5649861a7ee","isMergeCommit":false,"messageTitle":"Add placeholder movePiece() function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"36b657b73341f5386dcbddde151d1cd8b417590e","isMergeCommit":false,"messageTitle":"Parser.java: Add ParseCommand function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":10}}},{"hash":"5c3dcaac28b2874d45e7b11eca8bc53914f195dd","isMergeCommit":false,"messageTitle":"Update message for InvalidMoveException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"aad8c9191d3d81e12fc1a3d26a0e90353127740c","isMergeCommit":false,"messageTitle":"Update documentation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":7}}},{"hash":"c01a71e62fea28af6635422189d4179e321ae0dc","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"be3d08b56f3db7bab6e6dd2c0d07610386e5733e","isMergeCommit":true,"messageTitle":"Merge pull request #12 from ken-ruster/master","messageBody":"Add parseCommand","fileTypesAndContributionMap":{}},{"hash":"0733fc344115ccba632803263803c4e51e00ab8f","isMergeCommit":false,"messageTitle":"Update Parser to work with executeMove","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5}}},{"hash":"cc4d6742f26ea5ee50dd98a646bc948f7614dff7","isMergeCommit":true,"messageTitle":"Merge pull request #13 from ken-ruster/master","messageBody":"Update Parser to work with executeMove","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"cc1de14b8dbd21ae323f79c66791d60fba907572","isMergeCommit":true,"messageTitle":"Merge pull request #2 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"2f537195a96090920c3263243b6d72f2571a61e5","isMergeCommit":false,"messageTitle":"Add parsePromote","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":0}}},{"hash":"e8af2c24700f59a9ea4243a776584a100d4e2cdd","isMergeCommit":true,"messageTitle":"Merge pull request #22 from ken-ruster/parse-promote","messageBody":"Add parsePromote","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"1b8f09fa06caa73c93ceaf4bd7325f96e830d188","isMergeCommit":false,"messageTitle":"Optimise parseMove","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":4}}},{"hash":"abb3d1280718214199edb41df98078071f0b9f44","isMergeCommit":false,"messageTitle":"Modify Move to expose only piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":7}}},{"hash":"8c2e65cd475e0074d35b12b4e5b2ad8e99c9d21f","isMergeCommit":true,"messageTitle":"Merge pull request #23 from ken-ruster/parse-promote","messageBody":"Modify Move class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"8bcff2098b9526763e0cc36ec2391aa7d764de7b","isMergeCommit":true,"messageTitle":"Merge pull request #3 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"d17246f0048e71e2293e8174fc5b557e3a5a021a","isMergeCommit":true,"messageTitle":"Merge pull request #4 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"fe5200d7c19a4cd9021b625b6b8ab83bb56a4385","isMergeCommit":false,"messageTitle":"Add promotion function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":111,"deletions":36}}},{"hash":"aee0fdb2217b2711ece98c83d9c3f359cd57cd35","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into promote","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9b929ea7cccd3f42ef18b9938cf55287e7743840","isMergeCommit":true,"messageTitle":"Merge pull request #35 from ken-ruster/promote","messageBody":"Add promote","fileTypesAndContributionMap":{}},{"hash":"130c73447825d8722992d68eb30ae1a6554b72a4","isMergeCommit":true,"messageTitle":"Merge pull request #5 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"10aa63e2dcaaeb83ac98cb5a2c8307f2137ac15c","isMergeCommit":false,"messageTitle":"Refactor to replace ChessTile[][] with ChessBoard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":236,"deletions":165}}},{"hash":"180b17f79b261c4f3e88a68b6e76b2a754973308","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into inputChange","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b3e2b227dc0be3412277f0edd95d51ffe3636940","isMergeCommit":true,"messageTitle":"Merge pull request #41 from ken-ruster/inputChange","messageBody":"Convert ChessTile 2D Array to ChessBoard Objects within getAvailableCoordinates method of ChessPiece objects","fileTypesAndContributionMap":{}},{"hash":"e0234d99755f86ccd0fefd92c524df38f63bb1f5","isMergeCommit":true,"messageTitle":"Merge pull request #6 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"8b8a824082cf7a375a459b10a01ad0afec07369c","isMergeCommit":false,"messageTitle":"Fix bug in executeMove","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"71a9826f5af8b9a526398f92ab08efce1eaf57e1","isMergeCommit":true,"messageTitle":"Merge pull request #43 from ken-ruster/castling-fix","messageBody":"Fix bug from merge","fileTypesAndContributionMap":{}},{"hash":"4c4abc0175d821e56e9ad6ff226c3f6af6d1d02f","isMergeCommit":true,"messageTitle":"Merge pull request #7 from AY2324S1-CS2113-T18-1/master","messageBody":"update","fileTypesAndContributionMap":{}},{"hash":"950cd9421835d5d7cffe4f5ab388778553c5b704","isMergeCommit":false,"messageTitle":"Fix bug causing all moves to evaluate invalid","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":7}}},{"hash":"9719431bb9cc2c798dc3ad1d940641c09262591f","isMergeCommit":false,"messageTitle":"Fix checkStyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":67,"deletions":70}}},{"hash":"c799155550c6b18fe27328d60f294b5d7f5c0c29","isMergeCommit":true,"messageTitle":"Merge pull request #46 from ken-ruster/bugfix","messageBody":"Bugfix","fileTypesAndContributionMap":{}},{"hash":"6d82fdd693fb388a57751b397bbde643d804babd","isMergeCommit":true,"messageTitle":"Merge pull request #8 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"124550cac18d24dbdbc47af118d2a8084dc352bb","isMergeCommit":false,"messageTitle":"Add jUnit test for parsePromote","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":18,"deletions":0}}},{"hash":"74fa224b6e6a52bf56f565b20b8c4b556bb88211","isMergeCommit":false,"messageTitle":"Add assertion","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"cb91b595ac7c796524153f17787277b76c5d83f0","isMergeCommit":true,"messageTitle":"Merge pull request #47 from ken-ruster/jUnit-assert","messageBody":"Add jUnit and assertion","tags":["v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"849a9445c8c9b4f08f86b7be22904a2c213d12e8","isMergeCommit":true,"messageTitle":"Merge pull request #9 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"77d79bf75a86782bfe4b53cbce65a6a3701e382c","isMergeCommit":false,"messageTitle":"Add fn to show available moves for a piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":88,"deletions":5}}},{"hash":"db74989da863f7cc36f7540733676a617b46f37e","isMergeCommit":false,"messageTitle":"Fix checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":3}}},{"hash":"18393a590c44c6cf96e4841a37b6ecf814075c93","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into showAvailableMoves","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"605514ee0b1f6c6fe4f3d6d86732382422b67aba","isMergeCommit":false,"messageTitle":"Address review comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":26}}},{"hash":"39dba37db67348b1e3ab05dbc8803ead13bb7bf8","isMergeCommit":false,"messageTitle":"Fix CheckStyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":4}}},{"hash":"b25ef97f1e84834b6cc62fc1a28977004d91afe2","isMergeCommit":false,"messageTitle":"Fix CI tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"f30bce1d149e5821e72e906029dfc3b1721fe367","isMergeCommit":false,"messageTitle":"Move message displaying available coord","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"b1aa7a9f4c4af98b33eefff39b41c0218fb00e62","isMergeCommit":false,"messageTitle":"Move message displaying available coord","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":4}}},{"hash":"18d3d136b9a0ae86f204d2f9a23efa541765bdf4","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into showAvailableMoves","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5832b80bc3d13ccc24575533b0e4de9785e01170","isMergeCommit":true,"messageTitle":"Merge pull request #68 from ken-ruster/showAvailableMoves","messageBody":"Add function to show available moves","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"4594004f36864b213727d4b6c157c37da6696c36","isMergeCommit":true,"messageTitle":"Merge pull request #10 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"821658aebd0a3c9175df8f5674ac821b3ade7ff0","isMergeCommit":true,"messageTitle":"Merge pull request #79 from onx001/chessmasterai3","messageBody":"Implement board points and fix style checks","fileTypesAndContributionMap":{}},{"hash":"cefe15b6b81f45f76431209d9328384a78ec0008","isMergeCommit":false,"messageTitle":"Enable assertions","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-27","commitResults":[{"hash":"b4aadfb4faa57b329769af55b8fa1b7f5a17ad58","isMergeCommit":false,"messageTitle":"Add documentation for `Parser`","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":75,"deletions":0}}},{"hash":"33087366ca8fb5387e63aa249444b7a66edd28a8","isMergeCommit":false,"messageTitle":"Add class diagram for `Parser` and `Command`","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":60,"deletions":4}}},{"hash":"34d73b3c62929ccff345d978c0db31cc1f5773f5","isMergeCommit":true,"messageTitle":"Merge pull request #87 from TongZhengHong/branch-chessmaster-game-docs","messageBody":"Add documentation for `ChessMaster` and `Game`","fileTypesAndContributionMap":{}},{"hash":"8e3a157320a2d4bbc4c107d6a94ce8ccd06804b2","isMergeCommit":true,"messageTitle":"Merge pull request #86 from TriciaBK/tricia","messageBody":"Add Documentation for Storage ","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"785563562b942d5a764cd9e455208263e1060744","isMergeCommit":false,"messageTitle":"Modify getAvailableCoordinatesString()","messageBody":"Add a custom message for when there are no moves available for the piece chosen\n","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":2}}},{"hash":"d559284193d923c12f32de49b30cb98ff8e2a80d","isMergeCommit":true,"messageTitle":"Merge pull request #11 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"830c708f19d3f5c0367a1d75b685b1ea7df1633f","isMergeCommit":false,"messageTitle":"Fix CheckStyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"6569c8a0cf9d6b33801061fbf7efb8c81b555697","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into no-available-moves-message","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"aba0a9c401a093d478c1cb0e003bf1831cf6279c","isMergeCommit":false,"messageTitle":"Add help message at start of game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0}}},{"hash":"6a570cae9452da871b8528e58c8fb2cb9b960320","isMergeCommit":false,"messageTitle":"Add `moves` to list of commands in help","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}}]},{"date":"2023-10-31","commitResults":[{"hash":"4fc3a9d59d2c8b18fb2ccc534af76c9875732350","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into no-available-moves-message","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"4b2c0d0dd9049296eb88462fb65684b77c5632e5","isMergeCommit":false,"messageTitle":"Fix CI Tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":1}}},{"hash":"3f77fea303733594d649e2e947ca9ea27cf46a74","isMergeCommit":true,"messageTitle":"Merge pull request #98 from TongZhengHong/branch-show-board-with-prev-move","messageBody":"Show board with previous move","fileTypesAndContributionMap":{}},{"hash":"6ff8a8eb367c7d9d02af378e9437bcc6fd664996","isMergeCommit":true,"messageTitle":"Merge pull request #95 from TriciaBK/tricia","messageBody":"Update command strings to fit char constraint","fileTypesAndContributionMap":{}},{"hash":"0229bb2a68782acebb6449cbf8b488aa9072c62e","isMergeCommit":true,"messageTitle":"Merge pull request #100 from TongZhengHong/branch-draft-ug","messageBody":"User guide first draft template","fileTypesAndContributionMap":{}},{"hash":"5cc3981960d2dc85267082dff93348f91f2ad65d","isMergeCommit":true,"messageTitle":"Merge pull request #12 from AY2324S1-CS2113-T18-1/master","messageBody":"Update","fileTypesAndContributionMap":{}},{"hash":"8d91920f33d58713060290c596e042c042b291ab","isMergeCommit":false,"messageTitle":"Update user guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":72,"deletions":24}}},{"hash":"87915a49e9db62c6313abd56897822c5a88a656a","isMergeCommit":false,"messageTitle":"Add guide on end of game","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":0}}},{"hash":"680dfb1f3bd97d1b6e0dca47711237c8f8f99671","isMergeCommit":false,"messageTitle":"Add FAQ","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":1}}},{"hash":"5b9c7ce2b061baaf255293df38fb91953cafa9a5","isMergeCommit":true,"messageTitle":"Merge pull request #102 from onx001/DifficultySave","messageBody":"Add Difficulty and Bugfix","fileTypesAndContributionMap":{}}]}],"antrikshdhand":[{"date":"2023-10-05","commitResults":[{"hash":"b0a61b4e5ecda5db94f4ad8a08c8a11dca11e77b","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"7d48b22f326388f2eca1ddaa4894dac5c51d2485","isMergeCommit":true,"messageTitle":"Merge pull request #5 from antrikshdhand/antriksh-AboutUs","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"c801ea42692d588d4378a889cd284d324c242eea","isMergeCommit":false,"messageTitle":"Add basic Game and Player classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":96,"deletions":40}}},{"hash":"72e15c80654b8b9c589b6910a662a8c367315064","isMergeCommit":true,"messageTitle":"Expand Player and Game classes","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c623d03e5e2e13851592c85ae7f02d81590e5be3","isMergeCommit":false,"messageTitle":"Add template code for CPU","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":14}}},{"hash":"1f6a9e688b08833476b8db4b75441bb397e3382c","isMergeCommit":false,"messageTitle":"Make Player class abstract","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"1ee70b10c3755d2b766943710434006ab8a38d1b","isMergeCommit":true,"messageTitle":"Merge pull request #29 from antrikshdhand/master","messageBody":"Add Game and Player classes","fileTypesAndContributionMap":{}},{"hash":"69699348f9c5b5e995bee0120cc502ba2de3edef","isMergeCommit":false,"messageTitle":"Add randomised-move CPU","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":27}}},{"hash":"4fbf4f7b2a03be0a9a627c687b1d520bc2a6cf4b","isMergeCommit":true,"messageTitle":"Merge pull request #34 from antrikshdhand/master","messageBody":"Add randomised-move CPU","fileTypesAndContributionMap":{}},{"hash":"57557e1600d7cec0f7c99201f5668cff55c3ca3d","isMergeCommit":false,"messageTitle":"Add Javadoc comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":56,"deletions":9}}},{"hash":"e0c748497d6b7dae036fc751f024a702a1acbd09","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f39a2582f107c613370f40b1bce494547625f726","isMergeCommit":false,"messageTitle":"Fix game launcher class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":51}}},{"hash":"a03f6672f37537c87e2d823a682385d33f404366","isMergeCommit":true,"messageTitle":"Merge pull request #38 from antrikshdhand/master","messageBody":"Fix conflict between Game and ChessMaster classes","fileTypesAndContributionMap":{}}]}],"TriciaBK":[{"date":"2023-10-05","commitResults":[{"hash":"fc7c1bd4091ee83c6df0616f710bf7ab3651b856","isMergeCommit":false,"messageTitle":"?????","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"58e114c5917e81e436287764309e5165576cc4aa","isMergeCommit":true,"messageTitle":"Merge pull request #3 from TriciaBK/tricia","messageBody":"?????","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"f0541ec8fa6d99300896d53ff19d40d67c7ab2c4","isMergeCommit":false,"messageTitle":"added temporary method for executeMove method to access","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}},{"hash":"1ca4a431744c9f133d36d60d4808b2b72b3d9fb1","isMergeCommit":false,"messageTitle":"added temporary method for executeMove method to access","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":2}}},{"hash":"760456c7df5d6f6e094e4e65df781b09e632fa9c","isMergeCommit":false,"messageTitle":"Add executeMove method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":5}}},{"hash":"75807ce2a7deb81cb42415befcf264333f2bd42e","isMergeCommit":false,"messageTitle":"Removed move history","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":18}}},{"hash":"ef9786cafa2dc81bb582195af35e46f26008ac72","isMergeCommit":true,"messageTitle":"Merge pull request #11 from TriciaBK/chessboard-state","messageBody":"Chessboard state","fileTypesAndContributionMap":{}},{"hash":"eddf4457de673699da57131e019856e79e27339d","isMergeCommit":false,"messageTitle":"Add exception handling for saving board","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":0}}},{"hash":"b2fac1f5d326c2c39029ac7c3a388557ef3ac9c7","isMergeCommit":false,"messageTitle":"Add exception handling for loading board","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":0}}}]},{"date":"2023-10-17","commitResults":[{"hash":"d26a09bde262783d3a3312df1ac069dd2ef138a6","isMergeCommit":false,"messageTitle":"Add saveBoard and loadBoard methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":111,"deletions":1}}},{"hash":"432e0ca40922330edc0b0bd8e2f530f5c2a45ad3","isMergeCommit":false,"messageTitle":"Add setTile method for loadBoard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5}}},{"hash":"1197ab36e28a828f2ee61300cbbc07018b20b2f8","isMergeCommit":false,"messageTitle":"Update method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}},{"hash":"bd47e5d8ee0916a3164ae5c0c3f4fcf6defc164b","isMergeCommit":false,"messageTitle":"Update Save and Load method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"7ef957bdcd5debc1c7fb7af31a51a8ce8acb76f3","isMergeCommit":true,"messageTitle":"Merge branch \u0027storage\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"43b8f674c63120a95a4365894df2f54ae716833e","isMergeCommit":false,"messageTitle":"Add updatePosition method after move excution","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"adf3af69b9d133a9cd3b18393397d55a0032c64b","isMergeCommit":false,"messageTitle":"Add exception handling in executeMove method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":5}}},{"hash":"3d9ed6eda7e0a1c8e97d40fc2af25d562c8423d2","isMergeCommit":true,"messageTitle":"Merge pull request #24 from TriciaBK/chessboard-state","messageBody":"Update executeMove","fileTypesAndContributionMap":{}},{"hash":"962a3055847617e6ab3689d473755dd44a688e28","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into storage","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bf7f156df16b8da47a8fb666b93670e0186befdc","isMergeCommit":false,"messageTitle":"Fixed checkstyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":27}}},{"hash":"94b32dbefed7b8c9ba74a83454871c957e4e3866","isMergeCommit":true,"messageTitle":"Merge pull request #25 from TriciaBK/storage","messageBody":"Resolved Storage checkstyle violations","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"5a0364a5abe5bb30d994cf2bc70ade619328002b","isMergeCommit":false,"messageTitle":"Add method to check for end game and winning colour","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":55,"deletions":5}}},{"hash":"be8099ab0ada8f58ecbd2c527171d052f1516477","isMergeCommit":true,"messageTitle":"Merge pull request #44 from TriciaBK/tricia","messageBody":"Add method to check for end game and winning colour","fileTypesAndContributionMap":{}},{"hash":"405ae94c37c42748cf1bd5ac27107ffc1ca10e65","isMergeCommit":false,"messageTitle":"Add load method into game class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":6}}},{"hash":"af00691e10775886437e525b1933e910713da92d","isMergeCommit":false,"messageTitle":"Add assertions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0}}},{"hash":"2d29393dfa418b76ac5ffd025468a68dc3298302","isMergeCommit":true,"messageTitle":"Merge pull request #45 from TriciaBK/tricia","messageBody":"Add load method into game class and add assertions","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"7ca4c096e8a554e18a9bf59027a308b16adf5c4b","isMergeCommit":false,"messageTitle":"Added CPUFirstMove if playerColour is black","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":4}}},{"hash":"548e89850c1b79c57bfb5d3ad401356c1ade444a","isMergeCommit":true,"messageTitle":"Merge pull request #58 from TriciaBK/tricia","messageBody":"Added CPUFirstMove if playerColour is black","fileTypesAndContributionMap":{}},{"hash":"dd2257fb6cb082dbaf2175e58c66298bc43a0d71","isMergeCommit":false,"messageTitle":"Update Help Command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":1}}},{"hash":"70e64b55c5b725952af36c259c49a78b98a74358","isMergeCommit":false,"messageTitle":"Add RulesCommand and update HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":5}}},{"hash":"5cb6a76ebc89bfc88f68ec924f2dbf762535d17e","isMergeCommit":true,"messageTitle":"Merge pull request #59 from TriciaBK/tricia","messageBody":"Add RulesCommand and update HelpCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"1d15c2b26c03f1726de6f01947d026cccbab1160","isMergeCommit":false,"messageTitle":"Add ShowCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":5}}},{"hash":"06483415b35f057262101d7b05a6cc74d8ff8e4d","isMergeCommit":false,"messageTitle":"Fixed checkstlye","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":3}}},{"hash":"36a59b41f4c7b7bf9daeba45d7dcebfa10bddfd0","isMergeCommit":true,"messageTitle":"Merge pull request #65 from TriciaBK/tricia","messageBody":"Add ShowCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"d9d54711b5e6c6b7a46fb05f8c3731778683bea4","isMergeCommit":true,"messageTitle":"Merge pull request #84 from TongZhengHong/branch-junit-assert","messageBody":"Branch junit assert","fileTypesAndContributionMap":{}},{"hash":"7ee4c2cbc63b522c470538c1913a7d02cc382ef4","isMergeCommit":false,"messageTitle":"Update Developer Guide for storage class","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":38,"deletions":6}}},{"hash":"55728cacf7bc7be03eaaf762cbd0dcd6be2ac7e9","isMergeCommit":false,"messageTitle":"Update Developer Guide for storage class","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":152,"deletions":28}}},{"hash":"1bb9026a886788acbf115db4ff7b72717514a5cb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into tricia","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"61cc6492f4f3ca4f0c9652ef3d68bd8abd0ca2a2","isMergeCommit":false,"messageTitle":"Addressed reviewer comments","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"e9a257881b0fb6d741d6ce2dd310d6857908d22d","isMergeCommit":true,"messageTitle":"Merge branch \u0027tricia\u0027 of https://github.com/TriciaBK/tp into tricia","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"116aa70f1d31987b9ed33337655b72d763a18219","isMergeCommit":false,"messageTitle":"Update command string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":11}}},{"hash":"9b2c17f8f9a8801f00d1ebe88c75ca03196f3dab","isMergeCommit":false,"messageTitle":"Update execute to show board after string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}}]},{"date":"2023-11-01","commitResults":[{"hash":"e94e7187e2ba513ad0518efdf927f3c97e32ec70","isMergeCommit":false,"messageTitle":"edit ShowCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":2}}},{"hash":"964bcea9a14c78ed45f173a49b7f23e724db1ded","isMergeCommit":true,"messageTitle":"Resolved conflict","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"35716a17905f60ad3359017de5ea26861cacade1","isMergeCommit":false,"messageTitle":"Moved storage uml and png into diagram and image folder","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":4},"docs":{"insertions":3,"deletions":2}}},{"hash":"9d514da9798a0875f5c16f89463e86b5c0b43c9d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":16}}},{"hash":"ebb46ecae0cc9304fa2598857020e81c35744fd7","isMergeCommit":false,"messageTitle":"Update UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":16,"deletions":8}}},{"hash":"987ae2e15f927e277cc369d0b1e42f77e41dd9b8","isMergeCommit":false,"messageTitle":"Add ViewLegendCommand and update relevant classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":55,"deletions":21}}},{"hash":"8aab2ebc4c8f660ab1c80234e5e1865380d6de67","isMergeCommit":false,"messageTitle":"Fix checkstyle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":17}}},{"hash":"6ef26e9b8969914a48c5144b18f2e303d41289b4","isMergeCommit":false,"messageTitle":"Add storing and loading of currentPlayer","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":5}}},{"hash":"5764c5b12d20c38431e2e7c60aacccc25c02747d","isMergeCommit":false,"messageTitle":"Update ViewLegendCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":12}}},{"hash":"5ed0f5902e90c2741fc00a07b15c0192d77080c7","isMergeCommit":false,"messageTitle":"Update and rename LegendCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":38}}},{"hash":"3c73eacdf8f8b1fc88fbf1eb2a608a1b564b4896","isMergeCommit":false,"messageTitle":"Update Rules to use exact pieces representation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":7}}},{"hash":"509521f4ee843af5da5d446ced79c0e64d949f9b","isMergeCommit":false,"messageTitle":"Update Rules string","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"ac05f9ab44060ede7f5171c0b67873ea290783dc","isMergeCommit":false,"messageTitle":"Add tracking of current player colour","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":17}}},{"hash":"40fe47e42db430d93a0d1f5caa305f9d3a61d0a2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into player-color","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ee83ae30acd3dc83c614e71685ff334cddccedd3","isMergeCommit":false,"messageTitle":"Fixed checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":4}}}]},{"date":"2023-11-03","commitResults":[{"hash":"4094e74bfbe1ea20d3e48fe1cefcdf95032420ba","isMergeCommit":false,"messageTitle":"Exception handling in loadCurrentcolor","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":15}}}]}],"onx001":[{"date":"2023-10-05","commitResults":[{"hash":"3f292064f69048663493770d480744c23b56b6c4","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"5fa1cf229e9d7354ebd4e848ca46411c10ecbd5d","isMergeCommit":true,"messageTitle":"Merge pull request #2 from onx001/onx-AboutUs","messageBody":"Update README.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-11","commitResults":[{"hash":"67b268ef9145aba4ebf24e7d07d328c13b18ed03","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/onx-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"8753fbaa6e312c71a7e121ce566ee779e2a032a7","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"e2d445f2146c5512f3fbe96952c356004d7679b8","isMergeCommit":false,"messageTitle":"Display valid moves","messageBody":"Implementation of valid moves in progress.\n\nLet\u0027s have a function to display valid moves.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":78,"deletions":13}}},{"hash":"dfe81161128ae9c8510d3facc98671f4e24b04f5","isMergeCommit":true,"messageTitle":"Merge pull request #14 from onx001/ValidMoveDisplay","messageBody":"Display valid moves","fileTypesAndContributionMap":{}},{"hash":"c71ad2eaad3f4461ad84502c91a3530b5e325503","isMergeCommit":false,"messageTitle":"Update ChessPiece.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":53,"deletions":1}}},{"hash":"8dcb170f321be50a71ff77c18bcf80de9138253a","isMergeCommit":true,"messageTitle":"Merge pull request #15 from onx001/ValidMoveDisplay","messageBody":"Update ChessPiece.java","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"b0b7f5e2fdb988cbe187c8ce83fd7849263540fb","isMergeCommit":false,"messageTitle":"Implement Move Validation","messageBody":"Knowing whether a move is valid is important for gameplay, especially for future implementations of solving algorithms.\n\nLet\u0027s implement a generic available move and validity checker as well as basic UI additions for debugging.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":120,"deletions":51}}},{"hash":"7dcec1be03acca1a7f2c1d1c1f78d9b737c847eb","isMergeCommit":true,"messageTitle":"Merge pull request #17 from onx001/ValidMove","messageBody":"Implement Move Validation","fileTypesAndContributionMap":{}},{"hash":"d3893b200ef00ed734b42572a0f273fcf8919bb7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into storage","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"183d7f5d6905d378d6020cd098c1d048b32fb058","isMergeCommit":true,"messageTitle":"Merge pull request #16 from TriciaBK/storage","messageBody":"Storage","fileTypesAndContributionMap":{}},{"hash":"3d3ab4435289b7652113feb39f5e5330e0e77859","isMergeCommit":false,"messageTitle":"Edit JUnit test and add assert statement","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":0}}},{"hash":"69452968a4da01aeb4af72ca6a920b6a93bf11b7","isMergeCommit":true,"messageTitle":"Merge pull request #18 from onx001/JUnitAssert","messageBody":"Edit JUnit test and add assert statement","fileTypesAndContributionMap":{}},{"hash":"fd0cd7c36fa63644a017cbb77f06c9604a2be3b1","isMergeCommit":false,"messageTitle":"Fix coding standard for gradle style checks","messageBody":"Let\u0027s standardise coding styles for easier management across different programmers\n","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":34}}},{"hash":"aa2fb919ec3a346f4248ee74c8df431892942e57","isMergeCommit":true,"messageTitle":"Merge pull request #19 from onx001/Style-Fix-1","messageBody":"Fix coding standard for gradle style checks","fileTypesAndContributionMap":{}},{"hash":"d5b4508a9b9a8818e88eb0787e3e404d3429ba25","isMergeCommit":false,"messageTitle":"Add function for colour change","messageBody":"Swapping board axii every turn change is troublesome and resource-wasteful.\n\nLet\u0027s add valid function checking depending on board colour and orientation.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":2}}},{"hash":"bf4d6fc7abcfa8fec49b7a19a7b9991320c971f6","isMergeCommit":true,"messageTitle":"Merge pull request #20 from onx001/AddBlackPawnCheck","messageBody":"Add function for colour change","fileTypesAndContributionMap":{}},{"hash":"3dd93d8e677e892818307cb61a1a5105737b53e6","isMergeCommit":true,"messageTitle":"Merge pull request #21 from onx001/JUnitTest-1","messageBody":"Update EXPECTED.TXT","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"e1640df62e18fdbe1d3de90c17c1e0f21291953d","isMergeCommit":false,"messageTitle":"Implement Flatten Coordinate","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":0}}},{"hash":"7359a5d798ba0583174408e8b800f299d2b13377","isMergeCommit":true,"messageTitle":"Merge pull request #30 from onx001/flatten-coord","messageBody":"Flatten coord","fileTypesAndContributionMap":{}},{"hash":"9d23107cff35717d80ae6f52dfe1c333392cca88","isMergeCommit":false,"messageTitle":"Abstract Command Class","messageBody":"Having the parser handle all inputs results in messy and convoluted class files.\n\nLet\u0027s abstract out the command class to be handled separately.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":98,"deletions":6}}},{"hash":"f03e1b317732d8279bd6911d7b923d7f61858b72","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into AbstractCommandClass","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cc9aaecfd81fead5ecd23f0c2b0f9148fc3012fc","isMergeCommit":true,"messageTitle":"Merge pull request #37 from onx001/AbstractCommandClass","messageBody":"Abstract Command Class","fileTypesAndContributionMap":{}},{"hash":"0bc26ac88df85e06f0a3536103d65328eefcad15","isMergeCommit":false,"messageTitle":"Integrate command classes into game class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":12}}},{"hash":"231125b6a729e8416852c2942e88be3798eb5035","isMergeCommit":true,"messageTitle":"Merge pull request #39 from onx001/integratecommandgame","messageBody":"Integrate command classes into game class","fileTypesAndContributionMap":{}},{"hash":"3f2c7175536a406dd46bdbd29af467ff16c4e8cc","isMergeCommit":false,"messageTitle":"Add Castling Function","messageBody":"Castling is an important move in chess. Let\u0027s add the ability to do so.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":0}}},{"hash":"e23635bcc1abf7119eb3cb555194f461f9219a72","isMergeCommit":true,"messageTitle":"Merge pull request #40 from onx001/AddCastling","messageBody":"Add Castling Function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-21","commitResults":[{"hash":"47aec5c69ae9b3fe1402b7cfcfd23af951fb64a6","isMergeCommit":false,"messageTitle":"Abstract Command Exceptions","messageBody":"Abstract exception handling outside of command objects\n","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":6}}},{"hash":"7a8f63944552e64dbc8a4a644d2a2e36ae384b49","isMergeCommit":true,"messageTitle":"Merge pull request #49 from onx001/AbstractCommand","messageBody":"Abstract Command Exceptions","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"1c21298c9483f64cf3fd104245eecdcac9dbce5c","isMergeCommit":false,"messageTitle":"Add Point System","messageBody":"Point systems are important for chess pieces in the minimax algorithm. Let\u0027s assign points to chess pieces for later implementation.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":0},"test-code":{"insertions":21,"deletions":0}}},{"hash":"60126b4b0adcba8fdd28357d746e3997ea06aae2","isMergeCommit":true,"messageTitle":"Merge pull request #60 from onx001/points","messageBody":"Add Point System","fileTypesAndContributionMap":{}},{"hash":"788919bf75b60cca636a21110d84defbb20a0548","isMergeCommit":false,"messageTitle":"Add Minimax Function","messageBody":"Add basic minimax function for AI.\n\nTo-dos include returning a move and adding alpha-beta pruning, as well as difficulty selection.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":157,"deletions":0}}},{"hash":"ccba7cd34bf2a4fe3174226eff5b8f924460b603","isMergeCommit":true,"messageTitle":"Merge pull request #62 from onx001/minimax1","messageBody":"Add Minimax Function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"e29e6176dd302de0e4d938ea5b1f2d44b46e4145","isMergeCommit":false,"messageTitle":"Add move to minimax","messageBody":"Todo: Fix move changing error\n","fileTypesAndContributionMap":{"functional-code":{"insertions":94,"deletions":14}}},{"hash":"524828778d07bebd7681fe5b06c577527cd06687","isMergeCommit":true,"messageTitle":"Merge pull request #66 from onx001/move-minimax","messageBody":"Add move to minimax","fileTypesAndContributionMap":{}},{"hash":"84c39b46fc27e851c5c8ea01dfdcaa9d6112bcbd","isMergeCommit":false,"messageTitle":"Finish basic chessmaster logic","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"e05577a9d2517463c37dd95e8d6204d293e98537","isMergeCommit":true,"messageTitle":"Merge pull request #67 from onx001/chessmasterai1","messageBody":"Finish basic chessmaster logic","fileTypesAndContributionMap":{}},{"hash":"d3240ce55eecf45e23be9f8728e823f0e11f223a","isMergeCommit":false,"messageTitle":"Score Bug Hunting 1","messageBody":"Scores are not updating properly. Am in the process of finding the bug\n","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":7}}},{"hash":"ffa80a73b9f451294433b0196bb97ceb4ee0640f","isMergeCommit":true,"messageTitle":"Merge pull request #69 from onx001/chessmasterai1","messageBody":"Score Bug Hunting 1","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"bdf516f0afbbf54b5e57fa5b2056c28608aa7e19","isMergeCommit":false,"messageTitle":"SolveBugDiffPiece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":29}}},{"hash":"e5827f2a4239e43d0d50ad21e1f57b722c254867","isMergeCommit":true,"messageTitle":"Merge pull request #70 from onx001/chessmasterai1","messageBody":"SolveBugDiffPiece","fileTypesAndContributionMap":{}},{"hash":"fc7f3068828f8068002a709bf9d332ba2b36f085","isMergeCommit":false,"messageTitle":"Fix bug with cannibal code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":14}}},{"hash":"0771cd45a2d7e6a0253cf6f56fdfa7c847796d4b","isMergeCommit":true,"messageTitle":"Merge pull request #71 from onx001/chessmasterai1","messageBody":"Fix bug with cannibal code","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"ec076a39d09139babadbad8aa6ff0b5c4c8c0554","isMergeCommit":false,"messageTitle":"Implement board points and fix style checks","messageBody":"Also added a few comments for the algorithm\n\nTodo: Add comprehensive comments and testing\n","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":0}}},{"hash":"6da70024882468322789a89ae5734caa87c93b76","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into chessmasterai3","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"946c63e2c4467721d775f59d8e5ca6f47bf2cf4b","isMergeCommit":false,"messageTitle":"Resolve merge conflicts","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"09c58d80de779b1748c7e9358f5084395896a2f6","isMergeCommit":false,"messageTitle":"Add board weights","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":5}}},{"hash":"585a4fe97f4b4868b50d7644d5e636f1afbb534b","isMergeCommit":false,"messageTitle":"fix merges and update ui tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":17},"test-code":{"insertions":1,"deletions":1}}},{"hash":"29f3cf4eb8133dff60b85c7a320b78e57b95eb41","isMergeCommit":false,"messageTitle":"fix checkstyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"8a7066df090d46fd362d8fc25eb96441314d51a8","isMergeCommit":false,"messageTitle":"Add more description","messageBody":"Javadocs and comments are important for readability and cross-developer coordination. Let\u0027s add more.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":8}}},{"hash":"e78e1198480b5d5a30c581a72e859295bd836e90","isMergeCommit":false,"messageTitle":"Add v1 requirements to developer guide","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0},"docs":{"insertions":10,"deletions":0}}},{"hash":"7145ccccc6bf36fceff4f05f8deb736ff273d94d","isMergeCommit":false,"messageTitle":"Minimax fine tuning","messageBody":"Fine tuned minimax algorithm and updated developer guide\n","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4},"docs":{"insertions":6,"deletions":0}}},{"hash":"6bbb9a0c2ec11c08e53e511ffec62f6363403d99","isMergeCommit":true,"messageTitle":"Merge pull request #83 from ken-ruster/enable-Assert","messageBody":"Enable assert in gradle","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"af3aa0f88314fca926bdab1f867022a18746bccf","isMergeCommit":true,"messageTitle":"Merge pull request #94 from TongZhengHong/branch-nonstatic-textui","messageBody":"Make `TextUI` methods non-static","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"a94bbd6891733d423ab9986221732d9341a850d6","isMergeCommit":false,"messageTitle":"Add Difficulty and Bugfix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":114,"deletions":12},"docs":{"insertions":84,"deletions":0}}},{"hash":"47c5a32927ba0b7fc92202e58fa255c21b93a270","isMergeCommit":false,"messageTitle":"Update UML","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":4}}}]},{"date":"2023-11-02","commitResults":[{"hash":"fd6419a97c5723dc4a0b2017956ecb09e2c0a873","isMergeCommit":true,"messageTitle":"Merge pull request #103 from onx001/DifficultySave","messageBody":"Update MiniMax UML Sequence Diagram","tags":["v2.0"],"fileTypesAndContributionMap":{}},{"hash":"42ffd0f99fbca73257716acda02c83cc7b5ec675","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":4}}},{"hash":"ec1f0f818638260f70d6df5fc8ee7a33401b4289","isMergeCommit":false,"messageTitle":"Update PUML1","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":5}}},{"hash":"55c1feca4bea8fc38aa1662984b762b8c1ff3d0e","isMergeCommit":false,"messageTitle":"Update PUML2","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"d190c4157a8d9db8ef5eee78dc95d4dbf8e109b8","isMergeCommit":false,"messageTitle":"Fix bug for savefile manipulation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":0},"docs":{"insertions":11,"deletions":6}}}]},{"date":"2023-11-03","commitResults":[{"hash":"3f5ec119366ea3c7e4170abd160cb6b03a673e6a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into bugFixLoad","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9f7a1daa120f26057cfa2045f42d0496565b79b8","isMergeCommit":false,"messageTitle":"PR Review Fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":37}}},{"hash":"cdf3ef8d282e0b2cd1d286a056887f9d657dc829","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into bugFixLoad","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2a3bfeb06fa1a245208ec04bdaf2a84341e4bcb8","isMergeCommit":true,"messageTitle":"Merge pull request #114 from TongZhengHong/branch-storage-hasMoved","messageBody":"Store `hasMoved` flag for each ChessPiece","fileTypesAndContributionMap":{}},{"hash":"0401b9ef9bd5a298e3650fe166ad380ff7e23615","isMergeCommit":false,"messageTitle":"Fix Startcolor bug and add minimax test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0},"test-code":{"insertions":17,"deletions":0}}},{"hash":"f87fe025a37c31520e4c753e1144557236fb4dea","isMergeCommit":false,"messageTitle":"Fix stylecheck errors","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"853f43af018aad46f40aa4c9b6e0ca5d21673c97","isMergeCommit":false,"messageTitle":"Update test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"08f1efd01c936c4bcb77e288182c15dd42cb78a7","isMergeCommit":false,"messageTitle":"Update difficulty loading bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"0b8cf2d2817f4d1a80732be6343c1023e8beff66","isMergeCommit":false,"messageTitle":"Add check functionality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":0}}}]},{"date":"2023-11-04","commitResults":[{"hash":"70b700349f3404e942cd96f28a39542295845d75","isMergeCommit":false,"messageTitle":"Fix minimax aggro","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"e0159f0b9fb249ca72b0475f168fba3494ca89e6","isMergeCommit":false,"messageTitle":"Update MiniMax.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"80e109a0fae1bc93543d9580957a0b4f24fb29e3","isMergeCommit":true,"messageTitle":"Merge pull request #152 from TongZhengHong/fix-ug-formatting","messageBody":"Fix User Guide formatting","fileTypesAndContributionMap":{}},{"hash":"f17486a8b86942d94f3b4122b8f42805c1c7f3fd","isMergeCommit":true,"messageTitle":"Merge pull request #151 from TongZhengHong/fix-wrong-losing-color","messageBody":"Fix wrong color when player loses","fileTypesAndContributionMap":{}},{"hash":"dc3668c5adb118a60d9bbb69d5dca0aff57a6489","isMergeCommit":true,"messageTitle":"Merge pull request #150 from TongZhengHong/fix-moves-command","messageBody":"Fix empty payload in moves command","fileTypesAndContributionMap":{}}]}],"TongZhengHong":[{"date":"2023-10-05","commitResults":[{"hash":"62922ff6fccb29e15f6a330af40a4242b1addf1c","isMergeCommit":false,"messageTitle":"Close scanner","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"2b99e2930c4d2001569261848c570906d5a7fdfa","isMergeCommit":true,"messageTitle":"Merge pull request #4 from TongZhengHong/ZhengHong","messageBody":"Close scanner","fileTypesAndContributionMap":{}}]},{"date":"2023-10-08","commitResults":[{"hash":"c839a08a725946522e2ac0485e7c2fdf3267a493","isMergeCommit":false,"messageTitle":"Remove questions marks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"f5030d7118f9839cf6f7166b7f7fa8631d6bb98d","isMergeCommit":true,"messageTitle":"Merge pull request #6 from TongZhengHong/fix_cd_test","messageBody":"Remove questions marks","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"65df1cb11da47e7062fdfcad883dfc1aa3ad03a4","isMergeCommit":false,"messageTitle":"Change Duke to ChessMaster","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-15","commitResults":[{"hash":"6abb6778d5f773debb94bb877b519d9948c5464d","isMergeCommit":false,"messageTitle":"Basic skeleton classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":109,"deletions":5}}},{"hash":"c4f69a258ac8c205eef9450c9a6e7f18ba445e24","isMergeCommit":false,"messageTitle":"Change package board to package game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":74,"deletions":34}}},{"hash":"7f57dba052fa9a6e7d53ad264a6f46479d66634f","isMergeCommit":false,"messageTitle":"Add row, col and color to chessPieces","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":97,"deletions":9}}},{"hash":"65ae9d850d9aba82c149050ee4caf45918f4d25c","isMergeCommit":false,"messageTitle":"Update utility classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":8}}},{"hash":"29d972ea154a415ba986a02be82b5a4b67fe67a3","isMergeCommit":false,"messageTitle":"Change chess pieces from unicode to letter","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":13}}},{"hash":"264f8cb40e5caca637d71b091d4fdcc88923f99d","isMergeCommit":false,"messageTitle":"Update printing code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":24}}},{"hash":"df10c20c4ad72b22b262a879ebaaf5ff91f1962c","isMergeCommit":false,"messageTitle":"Remove key string and standardise color","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":34}}},{"hash":"a47b7be89bf74c89a7aaa0ef21170a27b87ee748","isMergeCommit":false,"messageTitle":"Update chess piece color initialisation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":17}}},{"hash":"75a416c5acfbe1ad67323668dac625a535b0be8a","isMergeCommit":false,"messageTitle":"Create basic exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":0}}},{"hash":"ae6ad89bcd9c3f3db05d2cccc9641e839b1954db","isMergeCommit":false,"messageTitle":"Create Coordinate class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":79,"deletions":0}}},{"hash":"dd431c7ff48227541dd9a409b77e093ef28e5a1d","isMergeCommit":false,"messageTitle":"Add getAvailableCoordinate for each chess piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":204,"deletions":4}}},{"hash":"1565b161990f065ab146cd9b0d607171b4b4a846","isMergeCommit":false,"messageTitle":"Minor changes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":5}}},{"hash":"ae54b6e50ee89ea5bd9516ee8745948bbf9cdc15","isMergeCommit":false,"messageTitle":"Update printChessBoard to show coordinate beside","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":3}}}]},{"date":"2023-10-16","commitResults":[{"hash":"049349fd79bcd94348ebdc4ed225b4223ec9beab","isMergeCommit":false,"messageTitle":"Add javadoc comments for important methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":2}}},{"hash":"a89e57499a273dffb13562c97b38aa1ff7de1cd0","isMergeCommit":false,"messageTitle":"Update checkstyle draft","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":85,"deletions":73}}},{"hash":"df797156621c80d93c4647ca00daa74290a42db7","isMergeCommit":false,"messageTitle":"Address checkstyles","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":24}}},{"hash":"c1cad31c65a0396670d913dee75b41918f2f7bdb","isMergeCommit":false,"messageTitle":"Fix IO redirection test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":21},"other":{"insertions":8,"deletions":2}}},{"hash":"88ba9a509231ff35aa0bdd960f330719e8b03182","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":19}}},{"hash":"ea5ecbfa6267d890a8aab3ae4e3beb8d2a0515c3","isMergeCommit":true,"messageTitle":"Merge pull request #8 from TongZhengHong/branch-setup-template","messageBody":"Branch setup template","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"c78ff2c464137518d661559179236062e0b33a33","isMergeCommit":false,"messageTitle":"Add ChessMasterException parent exception class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":5}}},{"hash":"a925d01c5ea210767e562f71f5fc10fed0036d3f","isMergeCommit":false,"messageTitle":"Create NullPieceException for empty piece at tile retrieval","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":3}}},{"hash":"fe912e66c55c2d129616ec0ccb0e5f4196a7fa46","isMergeCommit":false,"messageTitle":"Remove redundant MoveValidator class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":14}}},{"hash":"3c2e74665a7c6300f390ff3481c6243349179843","isMergeCommit":false,"messageTitle":"Add/Update utility access function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":29}}},{"hash":"59ebda2d24dbc3be6cfc1504988b92f86b2e35cd","isMergeCommit":false,"messageTitle":"Fix parseAlgebraicCoor method bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e99af55f311bf0441ee59cb852db6f984098c525","isMergeCommit":false,"messageTitle":"Implement main chess game engine","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":33}}},{"hash":"68f90d785ce97bb364e92287d8aa3b27b8418781","isMergeCommit":false,"messageTitle":"Clean up code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"7a91674b6218114e072cb688bf929bf358e1c995","isMergeCommit":false,"messageTitle":"Fix CI tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":52}}},{"hash":"595ce058d9f7bdd7ccb74c684a732d9e7147b220","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-setup-chessmaster-engine","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"52218d65a20ae4e67ab80a87a4c0d465b9185443","isMergeCommit":false,"messageTitle":"Test CI gradle build","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":4}}},{"hash":"78565daefec3130476e01ed3f7a53d44b41bdd4a","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-setup-chessmaster-engine\u0027 of https://github.com/TongZhengHong/tp into branch-setup-chessmaster-engine","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"bf12a91560598d566b3de5f872e60f2100c4f5fa","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5}}},{"hash":"8fb02e14aae84b7dba8f2d5fa5b6c08dbd92fae3","isMergeCommit":true,"messageTitle":"Merge pull request #26 from TongZhengHong/branch-setup-chessmaster-engine","messageBody":"Branch setup chessmaster engine","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"324bfb986eae77c3b4320681e737853fe54f86cc","isMergeCommit":false,"messageTitle":"Add random seed to CPU class for predictable moves","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3}}},{"hash":"02382a331c6ae7955bc9b8638a79e7a2e9524ec3","isMergeCommit":false,"messageTitle":"Disable loading chessboard from file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":10}}},{"hash":"49ac9a8ef5dac96d765e666ac3568955bd0a97b6","isMergeCommit":false,"messageTitle":"Remove unnecessary imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":8}}},{"hash":"684d03d43560c18eb09ac0741feba9440d747c82","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":95,"deletions":76}}}]},{"date":"2023-10-21","commitResults":[{"hash":"9206bedfacec06759286c5583eddd93460a83211","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"149c72293e41b61c832dccdefe2b4124bf349a88","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7bc96700214cbc3f3ab9e639c47e55e8c6e48200","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-random-seed\u0027 of https://github.com/TongZhengHong/tp into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"820dd8faab666fa676edb155ab3718e0fefc38fa","isMergeCommit":false,"messageTitle":"Disable logo display","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":14}}},{"hash":"2f50638243d2749ddb5e9ec730c4736334d65b73","isMergeCommit":false,"messageTitle":"Fix abort function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":14}}},{"hash":"99d7bc00cdab2ab7e4a8c2c18d3758f4c14ad2c9","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-random-seed\u0027 of https://github.com/TongZhengHong/tp into branch-random-seed","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9461a089c5cc50fa80e4364aab7ab8e78d58f48d","isMergeCommit":true,"messageTitle":"Merge pull request #48 from TongZhengHong/branch-random-seed","messageBody":"Add random seed to CPU class for predictable moves","fileTypesAndContributionMap":{}}]},{"date":"2023-10-22","commitResults":[{"hash":"ab98dd0d4e1f1e039e592fc724411497641373b8","isMergeCommit":false,"messageTitle":"Add CommandResult to store result of command execution","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":0}}},{"hash":"cb66ab4f5ffc05ae44f71298f88e293a68d9dc28","isMergeCommit":false,"messageTitle":"Add new exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":0}}},{"hash":"76a3ad44c9f47aebd2e353c063376a2897f70d35","isMergeCommit":false,"messageTitle":"Remove getMove and update commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":43,"deletions":56}}},{"hash":"bd0030634aae5a1a53832adad552fe4ff2ca00d0","isMergeCommit":false,"messageTitle":"Remove castling flags and add new utility methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":42}}},{"hash":"ca42df96c7d0a5d408886f4a23c4ef633cbcba0f","isMergeCommit":false,"messageTitle":"Clean up getAvailableCoor methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":112,"deletions":208}}},{"hash":"16904a75ccc4eaccbcf87f3446528d3b4ff0b1fa","isMergeCommit":false,"messageTitle":"Add captured and promotion checking when updating ChessTile","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":3}}},{"hash":"66041493be64a3bfeef58db574c54128dd9c4351","isMergeCommit":false,"messageTitle":"Add more utility methods in Coordinate and TextUI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":6}}},{"hash":"c6ff0391eeddc01d7fa84a44b2c9e5f73fdce71d","isMergeCommit":false,"messageTitle":"Update castling checking code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":9}}},{"hash":"f44e4d347f39ab93a7146787c671ec3462ab0787","isMergeCommit":false,"messageTitle":"Abstract methods from Player class to ChessMaster","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":120}}},{"hash":"681ba2dacf170b4f3b1c931547396ab58d88933b","isMergeCommit":false,"messageTitle":"Update main control flow in Game class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":218,"deletions":177}}},{"hash":"ec03db5e0cfb6dc0662257cc8506441cbc55affa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of tp into branch-more-oop","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b542a666ee82943b60342bf88d0622175ac10c11","isMergeCommit":false,"messageTitle":"Minor fix to storage to pass CI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"0a125a950de7455328a54205caa3c8995c2ca376","isMergeCommit":true,"messageTitle":"Merge pull request #53 from TongZhengHong/branch-more-oop","messageBody":"Branch more OOP","fileTypesAndContributionMap":{}},{"hash":"3bccc222482f5aaf807551620367b77d298b8682","isMergeCommit":false,"messageTitle":"Add createFile method before loading and saving","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":63,"deletions":58}}},{"hash":"0d1d6d2cc6bc3a457775b7dc10321bde6590452e","isMergeCommit":false,"messageTitle":"Add Color enum \u0026 javadoc to color utility methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":85,"deletions":25}}},{"hash":"8e97434da7c932e0b9175ef5f527967daf08b16e","isMergeCommit":false,"messageTitle":"Update ChessPiece classes to use Color enum","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":15}}},{"hash":"8722a95c98a28cf93fe73eba0a0f70330cd1415f","isMergeCommit":false,"messageTitle":"Update Player classes to use Color enum","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":6}}},{"hash":"28e2bfc05da8e6311e33bae03b98040cbadd83c0","isMergeCommit":false,"messageTitle":"Update remaining classes to use Color enum","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":38},"test-code":{"insertions":2,"deletions":1}}},{"hash":"1cb5d04a4441175f6089d232312c0391c9f8e0ee","isMergeCommit":true,"messageTitle":"Merge pull request #54 from TongZhengHong/branch-standardise-color","messageBody":"Branch standardise color","fileTypesAndContributionMap":{}},{"hash":"f72a760331a1b8add5ddbeda4dc93f056440619d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-fix-storage","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"ad1a4fbb5ab765ccfbb22144569c39dcf0f6cad0","isMergeCommit":false,"messageTitle":"Create Color enum and abstract utility functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":0}}},{"hash":"af1cfb79b3c2d4461d15784b706553c98080e871","isMergeCommit":false,"messageTitle":"Update classes with new Color enum class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":48},"test-code":{"insertions":1,"deletions":1}}},{"hash":"c6481859d17f8d39ab14de72dd20c28107c15a69","isMergeCommit":false,"messageTitle":"Update parse color function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":4}}},{"hash":"f8b093e01f799186bae92ff143f2a8ed5cdd6ae5","isMergeCommit":false,"messageTitle":"Add loadPlayerColor method to storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":11}}},{"hash":"d3c5763ecc8c09726028c212b83093df0d3065f1","isMergeCommit":false,"messageTitle":"Add new prompt messages in TextUI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":3}}},{"hash":"145579e2cfe2c8d42eb4bcdd31a15cf18eaec483","isMergeCommit":false,"messageTitle":"Add basic menu screen to incorporate storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":70,"deletions":5}}},{"hash":"405004cdcbd17a84b09651c91f74991c97b81429","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"06b4dfa6c0483278c474b09fd616ed73c70a299a","isMergeCommit":true,"messageTitle":"Merge pull request #55 from TongZhengHong/branch-fix-storage","messageBody":"Branch fix storage","fileTypesAndContributionMap":{}},{"hash":"368c3e0edc140b481ed9138db0af0cdf952f1de0","isMergeCommit":false,"messageTitle":"Add display prompts to ChessMaster when loading game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":80,"deletions":31}}},{"hash":"df760f8839fd4776b219a1f23fe319a0d0d908a8","isMergeCommit":false,"messageTitle":"Change minor format","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":4}}},{"hash":"5b09eef974fb106ded255114a355f98463a07be9","isMergeCommit":false,"messageTitle":"Add new exception for moving empty piece","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":52}}},{"hash":"417b80043947aa1788366f6b5381d104a96f22e0","isMergeCommit":false,"messageTitle":"Update MoveCommand to parse move in execute","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":22}}},{"hash":"9210900781e250acccccea531d5ecfa473aa4255","isMergeCommit":false,"messageTitle":"Reset storage file after end of game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":10}}},{"hash":"7795994c9da29cf8bade97a9f4b191a40ae34258","isMergeCommit":false,"messageTitle":"Update new display format of Chess Board","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":25}}},{"hash":"661eb2af274f956d09a7d70368efb9ca9c608ffa","isMergeCommit":false,"messageTitle":"Update Game class with new function implementation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"8fbdcaad36233bd9b10d2cba74ab813643446967","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-beautify-textUI","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"05353d08b67f19829e02157c3d06a406750d7a1c","isMergeCommit":false,"messageTitle":"Minor formatting changes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":20}}},{"hash":"9e1848b1a18fa75c185ad4282c0090a683183356","isMergeCommit":false,"messageTitle":"Minor changes to CPU first move","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":8}}},{"hash":"cebf92a411866dfac8b6986b7fa6067014cb3758","isMergeCommit":false,"messageTitle":"Add ant build config file for jar generation","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":35,"deletions":0}}},{"hash":"488a640bf673fad73526eb4568c244d96eb45241","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":26}}},{"hash":"ee7ab7e5d203d1eecddea51455428492b014d9c0","isMergeCommit":false,"messageTitle":"Add ant build config file for jar generation","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":35,"deletions":0}}},{"hash":"e9aeca72e4b8b494d9e56273a91dbb3436e66141","isMergeCommit":false,"messageTitle":"Fix CI checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":26},"test-code":{"insertions":2,"deletions":5}}},{"hash":"54c3377b719f551241501b8bc182d0751ff6ebd5","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-beautify-textUI\u0027 of https://github.com/TongZhengHong/tp into branch-beautify-textUI","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e9decd346e72260702f9498f0d549ac86cfb2b43","isMergeCommit":true,"messageTitle":"Merge pull request #61 from TongZhengHong/branch-beautify-textUI","messageBody":"Branch beautify text UI","fileTypesAndContributionMap":{}},{"hash":"3b77bd3c1503b15c4094d5915d6f0a461e68b01e","isMergeCommit":false,"messageTitle":"Update human promotion text UI","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":8}}},{"hash":"2aaa4b500ff41e6df2a114ab896570c7a5b154a2","isMergeCommit":false,"messageTitle":"Add MoveCommand and Player type checking methods","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":46}}},{"hash":"bfe394e40a9d946eaae91ae87684e529cc947086","isMergeCommit":false,"messageTitle":"Update main control logic to be turn based","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":51,"deletions":30}}},{"hash":"f208755af8b44abd8524f7f4125af7fe6806ed4f","isMergeCommit":true,"messageTitle":"Merge pull request #63 from TongZhengHong/branch-refactor-game","messageBody":"Branch refactor game","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"fd37c963ecab66fd0dc488a16503be88f2854b9c","isMergeCommit":false,"messageTitle":"Remove MoveEmptyPieceException replaced with NullPieceException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":29}}},{"hash":"fc51d27abe2870ddf88e528def55dee6b0b3f435","isMergeCommit":false,"messageTitle":"Pass playerColor into ChessBoard object instead of Game","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":28}}},{"hash":"a41b9f74ff067e4652f4074fd001b6814f0972e8","isMergeCommit":false,"messageTitle":"Add assertions where necessary","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":12}}},{"hash":"a3380a5541d4109ccabbd4c1fe2257244adbe3da","isMergeCommit":false,"messageTitle":"Rename chessmaster package to game package","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":3,"deletions":3}}},{"hash":"d7a6f346661aab400170ebe331b3c12a95a9281a","isMergeCommit":false,"messageTitle":"Add new junit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":269,"deletions":0}}}]},{"date":"2023-10-27","commitResults":[{"hash":"17d41bb39c2cf9db61e4bf4a2ff31cb2290f6ca5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into doc-promote","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f853d9e68d745fd78e94e46ad197d7bc51edd465","isMergeCommit":true,"messageTitle":"Merge pull request #85 from ken-ruster/doc-promote","messageBody":"Add documentation for `Parser` and `Command`","fileTypesAndContributionMap":{}},{"hash":"cb268266a25d2a1fe83ac4c8fde6f5a6a9c1b8f7","isMergeCommit":false,"messageTitle":"Developer guide for ChessMaster and Game","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":200,"deletions":3}}},{"hash":"9c14af88cf4e0323e343b2133ff00e4d4bb4e640","isMergeCommit":false,"messageTitle":"Add Documentation for ChessMaster and Game","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":200,"deletions":3}}},{"hash":"67ebaed0ee6dbca50bad9eb67cb9a66af4252b58","isMergeCommit":false,"messageTitle":"Remove unnecessary commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":28,"deletions":53}}},{"hash":"c6c6e2c440b93aa70517bce077fa995158214203","isMergeCommit":false,"messageTitle":"Add repo sense @author tags where necessary","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":16}}},{"hash":"9b6e910466d24058de8e3dbb70363e9d89b66ecf","isMergeCommit":false,"messageTitle":"Change @author to @@author","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":35,"deletions":38}}}]},{"date":"2023-10-29","commitResults":[{"hash":"30c6f15afd82f040617aa32cf07dd2a7a9aa610a","isMergeCommit":false,"messageTitle":"Update Move isValid method to take ChessBoard as arg","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"a825c4ec8796a233e4378ffbed0cb42b198aeda6","isMergeCommit":false,"messageTitle":"Check move validity in MoveCommand execute()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":3}}},{"hash":"7906eb0770108d9177d32669a02a0d70b2af00d8","isMergeCommit":true,"messageTitle":"Merge pull request #88 from TongZhengHong/branch-repo-sense","messageBody":"Update individual code contribution with repo sense @@author tags","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"5ee5c74ccae5d67085749e547ecbb516d0d52446","isMergeCommit":true,"messageTitle":"Merge pull request #91 from ken-ruster/start-help","messageBody":"Add help message at start","fileTypesAndContributionMap":{}},{"hash":"07c42614d1fe2f2408bb4703e5c78b23fef7a39d","isMergeCommit":false,"messageTitle":"Move static ExceptionMessages class to UI package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0},"other":{"insertions":1,"deletions":1}}},{"hash":"3af0fe8cf12d90ee9474692107f38811fce673df","isMergeCommit":true,"messageTitle":"Merge pull request #92 from TongZhengHong/branch-fix-move-validity","messageBody":"Branch fix move validity","fileTypesAndContributionMap":{}},{"hash":"35a7affaf4fff8bc962176a052c9426377845e7e","isMergeCommit":false,"messageTitle":"Add @@author tag for Exception classes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":0}}},{"hash":"70dbf1c6ffff949188b42329b8738b2167f6ab1d","isMergeCommit":false,"messageTitle":"Add isPawn method to check pawn object","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0}}},{"hash":"2ff8c015ca0166931a1dc9562be7fafb49bf8e86","isMergeCommit":false,"messageTitle":"Make TextUI non-static \u0026 move showChessBoard()","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":97,"deletions":112},"test-code":{"insertions":6,"deletions":2}}},{"hash":"ab72878747032985c724afae1dff382924795e1e","isMergeCommit":false,"messageTitle":"Add TextUI to Command execute method","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":7}}},{"hash":"2955134d8a0f503a43ac7b3a5a6d04bf7c795d95","isMergeCommit":false,"messageTitle":"Update showMoveCommand with new representation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":74,"deletions":13}}},{"hash":"d55dd8a502636b0ec5a7e157dcef3da3c297a3b3","isMergeCommit":false,"messageTitle":"Add whitespace around check in checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":27},"other":{"insertions":6,"deletions":0}}},{"hash":"32d148983e0fad987fcad755f9c4e4d333d36183","isMergeCommit":false,"messageTitle":"Update ShowCommand to show prompt first","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"e0936947c897ccb74d2c83e52afc901ee31df9ad","isMergeCommit":false,"messageTitle":"Fix checkstyle in ParserTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"52f68f227988d5f5d0c82bbcd60d01710062acdc","isMergeCommit":false,"messageTitle":"Remove unused import in MoveCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"c25b4df580cfa180e698ff4393e78ab4d31d2a17","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-nonstatic-textui","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"939d169550d1f73aa5ee9be3758cb9067da0ac43","isMergeCommit":true,"messageTitle":"Merge pull request #90 from ken-ruster/no-available-moves-message","messageBody":"Modify getAvailableCoordinatesString()","fileTypesAndContributionMap":{}},{"hash":"04d6400be685eb19bdc605570269fc7f77562da0","isMergeCommit":false,"messageTitle":"Remove print cpu best move","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"c43cff3a57536b8dfa766f255d3340888c6d6b0d","isMergeCommit":false,"messageTitle":"Add print chessboard with previous move","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":10}}},{"hash":"f89f8a612ac188875878075bd5bbe4a2224a703d","isMergeCommit":false,"messageTitle":"Add basic user guide draft template outline","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":170,"deletions":11}}},{"hash":"1400ca2d7fca8637ebd3dca58c772dc75387f2c0","isMergeCommit":true,"messageTitle":"Merge pull request #101 from ken-ruster/ug-commands","messageBody":"Update User Guide","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"dcf78f9901c9034e63845749d585570591eac03a","isMergeCommit":true,"messageTitle":"Merge pull request #104 from TriciaBK/tricia","messageBody":"Add ViewLegendCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"db9f74aa4330e8d29ca11b4808d785a88d4a0def","isMergeCommit":true,"messageTitle":"Merge pull request #112 from TriciaBK/player-color","messageBody":"Implement currentColour in ChessMaster","fileTypesAndContributionMap":{}},{"hash":"8e6bf7e207aca558201c8d2c2d8824cb9e5d9a23","isMergeCommit":false,"messageTitle":"Remove json tag in code blocks in user guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"e7652bbd4429a01488aa2a495c0f8b6fac4ad839","isMergeCommit":false,"messageTitle":"Update parse color method to include empty color check","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":12}}},{"hash":"b53e0da3c0ff85b8312dca47001b02742f5d7214","isMergeCommit":false,"messageTitle":"Update first move player checking","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":30}}},{"hash":"bca88623803ed3214658b5a69b89b7b55d5adca5","isMergeCommit":true,"messageTitle":"Merge pull request #111 from onx001/bugFixLoad","messageBody":"Check for presence of 2 kings when loading board and count number of pieces for both sides","fileTypesAndContributionMap":{}},{"hash":"222220bd6f92465521bc9fd41f9ad1a5ec1ca2f7","isMergeCommit":false,"messageTitle":"Update winning player ui message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":9}}},{"hash":"924a483adc27c704bed3ff9787055548f8df7214","isMergeCommit":false,"messageTitle":"Change minor text ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3}}},{"hash":"751e64a3c7e5647c8ef2de414e3a6321652562fe","isMergeCommit":false,"messageTitle":"Store hasMoved flag for each ChessPiece in text file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":15}}},{"hash":"bf251538a1352aafb68c213fe4412b5400fe66e0","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113-T18-1/tp into branch-storage-hasMoved","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b247f11ff249e41c9bec7bed2af9d2085980ccfc","isMergeCommit":false,"messageTitle":"Update parseColor test to throw exception when empty","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":6,"deletions":2}}},{"hash":"9fc8c134bfe7a14c4dabe0ca9438437b8658da81","isMergeCommit":true,"messageTitle":"Merge pull request #115 from onx001/StartBug","messageBody":"Start bug fix","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"f2e82359269df869737f4a384b4961378feea45c","isMergeCommit":true,"messageTitle":"Merge pull request #116 from onx001/Check","messageBody":"Add `isChecked` and `isCheckMated` features","fileTypesAndContributionMap":{}},{"hash":"10847a16e7f77143d6e7977af68c17b625c2bf7d","isMergeCommit":true,"messageTitle":"Merge pull request #149 from onx001/MinimaxAggro","messageBody":"Fix minimax aggro","fileTypesAndContributionMap":{}},{"hash":"37cbf93212a35dd1ef572caaf3338570d4bd8b64","isMergeCommit":false,"messageTitle":"Update no available moves ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":6}}},{"hash":"32688040fe6fa6bc3f628550b7cdece7eb5f5a07","isMergeCommit":false,"messageTitle":"Fix empty payload in ShowMovesCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3}}},{"hash":"98331c4ec0836a9d9ca76ab2322be080e539bdbf","isMergeCommit":false,"messageTitle":"Fix wrong color when player loses","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":4}}},{"hash":"c0b3577a3914f9841923932dae54626f541d67e0","isMergeCommit":false,"messageTitle":"Convert code blocks from markdown to html","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"0fe8b95a98fc5b02373a921a09b36323f9480072","isMergeCommit":false,"messageTitle":"Fix link to legend command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]}]},"authorFileTypeContributionMap":{"ken-ruster":{"docs":211,"functional-code":324,"test-code":20,"other":1},"antrikshdhand":{"docs":7,"functional-code":121,"test-code":0},"TriciaBK":{"docs":183,"functional-code":423,"test-code":0},"onx001":{"docs":106,"functional-code":759,"test-code":38},"TongZhengHong":{"docs":353,"functional-code":1802,"test-code":278,"other":48}},"authorContributionVariance":{"ken-ruster":8623.499,"antrikshdhand":3206.0898,"TriciaBK":5739.9644,"onx001":6565.1997,"TongZhengHong":111840.555},"authorDisplayNameMap":{"ken-ruster":"CS2113-T18-1 OH K.. WEI","antrikshdhand":"CS2113-T18-1 DHAN..IKSH","TriciaBK":"CS2113-T18-1 TRIC..PING","onx001":"CS2113-T18-1 OU N..IANG","TongZhengHong":"CS2113-T18-1 TONG..HONG"}} diff --git a/AY2324S1-CS2113-T18-3_tp_master/authorship.json b/AY2324S1-CS2113-T18-3_tp_master/authorship.json index 7535f41..dbe7fa2 100644 --- a/AY2324S1-CS2113-T18-3_tp_master/authorship.json +++ b/AY2324S1-CS2113-T18-3_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" implementation group: \u0027com.google.code.gson\u0027, name: \u0027gson\u0027, version: \u00272.10.1\u0027","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":33,"author":{"gitId":"-"},"content":" mainClass.set(\"seedu.duke.Duke\")","lastModifiedDate":"2023-08-05"},{"lineNumber":34,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveBaseName.set(\"duke\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":42,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":"run {","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":5,"-":46}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"Display | Name | Github Profile | Portfolio ","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"--------|:-----------------:|:----------------------------------------:|:---------:","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Cheung Ka Yuen | [Github](https://github.com/KenCheung18) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Lee Jun Hao Bryan | [Github](https://github.com/bljhty) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Lim Yuh Ching | [Github](https://github.com/limyuhching) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Ee Hong Zhi | [Github](https://github.com/Hongzhii) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"-"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Don Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"limyuhching":1,"bljhty":2,"Hongzhii":1,"KenCheung18":1,"-":4}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"We first give acknowledgement to Module Coordinator, Dr Akshay Narayan, and Teaching Assistant, Aditi Chadha for guidance and supervision over the KaChinnnng project.","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"We utilised the following resources to aid us in the development of KaChinnnng:","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"- [tp project](https://github.com/nus-cs2113-AY2324S1/tp) of the nus-cs2113-AY2324S1 organisation","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"- [addressbook-level2](https://github.com/se-edu/addressbook-level2) \u0026 [addressbook-level3](https://github.com/se-edu/addressbook-level3) project by SE-EDU largely inspired the format and coding style of KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"## Design \u0026 implementation","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"Below are the design and implementation details of KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"### Design","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"The architectural diagram of KaChinnnng is as follows:","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"![ArchitectureDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/ArchitectureDiagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"The kaChinnnng program will first enter the `run` state where the `storage` class will be accessed and data will be retrieved if the application has been used before.","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"Next, the `User` will input various `commands` via the `Ui` class. The `commands` will then be parsed by the `Parser` class and the relevant `managers` will be called to execute the `commands`.","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"Once the `User` inputs has been successfully executed, `commands` will make use of the `Ui` class to output the relevant information to the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"When the `User` exits the program, the `storage` class will be called to save the data to the local storage.","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"`Storage` will read from the local storage when the program is run again.","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":"### Expense Class Overview","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":"The Expenses are divided into three categories. Transport, Utilities and Food.","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":"Each of the categories inherit from a base Expense class which in turn","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":"inherits from the FinancialRecord class.","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":"![expense_class_diagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/expense_class_diagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"### IncomeManager","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"the IncomeManager is facilitated by `IncomeParser`, `IncomeManager`, `IncomeList` and `Ui`.","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":"1. The user inputs the command to add income. This input is then passed to `IncomeParser` to be parsed.","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"2. `IncomeParser` then parses the input and returns a `Income` object.","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":"3. `IncomeManager` then adds the `Income` object to the `IncomeList`.","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"4. `IncomeManager` then returns a `String` to `Ui` to be printed out to the user.","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":"![IncomeManager_seqdiagram.drawio.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/IncomeManager_seqdiagram.drawio.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"### ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":"The ExpenseManager is facilitated by `ExpenseParser`, `ExpenseManager`, `ExpenseList` and `Ui`","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":"1. The user inputs the command to add expense.","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":"2. This command is used to instantiate a ExpenseManager object which is executed.","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":"3. During execution, the command is passed to ExpenseParser which extracts and parses the input fields.","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":"4. Input field information is passed to the relevant Expense constructor which returns a Expense object.","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":"5. Expense object is returned to ExpenseManager from ExpenseParser.","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":"6. Expense obejct is returned to Duke from ExpenseManager.","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":"![expenseManager_sequence_diagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/expenseManager_sequence_diagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"### Find Command","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"The FindCommand is facilitated by `FindCommand`, `FindParser`, `Ui`,`ExpenseList` and `IncomeList`.","lastModifiedDate":"2023-10-25"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"1. The user will first input the command to find the expense or income.","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"find /t \u003ctype\u003e /cat [category] /de [description] /date [date]","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":"2. The inputs will then be passed to `FindParser` to get the necessary fields such as type, category, description and date.","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"3. The FindCommand is then instantiated with the necessary fields.","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":"4. Users can choose to search through the expense list or income list.","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"5. If users searches through the income list, either the description or date will be used to search through the income list.","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":"6. If users searches through the expense list, either the category or date will be used to search through the expense list.","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":"7. The execute method will then be called to search through the list and return the list of expenses or incomes that matches the search criteria.","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":"![FindCommand_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/FindCommand_SequenceDiagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":"### GetFromTxt Command","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":"The GetFromTxt Command is facilitated by `IOException`,`Scanner`, `KaChinnnnngException`, `IncomeList` and `ExpenseList`","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":"1. The user start the program and the command will start automatically with a default path","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":"2. Once the command executed, it will try to create an txt file on the default path","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":"3. If file failed to create, throw an `IOException`","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":"4. Catch the `IOExceotion` and print error messages","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":"5. Create a `Scanner` Object s to get content from txt file","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":"6. If amount in txt file exceed limit or incorrect, throw `KaChinnnningException`","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":"7. Read the content on the file and add corresponding object to incomes or expenses list","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":"![GetFromTxtCommands_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/GetFromTxt.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":"### ExchangeRateManager","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"limyuhching"},"content":"The Sequence Diagram below shows how the components interact with each other for the scenario ","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"limyuhching"},"content":"where the user issues the command `update exchange rate USD 0.8`.","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":"![UpdateExchangeRate_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/UpdateExchangeRate_SequenceDiagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":"This is facilitated by `Duke`, `UpdateExchangeRateCommand`, `ExchangeRateManager`\u0027and `ExchangeRateFileHandler`.","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":"### SaveToTxt Command","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":"The SaveToTxt Command is facilitated by `FileWriter` ,`IncomeList` and `ExpenseList`","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":"1. The user start the program and the function will run everytime after user input a command","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":"2. Once the command executed, the function saveIncomeAndExpense will run automatically","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":"3. It will run the function saveIncomeToTextFile first, the saveIncomeToTextFile will create a FileWriter and loop through the incomes list","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":"4. It will get description, date, and amount from the income list for every single income record in the list and save the information into the text file","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":"5. After that, the saveIncomeToTextFile will then call the saveExpenseToTextFile function ","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":"6. The saveExpenseToTextFile will create a new FileWriter and loop through the expenses list ","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":"7. It will get description, date, amount and type from the expenses list for every single expense record in the list and save the information into the text file","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":"![SaveToTxt_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/SaveToTxt.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":112,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":113,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":114,"author":{"gitId":"-"},"content":"{Describe the target user profile}","lastModifiedDate":"2020-05-24"},{"lineNumber":115,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":116,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":117,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":118,"author":{"gitId":"-"},"content":"{Describe the value proposition: what problem does it solve?}","lastModifiedDate":"2020-05-24"},{"lineNumber":119,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":120,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":121,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":122,"author":{"gitId":"-"},"content":"| Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2020-05-24"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":"|---------|----------|------------------------------------|-----------------------------------------------------------------------|","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"-"},"content":"| v1.0 |new user| see usage instructions | refer to them when I forget how to use the application |","lastModifiedDate":"2020-05-24"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| add new income entry | track all my incomes |","lastModifiedDate":"2023-10-25"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| add new expense entry | track all of my expenses |","lastModifiedDate":"2023-10-25"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| delete income entry | remove incomes that I no longer want to track |","lastModifiedDate":"2023-10-25"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| delete expense entry | remove expenses that I no longer want to track |","lastModifiedDate":"2023-10-25"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| list both income and expense entry | view all my expenses and incomes |","lastModifiedDate":"2023-10-25"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| check my balace | better bugdet my expenditures |","lastModifiedDate":"2023-10-25"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| search for past inputs | better find and track my past expenses |","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| be able to change the currency | better track my expenses in different currencies when i am travelling |","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| be able to edit my inputs | make necessary changes to my inputs when a mistake is made |","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| be able to save and load my inputs | save my inputs so that I can access them the next time I use the app |","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| reset my inputs | start afresh |","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":137,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":"- Domain rules:","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" - The application should not crash under normal circumstances.","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" - Dates can be entered in the format of dd/mmm/yyyy or dd/mm/yyyy and should not be in the future.","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" - Amount added should be in the format of 0.00 and should not be negative.","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" - The application only accepts commands in English.","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" - Users should refrain from using special characters in the description/category/type/date field.","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" - Users should refrain from tampering with the storage and log files as it may result in unexpected issues.","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":"- Constraints:","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" - the total number of entries for Expense and Income should not exceed 10 000 each.","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" - the amount input should be less than 1 billion.","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":"- Technical Requirements:","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" - The application must be able to run on Windows, MacOS and Linux.","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":"- Technical Requirements:","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" - KaChinnnng should be able to be used by users of all skill levels.","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":"- Others:","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" - Arguments should follow the format specified in the user guide.","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" - Should the arguments not be in the provided format, the application will not execute the command.","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":159,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":160,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":161,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":"| Term | Definition |","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":"|---------|------------|","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":"| Income | debit entry of user|","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":"| Expense | credit entry of user|","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":"| Balance | Net Amount|","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":"| Ui | User Interface, where user inputs commands and sees output|","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"| Parser | Parses user input into commands|","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":171,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":"Given below are the instructions for manual testing of KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"### Launching and exiting the application","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":"1. lauching the application","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" 1. download the jar file from the release page.","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" 2. open a terminal and navigate to the directory where the jar file is located.","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" 3. run the command `java -jar KaChinnnng.jar`","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":"2. exiting the application","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" 1. type `exit` in the command box and press enter.","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" 2. the application will exit.","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":"### Adding an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":"1. adding an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" 1. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" - To add an income: `add income /de \u003cdescription\u003e /date \u003cDD/MM/YYYY\u003e /amt \u003camount\u003e`","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" - To add an expense: `add expense /cat food /type lunch /de sushi /date 31/10/2023 /amt 20.00`","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" - /type for expense includes (`UNDEFINED`, `BREAKFAST`, `LUNCH`, `DINNER`) for the `food` category, (`TRAIN`, `BUS`, `TAXI`, `FUEL`, `UNDEFINED`) for the `TRANSPORT` category and (`UNDEFINED`, `WATER`, `ELECTRICITY`, `GAS`) for the `UTILITIES` category.","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" - Expected outcome: the income/expense will be added to the list and the balance will be updated accordingly and the user will be notified.","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" 2. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary`","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" - expense: `add expense /cat food /type lunnch`","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" - Expected outcome: the income/expense will not be added to the list and the user will be notified with an error message.","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" 3. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" - Other invalid test cases includes:","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary /date 31/11/2023 /amt 5000.00` where the date is in the future.","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary /date 31-10-2023 /amt 5000.00` where the date is in the wrong format.","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary /date 31/10/2023 /amt -5000.00` where the amount is negative.","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" - expense: `add expense /cat food /type lunch /de lunch /amt 5000.00` where there is missing fields","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":"### Deleting an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"limyuhching"},"content":"Deleting income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"limyuhching"},"content":"1. Test case: If there the index specified invalid","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `delete income \u003cinvalid_index\u003e`","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `Oops! Income \u003cinvaldi_index\u003e does not exist`","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"limyuhching"},"content":"2. Test case: If the index is missing","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `delete income`","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `You\u0027re missing an argument`","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"limyuhching"},"content":"3. Test case: If there index is not an integer","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `delete income abc`","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `Oops! An integer index is expected`","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":"### Editing an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"limyuhching"},"content":"Editing income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"limyuhching"},"content":"1. Test case: If there the index specified invalid","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `edit income \u003cinvalid_index\u003e income /de \u003cdescription\u003e /date \u003cDD/MM/YYYY\u003e /amt \u003camount\u003e`","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `Oops! Income \u003cinvaldi_index\u003e does not exist`","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"limyuhching"},"content":"2. Test case: Missing arguments","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"limyuhching"},"content":" Assuming Income 1 and Expense 1 exist:","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary`","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"limyuhching"},"content":" - expense: `edit expense 1 /cat food /type lunnch`","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: the income/expense will not be edited and the user will be notified with an error message.","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"limyuhching"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"limyuhching"},"content":"4. Test case: Other invalid test cases includes:","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"limyuhching"},"content":" Assuming index Income 1 exist:","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary /date 31/11/2023 /amt 5000.00` where the date is in the future.","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary /date 31-10-2023 /amt 5000.00` where the date is in the wrong format.","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary /date 31/10/2023 /amt -5000.00` where the amount is negative.","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"limyuhching"},"content":" - expense: `edit expense 1 /cat food /type lunch /de lunch /amt 5000.00` where there is missing fields","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"### Finding an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":"1. Finding income/expense:","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" 1. Pre-requisite: list should already contain income/expense. this can be checked via `list income`, `list expense` or `list`","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" 2. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" - For income: `find /t income /de salary`","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" - For expense: `find /t expense /cat food /de sushi /date 31/10/2023`","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" - Expected outcome: all income with description containing \"salary\" should be listed. all expense containing \"food\" in the category, \"sushi\" in the description and \"31/10/2023\" in the date should be listed.","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" 3. Test case: If there is no matching income/expenses","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":" - Income: `find /t income /de bonus`","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" - Expense: `find /t expense /cat food /de burger /date 31/10/2023`","lastModifiedDate":"2023-11-01"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":" - expected: no income/expense should be listed.","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"limyuhching":34,"bljhty":133,"Hongzhii":18,"KenCheung18":30,"-":31}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"# Hi","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"-"},"content":"{Give product intro here}","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"bljhty":1,"-":7}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"# KaChinnnng User Guide","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"Welcome to KaChinnnng a personal finance tracker that helps you keep track of your expenses and income.","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"1. Ensure that you have Java 11 or above installed.","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"2. Download the latest version of `KaChinnnng` from [here](http://link.to/duke).","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"3. Copy the downloaded file to the folder you want to use as the home folder for your KaChinnnng.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"4. open a command terminal and navigate to the folder where you have copied the file to.","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"5. type in the following to run the program","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"java -jar KaChinnnng.jar","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"6. if successful you should see the following output","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"Welcome to KaChinnnngggg! How may i assist you today?","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"7. type in desired commands and press enter to execute them. (note: commands are not case sensitive)","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":"8. \"[ ]\" denotes optional parameters","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"-"},"content":"## Features ","lastModifiedDate":"2020-05-24"},{"lineNumber":27,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"{Give detailed description of each feature}","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"### View help : help","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"Shows basic commands executable by the program.","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"Format:","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"help","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":"### Add an entry: add","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"Creates a new entry for income or expenses in the program.","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"Values of income and expense added has to be lower than 1000000.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"Income and Expense values takes up to 2 decimal places.","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":"To add an income (with foregin currency):","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"add income /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":"To add an expense (with foregin currency):","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"add expense /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"Use case:","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":"- Prompts users if any of the fields are empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"- There are only 3 categories for expenses: `Food`, `Transport`, `Utilities`.","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"- Amount is takes up to 2 decimal places.","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"- format of date is `dd/mm/yyyy`.","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"- Date needs to be an existing date, and cannot be dates in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":"- By default, amount is set to SGD.","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":"- User can specify the currency. Refer to the supported currencies for valid currency.","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":"- Currency specified must have been updated. Refer to list exchange rates for more details","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":63,"author":{"gitId":"-"},"content":"Example of usage:","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":"add income /de salary /date 01/01/2020 /amt 1000","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"add expense /cat transport /type taxi /de taxi to school /date 10/10/2023 /amt 10.00","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":"add expense /cat Food /type lunch /de lunch /date 01/01/2020 /amt 10.50","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":"add expense /cat Food /type breakfast /de chicken sandwich /date 01/01/2020 /amt USD 10.50","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":"### List all entries: list","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"Shows a full list of both the expenses and income created by the user.","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":"User can choose to view the list of income/expenses separately as well.","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"Format:","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":"list","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":"list income","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"list expense","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"### Delete an entry: delete","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"Deletes an entry from the list of income/expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":"Format:","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"delete expense \u003cindex\u003e","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"delete income \u003cindex\u003e","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":"### Check balance: balance","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":"Check the balance for current financial records","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":"balance","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"limyuhching"},"content":"### Edit an entry: edit ","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"limyuhching"},"content":"Edit an entry from the list of income/expenses.","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"limyuhching"},"content":"edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"limyuhching"},"content":"edit expense \u003cindex\u003e /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"limyuhching"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"limyuhching"},"content":"edit income 1 /de end of year bonus /date 02/10/2023 /amt HKD 3000.00","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"limyuhching"},"content":"edit expense 2 /cat food /type dinner /de dinner /date 01/10/2023 /amt 10.00","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"limyuhching"},"content":"### List the supported currencies: list currencies","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"limyuhching"},"content":"This function allows user to see the foreign currencies supported by KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"limyuhching"},"content":"Note: The default currency is SGD.","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"limyuhching"},"content":"list currencies","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"limyuhching"},"content":"Example output:","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"limyuhching"},"content":"These are the supported currencies:","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"limyuhching"},"content":"MYR USD JPY KRW EUR THB HKD INR IDR AUD GBP CNY CAD TWD VND PHP","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"limyuhching"},"content":"### List exisitng exchange rates: list exchange rates","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"limyuhching"},"content":"List all updated exchange rates. All exchange rates that are updated or loaded","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"limyuhching"},"content":"from ExchangeRate.txt will be shown. User can call the update exchange rates function to ","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"limyuhching"},"content":"register new exchange rates into their KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"limyuhching"},"content":"Note: Exchange rates are shown in SGD/{other currency}.","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"limyuhching"},"content":"list exchange rates","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"limyuhching"},"content":"### update exchange rate","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"limyuhching"},"content":"Update exchange rate of a specific foreign currency. Exchange rates will be saved upon","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"limyuhching"},"content":"successful update.","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":160,"author":{"gitId":"limyuhching"},"content":"Note: rate specified should be in SGD/{foreign currency}.","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"limyuhching"},"content":"update exchange rate \u003csupported_currency\u003e \u003crate\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"limyuhching"},"content":"Example","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"limyuhching"},"content":"update exchange rate USD 0.8","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":171,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":173,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":174,"author":{"gitId":"-"},"content":"**Q**: How do I transfer my data to another computer? ","lastModifiedDate":"2020-05-24"},{"lineNumber":175,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":176,"author":{"gitId":"KenCheung18"},"content":"**A**: Move the txt file from the folder where the jar file located, ","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"KenCheung18"},"content":"to the folder where the jar file located in the new computer ","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":179,"author":{"gitId":"KenCheung18"},"content":"**Q**: What do i need to do when I see the `format incorrect from storage file` at the beginning of running the program","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"KenCheung18"},"content":"**A**: The system will automatically remove that line from the txt after you give the first command to the bot, ","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"KenCheung18"},"content":"if you don\u0027t want to remove that line, just terminate the program using control/command c right after you see the error,","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"KenCheung18"},"content":"and change the line in txt file to the correct format.","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":185,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":186,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":"| Action | Format, Examples |","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":"| ------ |------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":"| Help | `help` |","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":"| Add Income | `add income /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` \u003cbr\u003e e.g., `add income /de salary /date 01/01/2020 /amt 1000` |","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":"| Add Expense | `add expense /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` \u003cbr\u003e e.g., `add expense /cat Food /type lunch /de sushi /date 01/01/2020 /amt 10.50` |","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"limyuhching"},"content":"| List | `list` \u003cbr\u003e `list income` \u003cbr\u003e `list expense` \u003cbr\u003e `list currencies` \u003cbr\u003e `list exchange rates`|","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":"| Delete | `delete expense \u003cindex\u003e` \u003cbr\u003e `delete income \u003cindex\u003e` |","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":"| Edit | `edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` \u003cbr\u003e `edit expense \u003cindex\u003e /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` |","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"limyuhching"},"content":"| Update Exchange Rate | `update exchange rate \u003csupported_currency\u003e \u003crate\u003e` |","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"limyuhching"},"content":"| Clear |`clear`|","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"limyuhching"},"content":"| Exit |`exit`|","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"limyuhching":79,"bljhty":78,"KenCheung18":15,"-":25}},{"path":"images/expenseManager_sequence_diagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"actor Duke","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"participant ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"participant ExpenseParser","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"participant Expense","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"participant ExchangeRateManager","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"Duke -\u003e ExpenseManager: provides expense details","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"activate ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager -\u003e ExpenseManager: execute()","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"activate ExpenseManager","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager -\u003e ExpenseManager: extractExpenseFields(details)","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager -\u003e ExpenseParser: parseExpense(expenseFields)","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":"activate ExpenseParser","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":"opt isOtherCurrency()","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser -\u003e ExchangeRateManager : convertCurrency()","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"ExchangeRateManager -\u003e ExpenseParser : amount","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser -\u003e ExpenseParser: parseDate(dateField)","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser -\u003e Expense: Expense(description, date, amount, type)","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":"Expense --\u003e ExpenseParser","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser --\u003e ExpenseManager","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":"deactivate ExpenseParser","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":"deactivate ExpenseManager","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager --\u003e Duke: returns new Expense object","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"deactivate ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Hongzhii":27}},{"path":"src/main/java/seedu/duke/Duke.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"package seedu.duke;","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.Balance;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearAll;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearExpenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearIncomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.DeleteExpenseCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.DeleteIncomeCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.EditExpenseCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.EditIncomeCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.ExpenseLister;","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ExpenseManager;","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.FindCommand;","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.IncomeLister;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.IncomeManager;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.ListCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.UpdateExchangeRateCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.UsageInstructions;","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.storage.ExchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.storage.GetFromTxt;","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.storage.SaveToTxt;","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-12"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"import seedu.duke.parser.Parser;","lastModifiedDate":"2023-10-12"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"import seedu.duke.parser.FindParser;","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-12"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" * This class is the main class of the program.","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" * It contains the main method that runs the program.","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"-"},"content":"public class Duke {","lastModifiedDate":"2019-07-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" private Ui ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-12"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" private String storagePath;","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" private SaveToTxt save;","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" private GetFromTxt get;","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager exchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateFileHandler exchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" public Duke() {","lastModifiedDate":"2023-10-12"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" ui \u003d new Ui();","lastModifiedDate":"2023-10-12"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-12"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" storagePath \u003d \"KaChinnnngggg.txt\";","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" save \u003d new SaveToTxt(storagePath);","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" get \u003d new GetFromTxt(storagePath);","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" exchangeRateFileHandler \u003d new ExchangeRateFileHandler(\"./data/ExchangeRates.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * This method runs the program.","lastModifiedDate":"2023-10-11"},{"lineNumber":62,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void run() {","lastModifiedDate":"2023-10-09"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" Ui.printWelcomeMessage();","lastModifiedDate":"2023-10-09"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" loadData();","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" boolean isExit \u003d false;","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" while (!isExit) {","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" String fullCommand \u003d ui.readCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" if (\"exit\".equals(fullCommand)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" isExit \u003d true;","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" continue;","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" executeCommand(fullCommand);","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" saveData();","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" ui.printGoodbyeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" protected void loadData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" get.getFromTextFile(incomes, expenses);","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"limyuhching"},"content":" if(!exchangeRateFileHandler.load()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"\\tOOPS!!! File not found.\");","lastModifiedDate":"2023-10-25"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"limyuhching"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" protected void executeCommand(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" String command \u003d Parser.parse(fullCommand);","lastModifiedDate":"2023-10-11"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" String[] parts \u003d command.split(\"-\", 2);","lastModifiedDate":"2023-10-11"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" // ... (switch-case structure extracted from the original `run()` method)","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" switch (parts[0]) {","lastModifiedDate":"2023-10-11"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" case \"exit\":","lastModifiedDate":"2023-10-11"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-11"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" case \"add_income\":","lastModifiedDate":"2023-10-12"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" IncomeManager incomeCommand \u003d new IncomeManager(fullCommand);","lastModifiedDate":"2023-10-12"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" incomeCommand.execute();","lastModifiedDate":"2023-10-12"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" Income newIncome \u003d incomeCommand.getNewIncome();","lastModifiedDate":"2023-10-12"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" incomes.add(newIncome);","lastModifiedDate":"2023-10-12"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" Ui.printIncomeAddedMessage(newIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-12"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" case \"list_income\":","lastModifiedDate":"2023-10-12"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" new IncomeLister(incomes, ui).listIncomes();","lastModifiedDate":"2023-10-12"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-12"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":122,"author":{"gitId":"Hongzhii"},"content":" case \"add_expense\":","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseCommand \u003d new ExpenseManager(fullCommand);","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"Hongzhii"},"content":" expenseCommand.execute();","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"Hongzhii"},"content":" Expense newExpense \u003d expenseCommand.getNewExpense();","lastModifiedDate":"2023-10-15"},{"lineNumber":126,"author":{"gitId":"Hongzhii"},"content":" expenses.add(newExpense);","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" Ui.printExpenseAddedMessage(newExpense);","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"Hongzhii"},"content":" break;","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"Hongzhii"},"content":" case \"list_expense\":","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"Hongzhii"},"content":" new ExpenseLister(expenses, ui).listExpenses();","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":133,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":" case \"list\":","lastModifiedDate":"2023-10-17"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":136,"author":{"gitId":"limyuhching"},"content":" new ListCommand(incomes, expenses, ui).execute();","lastModifiedDate":"2023-10-17"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":138,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":139,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":140,"author":{"gitId":"limyuhching"},"content":" case \"delete_income\":","lastModifiedDate":"2023-10-17"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"limyuhching"},"content":" new DeleteIncomeCommand().execute(incomes, fullCommand, ui);","lastModifiedDate":"2023-10-17"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":145,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":146,"author":{"gitId":"limyuhching"},"content":" case \"delete_expense\":","lastModifiedDate":"2023-10-17"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":148,"author":{"gitId":"limyuhching"},"content":" new DeleteExpenseCommand().execute(expenses, fullCommand, ui);","lastModifiedDate":"2023-10-17"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":151,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":152,"author":{"gitId":"KenCheung18"},"content":" case \"help\":","lastModifiedDate":"2023-10-16"},{"lineNumber":153,"author":{"gitId":"KenCheung18"},"content":" new UsageInstructions(ui).getHelp();","lastModifiedDate":"2023-10-16"},{"lineNumber":154,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-16"},{"lineNumber":155,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":156,"author":{"gitId":"KenCheung18"},"content":" case \"balance\":","lastModifiedDate":"2023-10-17"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-23"},{"lineNumber":158,"author":{"gitId":"KenCheung18"},"content":" new Balance(incomes, expenses).getBalanceMessage();","lastModifiedDate":"2023-10-17"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-23"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-23"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" case \"find\":","lastModifiedDate":"2023-10-23"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" String[] parsedParameters \u003d FindParser.parseFindCommand(fullCommand);","lastModifiedDate":"2023-10-23"},{"lineNumber":164,"author":{"gitId":"limyuhching"},"content":" FindCommand findCommand \u003d new FindCommand(incomes, expenses,","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" parsedParameters[0], parsedParameters[1],","lastModifiedDate":"2023-10-23"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" parsedParameters[2], parsedParameters[3], ui);","lastModifiedDate":"2023-10-23"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-23"},{"lineNumber":168,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"KenCheung18"},"content":" case \"clear_incomes\":","lastModifiedDate":"2023-10-25"},{"lineNumber":171,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"KenCheung18"},"content":" new ClearIncomes(incomes).clearAllIncomes();","lastModifiedDate":"2023-10-25"},{"lineNumber":173,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"KenCheung18"},"content":" case \"clear_expenses\":","lastModifiedDate":"2023-10-25"},{"lineNumber":177,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":178,"author":{"gitId":"KenCheung18"},"content":" new ClearExpenses(expenses).clearAllExpenses();","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":180,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"KenCheung18"},"content":" case \"clear_all\":","lastModifiedDate":"2023-10-25"},{"lineNumber":183,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":184,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes, expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-25"},{"lineNumber":185,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":186,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":188,"author":{"gitId":"limyuhching"},"content":" case \"edit_income\":","lastModifiedDate":"2023-10-26"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"limyuhching"},"content":" new EditIncomeCommand(incomes, fullCommand).execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-26"},{"lineNumber":193,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":194,"author":{"gitId":"limyuhching"},"content":" case \"edit_expense\":","lastModifiedDate":"2023-10-26"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"limyuhching"},"content":" new EditExpenseCommand(expenses, fullCommand).execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-26"},{"lineNumber":199,"author":{"gitId":"limyuhching"},"content":" case \"list_currencies\":","lastModifiedDate":"2023-10-27"},{"lineNumber":200,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showSupportedCurrencies();","lastModifiedDate":"2023-10-27"},{"lineNumber":201,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-27"},{"lineNumber":202,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":203,"author":{"gitId":"limyuhching"},"content":" case \"list_exchange_rates\":","lastModifiedDate":"2023-10-27"},{"lineNumber":204,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showExchangeRates();","lastModifiedDate":"2023-10-27"},{"lineNumber":205,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-27"},{"lineNumber":206,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"limyuhching"},"content":" case \"update_exchange_rate\":","lastModifiedDate":"2023-10-27"},{"lineNumber":208,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":209,"author":{"gitId":"limyuhching"},"content":" Command c \u003d new UpdateExchangeRateCommand(fullCommand, exchangeRateFileHandler);","lastModifiedDate":"2023-10-31"},{"lineNumber":210,"author":{"gitId":"limyuhching"},"content":" c.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":211,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":212,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-27"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" default:","lastModifiedDate":"2023-10-11"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid command. Please try again.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" + \"\\nType \u0027help\u0027 to see the list of commands available.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" private void saveData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":220,"author":{"gitId":"KenCheung18"},"content":" save.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-25"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":224,"author":{"gitId":"-"},"content":" public static void main(String[] args) {","lastModifiedDate":"2023-10-09"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" new Duke().run();","lastModifiedDate":"2023-10-11"},{"lineNumber":226,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" public int getIncomesSize() {","lastModifiedDate":"2023-10-31"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" return this.incomes.size();","lastModifiedDate":"2023-10-31"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" public int getExpensesSize() {","lastModifiedDate":"2023-10-31"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" return this.expenses.size();","lastModifiedDate":"2023-10-31"},{"lineNumber":234,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":236,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"limyuhching":57,"bljhty":113,"Hongzhii":9,"KenCheung18":46,"-":11}},{"path":"src/main/java/seedu/duke/commands/Balance.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * The `Balance` class represents a financial balance calculator","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" * that calculates the balance between income and expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":" * It takes a list of income and expense records as input and provides methods to calculate and display the balance.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"public class Balance {","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" private final ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" private final ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" public Balance(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses) {","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" * Calculates the financial balance by subtracting the total expenses from the total income.","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * @return The calculated financial balance.","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" public double getBalance() {","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" double totalIncome \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" double totalExpense \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" for (Income income : incomes) {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" totalIncome +\u003d income.getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" for (Expense expense : expenses) {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" totalExpense +\u003d expense.getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" return totalIncome - totalExpense;","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" * Prints a message to the console displaying the calculated financial balance.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" public void getBalanceMessage() {","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Balance: \" + getBalance());","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"KenCheung18":45}},{"path":"src/main/java/seedu/duke/commands/ClearAll.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * The ClearAll class is responsible for clearing both the list of incomes and expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" * It provides a method to clear all incomes and expenses from the corresponding list.","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"public class ClearAll {","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" * Constructs a ClearAll object with the given lists of incomes and expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The list of incomes to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The list of expenses to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" public ClearAll(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses) {","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" * Clears all incomes and expenses from their respective lists and prints a message to confirm the action.","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" public void clearAllIncomeAndExpense() {","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" incomes.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" expenses.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Both income and expense lists cleared\");","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":35}},{"path":"src/main/java/seedu/duke/commands/ClearExpenses.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":" * The ClearExpenses class is responsible for clearing the list of expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * It provides a method to clear all expenses from the list.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"public class ClearExpenses {","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" * Constructs a ClearExpenses object with the given list of expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The list of expenses to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" public ClearExpenses(ArrayList\u003cExpense\u003e expenses) {","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * Clears all expenses from the list and prints a message to confirm the action.","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" public void clearAllExpenses(){","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" expenses.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"You have cleared the expense list\");","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":30}},{"path":"src/main/java/seedu/duke/commands/ClearIncomes.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":" * The ClearIncomes class is responsible for clearing the list of incomes.","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * It provides a method to clear all incomes from the list.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"public class ClearIncomes {","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" * Constructs a ClearIncomes object with the given list of incomes.","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The list of incomes to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" public ClearIncomes(ArrayList\u003cIncome\u003e incomes) {","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * Clears all incomes from the list and prints a message to confirm the action.","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" public void clearAllIncomes() {","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" incomes.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"You have cleared the income list\");","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"KenCheung18":32}},{"path":"src/main/java/seedu/duke/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":" * Represents the abstract class for all commands.","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":" * This class serves as a blueprint for all specific command classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"limyuhching":2,"bljhty":16}},{"path":"src/main/java/seedu/duke/commands/DeleteExpenseCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":" * The `DeleteExpenseCommand` class represents a command to delete an expense record from a list of expenses.","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" * It extends the `Commands` class and is used to manage expense records in the application.","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"public class DeleteExpenseCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * Constructs a `DeleteExpenseCommand` object. This class does not have any specific constructor logic.","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" public DeleteExpenseCommand() {","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" * Executes the `DeleteExpenseCommand` to remove an expense record from the list of expenses.","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" * @param expenses The list of expense records to be modified.","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" * @param fullcommand The full command entered by the user, including the index of the expense to be deleted.","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" * @param ui The user interface for displaying messages.","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is a problem with the command execution, such as missing arguments,","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" * an invalid index, or a non-existent expense record.","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" public void execute(ArrayList\u003cExpense\u003e expenses, String fullcommand, Ui ui) throws KaChinnnngException {","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" int index \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullcommand.split(\" \", 3);","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" index \u003d Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" Expense removedExpense \u003d expenses.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" expenses.remove(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. This expense record has been deleted:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" System.out.println(removedExpense);","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument\");","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Expense \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"limyuhching":45}},{"path":"src/main/java/seedu/duke/commands/DeleteIncomeCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":" * The DeleteIncomeCommand class is responsible for deleting an income record from the list of incomes.","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"public class DeleteIncomeCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" * Constructs a DeleteIncomeCommand object.","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" public DeleteIncomeCommand() {","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" * Executes the DeleteIncomeCommand to remove an income record from the list of incomes.","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" * @param incomes The list of income records to be modified.","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" * @param fullcommand The full command entered by the user.","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" * @param ui The user interface for displaying messages.","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is a problem with the command execution, such as missing arguments,","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" * invalid index, or a non-existent income record.","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" public void execute(ArrayList\u003cIncome\u003e incomes, String fullcommand, Ui ui) throws KaChinnnngException {","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" int index \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullcommand.split(\" \", 3);","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" index \u003d Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" Income removedIncome \u003d incomes.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" incomes.remove(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. This income record has been deleted:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" System.out.println(removedIncome);","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument\");","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Income \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"limyuhching":45}},{"path":"src/main/java/seedu/duke/commands/EditExpenseCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public class EditExpenseCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":" private static final String EXPECTED_FORMAT \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" \"edit expense \u003cindex\u003e /cat \u003ccategory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" \"/date \u003cDD/MM/YYYY\u003e /amt [currency] \u003camount\u003e\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" int index;","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" * Constructs an EditExpenseCommand with the specified expense records and full command.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" * @param expenses The ArrayList of Expense objects containing expense records.","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string entered by the user.","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in the command creation, such as missing arguments.","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" public EditExpenseCommand(ArrayList\u003cExpense\u003e expenses, String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" this.fullCommand \u003d fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" * Executes the edit expense command. It parses the user input, retrieves the new expense information,","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * updates the expense record, and prints the changes.","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in executing the command, such as missing arguments,","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" * incorrect index, or if the specified expense record does not exist.","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" assert expenses !\u003d null : \"Incomes ArrayList must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" assert fullCommand !\u003d null : \"Full command string must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" index \u003d getIndex(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" ExpenseManager expenseCommand \u003d new ExpenseManager(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" expenseCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" Expense newExpense \u003d expenseCommand.getNewExpense();","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" Expense removedExpense \u003d expenses.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" expenses.set(index, newExpense);","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. The expense record you\u0027ve specified has been changed:\");","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Before: \" + removedExpense);","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"After: \" + newExpense);","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Expense \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" * Extracts and returns the index from the full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" * @return The index of the income record to be edited.","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in extracting the index, such as missing arguments","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" * or if the index is not a valid integer.","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" private int getIndex(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullCommand.split(\" \", 4);","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" assert tokens.length \u003e\u003d 4 : \"Command must have at least 4 tokens\";","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" return Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":74}},{"path":"src/main/java/seedu/duke/commands/EditIncomeCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public class EditIncomeCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" private static final String EXPECTED_FORMAT \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" \"edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cDD/MM/YYYY\u003e /amt [currency] \u003camount\u003e\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" int index;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" * Constructs an EditIncomeCommand with the specified income records and full command.","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" * @param incomes The ArrayList of Income objects containing income records.","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string entered by the user.","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" public EditIncomeCommand(ArrayList\u003cIncome\u003e incomes, String fullCommand) {","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" this.fullCommand \u003d fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * Executes the edit income command. It parses the user input, retrieves the new income information,","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" * updates the income record, and prints the changes.","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in executing the command, such as missing arguments,","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" * incorrect index, or if the specified income record does not exist.","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" assert incomes !\u003d null : \"Incomes ArrayList must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" assert fullCommand !\u003d null : \"Full command string must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" index \u003d getIndex(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" IncomeManager incomeCommand \u003d new IncomeManager(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" incomeCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" Income newIncome \u003d incomeCommand.getNewIncome();","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" Income removedIncome \u003d incomes.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" incomes.set(index, newIncome);","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. The income record you\u0027ve specified has been changed:\");","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Before: \" + removedIncome);","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"After: \" + newIncome);","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Income \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" * Extracts and returns the index from the full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" * @return The index of the income record to be edited.","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in extracting the index, such as missing arguments","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" * or if the index is not a valid integer.","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" private int getIndex(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullCommand.split(\" \", 4);","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" assert tokens.length \u003e\u003d 4 : \"Command must have at least 4 tokens\";","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" return Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":75}},{"path":"src/main/java/seedu/duke/commands/ExpenseLister.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Represents the command that when executed, lists all expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * This class is a child class of the Command class.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"public class ExpenseLister extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":" private final ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * Constructor for ExpenseLister.","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param expenses","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param ui","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" public ExpenseLister(ArrayList\u003cExpense\u003e expenses, Ui ui) {","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" public void execute() {","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" listExpenses();","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" * This method lists all incomes.","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" public void listExpenses() {","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" if (expenses.isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"You have no recorded expenses.\");","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" return;","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"Here are your expenses:\");","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" for (int i \u003d 0; i \u003c expenses.size(); i++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" System.out.println((i + 1) + \". \" + expenses.get(i).toString());","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"limyuhching":1,"Hongzhii":52}},{"path":"src/main/java/seedu/duke/commands/ExpenseManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.parser.ExpenseParser;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * This is the class that manages the creation of new expense","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"public class ExpenseManager extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private final String details;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":" private Expense newExpense;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" public ExpenseManager(String details) {","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" this.details \u003d details;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * This method is used to execute the command","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d extractExpenseFields(details);","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" newExpense \u003d ExpenseParser.parseExpense(expenseFields);","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * This method returns new expense created","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" public Expense getNewExpense() {","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" return newExpense;","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" * This method extracts the fields of the expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" * @param details String containing the details of the expense","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" * @return expenseFields HashMap containing the fields of the income","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" private HashMap\u003cString, String\u003e extractExpenseFields(String details) throws KaChinnnngException{","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" HashMap\u003cString,String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" String[] parts \u003d details.split(\"/cat | /type | /de | /date | /amt \");","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" if(parts.length !\u003d 6) {","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Missing fields detected\");","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, parts[1].trim());","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, parts[2].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, parts[3].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, parts[4].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, parts[5].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"Hongzhii"},"content":" return expenseFields;","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"limyuhching":2,"Hongzhii":60}},{"path":"src/main/java/seedu/duke/commands/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.time.YearMonth;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" * Represents a command to find and display financial records (either incomes or expenses) based on specific criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" * The criteria include type (income/expense), category, description, and date.","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" * This command supports searching by a specific date or by a month. If a date isn\u0027t provided, it will not be used","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" * as a filter. Similarly, if the category or description isn\u0027t provided, they won\u0027t be used as filters.","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" private static final List\u003cString\u003e VALID_EXPENSE_CAT \u003d Arrays.asList(\"food\", \"transport\", \"utilities\");","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" private final ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" private final ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" private final String type;","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" private final String category;","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" private final String description;","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" private final LocalDate date;","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" private boolean isSearchByMonth \u003d false;","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" if(!dir.mkdirs()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/FindCommand.log\", true);","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" * Constructs a new FindCommand with the given criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" * @param incomes The list of incomes to search from.","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" * @param expenses The list of expenses to search from.","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" * @param type The type of financial record to search for (either \"income\" or \"expense\").","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" * @param category The category to filter the results by.","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" * @param description The description to filter the results by.","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" * @param dateString The date (or month) to filter the results by. Expected format: dd/MMM/yyyy.","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" * @param ui The UI component to display results.","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If an invalid type is provided or if there\u0027s an error parsing the date.","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" public FindCommand(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses, String type,","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" String category, String description, String dateString, Ui ui) throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" if (type \u003d\u003d null || !type.equalsIgnoreCase(\"income\") \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" !type.equalsIgnoreCase(\"expense\")) {","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid type. Please use \u0027income\u0027 or \u0027expense\u0027.\");","lastModifiedDate":"2023-10-24"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" if (\"expense\".equalsIgnoreCase(type) \u0026\u0026 category !\u003d null \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" !VALID_EXPENSE_CAT.contains(category.toLowerCase())) {","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid expense category provided! Allowed categories are: \"","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" + VALID_EXPENSE_CAT);","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" this.type \u003d type;","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" this.category \u003d category;","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" this.date \u003d parseDate(dateString); // Convert date string to LocalDate","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, String.format(\"FindCommand initialised with type: %s\", type));","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" * Executes the find command. Searches through the provided list of incomes or expenses and displays","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" * matching results based on the given criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If there\u0027s an error during execution, such as an invalid type.","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" LOGGER.info(\"Executing FindCommand\");","lastModifiedDate":"2023-10-24"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" assert incomes !\u003d null : \"incomes should not be null\";","lastModifiedDate":"2023-10-24"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" assert expenses !\u003d null : \"expenses should not be null\";","lastModifiedDate":"2023-10-24"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cExpense\u003e matchingExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cIncome\u003e matchingIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" if (\"expense\".equalsIgnoreCase(type)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" for (Expense e : expenses) {","lastModifiedDate":"2023-10-23"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" if (matchesCriteria(e)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" matchingExpenses.add(e);","lastModifiedDate":"2023-10-23"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, String.format(\"Found %d matching expenses\", matchingExpenses.size()));","lastModifiedDate":"2023-10-26"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" if (matchingExpenses.isEmpty()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"No matching expenses found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" ui.showMatchingExpenses(matchingExpenses);","lastModifiedDate":"2023-10-29"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" } else if (\"income\".equalsIgnoreCase(type)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" for (Income i : incomes) {","lastModifiedDate":"2023-10-23"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" if (matchesCriteria(i)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" matchingIncomes.add(i);","lastModifiedDate":"2023-10-23"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO,String.format(\"Found %d matching incomes\", matchingIncomes.size()));","lastModifiedDate":"2023-10-26"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" if (matchingIncomes.isEmpty()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"No matching incomes found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" ui.showMatchingIncomes(matchingIncomes);","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-24"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid type: \" + type);","lastModifiedDate":"2023-10-24"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" * Determines if a given date matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" * @param dateToCheck The date to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" * @return True if the date matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" private boolean matchesDate(LocalDate dateToCheck) {","lastModifiedDate":"2023-10-24"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" if (this.date !\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" if (isSearchByMonth) {","lastModifiedDate":"2023-10-23"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" return dateToCheck.getMonthValue() \u003d\u003d this.date.getMonthValue()","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" \u0026\u0026 dateToCheck.getYear() \u003d\u003d this.date.getYear();","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" return dateToCheck.isEqual(this.date);","lastModifiedDate":"2023-10-24"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" return true; // If this.date is null, then any date matches the criteria","lastModifiedDate":"2023-10-24"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" * Determines if a given category matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" * @param categoryToCheck The category to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" * @return True if the category matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" private boolean matchesCategory(String categoryToCheck) {","lastModifiedDate":"2023-10-24"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" return this.category \u003d\u003d null || (categoryToCheck !\u003d null \u0026\u0026 categoryToCheck.equalsIgnoreCase(this.category));","lastModifiedDate":"2023-10-24"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" * Determines if a given description matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" * The description matches if it contains all the keywords specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" * If no description is specified in the command, then any description matches the criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" * @param descriptionToCheck The description to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" * @return True if the description matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" private boolean matchesDescription(String descriptionToCheck) {","lastModifiedDate":"2023-10-24"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" if (this.description !\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" String[] keywords \u003d this.description.split(\"\\\\s+\");","lastModifiedDate":"2023-10-23"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" for (String keyword : keywords) {","lastModifiedDate":"2023-10-23"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" if (!descriptionToCheck.toLowerCase().contains(keyword.toLowerCase())) {","lastModifiedDate":"2023-10-24"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" return false;","lastModifiedDate":"2023-10-24"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":" return true;","lastModifiedDate":"2023-10-23"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" * Determines if a given expense matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" * @param e The expense to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" * @return True if the expense matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" private boolean matchesCriteria(Expense e) {","lastModifiedDate":"2023-10-24"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" return matchesDate(e.getDate()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":" matchesCategory(e.getCategory()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" matchesDescription(e.getDescription()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" e.getAmount() !\u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" * Determines if a given income matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":" * @param i The income to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" * @return True if the income matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" private boolean matchesCriteria(Income i) {","lastModifiedDate":"2023-10-24"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" return matchesDate(i.getDate()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" matchesCategory(i.getCategory()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":" matchesDescription(i.getDescription()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" i.getAmount() !\u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" * Converts a date string into a LocalDate object. Supports full date strings and month names.","lastModifiedDate":"2023-10-26"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":" * @param dateString Date as a string in the format dd/MMM/yyyy or as a month name.","lastModifiedDate":"2023-10-26"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" * @return LocalDate representation of the provided dateString.","lastModifiedDate":"2023-10-26"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If the date string is in an invalid format.","lastModifiedDate":"2023-10-26"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" private LocalDate parseDate(String dateString) throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":" if (dateString \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" return null;","lastModifiedDate":"2023-10-23"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterDayMMM \u003d DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterDayMM \u003d DateTimeFormatter.ofPattern(\"dd/MM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterMonthMM \u003d DateTimeFormatter.ofPattern(\"MM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterMonthMMM \u003d DateTimeFormatter.ofPattern(\"MMM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" LocalDate parsedDate \u003d null;","lastModifiedDate":"2023-10-24"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d LocalDate.parse(dateString, formatterDayMMM);","lastModifiedDate":"2023-10-29"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e1) {","lastModifiedDate":"2023-10-29"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d LocalDate.parse(dateString, formatterDayMM);","lastModifiedDate":"2023-10-29"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e2) {","lastModifiedDate":"2023-10-29"},{"lineNumber":247,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":248,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d YearMonth.parse(dateString, formatterMonthMM).atDay(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":249,"author":{"gitId":"bljhty"},"content":" isSearchByMonth \u003d true;","lastModifiedDate":"2023-10-23"},{"lineNumber":250,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e3) {","lastModifiedDate":"2023-10-29"},{"lineNumber":251,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":252,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d YearMonth.parse(dateString, formatterMonthMMM).atDay(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":253,"author":{"gitId":"bljhty"},"content":" isSearchByMonth \u003d true;","lastModifiedDate":"2023-10-29"},{"lineNumber":254,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e4) {","lastModifiedDate":"2023-10-29"},{"lineNumber":255,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Failed to parse date \" + dateString, e4);","lastModifiedDate":"2023-10-29"},{"lineNumber":256,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid date format. \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":257,"author":{"gitId":"bljhty"},"content":" \"Please use formats like 20/Oct/2023, 20/10/2023, 10/2023, or Oct/2023.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":258,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":259,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":260,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":261,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":262,"author":{"gitId":"bljhty"},"content":" return parsedDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":263,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":264,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"limyuhching":1,"bljhty":263}},{"path":"src/main/java/seedu/duke/commands/IncomeLister.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * Represents the command that when executed, lists all incomes.","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * This class is a child class of the Command class.","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"public class IncomeLister extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(IncomeLister.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" private final ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/IncomeLister.log\", true);","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" * Constructor for IncomeLister.","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" * @param incomes ArrayList of incomes","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" * @param ui Instance of Ui","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" public IncomeLister(ArrayList\u003cIncome\u003e incomes, Ui ui) {","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" assert incomes !\u003d null : \"incomes should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" assert ui !\u003d null : \"ui should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, (\"Initialised IncomeLister\"));","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void execute() {","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" listIncomes();","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" * This method lists all incomes.","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" // Updated method name to follow Java naming conventions","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" public void listIncomes() {","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" if (incomes.isEmpty()) {","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"You have no recorded incomes.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" return;","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"Here are your incomes:\");","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" for (int i \u003d 0; i \u003c incomes.size(); i++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" ui.printMessage((i + 1) + \". \" + incomes.get(i).toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, (\"Incomes listed successfully\"));","lastModifiedDate":"2023-10-19"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"limyuhching":1,"bljhty":86}},{"path":"src/main/java/seedu/duke/commands/IncomeManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.parser.IncomeParser;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Represents the class that manages the creation of a new income.","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * This class serves as a blueprint for all specific income creation classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"public class IncomeManager extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" // Logger instance to log events and issues that occur during the execution of this class.","lastModifiedDate":"2023-10-19"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(IncomeManager.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" private final String details;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" private Income newIncome;","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" static{","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/IncomeManager.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" public IncomeManager(String details) {","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assert details !\u003d null : \"details should not be null\"; // Ensure that details is not null","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" this.details \u003d details;","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d extractIncomeFields(details);","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" newIncome \u003d IncomeParser.parseIncome(incomeFields);","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, \"successful parsing of income\"); // logging successful parsing of income","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" * This method returns the new income created.","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" * @return newIncome","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" public Income getNewIncome() {","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" return newIncome;","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" * This method extracts the fields of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" * @param details String containing the details of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" * @return incomeFields HashMap containing the fields of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" private HashMap\u003cString, String\u003e extractIncomeFields(String details) throws KaChinnnngException {","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" assert details !\u003d null : \"details should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" // Split the details string based on the field keywords","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" String[] parts \u003d details.split(\"/de|/date|/amt\");","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" // Check if all fields are present in the string","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" if (parts.length !\u003d 4) {","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Missing or out-of-order fields detected in income details: \" + details);","lastModifiedDate":"2023-10-23"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Expected fields `/de`, `/date`, and \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" \"`/amt` are missing or improperly formatted.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" // Populate the HashMap with extracted fields","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, parts[1].trim());","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, parts[2].trim());","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, parts[3].trim());","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" return incomeFields;","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"limyuhching":1,"bljhty":96}},{"path":"src/main/java/seedu/duke/commands/KaChinnnngException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":" * Represents the exception thrown when there is an error in the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"public class KaChinnnngException extends Exception{","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":" public KaChinnnngException(String message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":" super(message);","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bljhty":10}},{"path":"src/main/java/seedu/duke/commands/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" * The `ListCommand` class is responsible for displaying a list of income and expense records,","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" * along with the total income, total expenses, and the total balance.","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" * It extends the `Commands` class and is used to provide a summary of financial records to the user.","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" private Ui ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private double totalIncome;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private double totalExpenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" * Constructs a `ListCommand` object with the specified income and expense lists and a user interface.","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" * @param incomes The list of income records to be displayed.","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" * @param expenses The list of expense records to be displayed.","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" * @param ui The user interface for displaying messages and financial records.","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" public ListCommand(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses, Ui ui) {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" totalIncome \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" totalExpenses \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" * Executes the `ListCommand` to display a summary of income and expense records,","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" * along with the total balance.","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" public void execute() {","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" if (incomes.isEmpty() \u0026\u0026 expenses.isEmpty()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"You do not have any records.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" return;","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" // Print incomes","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" if (incomes.isEmpty()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"You have no recorded incomes.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Here are your incomes:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" for (int i \u003d 0; i \u003c incomes.size(); i++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" System.out.println((i + 1) + \". \" + incomes.get(i).toString());","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" totalIncome +\u003d incomes.get(i).getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"Total income is: $%.2f.\\n\", totalIncome);","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" System.out.println();","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" // Print expenses","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" if (expenses.isEmpty()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"You have no recorded expenses.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Here are your expenses:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" for (int i \u003d 0; i \u003c expenses.size(); i++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" System.out.println((i + 1) + \". \" + expenses.get(i).toString());","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" totalExpenses +\u003d expenses.get(i).getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"Total expenses is: $%.2f.\\n\", totalExpenses);","lastModifiedDate":"2023-10-17"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"\\nTotal balance is: $%.2f.\\n\", totalIncome - totalExpenses);","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"limyuhching":73}},{"path":"src/main/java/seedu/duke/commands/UpdateExchangeRateCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.storage.ExchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public class UpdateExchangeRateCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" private static final String EXPECTED_FORMAT \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" \"update exchange rate \u003csupported_currency\u003e \u003crate\u003e\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" ExchangeRateFileHandler exchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" String currency;","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" double rate;","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" public UpdateExchangeRateCommand(String fullCommand, ExchangeRateFileHandler exchangeRateFileHandler)","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" this.exchangeRateFileHandler \u003d exchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" String[] args \u003d parse(fullCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" currency \u003d args[0];","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" rate \u003d Double.parseDouble(args[1]);","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" } catch (NumberFormatException | NullPointerException e) {","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Invalid command.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"The SGD/%s rate has been updated to %s.\\n\", currency.toUpperCase(), rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" exchangeRateFileHandler.save(exchangeRateManager.getExchangeRates());","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" private static String[] parse(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" String[] args \u003d fullCommand.split(\" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" if (args.length !\u003d 5) {","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Invalid command.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" return Arrays.copyOfRange(args,3, 5);","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"limyuhching":42}},{"path":"src/main/java/seedu/duke/commands/UsageInstructions.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"public class UsageInstructions {","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":" // Shows a message linking the user to the user guide of our app","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":" private final seedu.duke.ui.Ui ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" * The `UsageInstructions` class provides usage instructions for the application,","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":" * including command formats and a link to the user guide.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" public UsageInstructions(Ui ui) {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" * Displays usage instructions for the application, including command formats and a link to the user guide.","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public void getHelp(){","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" // Shows a message linking the user to the user guide of our app","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" System.out.println(\"You can access our user guide by \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" \"https://docs.google.com/document/d/1BOz_v4eYQ8y7Dje6Jm6nqymi9jmrsb9MAohLCL_sLvI/edit?usp\u003dsharing\\n\");","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" // Displays the various commands that user can use including the respective formats of the commands","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Functions and their format:\\n\");","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Adding an entry: add\\nFormat:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" \"add income /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" \"add expense /cat \u003ccategory\u003e /type \u003ctype\u003e \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" \"/de \u003cdescription\u003e /date \u003cdate\u003e /amt \u003camount\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Listing all entries: list\\nFormat:\\n\" + \"list\\n\" + \"list income\\n\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" \"list expense\\nlist currencies\\nlist exchange rates\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Deleting an entry: delete\\nFormat:\\ndelete income \u003cindex_pos\u003e\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" \"delete expense \u003cindex_pos\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Edit an entry: edit\\nFormat:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" \"edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" \"edit expense \u003cindex\u003e /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" \"/amt [currency] \u003camount\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Check balance of income: balance\\nFormat: \" + \"balance\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Update exchange rate: update exchange rate\\nFormat: \" + \"update exchange rate \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" \"\u003csupported_currency\u003e \u003crate\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Exiting the program: exit\\nFormat: \" + \"exit\");","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bljhty":23,"KenCheung18":23}},{"path":"src/main/java/seedu/duke/financialrecords/ExchangeRateManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.List;","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" * The `ExchangeRateManager` class is responsible for managing exchange rates between the Singapore Dollar (SGD) and","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" * various foreign currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * It provides functionality to update, retrieve, and save exchange rates, as well as convert currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" * The class uses a singleton pattern to ensure a single instance of `ExchangeRateManager` throughout the application.","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" * Exchange rates are stored in a `HashMap`, and the data is read from and saved to a text file.","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateManager {","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private static ExchangeRateManager exchangeRateManager \u003d null;","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private static final List\u003cString\u003e SUPPORTED_CURRENCIES \u003d","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" Arrays.asList(","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" \"MYR\", \"USD\", \"JPY\", \"KRW\", \"EUR\", \"THB\", \"HKD\", \"INR\", \"IDR\",","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" \"AUD\", \"GBP\", \"CNY\", \"CAD\", \"TWD\", \"VND\", \"PHP\"","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" );","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" private HashMap\u003cString, Double\u003e exchangeRates;","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager() {","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" exchangeRates \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" public HashMap\u003cString, Double\u003e getExchangeRates() {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" return exchangeRates;","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" public static List\u003cString\u003e getSupportedCurrencies() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" return SUPPORTED_CURRENCIES;","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" * Gets the singleton instance of `ExchangeRateManager`.","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" * @return The singleton instance of `ExchangeRateManager`.","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" public static ExchangeRateManager getInstance() {","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" if (exchangeRateManager \u003d\u003d null) {","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager \u003d new ExchangeRateManager();","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" return exchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" public double getExchangeRate(String currency) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" if (!SUPPORTED_CURRENCIES.contains(currency)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"This currency is not supported\");","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" return exchangeRates.get(currency);","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" public void clear() {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" exchangeRates \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" * Displays the list of supported currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" public void showSupportedCurrencies() {","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"These are the supported currencies:\");","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" for (String currency : SUPPORTED_CURRENCIES) {","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" System.out.print(currency + \" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" System.out.print(\"\\n\");","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"limyuhching"},"content":" * Displays the exchange rates for supported currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"limyuhching"},"content":" public void showExchangeRates() {","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"limyuhching"},"content":" int count \u003d 0;","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":" for (Map.Entry\u003cString, Double\u003e entry : exchangeRates.entrySet()) {","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"limyuhching"},"content":" String currency \u003d entry.getKey();","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"limyuhching"},"content":" Double rate \u003d entry.getValue();","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"limyuhching"},"content":" if (rate !\u003d null) {","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"limyuhching"},"content":" if (count \u003d\u003d 0) {","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Here are the exchange rate(s):\");","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"%s, %s\\n\", currency, rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"limyuhching"},"content":" count +\u003d 1;","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"limyuhching"},"content":" if (count \u003d\u003d 0) {","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"No exchange rate has been updated\");","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":99,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":100,"author":{"gitId":"limyuhching"},"content":" * Displays a message about currency conversion for a specific currency.","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"limyuhching"},"content":" * @param currency The currency to convert.","lastModifiedDate":"2023-10-27"},{"lineNumber":103,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":104,"author":{"gitId":"limyuhching"},"content":" public void showCurrencyConversionMessage(String currency) {","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":106,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-27"},{"lineNumber":107,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"We have converted %s to SGD at the SGD/%s rate of %s\\n\",","lastModifiedDate":"2023-10-27"},{"lineNumber":108,"author":{"gitId":"limyuhching"},"content":" currency, currency, exchangeRates.get(currency));","lastModifiedDate":"2023-10-27"},{"lineNumber":109,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":110,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":111,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":112,"author":{"gitId":"limyuhching"},"content":" * Converts an amount from a foreign currency to SGD using the specified currency\u0027s exchange rate.","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"limyuhching"},"content":" * @param currency The currency to convert from.","lastModifiedDate":"2023-10-27"},{"lineNumber":115,"author":{"gitId":"limyuhching"},"content":" * @param amount The amount to convert.","lastModifiedDate":"2023-10-27"},{"lineNumber":116,"author":{"gitId":"limyuhching"},"content":" * @return The converted amount in SGD.","lastModifiedDate":"2023-10-27"},{"lineNumber":117,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If the currency is not supported or the exchange rate is not available.","lastModifiedDate":"2023-10-27"},{"lineNumber":118,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":119,"author":{"gitId":"limyuhching"},"content":" public double convertCurrency(String currency, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":120,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-27"},{"lineNumber":121,"author":{"gitId":"limyuhching"},"content":" if (!SUPPORTED_CURRENCIES.contains(currency)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":122,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"This currency is not supported\");","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"limyuhching"},"content":" } else if (exchangeRates.get(currency) \u003d\u003d null) {","lastModifiedDate":"2023-10-27"},{"lineNumber":124,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Please update the exchange rate for \" + currency);","lastModifiedDate":"2023-10-27"},{"lineNumber":125,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":126,"author":{"gitId":"limyuhching"},"content":" return amount / exchangeRates.get(currency);","lastModifiedDate":"2023-10-27"},{"lineNumber":127,"author":{"gitId":"limyuhching"},"content":" };","lastModifiedDate":"2023-10-27"},{"lineNumber":128,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":129,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":130,"author":{"gitId":"limyuhching"},"content":" * Updates the exchange rate for a specific currency.","lastModifiedDate":"2023-10-27"},{"lineNumber":131,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":132,"author":{"gitId":"limyuhching"},"content":" * @param currency The currency to update.","lastModifiedDate":"2023-10-27"},{"lineNumber":133,"author":{"gitId":"limyuhching"},"content":" * @param rate The new exchange rate.","lastModifiedDate":"2023-10-27"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If the currency is not supported or the rate is invalid.","lastModifiedDate":"2023-10-27"},{"lineNumber":135,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":136,"author":{"gitId":"limyuhching"},"content":" public void updateExchangeRate(String currency, double rate) throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":137,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-27"},{"lineNumber":138,"author":{"gitId":"limyuhching"},"content":" if (!SUPPORTED_CURRENCIES.contains(currency)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":139,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"This currency is not supported\");","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":141,"author":{"gitId":"limyuhching"},"content":" if (rate \u003e 3000000.00 || rate \u003c 0.001) {","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Fail to update exchange rate, \" +","lastModifiedDate":"2023-10-27"},{"lineNumber":143,"author":{"gitId":"limyuhching"},"content":" \"the exchange rate is not between 0.001 and 3000000\");","lastModifiedDate":"2023-10-27"},{"lineNumber":144,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":145,"author":{"gitId":"limyuhching"},"content":" exchangeRates.put(currency, rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":146,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":147,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":148,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"limyuhching":148}},{"path":"src/main/java/seedu/duke/financialrecords/Expense.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-13"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":" * Implementation of the Expense class","lastModifiedDate":"2023-10-13"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":" * Basic expense class inherits from FinancialRecord and does not include any additional attributes","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Attribute \"amount\" contains a negative double which will make it easier to tally up the net total at the end","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":"public class Expense extends FinancialRecord {","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" protected String category;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" public Expense(String description, LocalDate date, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" public String getCategory() {","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" return category;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" return \"Expense: \" + getDescription() +","lastModifiedDate":"2023-10-12"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":7,"Hongzhii":20}},{"path":"src/main/java/seedu/duke/financialrecords/FinancialRecord.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * Represents the abstract class for all financial records.","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * This class serves as a blueprint for all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public abstract class FinancialRecord{","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" // Logger instance to log events and issues that occur during the execution of this class.","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FinancialRecord.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" protected String description;","lastModifiedDate":"2023-10-12"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" protected LocalDate date;","lastModifiedDate":"2023-10-12"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" protected double amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" * Constructs a new financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" * @param description Description of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" * @param date Date of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" * @param amount Amount of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there are validation errors.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" public FinancialRecord(String description, LocalDate date, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" assert description !\u003d null : \"description should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" assert date !\u003d null : \"date should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" if (description.trim().isEmpty()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" LOGGER.warning(\"Description is empty\");","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Description cannot be empty!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" if (amount \u003c 0) {","lastModifiedDate":"2023-10-12"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" LOGGER.warning(\"Amount is negative\");","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Amount cannot be negative!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" if (date.isAfter(LocalDate.now())) {","lastModifiedDate":"2023-10-12"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" LOGGER.warning(\"Date is in the future\");","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Date cannot be in the future!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-12"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" this.date \u003d date;","lastModifiedDate":"2023-10-12"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" this.amount \u003d amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" * Returns the category of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" * @return Category of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" public String getCategory() {","lastModifiedDate":"2023-10-12"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" return \"\";","lastModifiedDate":"2023-10-12"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" * This method is used to get the description of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" * @return String containing the description of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public String getDescription() {","lastModifiedDate":"2023-10-12"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" return description;","lastModifiedDate":"2023-10-12"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" * This method is used to get the date of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" * @return LocalDate containing the date of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public LocalDate getDate() {","lastModifiedDate":"2023-10-12"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" return date;","lastModifiedDate":"2023-10-12"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" * This method is used to get the date of the financial record in a string format.","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" * @return String containing the date of the financial record in a string format","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" public String getDateString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\");","lastModifiedDate":"2023-10-12"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" return date.format(formatter);","lastModifiedDate":"2023-10-12"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" * This method is used to get the amount of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" * @return double containing the amount of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" public double getAmount() {","lastModifiedDate":"2023-10-12"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" return amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" * Sets the description of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" * @param description Description of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if description is empty or null.","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" public void setDescription(String description) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" assert description !\u003d null : \"description should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" if (description.trim().isEmpty()) {","lastModifiedDate":"2023-10-12"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Description cannot be empty!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-12"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" * This method is used to set the date of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" * @param date LocalDate containing the date of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" public void setDate(LocalDate date) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" assert date !\u003d null : \"date should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" this.date \u003d date;","lastModifiedDate":"2023-10-12"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" * This method is used to set the amount of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * @param amount double containing the amount of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" public void setAmount(double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" assert amount \u003e\u003d 0 : \"amount should not be negative\";","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" this.amount \u003d amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" * Provides a string representation of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" * @return String representation of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" public String toString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" return \"\";","lastModifiedDate":"2023-10-12"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":148}},{"path":"src/main/java/seedu/duke/financialrecords/Food.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Food class that inherits from expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * Represents food expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class Food extends Expense {","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private MealType mealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" * Food class constructor","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * @param description","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" * @param date","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param amount","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param mealType","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public Food(String description, LocalDate date, double amount, MealType mealType) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" this.category \u003d \"food\";","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" this.mealType \u003d mealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" * Returns meal type","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" public MealType getMealType() {","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" return mealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" * Returns a string that contains all the information on the expense record","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" return \"Food Expense (\" + getMealType() + \"): \" + getDescription() +","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"bljhty":1,"Hongzhii":45}},{"path":"src/main/java/seedu/duke/financialrecords/Income.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * Implementation of the Income class","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * Basic income class inherits from FinancialRecord and does not include any additional attributes","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public class Income extends FinancialRecord {","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" // Logger instance to log events and issues that occur during the execution of this class.","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(Income.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-19"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/Income.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * This method is used to create a new financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record creation classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" * @param description String containing the description of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" * @param date LocalDate containing the date of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" * @param amount double containing the amount of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" public Income(String description, LocalDate date, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-12"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO,(\"Income created with description: \" +","lastModifiedDate":"2023-10-19"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" description + \" date: \" + date + \" amount: \" + amount));","lastModifiedDate":"2023-10-19"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" * This method is used to get the category of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" * @return String containing the category of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-12"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" public String toString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" return \"Income: \" + getDescription() + ","lastModifiedDate":"2023-10-12"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" \" | Date: \" + getDateString()+ \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-12"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":64}},{"path":"src/main/java/seedu/duke/financialrecords/Transport.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Transport class that inherits from expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * Represents transportation expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class Transport extends Expense {","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private TransportationType transportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" * Transport class constructor","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * @param description","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" * @param date","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param amount","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param transportationType","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public Transport(String description, LocalDate date, double amount,","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" TransportationType transportationType) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" this.transportationType \u003d transportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" this.category \u003d \"Transport\";","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * Returns transportation type","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" public TransportationType getTransportationType() {","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" return transportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" * Returns a string that contains all the information on the expense record","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" return \"Transportation Expense (\" + getTransportationType() + \"): \" + getDescription() +","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"bljhty":1,"Hongzhii":46}},{"path":"src/main/java/seedu/duke/financialrecords/Utilities.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Utilities class that inherits from expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * Represents utility expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class Utilities extends Expense {","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private UtilityType utilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" * Utilities class constructor","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * @param description","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" * @param date","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param amount","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param utilityType","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public Utilities(String description, LocalDate date, double amount,","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" UtilityType utilityType) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" this.utilityType \u003d utilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" this.category \u003d \"Utilities\";","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * Returns utility type","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" public UtilityType getUtilityType() {","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" return utilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" * Returns a string that contains all the information on the expense record","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" return \"Utilities Expense(\" + getUtilityType() + \"): \" + getDescription() +","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"bljhty":1,"Hongzhii":46}},{"path":"src/main/java/seedu/duke/financialrecords/expensetypes/MealType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords.expensetypes;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Enum class to represent meal types.","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"public enum MealType {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":" UNDEFINED, BREAKFAST, LUNCH, DINNER","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"Hongzhii":8}},{"path":"src/main/java/seedu/duke/financialrecords/expensetypes/TransportationType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords.expensetypes;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Enum class that represents all transportation types.","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"public enum TransportationType {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":" UNDEFINED, TRAIN, BUS, TAXI, FUEL","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"Hongzhii":8}},{"path":"src/main/java/seedu/duke/financialrecords/expensetypes/UtilityType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords.expensetypes;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Enum class that represents all utility types.","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"public enum UtilityType {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":" UNDEFINED, WATER, ELECTRICITY, GAS","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"Hongzhii":8}},{"path":"src/main/java/seedu/duke/parser/ExpenseParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":"import java.time.format.ResolverStyle;","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":"public class ExpenseParser {","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" public static final String CATEGORY_FIELD \u003d \"ca\";","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" public static final String TYPE_FIELD \u003d \"ty\";","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" public static final String DESCRIPTION_FIELD \u003d \"de\";","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public static final String DATE_FIELD \u003d \"da\";","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" public static final String AMOUNT_FIELD \u003d \"am\";","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" public static final String INDEX_FIELD \u003d \"in\";","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" public static LocalDate parseDate(String expenseDateString) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" LocalDate expenseDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MM/uuuu\")","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" .withResolverStyle(ResolverStyle.STRICT);","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" expenseDate \u003d LocalDate.parse(expenseDateString, formatter);","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" } catch (DateTimeParseException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid date in the format dd/MM/yyyydon\");","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" if (expenseDate.isAfter(LocalDate.now())) {","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Please enter a date that is not in the future\");","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" return expenseDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" public static Expense parseExpense(HashMap\u003cString, String\u003e argumentsByField) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" if (!argumentsByField.containsKey(CATEGORY_FIELD) ||","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(TYPE_FIELD) ||","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(DESCRIPTION_FIELD) ||","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(DATE_FIELD) ||","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(AMOUNT_FIELD)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Missing fields detected\");","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" String expenseCategoryString \u003d argumentsByField.get(CATEGORY_FIELD).toLowerCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" String expenseTypeString \u003d argumentsByField.get(TYPE_FIELD).toLowerCase();","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":" String expenseDescriptionString \u003d argumentsByField.get(DESCRIPTION_FIELD);","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":" String expenseDateString \u003d argumentsByField.get(DATE_FIELD);","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":" String expenseAmountString \u003d argumentsByField.get(AMOUNT_FIELD);","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":" LocalDate expenseDate \u003d parseDate(expenseDateString);","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":" double expenseAmount;","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" if (!isOtherCurrency(expenseAmountString)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"Hongzhii"},"content":" expenseAmount \u003d Double.parseDouble(expenseAmountString);","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" // Convert Currency to SGD","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d expenseAmountString.split(\" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" String currency \u003d tokens[0].trim();","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" expenseAmount \u003d Double.parseDouble(tokens[1].trim());","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" expenseAmount \u003d exchangeRateManager.convertCurrency(currency, expenseAmount);","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showCurrencyConversionMessage(currency);","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"Hongzhii"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Please enter a valid amount\");","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"Hongzhii"},"content":" if (expenseAmount \u003e 999999.99 || expenseAmount \u003c\u003d 0) {","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Expense amount must be between $0.01 and $999999.99\");","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":79,"author":{"gitId":"Hongzhii"},"content":" if (expenseCategoryString.equals(\"food\")) {","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"Hongzhii"},"content":" if (expenseTypeString.equals(\"breakfast\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.BREAKFAST);","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"lunch\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.LUNCH);","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"dinner\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.DINNER);","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"Hongzhii"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.UNDEFINED);","lastModifiedDate":"2023-10-26"},{"lineNumber":88,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseCategoryString.equals(\"transport\")){","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"Hongzhii"},"content":" if (expenseTypeString.equals(\"train\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"Hongzhii"},"content":" TransportationType.TRAIN);","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"bus\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"Hongzhii"},"content":" TransportationType.BUS);","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"taxi\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"Hongzhii"},"content":" TransportationType.TAXI);","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"fuel\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"Hongzhii"},"content":" TransportationType.FUEL);","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"Hongzhii"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"Hongzhii"},"content":" TransportationType.UNDEFINED);","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" } else if (expenseCategoryString.equals(\"utilities\")) {","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"Hongzhii"},"content":" if (expenseTypeString.equals(\"water\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.WATER);","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"electricity\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.ELECTRICITY);","lastModifiedDate":"2023-10-26"},{"lineNumber":111,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"gas\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":112,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.GAS);","lastModifiedDate":"2023-10-26"},{"lineNumber":113,"author":{"gitId":"Hongzhii"},"content":" } else{","lastModifiedDate":"2023-10-26"},{"lineNumber":114,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.UNDEFINED);","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid category\");","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":120,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"Hongzhii"},"content":" public static int getIndex(HashMap\u003cString, String\u003e argumentsByFields) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":122,"author":{"gitId":"Hongzhii"},"content":" if (!argumentsByFields.containsKey(INDEX_FIELD)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Missing index field detected\");","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"Hongzhii"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":126,"author":{"gitId":"Hongzhii"},"content":" return Integer.parseInt(argumentsByFields.get(INDEX_FIELD));","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"Hongzhii"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":128,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Please enter a valid index\");","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":132,"author":{"gitId":"limyuhching"},"content":" private static boolean isOtherCurrency(String amount) {","lastModifiedDate":"2023-10-27"},{"lineNumber":133,"author":{"gitId":"limyuhching"},"content":" return (amount.split(\" \").length \u003e 1);","lastModifiedDate":"2023-10-27"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":135,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"limyuhching":15,"bljhty":4,"Hongzhii":116}},{"path":"src/main/java/seedu/duke/parser/FindParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"public class FindParser {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * Parses the find command input.","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * @param fullCommand The full command string input by the user.","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * @return An array of Strings containing the parsed parameters in the order: TYPE, CATEGORY, DESCRIPTION, DATE.","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If the command format is invalid.","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public static String[] parseFindCommand(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" String[] tokens \u003d fullCommand.split(\" \");","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" String[] parsedParameters \u003d new String[4]; // To store TYPE, CATEGORY, DESCRIPTION, DATE","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" String[] validParameters \u003d {\"/t\", \"/cat\", \"/de\", \"/date\"}; // List of valid parameters","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" for (String token : tokens) {","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" if (token.startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" boolean isValidParam \u003d false;","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" for (String validParam : validParameters) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" if (token.equals(validParam)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" isValidParam \u003d true;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" if (!isValidParam) {","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Unrecognized parameter \\\"\" + token + \"\\\". \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" \"Please refer to the help guide for valid parameters.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/type\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please use /t instead of /type for specifying the type.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/category\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please use /cat instead of /category for specifying the category.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/description\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please use /de instead of /description for specifying the description.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" if (!fullCommand.contains(\"/t\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The /t TYPE field is mandatory.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" int typeIndex \u003d indexOf(tokens, \"/t\");","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" if (typeIndex \u003d\u003d tokens.length - 1 || tokens[typeIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /t TYPE cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" parsedParameters[0] \u003d tokens[typeIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" if(\"income\".equalsIgnoreCase(parsedParameters[0])) {","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/cat\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The /cat CATEGORY field is not applicable for income.\");","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/cat\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" int categoryIndex \u003d indexOf(tokens, \"/cat\");","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" if (categoryIndex \u003d\u003d tokens.length - 1 || tokens[categoryIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /c CATEGORY cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" parsedParameters[1] \u003d tokens[categoryIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/de\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" int descriptionIndex \u003d indexOf(tokens, \"/de\");","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" if (descriptionIndex \u003d\u003d tokens.length - 1 || tokens[descriptionIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /de DESCRIPTION cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" parsedParameters[2] \u003d tokens[descriptionIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/date\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" int dateIndex \u003d indexOf(tokens, \"/date\");","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" if (dateIndex \u003d\u003d tokens.length - 1 || tokens[dateIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /da DATE cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" parsedParameters[3] \u003d tokens[dateIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" // Check that at least one optional field is provided","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" if (parsedParameters[1] \u003d\u003d null \u0026\u0026 parsedParameters[2] \u003d\u003d null \u0026\u0026 parsedParameters[3] \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"At least one of the optional fields [/c CATEGORY], \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" \"[/de DESCRIPTION], [/da DATE] must be provided.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" return parsedParameters;","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" * Helper method to find the index of a specific string in an array.","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" * @param array The array to search.","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" * @param value The string value to find.","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" * @return The index of the value in the array, or -1 if not found.","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" private static int indexOf(String[] array, String value) {","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" for (int i \u003d 0; i \u003c array.length; i++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" if (array[i].equals(value)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" return i;","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" return -1;","lastModifiedDate":"2023-10-23"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"bljhty":108}},{"path":"src/main/java/seedu/duke/parser/IncomeParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.time.format.ResolverStyle;","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" * Represents the parser for the Income class.","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" * This class serves to parse the user input into a format that the Income class can understand","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"public class IncomeParser {","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" public static final String DESCRIPTION_FIELD \u003d \"de\";","lastModifiedDate":"2023-10-12"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" public static final String DATE_FIELD \u003d \"da\";","lastModifiedDate":"2023-10-12"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" public static final String AMOUNT_FIELD \u003d \"am\";","lastModifiedDate":"2023-10-12"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" public static final String INDEX_FIELD \u003d \"in\";","lastModifiedDate":"2023-10-12"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(IncomeParser.class.getName());","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/IncomeParser.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" * This method is used to parse the date of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeParser class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeManager class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" * @param incomeDateString String containing the date of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" * @return incomeDate LocalDate containing the date of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" public static LocalDate parseDate(String incomeDateString) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" assert incomeDateString !\u003d null : \"incomeDateString should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" LocalDate incomeDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MM/uuuu\")","lastModifiedDate":"2023-10-12"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" .withResolverStyle(ResolverStyle.STRICT);","lastModifiedDate":"2023-10-12"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-12"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" incomeDate \u003d LocalDate.parse(incomeDateString, formatter);","lastModifiedDate":"2023-10-12"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e) {","lastModifiedDate":"2023-10-12"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid date format\" + incomeDateString, e);","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid date in the format dd/MM/yyyy\");","lastModifiedDate":"2023-10-12"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" if (incomeDate.isAfter(LocalDate.now())) {","lastModifiedDate":"2023-10-12"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Date is in the future\" + incomeDateString);","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a date that is not in the future\");","lastModifiedDate":"2023-10-12"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" return incomeDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" * This method is used to parse the fields of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeManager class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" * @param argumentsByField HashMap containing the description, date, and amount of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" * @return Income object created from the provided fields","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" public static Income parseIncome(HashMap\u003cString, String\u003e argumentsByField) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" if (argumentsByField \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Income fields cannot be null\");","lastModifiedDate":"2023-10-29"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" if (!argumentsByField.containsKey(DESCRIPTION_FIELD) ||","lastModifiedDate":"2023-10-12"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" !argumentsByField.containsKey(DATE_FIELD) ||","lastModifiedDate":"2023-10-12"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" !argumentsByField.containsKey(AMOUNT_FIELD)) {","lastModifiedDate":"2023-10-12"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Missing fields detected\");","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" String incomeDescriptionString \u003d argumentsByField.get(DESCRIPTION_FIELD);","lastModifiedDate":"2023-10-12"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" String incomeDateString \u003d argumentsByField.get(DATE_FIELD);","lastModifiedDate":"2023-10-12"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" String incomeAmountString \u003d argumentsByField.get(AMOUNT_FIELD);","lastModifiedDate":"2023-10-12"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" LocalDate incomeDate \u003d parseDate(incomeDateString);","lastModifiedDate":"2023-10-12"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" double incomeAmount;","lastModifiedDate":"2023-10-12"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-12"},{"lineNumber":105,"author":{"gitId":"limyuhching"},"content":" if (!isOtherCurrency(incomeAmountString)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" incomeAmount \u003d Double.parseDouble(incomeAmountString);","lastModifiedDate":"2023-10-12"},{"lineNumber":107,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"limyuhching"},"content":" // Convert Currency to SGD","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-11-01"},{"lineNumber":110,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d incomeAmountString.split(\" \");","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"limyuhching"},"content":" String currency \u003d tokens[0].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"limyuhching"},"content":" incomeAmount \u003d Double.parseDouble(tokens[1].trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"limyuhching"},"content":" incomeAmount \u003d exchangeRateManager.convertCurrency(currency, incomeAmount);","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showCurrencyConversionMessage(currency);","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-12"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid amount format\" + incomeAmountString, e);","lastModifiedDate":"2023-10-19"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid amount\");","lastModifiedDate":"2023-10-12"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" if (incomeAmount \u003e 999999.99 || incomeAmount \u003c\u003d 0) {","lastModifiedDate":"2023-10-12"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid amount\" + incomeAmountString);","lastModifiedDate":"2023-10-19"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Income amount must be between $0.01 and $999999.99\");","lastModifiedDate":"2023-10-12"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" return new Income(incomeDescriptionString, incomeDate, incomeAmount);","lastModifiedDate":"2023-10-12"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" * This method is used to get the index of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeDeleter class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * @param argumentsByFields HashMap containing the index of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" * @return index int containing the index of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" public static int getIndex(HashMap\u003cString, String\u003e argumentsByFields) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" assert argumentsByFields !\u003d null : \"argumentsByFields should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" if (!argumentsByFields.containsKey(INDEX_FIELD)) {","lastModifiedDate":"2023-10-12"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Missing index field detected\");","lastModifiedDate":"2023-10-12"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" int index;","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-12"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" index \u003d Integer.parseInt(argumentsByFields.get(INDEX_FIELD));","lastModifiedDate":"2023-10-18"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-12"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid index\");","lastModifiedDate":"2023-10-12"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" if (index \u003c\u003d 0) {","lastModifiedDate":"2023-10-18"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid index\");","lastModifiedDate":"2023-10-18"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" return index;","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":152,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"limyuhching"},"content":" private static boolean isOtherCurrency(String amount) {","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"limyuhching"},"content":" return (amount.split(\" \").length \u003e 1);","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"limyuhching":15,"bljhty":141}},{"path":"src/main/java/seedu/duke/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"/*","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * parser class to parse user input","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public class Parser {","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" //private static final Logger LOGGER \u003d Logger.getLogger(Parser.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(Parser.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-19"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/Parser.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * This method is used to parse the user input.","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * This method is used by the Main class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" * @param fullCommand String containing the user input","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" * @return String containing the command to be executed","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" public static String parse(String fullCommand) {","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" assert fullCommand !\u003d null : \"fullCommand should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" String trimmedCommand \u003d fullCommand.trim();","lastModifiedDate":"2023-10-11"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" String commandLowerCase \u003d trimmedCommand.toLowerCase();","lastModifiedDate":"2023-10-11"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, (\"Parsing user input:\") + fullCommand);","lastModifiedDate":"2023-10-19"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" String resultCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" if (commandLowerCase.equals(\"exit\")) {","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"exit\";","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" } else if (commandLowerCase.startsWith(\"add income\")) {","lastModifiedDate":"2023-10-12"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"add_income\";","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" } else if (commandLowerCase.equals(\"list income\")) {","lastModifiedDate":"2023-10-12"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"list_income\";","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":" } else if (commandLowerCase.startsWith(\"add expense\")) {","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"add_expense\";","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"Hongzhii"},"content":" } else if (commandLowerCase.equals((\"list expense\"))) {","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"list_expense\";","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.equals(\"help\")) {","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"help\";","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.equals(\"list\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"list\";","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"delete income\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"delete_income\";","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"delete expense\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"delete_expense\";","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.equals(\"balance\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"balance\";","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" } else if (commandLowerCase.startsWith(\"find\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"find\";","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.startsWith(\"clear incomes\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" resultCommand \u003d \"clear_incomes\";","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.startsWith(\"clear expenses\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" resultCommand \u003d \"clear_expenses\";","lastModifiedDate":"2023-10-25"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.startsWith(\"clear all\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" resultCommand \u003d \"clear_all\";","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"edit income\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"edit_income\";","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"edit expense\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"edit_expense\";","lastModifiedDate":"2023-10-26"},{"lineNumber":88,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.equals(\"list currencies\")) {","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"list_currencies\";","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.equals(\"list exchange rates\")) {","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"list_exchange_rates\";","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"update exchange rate\")) {","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"update_exchange_rate\";","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"invalid\";","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO , (\"Parsed command: \") + resultCommand);","lastModifiedDate":"2023-10-19"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" return resultCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"limyuhching":13,"bljhty":77,"Hongzhii":2,"KenCheung18":8}},{"path":"src/main/java/seedu/duke/storage/ExchangeRateFileHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateFileHandler {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private static final String WRONG_FORMAT_ERROR \u003d \"Invalid row in exchange rate file\";","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private String filePath;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" public ExchangeRateFileHandler(String filePath) {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" this.filePath \u003d filePath;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" public boolean load() throws KaChinnnngException, FileNotFoundException {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" boolean loadedAllRows \u003d true;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" if (createFile(filePath)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" return true; // File not found, created new file","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" String textLine \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d textLine.split(\",\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" String currency \u003d tokens[0].toUpperCase().trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" double rate \u003d Double.parseDouble(tokens[1].trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException | NumberFormatException | NullPointerException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" // Skip line if rate is not a double","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" System.out.println(WRONG_FORMAT_ERROR + \" : \" + textLine);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" loadedAllRows \u003d false;","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" return loadedAllRows;","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" public void save(HashMap\u003cString, Double\u003e exchangeRates) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" try (FileWriter fw \u003d new FileWriter(filePath)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" for (Map.Entry\u003cString, Double\u003e entry : exchangeRates.entrySet()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" String currency \u003d entry.getKey();","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" Double rate \u003d entry.getValue();","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" fw.write(currency + \",\" + rate + \"\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Something went wrong when saving exchange rates\");","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" private boolean createFile(String filePath) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" if (!file.getParentFile().exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" file.getParentFile().mkdirs();","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" return file.createNewFile();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Cannot create file; reason: \" + e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"limyuhching":69}},{"path":"src/main/java/seedu/duke/storage/GetFromTxt.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"import java.io.File;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" * The GetFromTxt class is responsible for reading financial records data from a text file.","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" * It parses the contents of the file and populates two ArrayLists: one for Incomes and one for Expenses.","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * This class handles exceptions for file creation errors, parsing errors, and other issues that may arise","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * when reading data from the file.","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":"public class GetFromTxt {","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" private static final String AMOUNT_NOT_SUPPORT_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" \"Amount field from this line is not supported from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" private static final String DATE_TIME_FORMAT_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" \"Date time format incorrect on this line from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" private static final String FILE_CREATION_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" \"Something went wrong while creating the file from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" private static final String INDEX_OUT_OF_BOUND_FROM_FILE_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" \"Details missed on this line from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" private static final String NUMBER_FROM_FILE_INCORRECT \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" \"The expense type is incorrect on this line from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" private final File file;","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" * Construct a new object of the GetFromTxt class with the provided file path.","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" * @param path The path to the text file containing financial records data.","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" public GetFromTxt(String path) {","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" file \u003d new File(path);","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" * Reads financial records data from the text file and add to the corresponding ArrayLists","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" * with Income and Expense objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The ArrayList to store Income objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The ArrayList to store Expense objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" * @throws FileNotFoundException If the file specified by the path cannot be found.","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" public void getFromTextFile(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses) throws FileNotFoundException {","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" if (file.createNewFile()) {","lastModifiedDate":"2023-10-25"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" return; // If there is no such file in the directory, create the file and return without reading data.","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" System.out.println(FILE_CREATION_ERROR);","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" String textLine \u003d s.nextLine();","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" // Parse the data from the text line","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" int expenseType \u003d 0;","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" String commandFromFile \u003d textLine.split(\" \\\\| \")[0];","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" String descriptionFromFile \u003d textLine.split(\" \\\\| \")[1];","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" double amountFromFile \u003d Double. parseDouble(textLine.split(\" \\\\| \")[2]);","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" LocalDate dateFromFile \u003d LocalDate.parse(textLine.split(\" \\\\| \")[3]);","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" // Check for valid amount range","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" if (amountFromFile \u003e 999999.99 || amountFromFile \u003c\u003d 0) {","lastModifiedDate":"2023-10-25"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" throw new KaChinnnngException(\"Expense amount must be between $0.01 and $999999.99\");","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" if (!commandFromFile.equals(\"I\")){","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" expenseType \u003d Integer.parseInt(textLine.split(\" \\\\| \")[4]);","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" // Create appropriate objects based on the commandFromFile","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" switch (commandFromFile) {","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" case \"I\":","lastModifiedDate":"2023-10-25"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(descriptionFromFile, dateFromFile, amountFromFile));","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" case \"EF\":","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(descriptionFromFile, dateFromFile,","lastModifiedDate":"2023-10-25"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" amountFromFile, MealType.values()[expenseType]));","lastModifiedDate":"2023-10-25"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" case \"ET\":","lastModifiedDate":"2023-10-25"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(descriptionFromFile, dateFromFile,","lastModifiedDate":"2023-10-25"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" amountFromFile, TransportationType.values()[expenseType]));","lastModifiedDate":"2023-10-25"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":" case \"EU\":","lastModifiedDate":"2023-10-25"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(descriptionFromFile, dateFromFile,","lastModifiedDate":"2023-10-25"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":" amountFromFile, UtilityType.values()[expenseType]));","lastModifiedDate":"2023-10-25"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":" default:","lastModifiedDate":"2023-10-25"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"The format of this line is incorrect \" + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":" System.out.println(INDEX_OUT_OF_BOUND_FROM_FILE_ERROR + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":" System.out.println(AMOUNT_NOT_SUPPORT_ERROR + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":111,"author":{"gitId":"KenCheung18"},"content":" } catch (DateTimeParseException e){","lastModifiedDate":"2023-10-25"},{"lineNumber":112,"author":{"gitId":"KenCheung18"},"content":" System.out.println(DATE_TIME_FORMAT_ERROR + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":113,"author":{"gitId":"KenCheung18"},"content":" } catch(NumberFormatException e){","lastModifiedDate":"2023-10-25"},{"lineNumber":114,"author":{"gitId":"KenCheung18"},"content":" System.out.println(NUMBER_FROM_FILE_INCORRECT + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":115,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":116,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":117,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":118}},{"path":"src/main/java/seedu/duke/storage/SaveToTxt.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" * The SaveToTxt class is responsible for saving financial records data to a text file.","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * It can save both Income and Expense objects to the specified file.","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" * This class handles exceptions for IO errors that may occur during file operations.","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"public class SaveToTxt {","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" private static final String IO_ERROR_MESSAGE \u003d \"An error occurred while saving tasks to the file.\";","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" private final String path;","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" * Construct a new object of the SaveToTxt class with the file path.","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * @param path The path to the text file where data will be saved.","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" public SaveToTxt(String path) {","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" this.path \u003d path;","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" * Saves both Income and Expense objects to the specified text file.","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The ArrayList of Income objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The ArrayList of Expense objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" public void saveIncomeAndExpense(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses){","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" System.out.println(IO_ERROR_MESSAGE);","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * Saves Income objects to the text file. Each Income object is represented as a line in the txt file.","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The ArrayList of Income objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" * @throws IOException If an IO error occurs during the file write operation.","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" public void saveIncomeToTextFile(ArrayList\u003cIncome\u003e incomes) throws IOException {","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" try (FileWriter fw \u003d new FileWriter(path)) {","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" for (Income income : incomes) {","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" String incomeDescription \u003d income.getDescription();","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" String incomeDate \u003d String.valueOf(income.getDate());","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" String incomeAmount \u003d String.valueOf(income.getAmount());","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" String textToAdd \u003d \"I\" + \" | \" + incomeDescription + \" | \" + incomeAmount + \" | \" + incomeDate + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" System.out.println(IO_ERROR_MESSAGE);","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" * Saves Expense objects to the text file. Each Expense object is represented as a line in the file,","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" * and the type of Expense (Food, Transport, or Utilities) is specified in the line.","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The ArrayList of Expense objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" * @throws IOException If an IO error occurs during the file write operation.","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" public void saveExpenseToTextFile(ArrayList\u003cExpense\u003e expenses) throws IOException{","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" try (FileWriter fw \u003d new FileWriter(path, true)) {","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" for (Expense expense : expenses) {","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" String textToAdd \u003d \"\";","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" String expenseDescription \u003d expense.getDescription();","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" String expenseDate \u003d String.valueOf(expense.getDate());;","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" String expenseAmount \u003d String.valueOf(expense.getAmount());","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" // Determine the type of Expense and format the line accordingly","lastModifiedDate":"2023-10-25"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" if (expense.getClass() \u003d\u003d Food.class) {","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" textToAdd \u003d \"EF\" + \" | \" + expenseDescription + \" | \" + expenseAmount + \" | \"","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" + expenseDate + \" | \" + ((Food) expense).getMealType().ordinal() + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" } else if (expense.getClass() \u003d\u003d Transport.class) {","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" textToAdd \u003d \"ET\" + \" | \" + expenseDescription + \" | \" + expenseAmount + \" | \"","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" + expenseDate + \" | \" + ((Transport) expense).getTransportationType().ordinal() + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" } else if (expense.getClass() \u003d\u003d Utilities.class) {","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" textToAdd \u003d \"EU\" + \" | \" + expenseDescription + \" | \" + expenseAmount + \" | \"","lastModifiedDate":"2023-10-25"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" + expenseDate + \" | \" + ((Utilities) expense).getUtilityType().ordinal() + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" System.out.println(IO_ERROR_MESSAGE);","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":98}},{"path":"src/main/java/seedu/duke/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.ui;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * This class handles the user interface of the program.","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"public class Ui {","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" private static final String lineDivider \u003d \"____________________________________________________________\";","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public Scanner scanner;","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" * Constructor for Ui.","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public Ui() {","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" this.scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" * This method reads the command input by the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" * @return String containing the command input by the user","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is no input provided by the user","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" public String readCommand() throws KaChinnnngException {","lastModifiedDate":"2023-10-11"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" if (scanner.hasNextLine()) {","lastModifiedDate":"2023-10-11"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" return scanner.nextLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"No input provided by the user.\");","lastModifiedDate":"2023-10-11"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * This method prints the line divider.","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" public static void showLineDivider() {","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-12"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" * Prints the welcome message when the program starts.","lastModifiedDate":"2023-10-12"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-12"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" public static void printWelcomeMessage() {","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-09"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Welcome to KaChinnnngggg! How may i assist you today?\");","lastModifiedDate":"2023-10-09"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-12"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" * Prints the goodbye message when the program ends.","lastModifiedDate":"2023-10-12"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-12"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" public void printGoodbyeMessage() {","lastModifiedDate":"2023-10-11"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Bye. Hope to see you again soon!\");","lastModifiedDate":"2023-10-09"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-09"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" * prints the message when the user inputs his income","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" * @param income Income object created from the provided fields","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public static void printIncomeAddedMessage(Income income) {","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Got it. I\u0027ve added this income:\\n\" + income.toString());","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * Prints a message indicating the start of the income list display.","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" public void printListIncomeMessage() {","lastModifiedDate":"2023-10-12"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Here are your incomes:\");","lastModifiedDate":"2023-10-12"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":80,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" public static void printExpenseAddedMessage(Expense expense) {","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"Got it. I\u0027ve added this expense:\\n\" + expense.toString());","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"Hongzhii"},"content":" public void printListExpenseMessage() {","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"Here are your expenses:\");","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" public void printMessage(String message) {","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" System.out.println(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncomes(List\u003cIncome\u003e matchingIncomes) {","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" if(matchingIncomes \u003d\u003d null || matchingIncomes.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" System.out.print(\"No matching incomes found.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Here are the matching incomes in your list:\");","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" for (Income income : matchingIncomes) {","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" System.out.println(income.toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses(List\u003cExpense\u003e matchingExpenses) {","lastModifiedDate":"2023-10-23"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" if (matchingExpenses \u003d\u003d null || matchingExpenses.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" System.out.print(\"No matching expenses found.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Here are the matching expenses in your list:\");","lastModifiedDate":"2023-10-23"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" for (Expense expense : matchingExpenses) {","lastModifiedDate":"2023-10-23"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" System.out.println(expense.toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"limyuhching":5,"bljhty":102,"Hongzhii":8}},{"path":"src/test/java/seedu/duke/DukeTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"package seedu.duke;","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"class DukeTest {","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" Duke duke;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" duke \u003d new Duke();","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" void loadData_noFileExists_createsFile() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" File file \u003d new File(\"KaChinnnngggg.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" boolean isDeleted \u003d file.delete();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" assertTrue(isDeleted, \"File should have been deleted before the test.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" duke.loadData();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" assertTrue(file.exists(), \"File should have been created\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" void loadData_fileExists_loadsData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" File file \u003d new File(\"KaChinnnngggg.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" boolean isDeleted \u003d file.delete();","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" assertTrue(isDeleted, \"File should have been deleted before the test.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" duke.loadData();","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assertTrue(file.exists(), \"File should have been created\");","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" void executeCommand_validCommand_noExceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"income /de Salary /date 12/10/2023 /amt 5000.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" void executeCommand_invalidCommand_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"income /de Salary /date 12/10/2023 /amt 5000.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" void executeCommand_addIncome_increasesSizeOfIncomeList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" int initialSize \u003d duke.getIncomesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 01/10/2023 /amt 1000.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" assertEquals(initialSize + 1, duke.getIncomesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" void addIncome_invalidIncome_exception() {","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 01/10/2024 /amt 1000.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" void executeCommand_addExpense_increasesSizeOfExpenseList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" int initialSize \u003d duke.getExpensesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add expense /cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" \" /de chicken sandwich /date 01/10/2023 /amt 10.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" assertEquals(initialSize + 1, duke.getExpensesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" void addExpense_invalidExpense_exception() {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e duke.executeCommand(\"add expense /cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" \" /de chicken sandwich /date 01/10/2024 /amt 10.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" void executeCommand_deleteIncome_decreasesSizeOfIncomeList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 03/10/2023 /amt 1000.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" int sizeAfterAddition \u003d duke.getIncomesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"delete income 1\"); // Assuming index 1 exists for this test","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" assertEquals(sizeAfterAddition - 1, duke.getIncomesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" void executeCommand_deleteExpense_decreasesSizeOfExpenseList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add expense /cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" \" /de chicken sandwich /date 03/10/2023 /amt 10.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" int sizeAfterAddition \u003d duke.getExpensesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"delete expense 1\"); // Assuming index 1 exists for this test","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" assertEquals(sizeAfterAddition - 1, duke.getExpensesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" void executeCommand_balance_correctOutput() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" // Backup the original system out","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" PrintStream captureStream \u003d new PrintStream(outputStream);","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" System.setOut(captureStream);","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" // Assuming the list starts empty, and you add an income and an expense","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 03/10/2023 /amt 1000.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add expense /cat food /type lunch \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" \"/de chicken sandwich /date 01/10/2023 /amt 10.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" // Clear the outputStream to only capture the balance output","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" outputStream.reset();","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" // Capture balance output","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"balance\");","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" String balanceOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" // The expected output based on the given additions","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" String expectedBalanceOutput \u003d","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" \"____________________________________________________________\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" \"Balance: 990.0\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" \"____________________________________________________________\";","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedBalanceOutput, balanceOutput);","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" // Restore the original System.out","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":134,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"bljhty":125,"-":9}},{"path":"src/test/java/seedu/duke/commands/BalanceTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Tests for the {@link Balance} class.","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * This test class provides test cases to check the calculation and reporting","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * of financial balance between income and expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"public class BalanceTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7), 100.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with both income and expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly subtracts expenses from income.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" public void testGetBalance_withBothIncomeAndExpenses_returnsCorrectDifference() {","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(incomes, expenses);","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" assertEquals(3900.0, balance.getBalance());","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with no records.","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly returns 0.","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" public void testNoRecords() {","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(new ArrayList\u003c\u003e(), new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" assertEquals(0, balance.getBalance(),","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" \"Balance should be 0 when no records are present.\");","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with no expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly returns a positive value equal to income.","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" public void testGetBalance_withNoExpenses_returnsIncomeValue()throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cIncome\u003e incomesOnly \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" incomesOnly.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(incomesOnly, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" assertEquals(5000.0, balance.getBalance(),","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" \"Balance should equal sum of all incomes when no expenses are present.\");","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with no incomes.","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly returns a negative value equal to expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public void testGetBalance_withNoIncomes_returnsNegativeExpenseValue()throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cExpense\u003e expensesOnly \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" expensesOnly.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(new ArrayList\u003c\u003e(), expensesOnly);","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" assertEquals(-2000.0, balance.getBalance(),","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" \"Balance should be negative sum of all expenses when no incomes are present.\");","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":85}},{"path":"src/test/java/seedu/duke/commands/ClearAllTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link ClearAll} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check the deletion of records in","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" * both incomes and expenses record list","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"public class ClearAllTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10),","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15),","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5),","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" 2000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7),","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" 100.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with both incomes and expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear all function correctly delete all the record in the income and expenses list.","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" public void testClearAll_withIncomesAndExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with only incomes but not expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear all function correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" * delete all the record in the both list without error.","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" public void testClearAll_withIncomesNoExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with only expenses but no incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear all function correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" * delete all the record in the both list without error.","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" public void testClearAll_withExpensesNoIncomes() {","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with no records.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if there is an empty list, whether clear income function will still process correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" public void testNoIncomesAndExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":99}},{"path":"src/test/java/seedu/duke/commands/ClearExpensesTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link ClearExpenses} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check the deletion of records in","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * expenses record list","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"public class ClearExpensesTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7),","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" 100.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearExpenses#clearAllExpenses()} method with expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear incomes function correctly delete all the record in the income list.","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" public void testClearExpenses_withExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" ClearExpenses clearExpenses \u003d new ClearExpenses(testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" clearExpenses.clearAllExpenses();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearExpenses#clearAllExpenses()} method with no records.","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if there is an empty list, whether clear income function will still process correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" public void testNoExpenses() throws KaChinnnngException{","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" ClearExpenses clearExpenses \u003d new ClearExpenses(testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" clearExpenses.clearAllExpenses();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":56}},{"path":"src/test/java/seedu/duke/commands/ClearIncomesTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link ClearAll} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check the deletion of records in","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * both incomes and expenses record list","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"public class ClearIncomesTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearIncomes#clearAllIncomes()} method with incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear incomes function correctly delete all the record in the income list.","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" public void testClearIncome_withIncomes() {","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncome \u003d new ArrayList\u003c\u003e(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" ClearIncomes clearTestIncome \u003d new ClearIncomes(testIncome);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" clearTestIncome.clearAllIncomes();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncome.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearIncomes#clearAllIncomes()} method with no records.","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if there is an empty list, whether clear income function will still process correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" public void testNoIncomes() {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncome \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" ClearIncomes clearTestIncome \u003d new ClearIncomes(testIncome);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" clearTestIncome.clearAllIncomes();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncome.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":57}},{"path":"src/test/java/seedu/duke/commands/DeleteExpenseCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * This class contains JUnit tests for the DeleteExpenseCommand class.","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":"public class DeleteExpenseCommandTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" private DeleteExpenseCommand deleteExpenseCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private Ui ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" public void setUp() {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" deleteExpenseCommand \u003d new DeleteExpenseCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" ui \u003d new Ui();","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with valid input. The expense should be deleted.","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_expenseDeleted() throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" Expense expense \u003d new Expense(\"Lunch\", LocalDate.now().minusDays(1), 20.00);","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" expenses.add(expense);","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" // Act","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" // Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" assertEquals(0, expenses.size());","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with missing arguments. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" public void testExecute_missingArgument_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense\";","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with an invalid index. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with a non-existent expense index.","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" * It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":" public void testExecute_nonExistentExpenseIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"limyuhching":82}},{"path":"src/test/java/seedu/duke/commands/DeleteIncomeCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * This class contains JUnit tests for the DeleteIncomeCommand class.","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":"public class DeleteIncomeCommandTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" private DeleteIncomeCommand deleteIncomeCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private Ui ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" public void setUp() {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" deleteIncomeCommand \u003d new DeleteIncomeCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" ui \u003d new Ui();","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with valid input. The income should be deleted.","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_incomeDeleted() throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" Income income \u003d new Income(\"Salary\",","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" incomes.add(income);","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" // Act","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" // Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" assertEquals(0, incomes.size());","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with missing arguments. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" public void testExecute_missingArgument_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income\";","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with an invalid index. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with a non-existent income index.","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" * It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" public void testExecute_nonExistentIncomeIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"limyuhching":83}},{"path":"src/test/java/seedu/duke/commands/EditExpenseCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class EditExpenseCommandTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" public void setUp() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" // Initialize the expenses and fullCommand for testing","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7), 100.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" fullCommand \u003d \"edit expense 3 expense /cat food /type lunch /de chicken sandwich /date 01/10/2023 /amt 10.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" EditExpenseCommand editExpenseCommand \u003d new EditExpenseCommand(expenses, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" // This test checks if the execute method throws an exception when the index is out of bounds","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" editExpenseCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_expenseEdited() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" fullCommand \u003d \"edit expense 1 expense /cat food /type lunch /de chicken rice /date 01/10/2023 /amt 10.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" EditExpenseCommand editExpenseCommand \u003d new EditExpenseCommand(expenses, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" // Test if the execute method changes the expense and prints the changes","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e editExpenseCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" // Verify if the expense was updated correctly","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" Expense updatedExpense \u003d expenses.get(0);","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" assertEquals(\"Food Expense (LUNCH): chicken rice | Date: 01/Oct/2023 | Amount: $10.00\",","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" updatedExpense.toString());","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidExpense_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" // Test if execute method throws a KaChinnnngException for an invalid command","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit expense 1 invalid expense command\";","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" EditExpenseCommand editExpenseCommand \u003d new EditExpenseCommand(expenses, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e editExpenseCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":54,"Hongzhii":4}},{"path":"src/test/java/seedu/duke/commands/EditIncomeCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class EditIncomeCommandTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private EditIncomeCommand editIncomeCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" private String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" public void setUp() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" // Initialize the incomes and fullCommand for testing","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit income 3 income /de salary for October /date 01/10/2023 /amt 5000.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand \u003d new EditIncomeCommand(incomes, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" // This test checks if the execute method throws an exception when the index is out of bounds","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_incomeEdited() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit income 1 income /de salary for October /date 01/10/2023 /amt 5000.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand \u003d new EditIncomeCommand(incomes, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" // Test if the execute method changes the income and prints the changes","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e editIncomeCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" // Verify if the income was updated correctly","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" Income updatedincome \u003d incomes.get(0);","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" assertEquals(\"Income: salary for October | Date: 01/Oct/2023 | Amount: $5000.00\",","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" updatedincome.toString());","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIncome_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" // Test if execute method throws a KaChinnnngException for an invalid command","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit income 1 invalid income command\";","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand \u003d new EditIncomeCommand(incomes, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e editIncomeCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":59}},{"path":"src/test/java/seedu/duke/commands/ExpenseManagerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class ExpenseManagerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private ExpenseManager expenseManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" public void setUp() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" // Initialize the expense manager","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" expenseManager \u003d new ExpenseManager(\"/cat food /type lunch /de chicken rice \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" \"/date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public void testConstructor_objectCreated() {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" assertNotNull(expenseManager);","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_getNewExpense() throws KaChinnnngException{","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" expenseManager.execute();","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" Expense expense \u003d expenseManager.getNewExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" assertNotNull(expense);","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_missingFields_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerMissingFields \u003d new ExpenseManager(\"/type lunch /de chicken rice \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" \"/date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerMissingFields::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_extraFields_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerExtraFields \u003d new ExpenseManager(\"/cat food /type lunch \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2001 /amt 100 /extra extra\");","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerExtraFields::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_wrongOrder_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerWrongOrder \u003d new ExpenseManager(\"/type lunch /cat food \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerWrongOrder::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_upperAndLowerCase_correctParsing() {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerUpperLowerCase \u003d new ExpenseManager(\"/cat fOoD /type lUNcH \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":" assertNotNull(expenseManagerUpperLowerCase);","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_invalidDate_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerInvalidDate \u003d new ExpenseManager(\"/cat food /type lunch \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 13/13/2000 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerInvalidDate::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_incorrectDateFormat_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerIncorrectDateFormat \u003d new ExpenseManager(\"/cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01-01-2003 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerIncorrectDateFormat::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_incorrectAmountFormat_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerIncorrectAmountFormat \u003d new ExpenseManager(\"/cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2003 /amt one hundred\");","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerIncorrectAmountFormat::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"Hongzhii":85}},{"path":"src/test/java/seedu/duke/commands/FindCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.MockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":"public class FindCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e testIncomes;","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cExpense\u003e testExpenses;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" private MockUi mockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" testIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" mockUi \u003d new MockUi(); // Assuming MockUi has a parameterless constructor.","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Food\",","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByDescription() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" \"Burger\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" null, \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByMonth() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" // Adding multiple expenses in October","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food(\"Pizza\", LocalDate.of(2023, 10, 15), 8.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" Food foodExpense3 \u003d new Food(\"Sandwich\", LocalDate.of(2023, 10, 28), 3.0, MealType.BREAKFAST);","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" // Adding an expense from another month for control","lastModifiedDate":"2023-10-29"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" Food foodExpenseOutsideMonth \u003d new Food(\"Salad\", LocalDate.of(2023, 9, 30), 4.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense3);","lastModifiedDate":"2023-10-29"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpenseOutsideMonth);","lastModifiedDate":"2023-10-29"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null, null, \"Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" + \"Food Expense (DINNER): Pizza | Date: 15/Oct/2023 | Amount: $8.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" + \"Food Expense (BREAKFAST): Sandwich | Date: 28/Oct/2023 | Amount: $3.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByDate2() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" null, \"10/10/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" void testMultipleMatchingExpenses() throws Exception{","lastModifiedDate":"2023-10-29"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food (\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food (\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023,10,11), 5.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" \"Burger\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" + \"Food Expense (DINNER): Burger | Date: 11/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" void testNoMatchingExpenses() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" \"NonexistentItem\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" assertTrue(mockUi.getPrintedMessages().contains(\"No matching expenses found.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" void testInvalidDateFormat() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" null, \"20231010\", mockUi); // Invalid date format","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Invalid date format.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" void testNullValues() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" null, null, null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandIncomeByDescription() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" \"Salary\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandIncomeByDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" null, \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" void testMultipleIncomeMatches() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":" Income income1 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" Income income2 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income1);","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income2);","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" \"Salary\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" + \"Income: Salary | Date: 11/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" void testNoMatchingIncomes() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":" \"NonexistentItem\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" assertTrue(mockUi.getPrintedMessages().contains(\"No matching incomes found.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" void testIncomesByMonth() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" Income income1 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" Income income2 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":" Income income3 \u003d new Income(\"Salary\", LocalDate.of(2023, 9, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income1);","lastModifiedDate":"2023-10-29"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income2);","lastModifiedDate":"2023-10-29"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income3);","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" null, \"Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" + \"Income: Salary | Date: 11/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":" void testIncomeFutureDate() {","lastModifiedDate":"2023-10-29"},{"lineNumber":247,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":248,"author":{"gitId":"bljhty"},"content":" Income futureIncome \u003d new Income(\"Bonus\", LocalDate.of(2025, 10, 10), 7000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":249,"author":{"gitId":"bljhty"},"content":" testIncomes.add(futureIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":250,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":251,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":252,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Date cannot be in the future!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":253,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":254,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":255,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":256,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDescriptionAndDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":257,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":258,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 11), 5.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":259,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":260,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":261,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":262,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":263,"author":{"gitId":"bljhty"},"content":" \"Burger\", \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":264,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":265,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":266,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":267,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":268,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":269,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":270,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":271,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDescriptionAndCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":272,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":273,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food(\"Pizza\", LocalDate.of(2023, 10, 11), 5.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":274,"author":{"gitId":"bljhty"},"content":" Transport transportExpense \u003d new Transport(\"Bus\",","lastModifiedDate":"2023-10-29"},{"lineNumber":275,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, TransportationType.BUS);","lastModifiedDate":"2023-10-29"},{"lineNumber":276,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":277,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":278,"author":{"gitId":"bljhty"},"content":" testExpenses.add(transportExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":279,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":280,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Food\",","lastModifiedDate":"2023-10-29"},{"lineNumber":281,"author":{"gitId":"bljhty"},"content":" \"Burger\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":282,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":283,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":284,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":285,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":286,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":287,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":288,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":289,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDateAndCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":290,"author":{"gitId":"bljhty"},"content":" Transport transportExpense1 \u003d new Transport(\"Bus\",","lastModifiedDate":"2023-10-29"},{"lineNumber":291,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, TransportationType.BUS);","lastModifiedDate":"2023-10-29"},{"lineNumber":292,"author":{"gitId":"bljhty"},"content":" Utilities utilitiesExpense \u003d new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-29"},{"lineNumber":293,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, UtilityType.WATER);","lastModifiedDate":"2023-10-29"},{"lineNumber":294,"author":{"gitId":"bljhty"},"content":" Transport transportExpense2 \u003d new Transport(\"Bus\",","lastModifiedDate":"2023-10-29"},{"lineNumber":295,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, TransportationType.TAXI);","lastModifiedDate":"2023-10-29"},{"lineNumber":296,"author":{"gitId":"bljhty"},"content":" testExpenses.add(transportExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":297,"author":{"gitId":"bljhty"},"content":" testExpenses.add(utilitiesExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":298,"author":{"gitId":"bljhty"},"content":" testExpenses.add(transportExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":299,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":300,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Transport\",","lastModifiedDate":"2023-10-29"},{"lineNumber":301,"author":{"gitId":"bljhty"},"content":" null, \"11/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":302,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":303,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":304,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Transportation Expense (BUS): Bus | Date: 11/Oct/2023 | Amount: $5.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":305,"author":{"gitId":"bljhty"},"content":" + \"Transportation Expense (TAXI): Bus | Date: 11/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":306,"author":{"gitId":"bljhty"},"content":" assertTrue(mockUi.getShowExpenses().contains(expectedOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":307,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":308,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":309,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":310,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDescriptionAndDateAndCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":311,"author":{"gitId":"bljhty"},"content":" Utilities utilitiesExpense1 \u003d new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-29"},{"lineNumber":312,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, UtilityType.ELECTRICITY);","lastModifiedDate":"2023-10-29"},{"lineNumber":313,"author":{"gitId":"bljhty"},"content":" Utilities utilitiesExpense2 \u003d new Utilities(\"Water\",","lastModifiedDate":"2023-10-29"},{"lineNumber":314,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, UtilityType.WATER);","lastModifiedDate":"2023-10-29"},{"lineNumber":315,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":316,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":317,"author":{"gitId":"bljhty"},"content":" testExpenses.add(utilitiesExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":318,"author":{"gitId":"bljhty"},"content":" testExpenses.add(utilitiesExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":319,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":320,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":321,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Utilities\",","lastModifiedDate":"2023-10-29"},{"lineNumber":322,"author":{"gitId":"bljhty"},"content":" \"Electricity\", \"11/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":323,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":324,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":325,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Utilities Expense(ELECTRICITY): Electricity | Date: 11/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":326,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":327,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":328,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":329,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":330,"author":{"gitId":"bljhty"},"content":" void testIncomeByDescriptionAndDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":331,"author":{"gitId":"bljhty"},"content":" Income income1 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":332,"author":{"gitId":"bljhty"},"content":" Income income2 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":333,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income1);","lastModifiedDate":"2023-10-29"},{"lineNumber":334,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income2);","lastModifiedDate":"2023-10-29"},{"lineNumber":335,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":336,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":337,"author":{"gitId":"bljhty"},"content":" \"Salary\", \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":338,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":339,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":340,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":341,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":342,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":343,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":344,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":345,"author":{"gitId":"bljhty"},"content":" void testNegativeIncomeAmount() {","lastModifiedDate":"2023-10-29"},{"lineNumber":346,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":347,"author":{"gitId":"bljhty"},"content":" Income negativeIncome \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), -5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":348,"author":{"gitId":"bljhty"},"content":" testIncomes.add(negativeIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":349,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":350,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":351,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Amount cannot be negative!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":352,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":353,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":354,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":355,"author":{"gitId":"bljhty"},"content":" void testNegativeExpenseAmount() {","lastModifiedDate":"2023-10-29"},{"lineNumber":356,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":357,"author":{"gitId":"bljhty"},"content":" Food negativeExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":358,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), -5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":359,"author":{"gitId":"bljhty"},"content":" testExpenses.add(negativeExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":360,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":361,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":362,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Amount cannot be negative!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":363,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":364,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":365,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":366,"author":{"gitId":"bljhty"},"content":" void testEmptyIncomeDescription() {","lastModifiedDate":"2023-10-29"},{"lineNumber":367,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":368,"author":{"gitId":"bljhty"},"content":" Income emptyDescriptionIncome \u003d new Income(\"\",","lastModifiedDate":"2023-10-29"},{"lineNumber":369,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":370,"author":{"gitId":"bljhty"},"content":" testIncomes.add(emptyDescriptionIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":371,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":372,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":373,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Description cannot be empty!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":374,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":375,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":376,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":377,"author":{"gitId":"bljhty"},"content":" void testEmptyExpenseDescription() {","lastModifiedDate":"2023-10-29"},{"lineNumber":378,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":379,"author":{"gitId":"bljhty"},"content":" Food emptyDescriptionExpense \u003d new Food(\"\",","lastModifiedDate":"2023-10-29"},{"lineNumber":380,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":381,"author":{"gitId":"bljhty"},"content":" testExpenses.add(emptyDescriptionExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":382,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":383,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":384,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Description cannot be empty!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":385,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":386,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":387,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":388,"author":{"gitId":"bljhty"},"content":" void testInvalidExpenseCategory() {","lastModifiedDate":"2023-10-29"},{"lineNumber":389,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":390,"author":{"gitId":"bljhty"},"content":" // Assuming \u0027Gaming\u0027 is not a valid category in your application","lastModifiedDate":"2023-10-29"},{"lineNumber":391,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":392,"author":{"gitId":"bljhty"},"content":" \"expense\", \"Gaming\", null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":393,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":394,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":395,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":396,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Invalid expense category provided! Allowed categories are: \"));","lastModifiedDate":"2023-10-29"},{"lineNumber":397,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":398,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":399,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":400,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":401,"author":{"gitId":"bljhty"},"content":" void testFindCommandWithZeroAmountExpense() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":402,"author":{"gitId":"bljhty"},"content":" Expense zeroAmountExpense \u003d new Expense(\"Zero Amount Expense\", LocalDate.now(), 0.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":403,"author":{"gitId":"bljhty"},"content":" testExpenses.add(zeroAmountExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":404,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":405,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":406,"author":{"gitId":"bljhty"},"content":" \"expense\", \"Food\", null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":407,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":408,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":409,"author":{"gitId":"bljhty"},"content":" assertFalse(mockUi.getShowExpenses().contains(\"Zero Amount Expense\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":410,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":411,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":412,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":413,"author":{"gitId":"bljhty"},"content":" void testFindCommandWithZeroIncome() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":414,"author":{"gitId":"bljhty"},"content":" Income zeroAmountIncome \u003d new Income(\"Zero Amount Income\", LocalDate.now(), 0.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":415,"author":{"gitId":"bljhty"},"content":" testIncomes.add(zeroAmountIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":416,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":417,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":418,"author":{"gitId":"bljhty"},"content":" \"income\", null, null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":419,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":420,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":421,"author":{"gitId":"bljhty"},"content":" assertFalse(mockUi.getShowIncomes().contains(\"Zero Amount Income\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":422,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":423,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":424,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":424}},{"path":"src/test/java/seedu/duke/commands/IncomeListerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.MockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.fail;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"public class IncomeListerTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" private MockUi mockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" mockUi \u003d new MockUi();","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" void listIncomes_emptyList_displayNoIncomes() {","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" IncomeLister incomeLister \u003d new IncomeLister(incomes, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" incomeLister.listIncomes();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" List\u003cString\u003e messages \u003d mockUi.getPrintedMessages();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" assertEquals(1, messages.size());","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" assertEquals(\"You have no recorded incomes.\", messages.get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" void listIncomes_nonEmptyList_displaysAllIncomes() {","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" LocalDate date1 \u003d LocalDate.parse(\"01/01/2023\", formatter);","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" LocalDate date2 \u003d LocalDate.parse(\"02/01/2023\", formatter);","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Description 1\", date1, 50.0));","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Description 2\", date2, 100.0));","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" IncomeLister incomeLister \u003d new IncomeLister(incomes, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" incomeLister.listIncomes();","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" List\u003cString\u003e messages \u003d mockUi.getPrintedMessages();","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assertEquals(3, messages.size()); // Three messages: header and two income details","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are your incomes:\", messages.get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" assertEquals(\"1. \" + incomes.get(0).toString(), messages.get(1));","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" assertEquals(\"2. \" + incomes.get(1).toString(), messages.get(2));","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" fail(\"Unexpected exception: \" + e.getMessage());","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" void testIncomeConstructor_negativeAmount() {","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" new Income(\"Test\", LocalDate.now(), -50.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" String expectedMessage \u003d \"Amount cannot be negative!\";","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" String actualMessage \u003d exception.getMessage();","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedMessage, actualMessage); // Using assertEquals for clarity","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" void testToString_validIncome() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Test\", LocalDate.of(2023, 1, 1), 50.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" String expected \u003d \"Income: Test | Date: 01/Jan/2023 | Amount: $50.00\";","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" assertEquals(expected, income.toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" void testLoggerFileCreation() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" new Income(\"Logger Test\", LocalDate.now(), 50.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" File logFile \u003d new File(\"logs/Income.log\");","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" assertTrue(logFile.exists());","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":88}},{"path":"src/test/java/seedu/duke/commands/IncomeManagerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public class IncomeManagerTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" private IncomeManager incomeManager;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" incomeManager \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" void constructor_initializesCorrectly() {","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" assertNotNull(incomeManager);","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" void execute_parsesIncomeSuccessfully() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" incomeManager.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" Income income \u003d incomeManager.getNewIncome();","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" assertNotNull(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" // You may also want to check the properties of `income` to ensure it\u0027s been parsed correctly.","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" void execute_missingFields_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithMissingFields \u003d new IncomeManager(\"/de Grocery /date 29/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithMissingFields::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" void execute_extraFields_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithExtraFields \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" \"/amt 50.0 /extraField Something\");","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithExtraFields::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" void constructor_nullDetails_throwsAssertionError() {","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" assertThrows(AssertionError.class, () -\u003e new IncomeManager(null));","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" void execute_incorrectFieldOrder_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithIncorrectOrder \u003d new IncomeManager(\"/amt 50.0 /de Grocery /date 29/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithIncorrectOrder::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" void execute_spacesInFields_parsedCorrectly() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithSpaces \u003d new IncomeManager(\"/de Grocery Store /date 29/10/2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" managerWithSpaces.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" Income income \u003d managerWithSpaces.getNewIncome();","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" assertNotNull(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" void execute_incorrectDateFormat_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithBadDate \u003d new IncomeManager(\"/de Grocery /date 29-10-2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithBadDate::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" void execute_incorrectAmountFormat_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithBadAmount \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 /amt fifty\");","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithBadAmount::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" void testLoggerFileCreation() {","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" // Initialization","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" IncomeManager incomeManager \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" // Assertion","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" File loggerFile \u003d new File(\"logs/IncomeManager.log\");","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" assertTrue(loggerFile.exists(), \"Logger file should be created\");","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" // Cleanup (optional, depending on whether you want to keep logs from test runs)","lastModifiedDate":"2023-10-29"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" loggerFile.delete();","lastModifiedDate":"2023-10-29"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":93}},{"path":"src/test/java/seedu/duke/financialrecords/ExchangeRateManagerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertSame;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.fail;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateManagerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager exchangeRateManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" public void setUp() {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" public void testGetInstance() {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" // Ensure that getInstance returns the same instance of ExchangeRateManager","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager instance1 \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager instance2 \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" assertSame(instance1, instance2);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" public void testSupportedCurrencies() {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" // Ensure that the list of supported currencies is not empty","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" assertFalse(ExchangeRateManager.getSupportedCurrencies().isEmpty());","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" public void testUpdateExchangeRate_validInput_updateSameAsRetrieved() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" String currency \u003d \"USD\";","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" double rate \u003d 1.3;","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" // Update the exchange rate","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" fail(\"Should not throw an exception\");","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" // Retrieve and compare the exchange rate","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" double retrievedRate \u003d exchangeRateManager.getExchangeRates().get(currency);","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" assertEquals(rate, retrievedRate);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" public void testConvertCurrency() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" String currency \u003d \"USD\";","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" double rate \u003d 1.3;","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" double amount \u003d 100.0;","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" // Update the exchange rate","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" fail(\"Should not throw an exception\");","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" // Convert currency and check the result","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" double convertedAmount \u003d exchangeRateManager.convertCurrency(currency, amount);","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" assertEquals(76.923, convertedAmount, 0.001);","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"limyuhching":68}},{"path":"src/test/java/seedu/duke/financialrecords/ExpenseTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.fail;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Test suite for the {@link Expense} class.","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * This class contains unit tests to validate the behavior of the Expense class and ensure","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * correctness in the representation and management of financial expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"public class ExpenseTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private Expense expense;","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" * Initializes common test fixtures before each test execution.","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" expense \u003d new Expense(\"Lunch\", LocalDate.now().minusDays(1), 20.00);","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" fail(\"Setup failed due to exception: \" + e.getMessage());","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the description of an Expense object is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" void testExpenseDescription_notEmpty(){","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e new Expense(\"\", LocalDate.now(), 20.00));","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the amount of an Expense object is negative.","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" void testExpenseAmount_notNegative(){","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e new Expense(\"Lunch\", LocalDate.now(), -20.00));","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the date of an Expense object is in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" void testExpenseDate_notFuture(){","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e new Expense(\"Lunch\", LocalDate.now().plusDays(1), 20.00));","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * Tests if the correct description of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" void getDescription() {","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Lunch\", expense.getDescription());","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" * Tests if the correct date of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" void getDate() {","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.now().minusDays(1), expense.getDate());","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * Tests if the correct amount of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" void getAmount() {","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" assertEquals(20.00, expense.getAmount());","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" * Tests if the correct date string of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" void getDateString() {","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.now().minusDays(1).format(DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\")),","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" expense.getDateString());","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" * Tests the string representation of the Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" void testToString() {","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Expense: Lunch | Date: \" +","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" LocalDate.now().minusDays(1).format(DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\")) +","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" \" | Amount: $20.00\",","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" expense.toString());","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":101}},{"path":"src/test/java/seedu/duke/financialrecords/IncomeTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"public class IncomeTest {","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" public void testIncomeCreation() throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" assertNotNull(income);","lastModifiedDate":"2023-10-12"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Salary\", income.getDescription());","lastModifiedDate":"2023-10-12"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.of(2023, 10, 12), income.getDate());","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" assertEquals(5000.00, income.getAmount());","lastModifiedDate":"2023-10-12"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" public void testToString() throws KaChinnnngException{","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" String expected \u003d \"Income: Salary | Date: 12/Oct/2023 | Amount: $5000.00\";","lastModifiedDate":"2023-10-12"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" assertEquals(expected, income.toString());","lastModifiedDate":"2023-10-12"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" public void testInvalidDescription() {","lastModifiedDate":"2023-10-12"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-12"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" new Income(\"\", LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-12"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" public void testInvalidAmount() {","lastModifiedDate":"2023-10-12"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-12"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" new Income(\"Salary\", LocalDate.of(2023, 10, 12), -5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-12"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":42}},{"path":"src/test/java/seedu/duke/parser/ExpenseParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"public class ExpenseParserTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the date is parsed correctly.","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the parsed date is invalid","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" void parseDate_validDate_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" LocalDate expectedDate \u003d LocalDate.of(2020, 02, 29);","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" LocalDate actualDate \u003d ExpenseParser.parseDate(\"29/02/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedDate, actualDate);","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid day.","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" void parseDate_invalidDay_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseDate(\"32/02/2020\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid year.","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" void parseDate_invalidDate_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseDate(\"10/10/20202\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse a date that is in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" void parseDate_futureDate_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseDate(\"10/10/3021\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * It verifies if the food category are correctly parsed into an Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException for invalid scenarios","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" void testParseExpense_foodCategory_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, \"lunch\");","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" assertTrue(ExpenseParser.parseExpense(expenseFields) instanceof Food);","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" * It verifies if the transport category are correctly parsed into an Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException for invalid scenarios","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" void testParseExpense_transportCategory_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"transport\");","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, \"bus\");","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"from nus to changi\");","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"1.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" assertTrue(ExpenseParser.parseExpense(expenseFields) instanceof Transport);","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" * It verifies if the utilities category are correctly parsed into an Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException for invalid scenarios","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" void testParseExpense_utilitiesCategory_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"utilities\");","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, \"electricity\");","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"air con bill\");","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"50.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" assertTrue(ExpenseParser.parseExpense(expenseFields) instanceof Utilities);","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for an unrecognized category.","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" void testParseExpense_invalidCategory_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"invalid\");","lastModifiedDate":"2023-10-18"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for missing amount fields.","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" void testParseExpense_missingAmountField_success() {","lastModifiedDate":"2023-10-18"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for missing description fields.","lastModifiedDate":"2023-10-18"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" void testParseExpense_missingDescriptionFields_success(){","lastModifiedDate":"2023-10-18"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for missing date fields.","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" void testParseExpense_missingDateField_success(){","lastModifiedDate":"2023-10-18"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" * Tests if the getIndex method in ExpenseParser throws an exception for a valid index format.","lastModifiedDate":"2023-10-18"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" void testGetIndexValid() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.INDEX_FIELD, \"1\");","lastModifiedDate":"2023-10-18"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":" assertEquals(1, ExpenseParser.getIndex(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" * Tests if the getIndex method in ExpenseParser throws an exception for an invalid index format.","lastModifiedDate":"2023-10-18"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" void testGetIndexInvalid() {","lastModifiedDate":"2023-10-18"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.INDEX_FIELD, \"a\");","lastModifiedDate":"2023-10-18"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.getIndex(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the provided amount exceeds the limit.","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" void testParseAmount_aboveLimit_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"1000000.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the category field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":" void testParseCategory_emptyString_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"9999.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the description field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":" void testParseDescription_emptyString_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"9999.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the date field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" void testParseDate_emptyString_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"9999.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":247,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":248,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":250,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":251,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the amount field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":252,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":253,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":254,"author":{"gitId":"bljhty"},"content":" void testParseAmount_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":255,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":256,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":257,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":258,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":260,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":261,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":262,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":263,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":258,"Hongzhii":5}},{"path":"src/test/java/seedu/duke/parser/FindParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertArrayEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * JUnit test class for FindParser.","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * This class tests if the find command is parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * It also tests if the correct exceptions are thrown when the command is invalid.","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"public class FindParserTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * This method tests if the find command is parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the parameters are parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the command format is invalid","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" public void validFindCommand_parsedCorrectly() throws KaChinnnngException{","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" String[] expected \u003d {\"expense\", \"food\", \"lunch\", \"12/Oct/2023\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" String[] result \u003d FindParser.parseFindCommand(\"/t expense /cat food /de lunch /date 12/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" assertArrayEquals(expected, result);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" * This method tests if the correct exception is thrown when the type is missing.","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" public void missingMandatoryTypeField_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/cat food /de lunch /date 12/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" * This method tests if the correct exception is thrown when the type is invalid.","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the correct exception is thrown when the type is not \"expense\" or \"income\".","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" public void usingInvalidParameter_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /cat food /de lunch /date 12/Oct/2023 /invalid\");","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when the full word for type is used instead of the shortcut.","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" public void usingFullWordTypeInsteadOfShortcut_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/type expense /cat food /de lunch /date 12/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when only the mandatory type parameter is provided,","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" * and all other optional parameters are missing.","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void missingAllOptionalFields_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense\");","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when a parameter is provided without its corresponding value.","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" public void missingValueForParameter_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t \");","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /cat \");","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" * Tests the correct parsing of a valid find command with the \"income\" type and no category.","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" * Expects successful parsing into an array of parameters.","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the command format is invalid","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" public void validFindCommandWithIncomeType_noCategoryParsed() throws KaChinnnngException {","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" String[] expected \u003d {\"income\", null, \"bonus\", \"15/Oct/2023\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" String[] result \u003d FindParser.parseFindCommand(\"/t income /de bonus /date 15/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" assertArrayEquals(expected, result);","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" * Tests the correct parsing of a valid find command with only type and category.","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" * Expects successful parsing into an array of parameters.","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the command format is invalid","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" public void validFindCommandWithOnlyTypeAndCategory_parsedCorrectly() throws KaChinnnngException {","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" String[] expected \u003d {\"expense\", \"food\", null, null};","lastModifiedDate":"2023-10-30"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" String[] result \u003d FindParser.parseFindCommand(\"/t expense /cat food\");","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" assertArrayEquals(expected, result);","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when deprecated parameter names are used.","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" public void usingOldParameterNames_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /description value\");","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /category food\");","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown for an empty command string.","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" public void emptyCommand_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown for a command string consisting only of spaces.","lastModifiedDate":"2023-10-30"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" public void commandWithOnlySpaces_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\" \");","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown for a command containing a parameter that doesn\u0027t exist.","lastModifiedDate":"2023-10-30"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" public void findCommandWithNonexistentParameter_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /nonexistent value\");","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"bljhty":150}},{"path":"src/test/java/seedu/duke/parser/IncomeParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-13"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-13"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-13"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-13"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-13"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-13"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-13"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-13"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Contains JUnit tests for the {@code IncomeParser} class. This class ensures that the parsing methods","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * related to incomes function as expected and handle invalid inputs gracefully.","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"public class IncomeParserTest {","lastModifiedDate":"2023-10-13"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" * This method tests the parseIncome method in IncomeParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" * It verifies if the incomeFields are correctly parsed into an Income object.","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" public void testParseIncome() throws KaChinnnngException {","lastModifiedDate":"2023-10-13"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-13"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-13"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-13"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5000.00\");","lastModifiedDate":"2023-10-13"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" Income income \u003d IncomeParser.parseIncome(incomeFields);","lastModifiedDate":"2023-10-13"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Salary\", income.getDescription());","lastModifiedDate":"2023-10-13"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.of(2023, 10, 12), income.getDate());","lastModifiedDate":"2023-10-13"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" assertEquals(5000.00, income.getAmount());","lastModifiedDate":"2023-10-13"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the date is parsed correctly.","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the parsed date is invalid","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" public void testParseDate_validDate() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" LocalDate result \u003d IncomeParser.parseDate(\"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.of(2023, 10, 12), result);","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid date.","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" * @see KaChinnnngException if the parsed date is invalid","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" public void testParseDate_invalidDate() {","lastModifiedDate":"2023-10-13"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseDate(\"12/13/2023\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse a date that is in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" public void testParseDate_futureDate() {","lastModifiedDate":"2023-10-13"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseDate(\"12/10/2025\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid day.","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" void testParseDate_invalidDay(){","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseDate(\"32/10/2023\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" * This method tests the getIndex method in IncomeParser when trying to get index from an empty input.","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" public void testGetIndex_missingField() {","lastModifiedDate":"2023-10-13"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-13"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs amount that is above the limit.","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" void testParseAmount_aboveLimit_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"1000000000.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an empty string for description.","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" void testParseDescription_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"10.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an empty string for date.","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" void testParseDate_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"10.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an empty string for amount.","lastModifiedDate":"2023-10-18"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" void testParseAmount_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-18"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an invalid index.","lastModifiedDate":"2023-10-18"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" * Specifically negative index","lastModifiedDate":"2023-10-18"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" void testGetIndex_negativeIndex_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" inputMap.put(IncomeParser.INDEX_FIELD, \"-1\");","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-18"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an invalid index.","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" * Specifically zero index","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" void testGetIndex_zeroIndex_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" inputMap.put(IncomeParser.INDEX_FIELD, \"0\");","lastModifiedDate":"2023-10-18"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-18"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" * Tests for an exception when a zero index is provided in the input data.","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" void testParseIncome_nullArguments_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(null));","lastModifiedDate":"2023-10-29"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" * Checks if an exception is thrown when null arguments are passed to the {@code parseIncome} method.","lastModifiedDate":"2023-10-30"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" void testParseIncome_missingDescription_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5000.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the date is missing in incomeFields.","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" void testParseIncome_missingDate_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5000.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" * Checks if an exception is thrown when the amount is missing in incomeFields.","lastModifiedDate":"2023-10-30"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" void testParseIncome_missingAmount_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" * Validates that an exception is thrown when the amount in incomeFields has an invalid format.","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" void testParseAmount_invalidFormat_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5,000.00\"); // Comma is not expected","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":" * Tests for an exception when a non-numeric value is provided for the index in the input data.","lastModifiedDate":"2023-10-30"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":" void testGetIndex_invalidFormat_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" inputMap.put(IncomeParser.INDEX_FIELD, \"abc\");","lastModifiedDate":"2023-10-29"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" * Checks if an exception is thrown when an unrecognized field is provided in incomeFields.","lastModifiedDate":"2023-10-30"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" void testParseIncome_nonExistingField_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" incomeFields.put(\"nonExistingField\", \"Value\");","lastModifiedDate":"2023-10-29"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-13"}],"authorContributionMap":{"bljhty":242}},{"path":"src/test/java/seedu/duke/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":" * JUnit test class for Parser.","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * This class tests if the commands are parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * It also tests if the correct exceptions are thrown when the command is invalid.","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"public class ParserTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" public void testParse_exitCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" assertEquals(\"exit\", Parser.parse(\"exit\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" public void testParse_addExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" assertEquals(\"add_expense\",","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" Parser.parse(\"add Expense /de lunch /amt 5.00 /cat food /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" public void testParse_addIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" assertEquals(\"add_income\",","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" Parser.parse(\"add Income /de salary /amt 5000.00 /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" public void testParse_listExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" assertEquals(\"list_expense\", Parser.parse(\"list Expense\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" public void testParse_listIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" assertEquals(\"list_income\", Parser.parse(\"list Income\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" public void testParse_deleteExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" assertEquals(\"delete_expense\", Parser.parse(\"delete Expense /i 1\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" public void testParse_deleteIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" assertEquals(\"delete_income\", Parser.parse(\"delete Income /i 1\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" public void testParse_findCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assertEquals(\"find\", Parser.parse(\"find /t expense /cat food /de lunch /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" public void testParse_helpCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" assertEquals(\"help\", Parser.parse(\"help\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void testParse_invalidCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" assertEquals(\"invalid\", Parser.parse(\"invalid\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public void testParse_listCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" assertEquals(\"list\", Parser.parse(\"list\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" public void testParse_balanceCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" assertEquals(\"balance\", Parser.parse(\"balance\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public void testParse_clearIncomesCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" assertEquals(\"clear_incomes\", Parser.parse(\"clear incomes\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" public void testParse_clearExpensesCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" assertEquals(\"clear_expenses\", Parser.parse(\"clear expenses\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" public void testParse_clearAllCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" assertEquals(\"clear_all\", Parser.parse(\"clear all\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" public void testParse_editIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" assertEquals(\"edit_income\", Parser.parse(\"edit income /i 1 /de salary /amt 5000.00 /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" public void testParse_editExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" assertEquals(\"edit_expense\", Parser.parse(\"edit expense /i 1 /de lunch /amt 5.00 /cat food /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"bljhty":101}},{"path":"src/test/java/seedu/duke/storage/ExchangeRateFileHandlerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import java.io.PrintWriter;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateFileHandlerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateFileHandler fileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.clear();","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" public void testLoad_validFileFormat_exchangeRateMatches() throws FileNotFoundException, KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" fileHandler \u003d new ExchangeRateFileHandler(\"./src/test/testData/ExchangeRatesTestLoad.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" fileHandler.load();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" // Verify that the loaded exchange rates match the original ones","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" assertEquals(1.0, exchangeRateManager.getExchangeRate(\"USD\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" assertEquals(0.85, exchangeRateManager.getExchangeRate(\"EUR\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" public void testSave_validInput_fileContentMatches() throws KaChinnnngException, FileNotFoundException {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" // load or create filepath","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" String filePath \u003d \"./src/test/testData/ExchangeRatesTestSave.txt\";","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" createFile(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" new PrintWriter(filePath).close(); // clears the file","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" fileHandler \u003d new ExchangeRateFileHandler(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" fileHandler.load();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" // Define test data","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(\"USD\", 1.0);","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" // Save the exchange rates to the file","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" fileHandler.save(exchangeRateManager.getExchangeRates());","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" String textLine \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" assertEquals(\"USD,1.0\", textLine);","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" private boolean createFile(String filePath) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" if (!file.getParentFile().exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" file.getParentFile().mkdirs();","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" return file.createNewFile();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Cannot create file; reason: \" + e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"limyuhching":69}},{"path":"src/test/java/seedu/duke/storage/GetFromTxtTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearAll;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"public class GetFromTxtTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" private String path;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" private String []lines \u003d new String[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" path \u003d \"Test.txt\";","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeToTextFile(ArrayList)} method with multiple incomes records without expenses,","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the more than one income from the txt file save to the list correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithMoreThanOneIncomes() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Salary\", newIncomes.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Bonus\", newIncomes.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 10), newIncomes.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 15), newIncomes.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" assertEquals(5000.0, newIncomes.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" assertEquals(1000.0, newIncomes.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link GetFromTxt#getFromTextFile(ArrayList, ArrayList)} method","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" * with different expense type without incomes, This test case checks whether the different type of expenses","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" * from the txt file save to the list correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithDifferentExpenseType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\",","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\",","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 2),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"chicken sandwich\", newExpenses.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Taxi\", newExpenses.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Electricity\", newExpenses.get(2).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 1), newExpenses.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 2), newExpenses.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 3), newExpenses.get(2).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" assertEquals(10.0, newExpenses.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" assertEquals(50.0, newExpenses.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" assertEquals(100.0, newExpenses.get(2).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" assertEquals(MealType.LUNCH, ((Food) newExpenses.get(0)).getMealType());","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" assertEquals(TransportationType.FUEL, ((Transport) newExpenses.get(1)).getTransportationType());","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" assertEquals(UtilityType.ELECTRICITY, ((Utilities) newExpenses.get(2)).getUtilityType());","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link GetFromTxt#getFromTextFile(ArrayList, ArrayList)} method with different expense type and incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the different type of expenses and income record get from","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":" * the txt file save to the list correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithDifferentIncomesAndExpenses() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\",","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\",","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 2),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\",","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\",","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes,expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"chicken sandwich\", newExpenses.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Taxi\", newExpenses.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Electricity\", newExpenses.get(2).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 1), newExpenses.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 2), newExpenses.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 3), newExpenses.get(2).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"KenCheung18"},"content":" assertEquals(10.0, newExpenses.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"KenCheung18"},"content":" assertEquals(50.0, newExpenses.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"KenCheung18"},"content":" assertEquals(100.0, newExpenses.get(2).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"KenCheung18"},"content":" assertEquals(MealType.LUNCH, ((Food) newExpenses.get(0)).getMealType());","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"KenCheung18"},"content":" assertEquals(TransportationType.FUEL, ((Transport) newExpenses.get(1)).getTransportationType());","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"KenCheung18"},"content":" assertEquals(UtilityType.ELECTRICITY, ((Utilities) newExpenses.get(2)).getUtilityType());","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Salary\", newIncomes.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Bonus\", newIncomes.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 10), newIncomes.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 15), newIncomes.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"KenCheung18"},"content":" assertEquals(5000.0, newIncomes.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"KenCheung18"},"content":" assertEquals(1000.0, newIncomes.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link GetFromTxt#getFromTextFile(ArrayList, ArrayList)} method with Both incorrect format.","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the program still working when user changes the txt file.","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithWrongFormat() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"KenCheung18"},"content":" try (FileWriter fw \u003d new FileWriter(path)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"nolthing special\");","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | 10000000000.0 | 2023-10-01 | 2\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | -1 | 2023-10/01 | 2\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF \\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"ABC | chicken sandwich | 1000.0 | 2023-10-01 | 1\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | 1000.0 | 2023-10-01 | asdf\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | 10000000000.0 | 2023-10-01 | 32\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Error\");","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, newIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, newExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":167}},{"path":"src/test/java/seedu/duke/storage/SaveToTxtTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearAll;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link SaveToTxt} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check whether incomes and expenses records","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" * are saved correctly to the txt file","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":"public class SaveToTxtTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" private String path;","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" private String []lines \u003d new String[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" path \u003d \"Test.txt\";","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeToTextFile(ArrayList)} method with income only.","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the one incomes record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithOneIncome() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" String line \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Salary | 5000.0 | 2023-10-10\", line);","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeToTextFile(ArrayList)} method with incomes only.","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the multiple incomes record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithMoreThanOneIncomes() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Salary | 5000.0 | 2023-10-10\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Bonus | 1000.0 | 2023-10-15\" ,lines[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with expense of Food type only.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the Food expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithFoodType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\", LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EF | chicken sandwich | 10.0 | 2023-10-01 | 2\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with expense of Transportation type only.","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the Transportation type expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithTransportationType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\", LocalDate.of(2023, 10, 1),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"ET | Taxi | 50.0 | 2023-10-01 | 4\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with expense of Utility type only.","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the Utility expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithUtilityType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\", LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EU | Electricity | 100.0 | 2023-10-03 | 2\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with different expense type but no incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the different type of expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithDifferentExpenseType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\", LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\", LocalDate.of(2023, 10, 1),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\", LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EF | chicken sandwich | 10.0 | 2023-10-01 | 2\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"ET | Taxi | 50.0 | 2023-10-01 | 4\", lines[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EU | Electricity | 100.0 | 2023-10-03 | 2\", lines[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeAndExpense(ArrayList, ArrayList)} method with both incomes and expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether both incomes and expenses can save correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithDifferentExpensesAndIncomes() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\", LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\", LocalDate.of(2023, 10, 1),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\", LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes,expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":187,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":188,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":189,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":190,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":191,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":192,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":193,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":194,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Salary | 5000.0 | 2023-10-10\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":195,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Bonus | 1000.0 | 2023-10-15\" ,lines[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":196,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EF | chicken sandwich | 10.0 | 2023-10-01 | 2\", lines[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":197,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"ET | Taxi | 50.0 | 2023-10-01 | 4\", lines[3]);","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EU | Electricity | 100.0 | 2023-10-03 | 2\", lines[4]);","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":200}},{"path":"src/test/java/seedu/duke/ui/MockUi.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"public class MockUi extends Ui{","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" private List\u003cString\u003e printedMessages \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" private List\u003cString\u003e showIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" private List\u003cString\u003e showExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public void printMessage(String message) {","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" printedMessages.add(message);","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncomes(List\u003cIncome\u003e matchingIncomes) {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" showIncomes.add(matchingIncomes.toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses(List\u003cExpense\u003e matchingExpenses) {","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" showExpenses.add(matchingExpenses.toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" public List\u003cString\u003e getPrintedMessages() {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" return printedMessages;","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" public List\u003cString\u003e getShowIncomes() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" return showIncomes;","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" public List\u003cString\u003e getShowExpenses() {","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" return showExpenses;","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":40}},{"path":"src/test/java/seedu/duke/ui/UiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.io.ByteArrayInputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"public class UiTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public void readCommand_validInput_commandReturned() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" // Set up simulated user input","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" ByteArrayInputStream in \u003d new ByteArrayInputStream(\"testCommand\".getBytes());","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" System.setIn(in);","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" // Act","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" String command \u003d ui.readCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" assertEquals(\"testCommand\", command);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" public void readCommand_noInput_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" // Set up simulated user input with no data","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" ByteArrayInputStream in \u003d new ByteArrayInputStream(\"\".getBytes());","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" System.setIn(in);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" // Act and Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, ui::readCommand);","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" public void printWelcomeMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" Ui.printWelcomeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assertEquals(\"____________________________________________________________\"+ System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" + \"Welcome to KaChinnnngggg! How may i assist you today?\"+ System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" + \"____________________________________________________________\"+ System.lineSeparator(),","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" public void printGoodbyeMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" ui.printGoodbyeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertEquals(\"____________________________________________________________\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" + \"Bye. Hope to see you again soon!\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" + \"____________________________________________________________\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" , out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public void showLineDivider_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" assertEquals(\"____________________________________________________________\"+ System.lineSeparator(),","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" public void printListIncomeMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" ui.printListIncomeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are your incomes:\" + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" public void printListExpenseMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" ui.printListExpenseMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are your expenses:\" + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncomes_nullTest() {","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" ui.showMatchingIncomes(null);","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" assertEquals(\"No matching incomes found.\", out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncome_correctTest(){","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" Income income \u003d null;","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" List\u003cIncome\u003e incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" income \u003d new Income(\"Test Description\", LocalDate.now(), 100.0);","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" incomes.add(income);","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" e.printStackTrace();","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" ui.showMatchingIncomes(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are the matching incomes in your list:\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" + income.toString() + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses_nullTest() {","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" ui.showMatchingExpenses(null);","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" assertEquals(\"No matching expenses found.\", out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses_correctTest(){","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" Expense expense \u003d null;","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" List\u003cExpense\u003e expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" expense \u003d new Expense(\"Test Description\", LocalDate.now(), 100.0);","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" expenses.add(expense);","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" e.printStackTrace();","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" ui.showMatchingExpenses(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are the matching expenses in your list:\"","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" + System.lineSeparator() + expense.toString() + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"bljhty":185}}] +[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" implementation group: \u0027com.google.code.gson\u0027, name: \u0027gson\u0027, version: \u00272.10.1\u0027","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":33,"author":{"gitId":"-"},"content":" mainClass.set(\"seedu.duke.Duke\")","lastModifiedDate":"2023-08-05"},{"lineNumber":34,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveBaseName.set(\"duke\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":39,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":42,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":"run {","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":5,"-":46}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"Display | Name | Github Profile | Portfolio ","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"--------|:-----------------:|:----------------------------------------:|:---------:","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Cheung Ka Yuen | [Github](https://github.com/KenCheung18) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Lee Jun Hao Bryan | [Github](https://github.com/bljhty) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Lim Yuh Ching | [Github](https://github.com/limyuhching) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Ee Hong Zhi | [Github](https://github.com/Hongzhii) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"-"},"content":"![](https://via.placeholder.com/100.png?text\u003dPhoto) | Don Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"limyuhching":1,"bljhty":2,"Hongzhii":1,"KenCheung18":1,"-":4}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"We first give acknowledgement to Module Coordinator, Dr Akshay Narayan, and Teaching Assistant, Aditi Chadha for guidance and supervision over the KaChinnnng project.","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"We utilised the following resources to aid us in the development of KaChinnnng:","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"- [tp project](https://github.com/nus-cs2113-AY2324S1/tp) of the nus-cs2113-AY2324S1 organisation","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"- [addressbook-level2](https://github.com/se-edu/addressbook-level2) \u0026 [addressbook-level3](https://github.com/se-edu/addressbook-level3) project by SE-EDU largely inspired the format and coding style of KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"## Design \u0026 implementation","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"Below are the design and implementation details of KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"### Design","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"The architectural diagram of KaChinnnng is as follows:","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"![ArchitectureDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/ArchitectureDiagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"The kaChinnnng program will first enter the `run` state where the `storage` class will be accessed and data will be retrieved if the application has been used before.","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"Next, the `User` will input various `commands` via the `Ui` class. The `commands` will then be parsed by the `Parser` class and the relevant `managers` will be called to execute the `commands`.","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"Once the `User` inputs has been successfully executed, `commands` will make use of the `Ui` class to output the relevant information to the user.","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"When the `User` exits the program, the `storage` class will be called to save the data to the local storage.","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"`Storage` will read from the local storage when the program is run again.","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":"### Expense Class Overview","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":"The Expenses are divided into three categories. Transport, Utilities and Food.","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":"Each of the categories inherit from a base Expense class which in turn","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":"inherits from the FinancialRecord class.","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":"![expense_class_diagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/expense_class_diagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"### IncomeManager","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"the IncomeManager is facilitated by `IncomeParser`, `IncomeManager`, `IncomeList` and `Ui`.","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":"1. The user inputs the command to add income. This input is then passed to `IncomeParser` to be parsed.","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"2. `IncomeParser` then parses the input and returns a `Income` object.","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":"3. `IncomeManager` then adds the `Income` object to the `IncomeList`.","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"4. `IncomeManager` then returns a `String` to `Ui` to be printed out to the user.","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":"![IncomeManager_seqdiagram.drawio.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/IncomeManager_seqdiagram.drawio.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"### ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":"The ExpenseManager is facilitated by `ExpenseParser`, `ExpenseManager`, `ExpenseList` and `Ui`","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":"1. The user inputs the command to add expense.","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":"2. This command is used to instantiate a ExpenseManager object which is executed.","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":"3. During execution, the command is passed to ExpenseParser which extracts and parses the input fields.","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":"4. Input field information is passed to the relevant Expense constructor which returns a Expense object.","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":"5. Expense object is returned to ExpenseManager from ExpenseParser.","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":"6. Expense obejct is returned to Duke from ExpenseManager.","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":"![expenseManager_sequence_diagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/expenseManager_sequence_diagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"### Find Command","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"The FindCommand is facilitated by `FindCommand`, `FindParser`, `Ui`,`ExpenseList` and `IncomeList`.","lastModifiedDate":"2023-10-25"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"1. The user will first input the command to find the expense or income.","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"find /t \u003ctype\u003e /cat [category] /de [description] /date [date]","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":"2. The inputs will then be passed to `FindParser` to get the necessary fields such as type, category, description and date.","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"3. The FindCommand is then instantiated with the necessary fields.","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":"4. Users can choose to search through the expense list or income list.","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"5. If users searches through the income list, either the description or date will be used to search through the income list.","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":"6. If users searches through the expense list, either the category or date will be used to search through the expense list.","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":"7. The execute method will then be called to search through the list and return the list of expenses or incomes that matches the search criteria.","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":"![FindCommand_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/FindCommand_SequenceDiagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":"### GetFromTxt Command","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":"The GetFromTxt Command is facilitated by `IOException`,`Scanner`, `KaChinnnnngException`, `IncomeList` and `ExpenseList`","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":"1. The user start the program and the command will start automatically with a default path","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":"2. Once the command executed, it will try to create an txt file on the default path","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":"3. If file failed to create, throw an `IOException`","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":"4. Catch the `IOExceotion` and print error messages","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":"5. Create a `Scanner` Object s to get content from txt file","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":"6. If amount in txt file exceed limit or incorrect, throw `KaChinnnningException`","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":"7. Read the content on the file and add corresponding object to incomes or expenses list","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":"![GetFromTxtCommands_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/GetFromTxt.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":"### ExchangeRateManager","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"limyuhching"},"content":"The Sequence Diagram below shows how the components interact with each other for the scenario ","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"limyuhching"},"content":"where the user issues the command `update exchange rate USD 0.8`.","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":"![UpdateExchangeRate_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/UpdateExchangeRate_SequenceDiagram.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":"This is facilitated by `Duke`, `UpdateExchangeRateCommand`, `ExchangeRateManager`\u0027and `ExchangeRateFileHandler`.","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":"### SaveToTxt Command","lastModifiedDate":"2023-11-01"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":"The SaveToTxt Command is facilitated by `FileWriter` ,`IncomeList` and `ExpenseList`","lastModifiedDate":"2023-11-01"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":"1. The user start the program and the function will run everytime after user input a command","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":"2. Once the command executed, the function saveIncomeAndExpense will run automatically","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":"3. It will run the function saveIncomeToTextFile first, the saveIncomeToTextFile will create a FileWriter and loop through the incomes list","lastModifiedDate":"2023-11-01"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":"4. It will get description, date, and amount from the income list for every single income record in the list and save the information into the text file","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":"5. After that, the saveIncomeToTextFile will then call the saveExpenseToTextFile function ","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":"6. The saveExpenseToTextFile will create a new FileWriter and loop through the expenses list ","lastModifiedDate":"2023-11-01"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":"7. It will get description, date, amount and type from the expenses list for every single expense record in the list and save the information into the text file","lastModifiedDate":"2023-11-01"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":"![SaveToTxt_SequenceDiagram.png](https://github.com/AY2324S1-CS2113-T18-3/tp/blob/master/images/SaveToTxt.png?raw\u003dtrue)","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":111,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":112,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":113,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":114,"author":{"gitId":"-"},"content":"{Describe the target user profile}","lastModifiedDate":"2020-05-24"},{"lineNumber":115,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":116,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":117,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":118,"author":{"gitId":"-"},"content":"{Describe the value proposition: what problem does it solve?}","lastModifiedDate":"2020-05-24"},{"lineNumber":119,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":120,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":121,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":122,"author":{"gitId":"-"},"content":"| Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2020-05-24"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":"|---------|----------|------------------------------------|-----------------------------------------------------------------------|","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"-"},"content":"| v1.0 |new user| see usage instructions | refer to them when I forget how to use the application |","lastModifiedDate":"2020-05-24"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| add new income entry | track all my incomes |","lastModifiedDate":"2023-10-25"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| add new expense entry | track all of my expenses |","lastModifiedDate":"2023-10-25"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| delete income entry | remove incomes that I no longer want to track |","lastModifiedDate":"2023-10-25"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| delete expense entry | remove expenses that I no longer want to track |","lastModifiedDate":"2023-10-25"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| list both income and expense entry | view all my expenses and incomes |","lastModifiedDate":"2023-10-25"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"| v1.0 |user| check my balace | better bugdet my expenditures |","lastModifiedDate":"2023-10-25"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| search for past inputs | better find and track my past expenses |","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| be able to change the currency | better track my expenses in different currencies when i am travelling |","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| be able to edit my inputs | make necessary changes to my inputs when a mistake is made |","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| be able to save and load my inputs | save my inputs so that I can access them the next time I use the app |","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":"| v2.0 |user| reset my inputs | start afresh |","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":137,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":"- Domain rules:","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" - The application should not crash under normal circumstances.","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" - Dates can be entered in the format of dd/mmm/yyyy or dd/mm/yyyy and should not be in the future.","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" - Amount added should be in the format of 0.00 and should not be negative.","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" - The application only accepts commands in English.","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" - Users should refrain from using special characters in the description/category/type/date field.","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" - Users should refrain from tampering with the storage and log files as it may result in unexpected issues.","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":"- Constraints:","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" - the total number of entries for Expense and Income should not exceed 10 000 each.","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" - the amount input should be less than 1 billion.","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":"- Technical Requirements:","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" - The application must be able to run on Windows, MacOS and Linux.","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":"- Technical Requirements:","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" - KaChinnnng should be able to be used by users of all skill levels.","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":"- Others:","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" - Arguments should follow the format specified in the user guide.","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" - Should the arguments not be in the provided format, the application will not execute the command.","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":159,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":160,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":161,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":"| Term | Definition |","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":"|---------|------------|","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":"| Income | debit entry of user|","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":"| Expense | credit entry of user|","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":"| Balance | Net Amount|","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":"| Ui | User Interface, where user inputs commands and sees output|","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"| Parser | Parses user input into commands|","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":171,"author":{"gitId":"-"},"content":"## Instructions for manual testing","lastModifiedDate":"2020-05-24"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":"Given below are the instructions for manual testing of KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"### Launching and exiting the application","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":"1. lauching the application","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" 1. download the jar file from the release page.","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" 2. open a terminal and navigate to the directory where the jar file is located.","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" 3. run the command `java -jar KaChinnnng.jar`","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":"2. exiting the application","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" 1. type `exit` in the command box and press enter.","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" 2. the application will exit.","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":"### Adding an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":"1. adding an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" 1. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" - To add an income: `add income /de \u003cdescription\u003e /date \u003cDD/MM/YYYY\u003e /amt \u003camount\u003e`","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" - To add an expense: `add expense /cat food /type lunch /de sushi /date 31/10/2023 /amt 20.00`","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" - /type for expense includes (`UNDEFINED`, `BREAKFAST`, `LUNCH`, `DINNER`) for the `food` category, (`TRAIN`, `BUS`, `TAXI`, `FUEL`, `UNDEFINED`) for the `TRANSPORT` category and (`UNDEFINED`, `WATER`, `ELECTRICITY`, `GAS`) for the `UTILITIES` category.","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" - Expected outcome: the income/expense will be added to the list and the balance will be updated accordingly and the user will be notified.","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" 2. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary`","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" - expense: `add expense /cat food /type lunnch`","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" - Expected outcome: the income/expense will not be added to the list and the user will be notified with an error message.","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" 3. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" - Other invalid test cases includes:","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary /date 31/11/2023 /amt 5000.00` where the date is in the future.","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary /date 31-10-2023 /amt 5000.00` where the date is in the wrong format.","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" - income: `add income /de salary /date 31/10/2023 /amt -5000.00` where the amount is negative.","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" - expense: `add expense /cat food /type lunch /de lunch /amt 5000.00` where there is missing fields","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":"### Deleting an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"limyuhching"},"content":"Deleting income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"limyuhching"},"content":"1. Test case: If there the index specified invalid","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `delete income \u003cinvalid_index\u003e`","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `Oops! Income \u003cinvaldi_index\u003e does not exist`","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"limyuhching"},"content":"2. Test case: If the index is missing","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `delete income`","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `You\u0027re missing an argument`","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"limyuhching"},"content":"3. Test case: If there index is not an integer","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `delete income abc`","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `Oops! An integer index is expected`","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":"### Editing an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"limyuhching"},"content":"Editing income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"limyuhching"},"content":"1. Test case: If there the index specified invalid","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"limyuhching"},"content":" - For income/expense: `edit income \u003cinvalid_index\u003e income /de \u003cdescription\u003e /date \u003cDD/MM/YYYY\u003e /amt \u003camount\u003e`","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: `Oops! Income \u003cinvaldi_index\u003e does not exist`","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"limyuhching"},"content":"2. Test case: Missing arguments","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"limyuhching"},"content":" Assuming Income 1 and Expense 1 exist:","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary`","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"limyuhching"},"content":" - expense: `edit expense 1 /cat food /type lunnch`","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"limyuhching"},"content":" - Expected outcome: the income/expense will not be edited and the user will be notified with an error message.","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"limyuhching"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"limyuhching"},"content":"4. Test case: Other invalid test cases includes:","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"limyuhching"},"content":" Assuming index Income 1 exist:","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary /date 31/11/2023 /amt 5000.00` where the date is in the future.","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary /date 31-10-2023 /amt 5000.00` where the date is in the wrong format.","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"limyuhching"},"content":" - income: `edit income 1 /de salary /date 31/10/2023 /amt -5000.00` where the amount is negative.","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"limyuhching"},"content":" - expense: `edit expense 1 /cat food /type lunch /de lunch /amt 5000.00` where there is missing fields","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"### Finding an income/expense","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":"1. Finding income/expense:","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" 1. Pre-requisite: list should already contain income/expense. this can be checked via `list income`, `list expense` or `list`","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" 2. Test case:","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" - For income: `find /t income /de salary`","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" - For expense: `find /t expense /cat food /de sushi /date 31/10/2023`","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" - Expected outcome: all income with description containing \"salary\" should be listed. all expense containing \"food\" in the category, \"sushi\" in the description and \"31/10/2023\" in the date should be listed.","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" 3. Test case: If there is no matching income/expenses","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":" - Income: `find /t income /de bonus`","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" - Expense: `find /t expense /cat food /de burger /date 31/10/2023`","lastModifiedDate":"2023-11-01"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":" - expected: no income/expense should be listed.","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"limyuhching":34,"bljhty":133,"Hongzhii":18,"KenCheung18":30,"-":31}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"# Hi","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"-"},"content":"{Give product intro here}","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"bljhty":1,"-":7}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"# KaChinnnng User Guide","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Introduction","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"Welcome to KaChinnnng a personal finance tracker that helps you keep track of your expenses and income.","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"## Quick Start","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"1. Ensure that you have Java 11 or above installed.","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"2. Download the latest version of `KaChinnnng` from [here](http://link.to/duke).","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"3. Copy the downloaded file to the folder you want to use as the home folder for your KaChinnnng.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"4. open a command terminal and navigate to the folder where you have copied the file to.","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"5. type in the following to run the program","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"java -jar KaChinnnng.jar","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"6. if successful you should see the following output","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"Welcome to KaChinnnngggg! How may i assist you today?","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"7. type in desired commands and press enter to execute them. (note: commands are not case sensitive)","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":"8. \"[ ]\" denotes optional parameters","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":26,"author":{"gitId":"-"},"content":"## Features ","lastModifiedDate":"2020-05-24"},{"lineNumber":27,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":28,"author":{"gitId":"-"},"content":"{Give detailed description of each feature}","lastModifiedDate":"2020-05-24"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"### View help : help","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"Shows basic commands executable by the program.","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"Format:","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"help","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":"### Add an entry: add","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"Creates a new entry for income or expenses in the program.","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"Values of income and expense added has to be lower than 1000000.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"Income and Expense values takes up to 2 decimal places.","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":"To add an income (with foregin currency):","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"add income /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"note:","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"- fields `/de`, `/date`, and `/amt` are case-sensitive and should be in the specified order.","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":"- should users add additional characters behind income eg. add incomeABCDE, the system will still recognise it as add income but not addABCDE income.","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":"- users should not use \"|\" in the description as it is used as a delimiter in the storage file.","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":"To add an expense (with foregin currency):","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":"add expense /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"note:","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"- fields `/cat`, `/type`, `/de`, `date`, and `amt` are case-sensitive and should be in the specified order.","lastModifiedDate":"2023-11-04"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"- should users enter `/cat`, `/type` or the other fields that is case-sensitive, system will take it as missing field.","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"- should users add additional characters behind expense eg. add expenseABCDE, the system will still recognise it as add expense.","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":"- users should not use \"|\" in the description as it is used as a delimiter in the storage file.","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"- There are only 3 categories for expenses: `Food`, `Transport`, `Utilities`.","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":"- There are 3 types associated with `Food` category: `Breakfast`, `Lunch`, `Dinner`, else it will default to `UNDEFINED`.","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"- There are 4 types associated with `Transport` category: `Bus`, `Train`, `Taxi`, `Fuel`, else it will default to `UNDEFINED`.","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"- There are 3 types associated with `Utilities` category: `Water`, `Electricity`, `Gas`, else it will default to `UNDEFINED`.","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"Use case:","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"- Prompts users if any of the fields are empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"- Amount is takes up to 2 decimal places.","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":"- format of date is `dd/mm/yyyy`.","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"- Date needs to be an existing date, and cannot be dates in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":"- By default, amount is set to SGD.","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":"- User can specify the currency. Refer to the supported currencies for valid currency.","lastModifiedDate":"2023-11-01"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":"- Currency specified must have been updated. Refer to list exchange rates for more details","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":76,"author":{"gitId":"-"},"content":"Example of usage:","lastModifiedDate":"2020-05-24"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":"add income /de salary /date 01/01/2020 /amt 1000","lastModifiedDate":"2023-11-01"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"add expense /cat transport /type taxi /de taxi to school /date 10/10/2023 /amt 10.00","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":83,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":84,"author":{"gitId":"limyuhching"},"content":"add expense /cat Food /type lunch /de lunch /date 01/01/2020 /amt 10.50","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"limyuhching"},"content":"add expense /cat Food /type breakfast /de chicken sandwich /date 01/01/2020 /amt USD 10.50","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":"add expense /cat transport /type train /de train to school /date 10/10/2023 /amt 10.00","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"### List all entries: list","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":"Shows a full list of both the expenses and income created by the user.","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":"User can choose to view the list of income/expenses separately as well.","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"Format:","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":"list","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"list income","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":"list expense","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":"### Delete an entry: delete","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":"Deletes an entry from the list of income/expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":"Format:","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":"delete expense \u003cindex\u003e","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":"delete income \u003cindex\u003e","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":"```","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"KenCheung18"},"content":"### Check balance: balance","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"KenCheung18"},"content":"Check the balance for current financial records","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"KenCheung18"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"KenCheung18"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"KenCheung18"},"content":"balance","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"KenCheung18"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"limyuhching"},"content":"### Edit an entry: edit ","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"limyuhching"},"content":"Edit an entry from the list of income/expenses.","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"limyuhching"},"content":"edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"limyuhching"},"content":"edit expense \u003cindex\u003e /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"limyuhching"},"content":"Example of usage:","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"limyuhching"},"content":"edit income 1 /de end of year bonus /date 02/10/2023 /amt HKD 3000.00","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"limyuhching"},"content":"edit expense 2 /cat food /type dinner /de dinner /date 01/10/2023 /amt 10.00","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"limyuhching"},"content":"### List the supported currencies: list currencies","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"limyuhching"},"content":"This function allows user to see the foreign currencies supported by KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"limyuhching"},"content":"Note: The default currency is SGD.","lastModifiedDate":"2023-11-01"},{"lineNumber":149,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":150,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":151,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":152,"author":{"gitId":"limyuhching"},"content":"list currencies","lastModifiedDate":"2023-11-01"},{"lineNumber":153,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":154,"author":{"gitId":"limyuhching"},"content":"Example output:","lastModifiedDate":"2023-11-01"},{"lineNumber":155,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":156,"author":{"gitId":"limyuhching"},"content":"These are the supported currencies:","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"limyuhching"},"content":"MYR USD JPY KRW EUR THB HKD INR IDR AUD GBP CNY CAD TWD VND PHP","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":160,"author":{"gitId":"limyuhching"},"content":"### List exisitng exchange rates: list exchange rates","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"limyuhching"},"content":"List all updated exchange rates. All exchange rates that are updated or loaded","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"limyuhching"},"content":"from ExchangeRate.txt will be shown. User can call the update exchange rates function to ","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"limyuhching"},"content":"register new exchange rates into their KaChinnnng.","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"limyuhching"},"content":"Note: Exchange rates are shown in SGD/{other currency}.","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"limyuhching"},"content":"list exchange rates","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":171,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":172,"author":{"gitId":"limyuhching"},"content":"### update exchange rate","lastModifiedDate":"2023-11-01"},{"lineNumber":173,"author":{"gitId":"limyuhching"},"content":"Update exchange rate of a specific foreign currency. Exchange rates will be saved upon","lastModifiedDate":"2023-11-01"},{"lineNumber":174,"author":{"gitId":"limyuhching"},"content":"successful update.","lastModifiedDate":"2023-11-01"},{"lineNumber":175,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"limyuhching"},"content":"Note: rate specified should be in SGD/{foreign currency}.","lastModifiedDate":"2023-11-01"},{"lineNumber":177,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"limyuhching"},"content":"Format:","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":180,"author":{"gitId":"limyuhching"},"content":"update exchange rate \u003csupported_currency\u003e \u003crate\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":181,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":182,"author":{"gitId":"limyuhching"},"content":"Example","lastModifiedDate":"2023-11-01"},{"lineNumber":183,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":184,"author":{"gitId":"limyuhching"},"content":"update exchange rate USD 0.8","lastModifiedDate":"2023-11-01"},{"lineNumber":185,"author":{"gitId":"limyuhching"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":186,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":187,"author":{"gitId":"-"},"content":"## FAQ","lastModifiedDate":"2020-05-24"},{"lineNumber":188,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":189,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":190,"author":{"gitId":"-"},"content":"**Q**: How do I transfer my data to another computer? ","lastModifiedDate":"2020-05-24"},{"lineNumber":191,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":192,"author":{"gitId":"KenCheung18"},"content":"**A**: Move the txt file from the folder where the jar file located, ","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"KenCheung18"},"content":"to the folder where the jar file located in the new computer ","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":195,"author":{"gitId":"KenCheung18"},"content":"**Q**: What do i need to do when I see the `format incorrect from storage file` at the beginning of running the program","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"KenCheung18"},"content":"**A**: The system will automatically remove that line from the txt after you give the first command to the bot, ","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"KenCheung18"},"content":"if you don\u0027t want to remove that line, just terminate the program using control/command c right after you see the error,","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"KenCheung18"},"content":"and change the line in txt file to the correct format.","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":201,"author":{"gitId":"-"},"content":"## Command Summary","lastModifiedDate":"2020-05-24"},{"lineNumber":202,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":"| Action | Format, Examples |","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":"| ------ |------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":"| Help | `help` |","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":"| Add Income | `add income /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` \u003cbr\u003e e.g., `add income /de salary /date 01/01/2020 /amt 1000` |","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":"| Add Expense | `add expense /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` \u003cbr\u003e e.g., `add expense /cat Food /type lunch /de sushi /date 01/01/2020 /amt 10.50` |","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"limyuhching"},"content":"| List | `list` \u003cbr\u003e `list income` \u003cbr\u003e `list expense` \u003cbr\u003e `list currencies` \u003cbr\u003e `list exchange rates`|","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":"| Delete | `delete expense \u003cindex\u003e` \u003cbr\u003e `delete income \u003cindex\u003e` |","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":"| Edit | `edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` \u003cbr\u003e `edit expense \u003cindex\u003e /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e` |","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"limyuhching"},"content":"| Update Exchange Rate | `update exchange rate \u003csupported_currency\u003e \u003crate\u003e` |","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"limyuhching"},"content":"| Clear |`clear`|","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"limyuhching"},"content":"| Exit |`exit`|","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"limyuhching":79,"bljhty":94,"KenCheung18":15,"-":25}},{"path":"images/expenseManager_sequence_diagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"actor Duke","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"participant ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"participant ExpenseParser","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"participant Expense","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"participant ExchangeRateManager","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"Duke -\u003e ExpenseManager: provides expense details","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"activate ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager -\u003e ExpenseManager: execute()","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"activate ExpenseManager","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager -\u003e ExpenseManager: extractExpenseFields(details)","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager -\u003e ExpenseParser: parseExpense(expenseFields)","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":"activate ExpenseParser","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":"opt isOtherCurrency()","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser -\u003e ExchangeRateManager : convertCurrency()","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"ExchangeRateManager -\u003e ExpenseParser : amount","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser -\u003e ExpenseParser: parseDate(dateField)","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser -\u003e Expense: Expense(description, date, amount, type)","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":"Expense --\u003e ExpenseParser","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":"ExpenseParser --\u003e ExpenseManager","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":"deactivate ExpenseParser","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":"deactivate ExpenseManager","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":"ExpenseManager --\u003e Duke: returns new Expense object","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"deactivate ExpenseManager","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"Hongzhii":27}},{"path":"src/main/java/seedu/duke/Duke.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"package seedu.duke;","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.Balance;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearAll;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearExpenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearIncomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.DeleteExpenseCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.DeleteIncomeCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.EditExpenseCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.EditIncomeCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.ExpenseLister;","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ExpenseManager;","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.FindCommand;","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.IncomeLister;","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.IncomeManager;","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.ListCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.UpdateExchangeRateCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.UsageInstructions;","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.storage.ExchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.storage.GetFromTxt;","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.storage.SaveToTxt;","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-12"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"import seedu.duke.parser.Parser;","lastModifiedDate":"2023-10-12"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"import seedu.duke.parser.FindParser;","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-12"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" * This class is the main class of the program.","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" * It contains the main method that runs the program.","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"-"},"content":"public class Duke {","lastModifiedDate":"2019-07-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" private Ui ui;","lastModifiedDate":"2023-10-09"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-12"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" private String storagePath;","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" private SaveToTxt save;","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" private GetFromTxt get;","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager exchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateFileHandler exchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" public Duke() {","lastModifiedDate":"2023-10-12"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" ui \u003d new Ui();","lastModifiedDate":"2023-10-12"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-12"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" storagePath \u003d \"KaChinnnngggg.txt\";","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" save \u003d new SaveToTxt(storagePath);","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" get \u003d new GetFromTxt(storagePath);","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" exchangeRateFileHandler \u003d new ExchangeRateFileHandler(\"./data/ExchangeRates.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * This method runs the program.","lastModifiedDate":"2023-10-11"},{"lineNumber":62,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void run() {","lastModifiedDate":"2023-10-09"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" Ui.printWelcomeMessage();","lastModifiedDate":"2023-10-09"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" loadData();","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" boolean isExit \u003d false;","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" while (!isExit) {","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" String fullCommand \u003d ui.readCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" if (\"exit\".equals(fullCommand)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" isExit \u003d true;","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" continue;","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" executeCommand(fullCommand);","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" saveData();","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" ui.printGoodbyeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" protected void loadData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" get.getFromTextFile(incomes, expenses);","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"limyuhching"},"content":" if(!exchangeRateFileHandler.load()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" } catch (FileNotFoundException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"\\tOOPS!!! File not found.\");","lastModifiedDate":"2023-10-25"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"limyuhching"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" protected void executeCommand(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" String command \u003d Parser.parse(fullCommand);","lastModifiedDate":"2023-10-11"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" String[] parts \u003d command.split(\"-\", 2);","lastModifiedDate":"2023-10-11"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" // ... (switch-case structure extracted from the original `run()` method)","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" switch (parts[0]) {","lastModifiedDate":"2023-10-11"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" case \"exit\":","lastModifiedDate":"2023-10-11"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-11"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" case \"add_income\":","lastModifiedDate":"2023-10-12"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" IncomeManager incomeCommand \u003d new IncomeManager(fullCommand);","lastModifiedDate":"2023-10-12"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" incomeCommand.execute();","lastModifiedDate":"2023-10-12"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" Income newIncome \u003d incomeCommand.getNewIncome();","lastModifiedDate":"2023-10-12"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" incomes.add(newIncome);","lastModifiedDate":"2023-10-12"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" Ui.printIncomeAddedMessage(newIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-12"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" case \"list_income\":","lastModifiedDate":"2023-10-12"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" new IncomeLister(incomes, ui).listIncomes();","lastModifiedDate":"2023-10-12"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-12"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":122,"author":{"gitId":"Hongzhii"},"content":" case \"add_expense\":","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseCommand \u003d new ExpenseManager(fullCommand);","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"Hongzhii"},"content":" expenseCommand.execute();","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"Hongzhii"},"content":" Expense newExpense \u003d expenseCommand.getNewExpense();","lastModifiedDate":"2023-10-15"},{"lineNumber":126,"author":{"gitId":"Hongzhii"},"content":" expenses.add(newExpense);","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" Ui.printExpenseAddedMessage(newExpense);","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"Hongzhii"},"content":" break;","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"Hongzhii"},"content":" case \"list_expense\":","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"Hongzhii"},"content":" new ExpenseLister(expenses, ui).listExpenses();","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":133,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":" case \"list\":","lastModifiedDate":"2023-10-17"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":136,"author":{"gitId":"limyuhching"},"content":" new ListCommand(incomes, expenses, ui).execute();","lastModifiedDate":"2023-10-17"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":138,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":139,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":140,"author":{"gitId":"limyuhching"},"content":" case \"delete_income\":","lastModifiedDate":"2023-10-17"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"limyuhching"},"content":" new DeleteIncomeCommand().execute(incomes, fullCommand, ui);","lastModifiedDate":"2023-10-17"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":145,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":146,"author":{"gitId":"limyuhching"},"content":" case \"delete_expense\":","lastModifiedDate":"2023-10-17"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":148,"author":{"gitId":"limyuhching"},"content":" new DeleteExpenseCommand().execute(expenses, fullCommand, ui);","lastModifiedDate":"2023-10-17"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":151,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":152,"author":{"gitId":"KenCheung18"},"content":" case \"help\":","lastModifiedDate":"2023-10-16"},{"lineNumber":153,"author":{"gitId":"KenCheung18"},"content":" new UsageInstructions(ui).getHelp();","lastModifiedDate":"2023-10-16"},{"lineNumber":154,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-16"},{"lineNumber":155,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":156,"author":{"gitId":"KenCheung18"},"content":" case \"balance\":","lastModifiedDate":"2023-10-17"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-23"},{"lineNumber":158,"author":{"gitId":"KenCheung18"},"content":" new Balance(incomes, expenses).getBalanceMessage();","lastModifiedDate":"2023-10-17"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-23"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-23"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" case \"find\":","lastModifiedDate":"2023-10-23"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" String[] parsedParameters \u003d FindParser.parseFindCommand(fullCommand);","lastModifiedDate":"2023-10-23"},{"lineNumber":164,"author":{"gitId":"limyuhching"},"content":" FindCommand findCommand \u003d new FindCommand(incomes, expenses,","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" parsedParameters[0], parsedParameters[1],","lastModifiedDate":"2023-10-23"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" parsedParameters[2], parsedParameters[3], ui);","lastModifiedDate":"2023-10-23"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-23"},{"lineNumber":168,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"KenCheung18"},"content":" case \"clear_incomes\":","lastModifiedDate":"2023-10-25"},{"lineNumber":171,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"KenCheung18"},"content":" new ClearIncomes(incomes).clearAllIncomes();","lastModifiedDate":"2023-10-25"},{"lineNumber":173,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"KenCheung18"},"content":" case \"clear_expenses\":","lastModifiedDate":"2023-10-25"},{"lineNumber":177,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":178,"author":{"gitId":"KenCheung18"},"content":" new ClearExpenses(expenses).clearAllExpenses();","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":180,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"KenCheung18"},"content":" case \"clear_all\":","lastModifiedDate":"2023-10-25"},{"lineNumber":183,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":184,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes, expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-25"},{"lineNumber":185,"author":{"gitId":"KenCheung18"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-25"},{"lineNumber":186,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":188,"author":{"gitId":"limyuhching"},"content":" case \"edit_income\":","lastModifiedDate":"2023-10-26"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"limyuhching"},"content":" new EditIncomeCommand(incomes, fullCommand).execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-26"},{"lineNumber":193,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":194,"author":{"gitId":"limyuhching"},"content":" case \"edit_expense\":","lastModifiedDate":"2023-10-26"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"limyuhching"},"content":" new EditExpenseCommand(expenses, fullCommand).execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-26"},{"lineNumber":199,"author":{"gitId":"limyuhching"},"content":" case \"list_currencies\":","lastModifiedDate":"2023-10-27"},{"lineNumber":200,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showSupportedCurrencies();","lastModifiedDate":"2023-10-27"},{"lineNumber":201,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-27"},{"lineNumber":202,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":203,"author":{"gitId":"limyuhching"},"content":" case \"list_exchange_rates\":","lastModifiedDate":"2023-10-27"},{"lineNumber":204,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showExchangeRates();","lastModifiedDate":"2023-10-27"},{"lineNumber":205,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-27"},{"lineNumber":206,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"limyuhching"},"content":" case \"update_exchange_rate\":","lastModifiedDate":"2023-10-27"},{"lineNumber":208,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":209,"author":{"gitId":"limyuhching"},"content":" Command c \u003d new UpdateExchangeRateCommand(fullCommand, exchangeRateFileHandler);","lastModifiedDate":"2023-10-31"},{"lineNumber":210,"author":{"gitId":"limyuhching"},"content":" c.execute();","lastModifiedDate":"2023-10-27"},{"lineNumber":211,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":212,"author":{"gitId":"limyuhching"},"content":" break;","lastModifiedDate":"2023-10-27"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" default:","lastModifiedDate":"2023-10-11"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid command. Please try again.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" + \"\\nType \u0027help\u0027 to see the list of commands available.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" private void saveData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":220,"author":{"gitId":"KenCheung18"},"content":" save.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-25"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":224,"author":{"gitId":"-"},"content":" public static void main(String[] args) {","lastModifiedDate":"2023-10-09"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" new Duke().run();","lastModifiedDate":"2023-10-11"},{"lineNumber":226,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" public int getIncomesSize() {","lastModifiedDate":"2023-10-31"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" return this.incomes.size();","lastModifiedDate":"2023-10-31"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" public int getExpensesSize() {","lastModifiedDate":"2023-10-31"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" return this.expenses.size();","lastModifiedDate":"2023-10-31"},{"lineNumber":234,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":236,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"limyuhching":57,"bljhty":113,"Hongzhii":9,"KenCheung18":46,"-":11}},{"path":"src/main/java/seedu/duke/commands/Balance.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * The `Balance` class represents a financial balance calculator","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" * that calculates the balance between income and expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":" * It takes a list of income and expense records as input and provides methods to calculate and display the balance.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"public class Balance {","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" private final ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" private final ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" public Balance(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses) {","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" * Calculates the financial balance by subtracting the total expenses from the total income.","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * @return The calculated financial balance.","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" public double getBalance() {","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" double totalIncome \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" double totalExpense \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" for (Income income : incomes) {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" totalIncome +\u003d income.getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" for (Expense expense : expenses) {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" totalExpense +\u003d expense.getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" return totalIncome - totalExpense;","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" * Prints a message to the console displaying the calculated financial balance.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" public void getBalanceMessage() {","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Balance: \" + getBalance());","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"KenCheung18":45}},{"path":"src/main/java/seedu/duke/commands/ClearAll.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * The ClearAll class is responsible for clearing both the list of incomes and expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" * It provides a method to clear all incomes and expenses from the corresponding list.","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"public class ClearAll {","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" * Constructs a ClearAll object with the given lists of incomes and expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The list of incomes to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The list of expenses to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" public ClearAll(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses) {","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" * Clears all incomes and expenses from their respective lists and prints a message to confirm the action.","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" public void clearAllIncomeAndExpense() {","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" incomes.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" expenses.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Both income and expense lists cleared\");","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":35}},{"path":"src/main/java/seedu/duke/commands/ClearExpenses.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":" * The ClearExpenses class is responsible for clearing the list of expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * It provides a method to clear all expenses from the list.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"public class ClearExpenses {","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" * Constructs a ClearExpenses object with the given list of expenses.","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The list of expenses to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" public ClearExpenses(ArrayList\u003cExpense\u003e expenses) {","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * Clears all expenses from the list and prints a message to confirm the action.","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" public void clearAllExpenses(){","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" expenses.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"You have cleared the expense list\");","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":30}},{"path":"src/main/java/seedu/duke/commands/ClearIncomes.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":" * The ClearIncomes class is responsible for clearing the list of incomes.","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" * It provides a method to clear all incomes from the list.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"public class ClearIncomes {","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" * Constructs a ClearIncomes object with the given list of incomes.","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The list of incomes to be cleared.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" public ClearIncomes(ArrayList\u003cIncome\u003e incomes) {","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * Clears all incomes from the list and prints a message to confirm the action.","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" public void clearAllIncomes() {","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" incomes.clear();","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"You have cleared the income list\");","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"KenCheung18":32}},{"path":"src/main/java/seedu/duke/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":" * Represents the abstract class for all commands.","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":" * This class serves as a blueprint for all specific command classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"limyuhching":2,"bljhty":16}},{"path":"src/main/java/seedu/duke/commands/DeleteExpenseCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":" * The `DeleteExpenseCommand` class represents a command to delete an expense record from a list of expenses.","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" * It extends the `Commands` class and is used to manage expense records in the application.","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"public class DeleteExpenseCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * Constructs a `DeleteExpenseCommand` object. This class does not have any specific constructor logic.","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" public DeleteExpenseCommand() {","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" * Executes the `DeleteExpenseCommand` to remove an expense record from the list of expenses.","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" * @param expenses The list of expense records to be modified.","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" * @param fullcommand The full command entered by the user, including the index of the expense to be deleted.","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" * @param ui The user interface for displaying messages.","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is a problem with the command execution, such as missing arguments,","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" * an invalid index, or a non-existent expense record.","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" public void execute(ArrayList\u003cExpense\u003e expenses, String fullcommand, Ui ui) throws KaChinnnngException {","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" int index \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullcommand.split(\" \", 3);","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" index \u003d Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" Expense removedExpense \u003d expenses.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" expenses.remove(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. This expense record has been deleted:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" System.out.println(removedExpense);","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument\");","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Expense \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"limyuhching":45}},{"path":"src/main/java/seedu/duke/commands/DeleteIncomeCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":" * The DeleteIncomeCommand class is responsible for deleting an income record from the list of incomes.","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"public class DeleteIncomeCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" * Constructs a DeleteIncomeCommand object.","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" public DeleteIncomeCommand() {","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" * Executes the DeleteIncomeCommand to remove an income record from the list of incomes.","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" * @param incomes The list of income records to be modified.","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" * @param fullcommand The full command entered by the user.","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" * @param ui The user interface for displaying messages.","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is a problem with the command execution, such as missing arguments,","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" * invalid index, or a non-existent income record.","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" public void execute(ArrayList\u003cIncome\u003e incomes, String fullcommand, Ui ui) throws KaChinnnngException {","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" int index \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullcommand.split(\" \", 3);","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" index \u003d Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" Income removedIncome \u003d incomes.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" incomes.remove(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. This income record has been deleted:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" System.out.println(removedIncome);","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument\");","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Income \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"limyuhching":45}},{"path":"src/main/java/seedu/duke/commands/EditExpenseCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public class EditExpenseCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":" private static final String EXPECTED_FORMAT \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" \"edit expense \u003cindex\u003e /cat \u003ccategory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" \"/date \u003cDD/MM/YYYY\u003e /amt [currency] \u003camount\u003e\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" int index;","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" * Constructs an EditExpenseCommand with the specified expense records and full command.","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" * @param expenses The ArrayList of Expense objects containing expense records.","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string entered by the user.","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in the command creation, such as missing arguments.","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" public EditExpenseCommand(ArrayList\u003cExpense\u003e expenses, String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" this.fullCommand \u003d fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" * Executes the edit expense command. It parses the user input, retrieves the new expense information,","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * updates the expense record, and prints the changes.","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in executing the command, such as missing arguments,","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" * incorrect index, or if the specified expense record does not exist.","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" assert expenses !\u003d null : \"Incomes ArrayList must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" assert fullCommand !\u003d null : \"Full command string must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" index \u003d getIndex(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" ExpenseManager expenseCommand \u003d new ExpenseManager(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" expenseCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" Expense newExpense \u003d expenseCommand.getNewExpense();","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" Expense removedExpense \u003d expenses.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" expenses.set(index, newExpense);","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. The expense record you\u0027ve specified has been changed:\");","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Before: \" + removedExpense);","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"After: \" + newExpense);","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Expense \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" * Extracts and returns the index from the full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" * @return The index of the income record to be edited.","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in extracting the index, such as missing arguments","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" * or if the index is not a valid integer.","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" private int getIndex(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullCommand.split(\" \", 4);","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" assert tokens.length \u003e\u003d 4 : \"Command must have at least 4 tokens\";","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" return Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":74}},{"path":"src/main/java/seedu/duke/commands/EditIncomeCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public class EditIncomeCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" private static final String EXPECTED_FORMAT \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" \"edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cDD/MM/YYYY\u003e /amt [currency] \u003camount\u003e\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" int index;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" * Constructs an EditIncomeCommand with the specified income records and full command.","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" * @param incomes The ArrayList of Income objects containing income records.","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string entered by the user.","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" public EditIncomeCommand(ArrayList\u003cIncome\u003e incomes, String fullCommand) {","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" this.fullCommand \u003d fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * Executes the edit income command. It parses the user input, retrieves the new income information,","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" * updates the income record, and prints the changes.","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in executing the command, such as missing arguments,","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" * incorrect index, or if the specified income record does not exist.","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" assert incomes !\u003d null : \"Incomes ArrayList must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" assert fullCommand !\u003d null : \"Full command string must not be null\";","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" index \u003d getIndex(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" IncomeManager incomeCommand \u003d new IncomeManager(fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" incomeCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" Income newIncome \u003d incomeCommand.getNewIncome();","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" Income removedIncome \u003d incomes.get(index);","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" incomes.set(index, newIncome);","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Noted. The income record you\u0027ve specified has been changed:\");","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Before: \" + removedIncome);","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"After: \" + newIncome);","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! Income \" + (index+1) + \" does not exist\");","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" * Extracts and returns the index from the full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" * @param fullCommand The full command string.","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" * @return The index of the income record to be edited.","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If there is an error in extracting the index, such as missing arguments","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" * or if the index is not a valid integer.","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" private int getIndex(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d fullCommand.split(\" \", 4);","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" assert tokens.length \u003e\u003d 4 : \"Command must have at least 4 tokens\";","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" return Integer.parseInt(tokens[2])-1;","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" } catch (ArrayIndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"You\u0027re missing an argument.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" } catch (NullPointerException | NumberFormatException e) {","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Oops! An integer index is expected\");","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":75}},{"path":"src/main/java/seedu/duke/commands/ExpenseLister.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Represents the command that when executed, lists all expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * This class is a child class of the Command class.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"public class ExpenseLister extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":" private final ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * Constructor for ExpenseLister.","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param expenses","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param ui","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" public ExpenseLister(ArrayList\u003cExpense\u003e expenses, Ui ui) {","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" public void execute() {","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" listExpenses();","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" * This method lists all incomes.","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" public void listExpenses() {","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" if (expenses.isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"You have no recorded expenses.\");","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" return;","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"Here are your expenses:\");","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" for (int i \u003d 0; i \u003c expenses.size(); i++) {","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" System.out.println((i + 1) + \". \" + expenses.get(i).toString());","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"limyuhching":1,"Hongzhii":52}},{"path":"src/main/java/seedu/duke/commands/ExpenseManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.parser.ExpenseParser;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * This is the class that manages the creation of new expense","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"public class ExpenseManager extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private final String details;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":" private Expense newExpense;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" public ExpenseManager(String details) {","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" this.details \u003d details;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * This method is used to execute the command","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d extractExpenseFields(details);","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" newExpense \u003d ExpenseParser.parseExpense(expenseFields);","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * This method returns new expense created","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" public Expense getNewExpense() {","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" return newExpense;","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" * This method extracts the fields of the expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" * @param details String containing the details of the expense","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" * @return expenseFields HashMap containing the fields of the income","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" private HashMap\u003cString, String\u003e extractExpenseFields(String details) throws KaChinnnngException{","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" HashMap\u003cString,String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" String[] parts \u003d details.split(\"/cat | /type | /de | /date | /amt \");","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" if(parts.length !\u003d 6) {","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Missing fields detected\");","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, parts[1].trim());","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, parts[2].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, parts[3].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, parts[4].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, parts[5].trim());","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"Hongzhii"},"content":" return expenseFields;","lastModifiedDate":"2023-10-15"},{"lineNumber":61,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"limyuhching":2,"Hongzhii":60}},{"path":"src/main/java/seedu/duke/commands/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.time.YearMonth;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" * Represents a command to find and display financial records (either incomes or expenses) based on specific criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" * The criteria include type (income/expense), category, description, and date.","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" * This command supports searching by a specific date or by a month. If a date isn\u0027t provided, it will not be used","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" * as a filter. Similarly, if the category or description isn\u0027t provided, they won\u0027t be used as filters.","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" private static final List\u003cString\u003e VALID_EXPENSE_CAT \u003d Arrays.asList(\"food\", \"transport\", \"utilities\");","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" private final ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" private final ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" private final String type;","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" private final String category;","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" private final String description;","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" private final LocalDate date;","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" private boolean isSearchByMonth \u003d false;","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" if(!dir.mkdirs()) {","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/FindCommand.log\", true);","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" } catch (SecurityException se) {","lastModifiedDate":"2023-11-04"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", se);","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" System.err.println(\"Insufficient permissions to create logs directory. Please check your permissions or \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" \"run the program in a different directory.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-24"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" * Constructs a new FindCommand with the given criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" * @param incomes The list of incomes to search from.","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" * @param expenses The list of expenses to search from.","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" * @param type The type of financial record to search for (either \"income\" or \"expense\").","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" * @param category The category to filter the results by.","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" * @param description The description to filter the results by.","lastModifiedDate":"2023-10-26"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" * @param dateString The date (or month) to filter the results by. Expected format: dd/MMM/yyyy.","lastModifiedDate":"2023-10-26"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * @param ui The UI component to display results.","lastModifiedDate":"2023-10-26"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If an invalid type is provided or if there\u0027s an error parsing the date.","lastModifiedDate":"2023-10-26"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" public FindCommand(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses, String type,","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" String category, String description, String dateString, Ui ui) throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" if (type \u003d\u003d null || !type.equalsIgnoreCase(\"income\") \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" !type.equalsIgnoreCase(\"expense\")) {","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid type. Please use \u0027income\u0027 or \u0027expense\u0027.\");","lastModifiedDate":"2023-10-24"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" if (\"expense\".equalsIgnoreCase(type) \u0026\u0026 category !\u003d null \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" !VALID_EXPENSE_CAT.contains(category.toLowerCase())) {","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid expense category provided! Allowed categories are: \"","lastModifiedDate":"2023-10-29"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" + VALID_EXPENSE_CAT);","lastModifiedDate":"2023-10-29"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" this.type \u003d type;","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" this.category \u003d category;","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" this.date \u003d parseDate(dateString); // Convert date string to LocalDate","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, String.format(\"FindCommand initialised with type: %s\", type));","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" * Executes the find command. Searches through the provided list of incomes or expenses and displays","lastModifiedDate":"2023-10-26"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" * matching results based on the given criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If there\u0027s an error during execution, such as an invalid type.","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-24"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" LOGGER.info(\"Executing FindCommand\");","lastModifiedDate":"2023-10-24"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" assert incomes !\u003d null : \"incomes should not be null\";","lastModifiedDate":"2023-10-24"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" assert expenses !\u003d null : \"expenses should not be null\";","lastModifiedDate":"2023-10-24"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cExpense\u003e matchingExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cIncome\u003e matchingIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" if (\"expense\".equalsIgnoreCase(type)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" for (Expense e : expenses) {","lastModifiedDate":"2023-10-23"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" if (matchesCriteria(e)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" matchingExpenses.add(e);","lastModifiedDate":"2023-10-23"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, String.format(\"Found %d matching expenses\", matchingExpenses.size()));","lastModifiedDate":"2023-10-26"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" if (matchingExpenses.isEmpty()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"No matching expenses found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" ui.showMatchingExpenses(matchingExpenses);","lastModifiedDate":"2023-10-29"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" } else if (\"income\".equalsIgnoreCase(type)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" for (Income i : incomes) {","lastModifiedDate":"2023-10-23"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" if (matchesCriteria(i)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" matchingIncomes.add(i);","lastModifiedDate":"2023-10-23"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO,String.format(\"Found %d matching incomes\", matchingIncomes.size()));","lastModifiedDate":"2023-10-26"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" if (matchingIncomes.isEmpty()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"No matching incomes found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" ui.showMatchingIncomes(matchingIncomes);","lastModifiedDate":"2023-10-29"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-24"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid type: \" + type);","lastModifiedDate":"2023-10-24"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" * Determines if a given date matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" * @param dateToCheck The date to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" * @return True if the date matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" private boolean matchesDate(LocalDate dateToCheck) {","lastModifiedDate":"2023-10-24"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" if (this.date !\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" if (isSearchByMonth) {","lastModifiedDate":"2023-10-23"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" return dateToCheck.getMonthValue() \u003d\u003d this.date.getMonthValue()","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" \u0026\u0026 dateToCheck.getYear() \u003d\u003d this.date.getYear();","lastModifiedDate":"2023-10-29"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" return dateToCheck.isEqual(this.date);","lastModifiedDate":"2023-10-24"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-24"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" return true; // If this.date is null, then any date matches the criteria","lastModifiedDate":"2023-10-24"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" * Determines if a given category matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" * @param categoryToCheck The category to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" * @return True if the category matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" private boolean matchesCategory(String categoryToCheck) {","lastModifiedDate":"2023-10-24"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" return this.category \u003d\u003d null || (categoryToCheck !\u003d null \u0026\u0026 categoryToCheck.equalsIgnoreCase(this.category));","lastModifiedDate":"2023-10-24"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" * Determines if a given description matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" * The description matches if it contains all the keywords specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" * If no description is specified in the command, then any description matches the criteria.","lastModifiedDate":"2023-10-26"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" * @param descriptionToCheck The description to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" * @return True if the description matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" private boolean matchesDescription(String descriptionToCheck) {","lastModifiedDate":"2023-10-24"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" if (this.description !\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" String[] keywords \u003d this.description.split(\"\\\\s+\");","lastModifiedDate":"2023-10-23"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" for (String keyword : keywords) {","lastModifiedDate":"2023-10-23"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" if (!descriptionToCheck.toLowerCase().contains(keyword.toLowerCase())) {","lastModifiedDate":"2023-10-24"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":" return false;","lastModifiedDate":"2023-10-24"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" return true;","lastModifiedDate":"2023-10-23"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" * Determines if a given expense matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" * @param e The expense to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":" * @return True if the expense matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" private boolean matchesCriteria(Expense e) {","lastModifiedDate":"2023-10-24"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":" return matchesDate(e.getDate()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":" matchesCategory(e.getCategory()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":" matchesDescription(e.getDescription()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" e.getAmount() !\u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" * Determines if a given income matches the criteria specified in the command.","lastModifiedDate":"2023-10-26"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" * @param i The income to be checked.","lastModifiedDate":"2023-10-26"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" * @return True if the income matches the criteria, false otherwise.","lastModifiedDate":"2023-10-26"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" private boolean matchesCriteria(Income i) {","lastModifiedDate":"2023-10-24"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" return matchesDate(i.getDate()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":" matchesCategory(i.getCategory()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" matchesDescription(i.getDescription()) \u0026\u0026","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":" i.getAmount() !\u003d 0;","lastModifiedDate":"2023-10-29"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-26"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" * Converts a date string into a LocalDate object. Supports full date strings and month names.","lastModifiedDate":"2023-10-26"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-26"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" * @param dateString Date as a string in the format dd/MMM/yyyy or as a month name.","lastModifiedDate":"2023-10-26"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":" * @return LocalDate representation of the provided dateString.","lastModifiedDate":"2023-10-26"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If the date string is in an invalid format.","lastModifiedDate":"2023-10-26"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-26"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" private LocalDate parseDate(String dateString) throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":" if (dateString \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" return null;","lastModifiedDate":"2023-10-23"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterDayMMM \u003d DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterDayMM \u003d DateTimeFormatter.ofPattern(\"dd/MM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterMonthMM \u003d DateTimeFormatter.ofPattern(\"MM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatterMonthMMM \u003d DateTimeFormatter.ofPattern(\"MMM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" LocalDate parsedDate \u003d null;","lastModifiedDate":"2023-10-24"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-23"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d LocalDate.parse(dateString, formatterDayMMM);","lastModifiedDate":"2023-10-29"},{"lineNumber":247,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e1) {","lastModifiedDate":"2023-10-29"},{"lineNumber":248,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":249,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d LocalDate.parse(dateString, formatterDayMM);","lastModifiedDate":"2023-10-29"},{"lineNumber":250,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e2) {","lastModifiedDate":"2023-10-29"},{"lineNumber":251,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":252,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d YearMonth.parse(dateString, formatterMonthMM).atDay(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":253,"author":{"gitId":"bljhty"},"content":" isSearchByMonth \u003d true;","lastModifiedDate":"2023-10-23"},{"lineNumber":254,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e3) {","lastModifiedDate":"2023-10-29"},{"lineNumber":255,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":256,"author":{"gitId":"bljhty"},"content":" parsedDate \u003d YearMonth.parse(dateString, formatterMonthMMM).atDay(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":257,"author":{"gitId":"bljhty"},"content":" isSearchByMonth \u003d true;","lastModifiedDate":"2023-10-29"},{"lineNumber":258,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e4) {","lastModifiedDate":"2023-10-29"},{"lineNumber":259,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Failed to parse date \" + dateString, e4);","lastModifiedDate":"2023-10-29"},{"lineNumber":260,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Invalid date format. \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":261,"author":{"gitId":"bljhty"},"content":" \"Please use formats like 20/Oct/2023, 20/10/2023, 10/2023, or Oct/2023.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":262,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":263,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":264,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":265,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":266,"author":{"gitId":"bljhty"},"content":" return parsedDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":267,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":268,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"limyuhching":1,"bljhty":267}},{"path":"src/main/java/seedu/duke/commands/IncomeLister.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * Represents the command that when executed, lists all incomes.","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * This class is a child class of the Command class.","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"public class IncomeLister extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(IncomeLister.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" private final ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" private final Ui ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/IncomeLister.log\", true);","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" } catch (SecurityException se) {","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", se);","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" System.err.println(\"Insufficient permissions to create logs directory. Please check your permissions or \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" \"run the program in a different directory.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" * Constructor for IncomeLister.","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * @param incomes ArrayList of incomes","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" * @param ui Instance of Ui","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" public IncomeLister(ArrayList\u003cIncome\u003e incomes, Ui ui) {","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assert incomes !\u003d null : \"incomes should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assert ui !\u003d null : \"ui should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, (\"Initialised IncomeLister\"));","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" public void execute() {","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" listIncomes();","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" * This method lists all incomes.","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" // Updated method name to follow Java naming conventions","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" public void listIncomes() {","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" if (incomes.isEmpty()) {","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"You have no recorded incomes.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" return;","lastModifiedDate":"2023-10-16"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" ui.printMessage(\"Here are your incomes:\");","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" for (int i \u003d 0; i \u003c incomes.size(); i++) {","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" ui.printMessage((i + 1) + \". \" + incomes.get(i).toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, (\"Incomes listed successfully\"));","lastModifiedDate":"2023-10-19"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"limyuhching":1,"bljhty":90}},{"path":"src/main/java/seedu/duke/commands/IncomeManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.parser.IncomeParser;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Represents the class that manages the creation of a new income.","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * This class serves as a blueprint for all specific income creation classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"public class IncomeManager extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" // Logger instance to log events and issues that occur during the execution of this class.","lastModifiedDate":"2023-10-19"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(IncomeManager.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" private final String details;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" private Income newIncome;","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" static{","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/IncomeManager.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }catch (SecurityException se) {","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", se);","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" System.err.println(\"Insufficient permissions to create logs directory. Please check your permissions or \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" \"run the program in a different directory.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" public IncomeManager(String details) {","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" assert details !\u003d null : \"details should not be null\"; // Ensure that details is not null","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" this.details \u003d details;","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" * This method is used to execute the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d extractIncomeFields(details);","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" newIncome \u003d IncomeParser.parseIncome(incomeFields);","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, \"successful parsing of income\"); // logging successful parsing of income","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" * This method returns the new income created.","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" * @return newIncome","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public Income getNewIncome() {","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" return newIncome;","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" * This method extracts the fields of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * @param details String containing the details of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" * @return incomeFields HashMap containing the fields of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" private HashMap\u003cString, String\u003e extractIncomeFields(String details) throws KaChinnnngException {","lastModifiedDate":"2023-10-16"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" assert details !\u003d null : \"details should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" // Split the details string based on the field keywords","lastModifiedDate":"2023-10-23"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" String[] parts \u003d details.split(\"/de |/date |/amt \");","lastModifiedDate":"2023-10-23"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" // Check if all fields are present in the string","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" if (parts.length !\u003d 4) {","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Missing or out-of-order fields detected in income details: \" + details);","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Expected fields `/de`, `/date`, and \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" \"`/amt` are missing or improperly formatted.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" // Populate the HashMap with extracted fields","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, parts[1].trim());","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, parts[2].trim());","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, parts[3].trim());","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" return incomeFields;","lastModifiedDate":"2023-10-16"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"limyuhching":1,"bljhty":102}},{"path":"src/main/java/seedu/duke/commands/KaChinnnngException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":" * Represents the exception thrown when there is an error in the command.","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"public class KaChinnnngException extends Exception{","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":" public KaChinnnngException(String message) {","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":" super(message);","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bljhty":10}},{"path":"src/main/java/seedu/duke/commands/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" * The `ListCommand` class is responsible for displaying a list of income and expense records,","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" * along with the total income, total expenses, and the total balance.","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" * It extends the `Commands` class and is used to provide a summary of financial records to the user.","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" private Ui ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private double totalIncome;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private double totalExpenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" * Constructs a `ListCommand` object with the specified income and expense lists and a user interface.","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" * @param incomes The list of income records to be displayed.","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" * @param expenses The list of expense records to be displayed.","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" * @param ui The user interface for displaying messages and financial records.","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" public ListCommand(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses, Ui ui) {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" this.incomes \u003d incomes;","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" this.expenses \u003d expenses;","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" totalIncome \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" totalExpenses \u003d 0;","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" * Executes the `ListCommand` to display a summary of income and expense records,","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" * along with the total balance.","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" public void execute() {","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" if (incomes.isEmpty() \u0026\u0026 expenses.isEmpty()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"You do not have any records.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" return;","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" // Print incomes","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" if (incomes.isEmpty()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"You have no recorded incomes.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Here are your incomes:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" for (int i \u003d 0; i \u003c incomes.size(); i++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" System.out.println((i + 1) + \". \" + incomes.get(i).toString());","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" totalIncome +\u003d incomes.get(i).getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"Total income is: $%.2f.\\n\", totalIncome);","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" System.out.println();","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" // Print expenses","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" if (expenses.isEmpty()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"You have no recorded expenses.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Here are your expenses:\");","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" for (int i \u003d 0; i \u003c expenses.size(); i++) {","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" System.out.println((i + 1) + \". \" + expenses.get(i).toString());","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" totalExpenses +\u003d expenses.get(i).getAmount();","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"Total expenses is: $%.2f.\\n\", totalExpenses);","lastModifiedDate":"2023-10-17"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"\\nTotal balance is: $%.2f.\\n\", totalIncome - totalExpenses);","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"limyuhching":73}},{"path":"src/main/java/seedu/duke/commands/UpdateExchangeRateCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.storage.ExchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"public class UpdateExchangeRateCommand extends Command {","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":" private static final String EXPECTED_FORMAT \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":" \"update exchange rate \u003csupported_currency\u003e \u003crate\u003e\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" ExchangeRateFileHandler exchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" String currency;","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" double rate;","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" public UpdateExchangeRateCommand(String fullCommand, ExchangeRateFileHandler exchangeRateFileHandler)","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" this.exchangeRateFileHandler \u003d exchangeRateFileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" String[] args \u003d parse(fullCommand);","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" currency \u003d args[0];","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" rate \u003d Double.parseDouble(args[1]);","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" } catch (NumberFormatException | NullPointerException e) {","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Invalid command.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" @Override","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" public void execute() throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"The SGD/%s rate has been updated to %s.\\n\", currency.toUpperCase(), rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" exchangeRateFileHandler.save(exchangeRateManager.getExchangeRates());","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" private static String[] parse(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" String[] args \u003d fullCommand.split(\" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" if (args.length !\u003d 5) {","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Invalid command.\\nExpected: \"+EXPECTED_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" return Arrays.copyOfRange(args,3, 5);","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"limyuhching":42}},{"path":"src/main/java/seedu/duke/commands/UsageInstructions.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"public class UsageInstructions {","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":" // Shows a message linking the user to the user guide of our app","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":" private final seedu.duke.ui.Ui ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":" * The `UsageInstructions` class provides usage instructions for the application,","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":" * including command formats and a link to the user guide.","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" public UsageInstructions(Ui ui) {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" this.ui \u003d ui;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" * Displays usage instructions for the application, including command formats and a link to the user guide.","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public void getHelp(){","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" // Shows a message linking the user to the user guide of our app","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" System.out.println(\"You can access our user guide by \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" \"https://docs.google.com/document/d/1BOz_v4eYQ8y7Dje6Jm6nqymi9jmrsb9MAohLCL_sLvI/edit?usp\u003dsharing\\n\");","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" // Displays the various commands that user can use including the respective formats of the commands","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Functions and their format:\\n\");","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Adding an entry: add\\nFormat:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" \"add income /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" \"add expense /cat \u003ccategory\u003e /type \u003ctype\u003e \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" \"/de \u003cdescription\u003e /date \u003cdate\u003e /amt \u003camount\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Listing all entries: list\\nFormat:\\n\" + \"list\\n\" + \"list income\\n\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" \"list expense\\nlist currencies\\nlist exchange rates\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Deleting an entry: delete\\nFormat:\\ndelete income \u003cindex_pos\u003e\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" \"delete expense \u003cindex_pos\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Edit an entry: edit\\nFormat:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" \"edit income \u003cindex\u003e /de \u003cdescription\u003e /date \u003cdate\u003e /amt [currency] \u003camount\u003e\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" \"edit expense \u003cindex\u003e /cat \u003ccatergory\u003e /type \u003ctype\u003e /de \u003cdescription\u003e /date \u003cdate\u003e \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" \"/amt [currency] \u003camount\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Check balance of income: balance\\nFormat: \" + \"balance\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Update exchange rate: update exchange rate\\nFormat: \" + \"update exchange rate \" +","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" \"\u003csupported_currency\u003e \u003crate\u003e\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Exiting the program: exit\\nFormat: \" + \"exit\");","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" ui.showLineDivider();","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bljhty":23,"KenCheung18":23}},{"path":"src/main/java/seedu/duke/financialrecords/ExchangeRateManager.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-27"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-27"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.util.Arrays;","lastModifiedDate":"2023-10-27"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-27"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.List;","lastModifiedDate":"2023-10-27"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-27"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-27"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":" * The `ExchangeRateManager` class is responsible for managing exchange rates between the Singapore Dollar (SGD) and","lastModifiedDate":"2023-10-27"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" * various foreign currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * It provides functionality to update, retrieve, and save exchange rates, as well as convert currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" * The class uses a singleton pattern to ensure a single instance of `ExchangeRateManager` throughout the application.","lastModifiedDate":"2023-10-27"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" * Exchange rates are stored in a `HashMap`, and the data is read from and saved to a text file.","lastModifiedDate":"2023-10-27"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateManager {","lastModifiedDate":"2023-10-27"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private static ExchangeRateManager exchangeRateManager \u003d null;","lastModifiedDate":"2023-10-27"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private static final List\u003cString\u003e SUPPORTED_CURRENCIES \u003d","lastModifiedDate":"2023-10-27"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" Arrays.asList(","lastModifiedDate":"2023-10-27"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" \"MYR\", \"USD\", \"JPY\", \"KRW\", \"EUR\", \"THB\", \"HKD\", \"INR\", \"IDR\",","lastModifiedDate":"2023-10-27"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" \"AUD\", \"GBP\", \"CNY\", \"CAD\", \"TWD\", \"VND\", \"PHP\"","lastModifiedDate":"2023-10-27"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" );","lastModifiedDate":"2023-10-27"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" private HashMap\u003cString, Double\u003e exchangeRates;","lastModifiedDate":"2023-10-27"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager() {","lastModifiedDate":"2023-10-27"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" exchangeRates \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-27"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" public HashMap\u003cString, Double\u003e getExchangeRates() {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" return exchangeRates;","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" public static List\u003cString\u003e getSupportedCurrencies() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" return SUPPORTED_CURRENCIES;","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" * Gets the singleton instance of `ExchangeRateManager`.","lastModifiedDate":"2023-10-27"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" * @return The singleton instance of `ExchangeRateManager`.","lastModifiedDate":"2023-10-27"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" public static ExchangeRateManager getInstance() {","lastModifiedDate":"2023-10-27"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" if (exchangeRateManager \u003d\u003d null) {","lastModifiedDate":"2023-10-27"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager \u003d new ExchangeRateManager();","lastModifiedDate":"2023-10-27"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" return exchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" public double getExchangeRate(String currency) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" if (!SUPPORTED_CURRENCIES.contains(currency)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"This currency is not supported\");","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" return exchangeRates.get(currency);","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" public void clear() {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" exchangeRates \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" * Displays the list of supported currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" public void showSupportedCurrencies() {","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"These are the supported currencies:\");","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" for (String currency : SUPPORTED_CURRENCIES) {","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" System.out.print(currency + \" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" System.out.print(\"\\n\");","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"limyuhching"},"content":" * Displays the exchange rates for supported currencies.","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"limyuhching"},"content":" public void showExchangeRates() {","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"limyuhching"},"content":" int count \u003d 0;","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":" for (Map.Entry\u003cString, Double\u003e entry : exchangeRates.entrySet()) {","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"limyuhching"},"content":" String currency \u003d entry.getKey();","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"limyuhching"},"content":" Double rate \u003d entry.getValue();","lastModifiedDate":"2023-10-27"},{"lineNumber":85,"author":{"gitId":"limyuhching"},"content":" if (rate !\u003d null) {","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"limyuhching"},"content":" if (count \u003d\u003d 0) {","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"Here are the exchange rate(s):\");","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"%s, %s\\n\", currency, rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"limyuhching"},"content":" count +\u003d 1;","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"limyuhching"},"content":" if (count \u003d\u003d 0) {","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":" System.out.println(\"No exchange rate has been updated\");","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":99,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":100,"author":{"gitId":"limyuhching"},"content":" * Displays a message about currency conversion for a specific currency.","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"limyuhching"},"content":" * @param currency The currency to convert.","lastModifiedDate":"2023-10-27"},{"lineNumber":103,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":104,"author":{"gitId":"limyuhching"},"content":" public void showCurrencyConversionMessage(String currency) {","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":106,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-27"},{"lineNumber":107,"author":{"gitId":"limyuhching"},"content":" System.out.printf(\"We have converted %s to SGD at the SGD/%s rate of %s\\n\",","lastModifiedDate":"2023-10-27"},{"lineNumber":108,"author":{"gitId":"limyuhching"},"content":" currency, currency, exchangeRates.get(currency));","lastModifiedDate":"2023-10-27"},{"lineNumber":109,"author":{"gitId":"limyuhching"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-27"},{"lineNumber":110,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":111,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":112,"author":{"gitId":"limyuhching"},"content":" * Converts an amount from a foreign currency to SGD using the specified currency\u0027s exchange rate.","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"limyuhching"},"content":" * @param currency The currency to convert from.","lastModifiedDate":"2023-10-27"},{"lineNumber":115,"author":{"gitId":"limyuhching"},"content":" * @param amount The amount to convert.","lastModifiedDate":"2023-10-27"},{"lineNumber":116,"author":{"gitId":"limyuhching"},"content":" * @return The converted amount in SGD.","lastModifiedDate":"2023-10-27"},{"lineNumber":117,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If the currency is not supported or the exchange rate is not available.","lastModifiedDate":"2023-10-27"},{"lineNumber":118,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":119,"author":{"gitId":"limyuhching"},"content":" public double convertCurrency(String currency, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":120,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-27"},{"lineNumber":121,"author":{"gitId":"limyuhching"},"content":" if (!SUPPORTED_CURRENCIES.contains(currency)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":122,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"This currency is not supported\");","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"limyuhching"},"content":" } else if (exchangeRates.get(currency) \u003d\u003d null) {","lastModifiedDate":"2023-10-27"},{"lineNumber":124,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Please update the exchange rate for \" + currency);","lastModifiedDate":"2023-10-27"},{"lineNumber":125,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":126,"author":{"gitId":"limyuhching"},"content":" return amount / exchangeRates.get(currency);","lastModifiedDate":"2023-10-27"},{"lineNumber":127,"author":{"gitId":"limyuhching"},"content":" };","lastModifiedDate":"2023-10-27"},{"lineNumber":128,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":129,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-27"},{"lineNumber":130,"author":{"gitId":"limyuhching"},"content":" * Updates the exchange rate for a specific currency.","lastModifiedDate":"2023-10-27"},{"lineNumber":131,"author":{"gitId":"limyuhching"},"content":" *","lastModifiedDate":"2023-10-27"},{"lineNumber":132,"author":{"gitId":"limyuhching"},"content":" * @param currency The currency to update.","lastModifiedDate":"2023-10-27"},{"lineNumber":133,"author":{"gitId":"limyuhching"},"content":" * @param rate The new exchange rate.","lastModifiedDate":"2023-10-27"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":" * @throws KaChinnnngException If the currency is not supported or the rate is invalid.","lastModifiedDate":"2023-10-27"},{"lineNumber":135,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-27"},{"lineNumber":136,"author":{"gitId":"limyuhching"},"content":" public void updateExchangeRate(String currency, double rate) throws KaChinnnngException {","lastModifiedDate":"2023-10-27"},{"lineNumber":137,"author":{"gitId":"limyuhching"},"content":" currency \u003d currency.toUpperCase();","lastModifiedDate":"2023-10-27"},{"lineNumber":138,"author":{"gitId":"limyuhching"},"content":" if (!SUPPORTED_CURRENCIES.contains(currency)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":139,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"This currency is not supported\");","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":141,"author":{"gitId":"limyuhching"},"content":" if (rate \u003e 3000000.00 || rate \u003c 0.001) {","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Fail to update exchange rate, \" +","lastModifiedDate":"2023-10-27"},{"lineNumber":143,"author":{"gitId":"limyuhching"},"content":" \"the exchange rate is not between 0.001 and 3000000\");","lastModifiedDate":"2023-10-27"},{"lineNumber":144,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":145,"author":{"gitId":"limyuhching"},"content":" exchangeRates.put(currency, rate);","lastModifiedDate":"2023-10-27"},{"lineNumber":146,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":147,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":148,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-27"}],"authorContributionMap":{"limyuhching":148}},{"path":"src/main/java/seedu/duke/financialrecords/Expense.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-13"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":" * Implementation of the Expense class","lastModifiedDate":"2023-10-13"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":" * Basic expense class inherits from FinancialRecord and does not include any additional attributes","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Attribute \"amount\" contains a negative double which will make it easier to tally up the net total at the end","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":"public class Expense extends FinancialRecord {","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" protected String category;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" public Expense(String description, LocalDate date, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" public String getCategory() {","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" return category;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" return \"Expense: \" + getDescription() +","lastModifiedDate":"2023-10-12"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":7,"Hongzhii":20}},{"path":"src/main/java/seedu/duke/financialrecords/FinancialRecord.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * Represents the abstract class for all financial records.","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * This class serves as a blueprint for all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public abstract class FinancialRecord{","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" // Logger instance to log events and issues that occur during the execution of this class.","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FinancialRecord.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" protected String description;","lastModifiedDate":"2023-10-12"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" protected LocalDate date;","lastModifiedDate":"2023-10-12"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" protected double amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" * Constructs a new financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" * @param description Description of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" * @param date Date of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" * @param amount Amount of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there are validation errors.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" public FinancialRecord(String description, LocalDate date, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" assert description !\u003d null : \"description should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" assert date !\u003d null : \"date should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" if (description.trim().isEmpty()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" LOGGER.warning(\"Description is empty\");","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Description cannot be empty!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" if (amount \u003c 0) {","lastModifiedDate":"2023-10-12"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" LOGGER.warning(\"Amount is negative\");","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Amount cannot be negative!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" if (date.isAfter(LocalDate.now())) {","lastModifiedDate":"2023-10-12"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" LOGGER.warning(\"Date is in the future\");","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Date cannot be in the future!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-12"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" this.date \u003d date;","lastModifiedDate":"2023-10-12"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" this.amount \u003d amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" * Returns the category of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" * @return Category of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" public String getCategory() {","lastModifiedDate":"2023-10-12"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" return \"\";","lastModifiedDate":"2023-10-12"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" * This method is used to get the description of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" * @return String containing the description of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public String getDescription() {","lastModifiedDate":"2023-10-12"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" return description;","lastModifiedDate":"2023-10-12"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" * This method is used to get the date of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" * @return LocalDate containing the date of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public LocalDate getDate() {","lastModifiedDate":"2023-10-12"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" return date;","lastModifiedDate":"2023-10-12"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" * This method is used to get the date of the financial record in a string format.","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" * @return String containing the date of the financial record in a string format","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" public String getDateString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\");","lastModifiedDate":"2023-10-12"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" return date.format(formatter);","lastModifiedDate":"2023-10-12"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" * This method is used to get the amount of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" * @return double containing the amount of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" public double getAmount() {","lastModifiedDate":"2023-10-12"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" return amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" * Sets the description of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" * @param description Description of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if description is empty or null.","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" public void setDescription(String description) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" assert description !\u003d null : \"description should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" if (description.trim().isEmpty()) {","lastModifiedDate":"2023-10-12"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Description cannot be empty!\");","lastModifiedDate":"2023-10-12"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-12"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" * This method is used to set the date of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" * @param date LocalDate containing the date of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" public void setDate(LocalDate date) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" assert date !\u003d null : \"date should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" this.date \u003d date;","lastModifiedDate":"2023-10-12"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" * This method is used to set the amount of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * @param amount double containing the amount of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" public void setAmount(double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" assert amount \u003e\u003d 0 : \"amount should not be negative\";","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" this.amount \u003d amount;","lastModifiedDate":"2023-10-12"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" * Provides a string representation of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" * @return String representation of the financial record.","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" public String toString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" return \"\";","lastModifiedDate":"2023-10-12"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":148}},{"path":"src/main/java/seedu/duke/financialrecords/Food.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Food class that inherits from expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * Represents food expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class Food extends Expense {","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private MealType mealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" * Food class constructor","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * @param description","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" * @param date","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param amount","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param mealType","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public Food(String description, LocalDate date, double amount, MealType mealType) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" this.category \u003d \"food\";","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" this.mealType \u003d mealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" * Returns meal type","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" public MealType getMealType() {","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" return mealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" * Returns a string that contains all the information on the expense record","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" return \"Food Expense (\" + getMealType() + \"): \" + getDescription() +","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"bljhty":1,"Hongzhii":45}},{"path":"src/main/java/seedu/duke/financialrecords/Income.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * Implementation of the Income class","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * Basic income class inherits from FinancialRecord and does not include any additional attributes","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public class Income extends FinancialRecord {","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" // Logger instance to log events and issues that occur during the execution of this class.","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(Income.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-19"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/Income.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" } catch (SecurityException se) {","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", se);","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" System.err.println(\"Insufficient permissions to create logs directory. Please check your permissions or \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" \"run the program in a different directory.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" * This method is used to create a new financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record creation classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" * @param description String containing the description of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" * @param date LocalDate containing the date of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" * @param amount double containing the amount of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" public Income(String description, LocalDate date, double amount) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-12"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO,(\"Income created with description: \" +","lastModifiedDate":"2023-10-19"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" description + \" date: \" + date + \" amount: \" + amount));","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" * This method is used to get the category of the financial record.","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * This method is used by all specific financial record classes in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * @return String containing the category of the financial record","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-12"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" public String toString() {","lastModifiedDate":"2023-10-12"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" return \"Income: \" + getDescription() + ","lastModifiedDate":"2023-10-12"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" \" | Date: \" + getDateString()+ \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-12"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":68}},{"path":"src/main/java/seedu/duke/financialrecords/Transport.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Transport class that inherits from expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * Represents transportation expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class Transport extends Expense {","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private TransportationType transportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" * Transport class constructor","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * @param description","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" * @param date","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param amount","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param transportationType","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public Transport(String description, LocalDate date, double amount,","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" TransportationType transportationType) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" this.transportationType \u003d transportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" this.category \u003d \"Transport\";","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * Returns transportation type","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" public TransportationType getTransportationType() {","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" return transportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" * Returns a string that contains all the information on the expense record","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" return \"Transportation Expense (\" + getTransportationType() + \"): \" + getDescription() +","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"bljhty":1,"Hongzhii":46}},{"path":"src/main/java/seedu/duke/financialrecords/Utilities.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":" * Utilities class that inherits from expense.","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":" * Represents utility expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class Utilities extends Expense {","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private UtilityType utilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" * Utilities class constructor","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" * @param description","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" * @param date","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":" * @param amount","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" * @param utilityType","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" * @throws KaChinnnngException","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public Utilities(String description, LocalDate date, double amount,","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" UtilityType utilityType) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" super(description, date, amount);","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":" this.utilityType \u003d utilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" this.category \u003d \"Utilities\";","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" * Returns utility type","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":" public UtilityType getUtilityType() {","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" return utilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" * Returns a string that contains all the information on the expense record","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" * @return","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" public String toString() {","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" return \"Utilities Expense(\" + getUtilityType() + \"): \" + getDescription() +","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" \" | Date: \" + getDateString() + \" | Amount: $\" + String.format(\"%.2f\", getAmount());","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"bljhty":1,"Hongzhii":46}},{"path":"src/main/java/seedu/duke/financialrecords/expensetypes/MealType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords.expensetypes;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Enum class to represent meal types.","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"public enum MealType {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":" UNDEFINED, BREAKFAST, LUNCH, DINNER","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"Hongzhii":8}},{"path":"src/main/java/seedu/duke/financialrecords/expensetypes/TransportationType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords.expensetypes;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Enum class that represents all transportation types.","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"public enum TransportationType {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":" UNDEFINED, TRAIN, BUS, TAXI, FUEL","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"Hongzhii":8}},{"path":"src/main/java/seedu/duke/financialrecords/expensetypes/UtilityType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.financialrecords.expensetypes;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":" * Enum class that represents all utility types.","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"public enum UtilityType {","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":" UNDEFINED, WATER, ELECTRICITY, GAS","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"Hongzhii":8}},{"path":"src/main/java/seedu/duke/parser/ExpenseParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-27"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-15"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":"import java.time.format.ResolverStyle;","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":"public class ExpenseParser {","lastModifiedDate":"2023-10-15"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" public static final String CATEGORY_FIELD \u003d \"ca\";","lastModifiedDate":"2023-10-15"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":" public static final String TYPE_FIELD \u003d \"ty\";","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" public static final String DESCRIPTION_FIELD \u003d \"de\";","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public static final String DATE_FIELD \u003d \"da\";","lastModifiedDate":"2023-10-15"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" public static final String AMOUNT_FIELD \u003d \"am\";","lastModifiedDate":"2023-10-15"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" public static final String INDEX_FIELD \u003d \"in\";","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" public static LocalDate parseDate(String expenseDateString) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" LocalDate expenseDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MM/uuuu\")","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" .withResolverStyle(ResolverStyle.STRICT);","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" expenseDate \u003d LocalDate.parse(expenseDateString, formatter);","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" } catch (DateTimeParseException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid date in the format dd/MM/yyyydon\");","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" if (expenseDate.isAfter(LocalDate.now())) {","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Please enter a date that is not in the future\");","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" return expenseDate;","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":" public static Expense parseExpense(HashMap\u003cString, String\u003e argumentsByField) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" if (!argumentsByField.containsKey(CATEGORY_FIELD) ||","lastModifiedDate":"2023-10-15"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(TYPE_FIELD) ||","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(DESCRIPTION_FIELD) ||","lastModifiedDate":"2023-10-15"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(DATE_FIELD) ||","lastModifiedDate":"2023-10-15"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" !argumentsByField.containsKey(AMOUNT_FIELD)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Missing fields detected\");","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" String expenseCategoryString \u003d argumentsByField.get(CATEGORY_FIELD).toLowerCase();","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" String expenseTypeString \u003d argumentsByField.get(TYPE_FIELD).toLowerCase();","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":" String expenseDescriptionString \u003d argumentsByField.get(DESCRIPTION_FIELD);","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":" String expenseDateString \u003d argumentsByField.get(DATE_FIELD);","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":" String expenseAmountString \u003d argumentsByField.get(AMOUNT_FIELD);","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":" LocalDate expenseDate \u003d parseDate(expenseDateString);","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":" double expenseAmount;","lastModifiedDate":"2023-10-15"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" if (!isOtherCurrency(expenseAmountString)) {","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"Hongzhii"},"content":" expenseAmount \u003d Double.parseDouble(expenseAmountString);","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" // Convert Currency to SGD","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d expenseAmountString.split(\" \");","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" String currency \u003d tokens[0].trim();","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" expenseAmount \u003d Double.parseDouble(tokens[1].trim());","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" expenseAmount \u003d exchangeRateManager.convertCurrency(currency, expenseAmount);","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showCurrencyConversionMessage(currency);","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"Hongzhii"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Please enter a valid amount\");","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":75,"author":{"gitId":"Hongzhii"},"content":" if (expenseAmount \u003e 999999.99 || expenseAmount \u003c\u003d 0) {","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Expense amount must be between $0.01 and $999999.99\");","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":79,"author":{"gitId":"Hongzhii"},"content":" if (expenseCategoryString.equals(\"food\")) {","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"Hongzhii"},"content":" if (expenseTypeString.equals(\"breakfast\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.BREAKFAST);","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"lunch\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.LUNCH);","lastModifiedDate":"2023-10-26"},{"lineNumber":84,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"dinner\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.DINNER);","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"Hongzhii"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"Hongzhii"},"content":" return new Food(expenseDescriptionString, expenseDate, expenseAmount, MealType.UNDEFINED);","lastModifiedDate":"2023-10-26"},{"lineNumber":88,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseCategoryString.equals(\"transport\")){","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"Hongzhii"},"content":" if (expenseTypeString.equals(\"train\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"Hongzhii"},"content":" TransportationType.TRAIN);","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"bus\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":94,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":95,"author":{"gitId":"Hongzhii"},"content":" TransportationType.BUS);","lastModifiedDate":"2023-10-26"},{"lineNumber":96,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"taxi\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":97,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"Hongzhii"},"content":" TransportationType.TAXI);","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"fuel\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"Hongzhii"},"content":" TransportationType.FUEL);","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"Hongzhii"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"Hongzhii"},"content":" return new Transport(expenseDescriptionString, expenseDate, expenseAmount,","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"Hongzhii"},"content":" TransportationType.UNDEFINED);","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" } else if (expenseCategoryString.equals(\"utilities\")) {","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"Hongzhii"},"content":" if (expenseTypeString.equals(\"water\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.WATER);","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"electricity\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":110,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.ELECTRICITY);","lastModifiedDate":"2023-10-26"},{"lineNumber":111,"author":{"gitId":"Hongzhii"},"content":" } else if (expenseTypeString.equals(\"gas\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":112,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.GAS);","lastModifiedDate":"2023-10-26"},{"lineNumber":113,"author":{"gitId":"Hongzhii"},"content":" } else{","lastModifiedDate":"2023-10-26"},{"lineNumber":114,"author":{"gitId":"Hongzhii"},"content":" return new Utilities(expenseDescriptionString, expenseDate, expenseAmount, UtilityType.UNDEFINED);","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid category\");","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":120,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"Hongzhii"},"content":" public static int getIndex(HashMap\u003cString, String\u003e argumentsByFields) throws KaChinnnngException {","lastModifiedDate":"2023-10-15"},{"lineNumber":122,"author":{"gitId":"Hongzhii"},"content":" if (!argumentsByFields.containsKey(INDEX_FIELD)) {","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Missing index field detected\");","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"Hongzhii"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":126,"author":{"gitId":"Hongzhii"},"content":" return Integer.parseInt(argumentsByFields.get(INDEX_FIELD));","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"Hongzhii"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":128,"author":{"gitId":"Hongzhii"},"content":" throw new KaChinnnngException(\"Please enter a valid index\");","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":130,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":132,"author":{"gitId":"limyuhching"},"content":" private static boolean isOtherCurrency(String amount) {","lastModifiedDate":"2023-10-27"},{"lineNumber":133,"author":{"gitId":"limyuhching"},"content":" return (amount.split(\" \").length \u003e 1);","lastModifiedDate":"2023-10-27"},{"lineNumber":134,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-27"},{"lineNumber":135,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"limyuhching":15,"bljhty":4,"Hongzhii":116}},{"path":"src/main/java/seedu/duke/parser/FindParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"public class FindParser {","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * Parses the find command input.","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * @param fullCommand The full command string input by the user.","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * @return An array of Strings containing the parsed parameters in the order: TYPE, CATEGORY, DESCRIPTION, DATE.","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException If the command format is invalid.","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public static String[] parseFindCommand(String fullCommand) throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" String[] tokens \u003d fullCommand.split(\" \");","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" String[] parsedParameters \u003d new String[4]; // To store TYPE, CATEGORY, DESCRIPTION, DATE","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" String[] validParameters \u003d {\"/t\", \"/cat\", \"/de\", \"/date\"}; // List of valid parameters","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" for (String token : tokens) {","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" if (token.startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" boolean isValidParam \u003d false;","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" for (String validParam : validParameters) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" if (token.equals(validParam)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" isValidParam \u003d true;","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" break;","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" if (!isValidParam) {","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Unrecognized parameter \\\"\" + token + \"\\\". \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" \"Please refer to the help guide for valid parameters.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/type\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please use /t instead of /type for specifying the type.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/category\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please use /cat instead of /category for specifying the category.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/description\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please use /de instead of /description for specifying the description.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" if (!fullCommand.contains(\"/t\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The /t TYPE field is mandatory.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" int typeIndex \u003d indexOf(tokens, \"/t\");","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" if (typeIndex \u003d\u003d tokens.length - 1 || tokens[typeIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /t TYPE cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" parsedParameters[0] \u003d tokens[typeIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" if(\"income\".equalsIgnoreCase(parsedParameters[0])) {","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/cat\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The /cat CATEGORY field is not applicable for income.\");","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/cat\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" int categoryIndex \u003d indexOf(tokens, \"/cat\");","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" if (categoryIndex \u003d\u003d tokens.length - 1 || tokens[categoryIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /c CATEGORY cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" parsedParameters[1] \u003d tokens[categoryIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/de\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" int descriptionIndex \u003d indexOf(tokens, \"/de\");","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" if (descriptionIndex \u003d\u003d tokens.length - 1 || tokens[descriptionIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /de DESCRIPTION cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" parsedParameters[2] \u003d tokens[descriptionIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" if (fullCommand.contains(\"/date\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" int dateIndex \u003d indexOf(tokens, \"/date\");","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" if (dateIndex \u003d\u003d tokens.length - 1 || tokens[dateIndex + 1].startsWith(\"/\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"The value for /da DATE cannot be empty.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" parsedParameters[3] \u003d tokens[dateIndex + 1];","lastModifiedDate":"2023-10-23"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" // Check that at least one optional field is provided","lastModifiedDate":"2023-10-23"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" if (parsedParameters[1] \u003d\u003d null \u0026\u0026 parsedParameters[2] \u003d\u003d null \u0026\u0026 parsedParameters[3] \u003d\u003d null) {","lastModifiedDate":"2023-10-23"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"At least one of the optional fields [/c CATEGORY], \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" \"[/de DESCRIPTION], [/da DATE] must be provided.\");","lastModifiedDate":"2023-10-23"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" return parsedParameters;","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" * Helper method to find the index of a specific string in an array.","lastModifiedDate":"2023-10-23"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" * @param array The array to search.","lastModifiedDate":"2023-10-23"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" * @param value The string value to find.","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" * @return The index of the value in the array, or -1 if not found.","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" private static int indexOf(String[] array, String value) {","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" for (int i \u003d 0; i \u003c array.length; i++) {","lastModifiedDate":"2023-10-23"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" if (array[i].equals(value)) {","lastModifiedDate":"2023-10-23"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" return i;","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" return -1;","lastModifiedDate":"2023-10-23"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"bljhty":108}},{"path":"src/main/java/seedu/duke/parser/IncomeParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.time.format.ResolverStyle;","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" * Represents the parser for the Income class.","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" * This class serves to parse the user input into a format that the Income class can understand","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"public class IncomeParser {","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" public static final String DESCRIPTION_FIELD \u003d \"de\";","lastModifiedDate":"2023-10-12"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" public static final String DATE_FIELD \u003d \"da\";","lastModifiedDate":"2023-10-12"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" public static final String AMOUNT_FIELD \u003d \"am\";","lastModifiedDate":"2023-10-12"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" public static final String INDEX_FIELD \u003d \"in\";","lastModifiedDate":"2023-10-12"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(IncomeParser.class.getName());","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/IncomeParser.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" } catch (SecurityException se) {","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", se);","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" System.err.println(\"Insufficient permissions to create logs directory. Please check your permissions or \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" \"run the program in a different directory.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" * This method is used to parse the date of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeParser class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeManager class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * @param incomeDateString String containing the date of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" * @return incomeDate LocalDate containing the date of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" public static LocalDate parseDate(String incomeDateString) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" assert incomeDateString !\u003d null : \"incomeDateString should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" LocalDate incomeDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MM/uuuu\")","lastModifiedDate":"2023-10-12"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" .withResolverStyle(ResolverStyle.STRICT);","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-12"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" incomeDate \u003d LocalDate.parse(incomeDateString, formatter);","lastModifiedDate":"2023-10-12"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" } catch (DateTimeParseException e) {","lastModifiedDate":"2023-10-12"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid date format\" + incomeDateString, e);","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid date in the format dd/MM/yyyy\");","lastModifiedDate":"2023-10-12"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" if (incomeDate.isAfter(LocalDate.now())) {","lastModifiedDate":"2023-10-12"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Date is in the future\" + incomeDateString);","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a date that is not in the future\");","lastModifiedDate":"2023-10-12"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" if (incomeDate.getYear() \u003c 0) {","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid year\" + incomeDateString);","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Year should not be negative, Please enter a valid year\");","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" return incomeDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" * This method is used to parse the fields of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeManager class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" * @param argumentsByField HashMap containing the description, date, and amount of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" * @return Income object created from the provided fields","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" public static Income parseIncome(HashMap\u003cString, String\u003e argumentsByField) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" if (argumentsByField \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Income fields cannot be null\");","lastModifiedDate":"2023-10-29"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" if (!argumentsByField.containsKey(DESCRIPTION_FIELD) ||","lastModifiedDate":"2023-10-12"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" !argumentsByField.containsKey(DATE_FIELD) ||","lastModifiedDate":"2023-10-12"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" !argumentsByField.containsKey(AMOUNT_FIELD)) {","lastModifiedDate":"2023-10-12"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Missing fields detected\");","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" String incomeDescriptionString \u003d argumentsByField.get(DESCRIPTION_FIELD);","lastModifiedDate":"2023-10-12"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" String incomeDateString \u003d argumentsByField.get(DATE_FIELD);","lastModifiedDate":"2023-10-12"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" String incomeAmountString \u003d argumentsByField.get(AMOUNT_FIELD);","lastModifiedDate":"2023-10-12"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" LocalDate incomeDate \u003d parseDate(incomeDateString);","lastModifiedDate":"2023-10-12"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" double incomeAmount;","lastModifiedDate":"2023-10-12"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-12"},{"lineNumber":113,"author":{"gitId":"limyuhching"},"content":" if (!isOtherCurrency(incomeAmountString)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" incomeAmount \u003d Double.parseDouble(incomeAmountString);","lastModifiedDate":"2023-10-12"},{"lineNumber":115,"author":{"gitId":"limyuhching"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"limyuhching"},"content":" // Convert Currency to SGD","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d incomeAmountString.split(\" \");","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"limyuhching"},"content":" String currency \u003d tokens[0].trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":120,"author":{"gitId":"limyuhching"},"content":" incomeAmount \u003d Double.parseDouble(tokens[1].trim());","lastModifiedDate":"2023-11-01"},{"lineNumber":121,"author":{"gitId":"limyuhching"},"content":" incomeAmount \u003d exchangeRateManager.convertCurrency(currency, incomeAmount);","lastModifiedDate":"2023-11-01"},{"lineNumber":122,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.showCurrencyConversionMessage(currency);","lastModifiedDate":"2023-11-01"},{"lineNumber":123,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-12"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid amount format\" + incomeAmountString, e);","lastModifiedDate":"2023-10-19"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid amount\");","lastModifiedDate":"2023-10-12"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" if (incomeAmount \u003e 999999.99 || incomeAmount \u003c\u003d 0) {","lastModifiedDate":"2023-10-12"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.WARNING, \"Invalid amount\" + incomeAmountString);","lastModifiedDate":"2023-10-19"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Income amount must be between $0.01 and $999999.99\");","lastModifiedDate":"2023-10-12"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" return new Income(incomeDescriptionString, incomeDate, incomeAmount);","lastModifiedDate":"2023-10-12"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" * This method is used to get the index of the income.","lastModifiedDate":"2023-10-16"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" * This method is used by the IncomeDeleter class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" * @param argumentsByFields HashMap containing the index of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" * @return index int containing the index of the income","lastModifiedDate":"2023-10-16"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is an error in the command","lastModifiedDate":"2023-10-16"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" public static int getIndex(HashMap\u003cString, String\u003e argumentsByFields) throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" assert argumentsByFields !\u003d null : \"argumentsByFields should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" if (!argumentsByFields.containsKey(INDEX_FIELD)) {","lastModifiedDate":"2023-10-12"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Missing index field detected\");","lastModifiedDate":"2023-10-12"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" int index;","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-12"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" index \u003d Integer.parseInt(argumentsByFields.get(INDEX_FIELD));","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-12"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid index\");","lastModifiedDate":"2023-10-12"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" if (index \u003c\u003d 0) {","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Please enter a valid index\");","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" return index;","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":160,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"limyuhching"},"content":" private static boolean isOtherCurrency(String amount) {","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"limyuhching"},"content":" return (amount.split(\" \").length \u003e 1);","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"limyuhching":15,"bljhty":149}},{"path":"src/main/java/seedu/duke/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-19"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-19"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"/*","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" * parser class to parse user input","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public class Parser {","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" //private static final Logger LOGGER \u003d Logger.getLogger(Parser.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(Parser.class.getName());","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" static {","lastModifiedDate":"2023-10-19"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" File dir \u003d new File(\"logs\");","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" if (!dir.exists()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" if (!dir.mkdirs()) {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"Failed to create directory \" + dir.getAbsolutePath());","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" FileHandler fh \u003d new FileHandler(\"logs/Parser.log\", true);","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-19"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" fh.setFormatter(formatter);","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" LOGGER.addHandler(fh);","lastModifiedDate":"2023-10-19"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" LOGGER.setLevel(Level.ALL);","lastModifiedDate":"2023-10-19"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" LOGGER.setUseParentHandlers(false);","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" } catch (SecurityException se) {","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", se);","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" System.err.println(\"Insufficient permissions to create logs directory. Please check your permissions or \" +","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" \"run the program in a different directory.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" } catch (Exception e) {","lastModifiedDate":"2023-10-19"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.SEVERE, \"Error creating log file\", e);","lastModifiedDate":"2023-10-19"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" * This method is used to parse the user input.","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" * This method is used by the Main class in the application","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" * @param fullCommand String containing the user input","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" * @return String containing the command to be executed","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" public static String parse(String fullCommand) {","lastModifiedDate":"2023-10-11"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" assert fullCommand !\u003d null : \"fullCommand should not be null\";","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" String trimmedCommand \u003d fullCommand.trim();","lastModifiedDate":"2023-10-11"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" String commandLowerCase \u003d trimmedCommand.toLowerCase();","lastModifiedDate":"2023-10-11"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO, (\"Parsing user input:\") + fullCommand);","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" String resultCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" if (commandLowerCase.equals(\"exit\")) {","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"exit\";","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" } else if (commandLowerCase.startsWith(\"add income\")) {","lastModifiedDate":"2023-10-12"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"add_income\";","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" } else if (commandLowerCase.equals(\"list income\")) {","lastModifiedDate":"2023-10-12"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"list_income\";","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"Hongzhii"},"content":" } else if (commandLowerCase.startsWith(\"add expense\")) {","lastModifiedDate":"2023-10-15"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"add_expense\";","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"Hongzhii"},"content":" } else if (commandLowerCase.equals((\"list expense\"))) {","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"list_expense\";","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.equals(\"help\")) {","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"help\";","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.equals(\"list\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"list\";","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"delete income\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"delete_income\";","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"delete expense\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"delete_expense\";","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.equals(\"balance\")) {","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"balance\";","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" } else if (commandLowerCase.startsWith(\"find\")) {","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"find\";","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.startsWith(\"clear incomes\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" resultCommand \u003d \"clear_incomes\";","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.startsWith(\"clear expenses\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" resultCommand \u003d \"clear_expenses\";","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" } else if (commandLowerCase.startsWith(\"clear all\")) {","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" resultCommand \u003d \"clear_all\";","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"edit income\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"edit_income\";","lastModifiedDate":"2023-10-26"},{"lineNumber":90,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"edit expense\")) {","lastModifiedDate":"2023-10-26"},{"lineNumber":91,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"edit_expense\";","lastModifiedDate":"2023-10-26"},{"lineNumber":92,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.equals(\"list currencies\")) {","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"list_currencies\";","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.equals(\"list exchange rates\")) {","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"list_exchange_rates\";","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"limyuhching"},"content":" } else if (commandLowerCase.startsWith(\"update exchange rate\")) {","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"limyuhching"},"content":" resultCommand \u003d \"update_exchange_rate\";","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" resultCommand \u003d \"invalid\";","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" LOGGER.log(Level.INFO , (\"Parsed command: \") + resultCommand);","lastModifiedDate":"2023-10-19"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" return resultCommand;","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"limyuhching":13,"bljhty":81,"Hongzhii":2,"KenCheung18":8}},{"path":"src/main/java/seedu/duke/storage/ExchangeRateFileHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateFileHandler {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private static final String WRONG_FORMAT_ERROR \u003d \"Invalid row in exchange rate file\";","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private String filePath;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" public ExchangeRateFileHandler(String filePath) {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" this.filePath \u003d filePath;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" public boolean load() throws KaChinnnngException, FileNotFoundException {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" boolean loadedAllRows \u003d true;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" if (createFile(filePath)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" return true; // File not found, created new file","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" String textLine \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" String[] tokens \u003d textLine.split(\",\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" String currency \u003d tokens[0].toUpperCase().trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" double rate \u003d Double.parseDouble(tokens[1].trim());","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" } catch (IndexOutOfBoundsException | NumberFormatException | NullPointerException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" // Skip line if rate is not a double","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" System.out.println(WRONG_FORMAT_ERROR + \" : \" + textLine);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" loadedAllRows \u003d false;","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" return loadedAllRows;","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" public void save(HashMap\u003cString, Double\u003e exchangeRates) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" try (FileWriter fw \u003d new FileWriter(filePath)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" for (Map.Entry\u003cString, Double\u003e entry : exchangeRates.entrySet()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" String currency \u003d entry.getKey();","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" Double rate \u003d entry.getValue();","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" fw.write(currency + \",\" + rate + \"\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Something went wrong when saving exchange rates\");","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" private boolean createFile(String filePath) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" if (!file.getParentFile().exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" file.getParentFile().mkdirs();","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" return file.createNewFile();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Cannot create file; reason: \" + e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"limyuhching":69}},{"path":"src/main/java/seedu/duke/storage/GetFromTxt.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"import java.io.File;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" * The GetFromTxt class is responsible for reading financial records data from a text file.","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" * It parses the contents of the file and populates two ArrayLists: one for Incomes and one for Expenses.","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * This class handles exceptions for file creation errors, parsing errors, and other issues that may arise","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * when reading data from the file.","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":"public class GetFromTxt {","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" private static final String AMOUNT_NOT_SUPPORT_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" \"Amount field from this line is not supported from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" private static final String DATE_TIME_FORMAT_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" \"Date time format incorrect on this line from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" private static final String FILE_CREATION_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" \"Something went wrong while creating the file from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" private static final String INDEX_OUT_OF_BOUND_FROM_FILE_ERROR \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" \"Details missed on this line from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" private static final String NUMBER_FROM_FILE_INCORRECT \u003d","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" \"The expense type is incorrect on this line from storage file \";","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" private final File file;","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" * Construct a new object of the GetFromTxt class with the provided file path.","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" * @param path The path to the text file containing financial records data.","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" public GetFromTxt(String path) {","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" file \u003d new File(path);","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" * Reads financial records data from the text file and add to the corresponding ArrayLists","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" * with Income and Expense objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The ArrayList to store Income objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The ArrayList to store Expense objects.","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" * @throws FileNotFoundException If the file specified by the path cannot be found.","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" public void getFromTextFile(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses) throws FileNotFoundException {","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" if (file.createNewFile()) {","lastModifiedDate":"2023-10-25"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" return; // If there is no such file in the directory, create the file and return without reading data.","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" System.out.println(FILE_CREATION_ERROR);","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" String textLine \u003d s.nextLine();","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" // Parse the data from the text line","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" int expenseType \u003d 0;","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" String commandFromFile \u003d textLine.split(\" \\\\| \")[0];","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" String descriptionFromFile \u003d textLine.split(\" \\\\| \")[1];","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" double amountFromFile \u003d Double. parseDouble(textLine.split(\" \\\\| \")[2]);","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" LocalDate dateFromFile \u003d LocalDate.parse(textLine.split(\" \\\\| \")[3]);","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" // Check for valid amount range","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" if (amountFromFile \u003e 999999.99 || amountFromFile \u003c\u003d 0) {","lastModifiedDate":"2023-10-25"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" throw new KaChinnnngException(\"Expense amount must be between $0.01 and $999999.99\");","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" if (!commandFromFile.equals(\"I\")){","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" expenseType \u003d Integer.parseInt(textLine.split(\" \\\\| \")[4]);","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" // Create appropriate objects based on the commandFromFile","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" switch (commandFromFile) {","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" case \"I\":","lastModifiedDate":"2023-10-25"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(descriptionFromFile, dateFromFile, amountFromFile));","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" case \"EF\":","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(descriptionFromFile, dateFromFile,","lastModifiedDate":"2023-10-25"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" amountFromFile, MealType.values()[expenseType]));","lastModifiedDate":"2023-10-25"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" case \"ET\":","lastModifiedDate":"2023-10-25"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(descriptionFromFile, dateFromFile,","lastModifiedDate":"2023-10-25"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" amountFromFile, TransportationType.values()[expenseType]));","lastModifiedDate":"2023-10-25"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":" case \"EU\":","lastModifiedDate":"2023-10-25"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(descriptionFromFile, dateFromFile,","lastModifiedDate":"2023-10-25"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":" amountFromFile, UtilityType.values()[expenseType]));","lastModifiedDate":"2023-10-25"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":" break;","lastModifiedDate":"2023-10-25"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":" default:","lastModifiedDate":"2023-10-25"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"The format of this line is incorrect \" + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":" } catch (IndexOutOfBoundsException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":" System.out.println(INDEX_OUT_OF_BOUND_FROM_FILE_ERROR + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":" System.out.println(AMOUNT_NOT_SUPPORT_ERROR + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":111,"author":{"gitId":"KenCheung18"},"content":" } catch (DateTimeParseException e){","lastModifiedDate":"2023-10-25"},{"lineNumber":112,"author":{"gitId":"KenCheung18"},"content":" System.out.println(DATE_TIME_FORMAT_ERROR + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":113,"author":{"gitId":"KenCheung18"},"content":" } catch(NumberFormatException e){","lastModifiedDate":"2023-10-25"},{"lineNumber":114,"author":{"gitId":"KenCheung18"},"content":" System.out.println(NUMBER_FROM_FILE_INCORRECT + \"\\\"\" + textLine + \"\\\"\");","lastModifiedDate":"2023-10-25"},{"lineNumber":115,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":116,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":117,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":118}},{"path":"src/main/java/seedu/duke/storage/SaveToTxt.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" * The SaveToTxt class is responsible for saving financial records data to a text file.","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * It can save both Income and Expense objects to the specified file.","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" * This class handles exceptions for IO errors that may occur during file operations.","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"public class SaveToTxt {","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" private static final String IO_ERROR_MESSAGE \u003d \"An error occurred while saving tasks to the file.\";","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" private final String path;","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" * Construct a new object of the SaveToTxt class with the file path.","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * @param path The path to the text file where data will be saved.","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" public SaveToTxt(String path) {","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" this.path \u003d path;","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" * Saves both Income and Expense objects to the specified text file.","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The ArrayList of Income objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The ArrayList of Expense objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" public void saveIncomeAndExpense(ArrayList\u003cIncome\u003e incomes, ArrayList\u003cExpense\u003e expenses){","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" System.out.println(IO_ERROR_MESSAGE);","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * Saves Income objects to the text file. Each Income object is represented as a line in the txt file.","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" * @param incomes The ArrayList of Income objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" * @throws IOException If an IO error occurs during the file write operation.","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" public void saveIncomeToTextFile(ArrayList\u003cIncome\u003e incomes) throws IOException {","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" try (FileWriter fw \u003d new FileWriter(path)) {","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" for (Income income : incomes) {","lastModifiedDate":"2023-10-25"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" String incomeDescription \u003d income.getDescription();","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" String incomeDate \u003d String.valueOf(income.getDate());","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" String incomeAmount \u003d String.valueOf(income.getAmount());","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" String textToAdd \u003d \"I\" + \" | \" + incomeDescription + \" | \" + incomeAmount + \" | \" + incomeDate + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" System.out.println(IO_ERROR_MESSAGE);","lastModifiedDate":"2023-10-25"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" * Saves Expense objects to the text file. Each Expense object is represented as a line in the file,","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" * and the type of Expense (Food, Transport, or Utilities) is specified in the line.","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" *","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" * @param expenses The ArrayList of Expense objects to save.","lastModifiedDate":"2023-10-25"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" * @throws IOException If an IO error occurs during the file write operation.","lastModifiedDate":"2023-10-25"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" public void saveExpenseToTextFile(ArrayList\u003cExpense\u003e expenses) throws IOException{","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" try (FileWriter fw \u003d new FileWriter(path, true)) {","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" for (Expense expense : expenses) {","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" String textToAdd \u003d \"\";","lastModifiedDate":"2023-10-25"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" String expenseDescription \u003d expense.getDescription();","lastModifiedDate":"2023-10-25"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" String expenseDate \u003d String.valueOf(expense.getDate());;","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" String expenseAmount \u003d String.valueOf(expense.getAmount());","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" // Determine the type of Expense and format the line accordingly","lastModifiedDate":"2023-10-25"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" if (expense.getClass() \u003d\u003d Food.class) {","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" textToAdd \u003d \"EF\" + \" | \" + expenseDescription + \" | \" + expenseAmount + \" | \"","lastModifiedDate":"2023-10-25"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" + expenseDate + \" | \" + ((Food) expense).getMealType().ordinal() + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" } else if (expense.getClass() \u003d\u003d Transport.class) {","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" textToAdd \u003d \"ET\" + \" | \" + expenseDescription + \" | \" + expenseAmount + \" | \"","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" + expenseDate + \" | \" + ((Transport) expense).getTransportationType().ordinal() + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" } else if (expense.getClass() \u003d\u003d Utilities.class) {","lastModifiedDate":"2023-10-25"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" textToAdd \u003d \"EU\" + \" | \" + expenseDescription + \" | \" + expenseAmount + \" | \"","lastModifiedDate":"2023-10-25"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" + expenseDate + \" | \" + ((Utilities) expense).getUtilityType().ordinal() + \"\\n\";","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" fw.write(textToAdd);","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-25"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" System.out.println(IO_ERROR_MESSAGE);","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"KenCheung18":98}},{"path":"src/main/java/seedu/duke/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.ui;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * This class handles the user interface of the program.","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"public class Ui {","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" private static final String lineDivider \u003d \"____________________________________________________________\";","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public Scanner scanner;","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" * Constructor for Ui.","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public Ui() {","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" this.scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" * This method reads the command input by the user.","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" * @return String containing the command input by the user","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if there is no input provided by the user","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" public String readCommand() throws KaChinnnngException {","lastModifiedDate":"2023-10-11"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" if (scanner.hasNextLine()) {","lastModifiedDate":"2023-10-11"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" return scanner.nextLine();","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" throw new KaChinnnngException(\"No input provided by the user.\");","lastModifiedDate":"2023-10-11"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * This method prints the line divider.","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" public static void showLineDivider() {","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-12"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" * Prints the welcome message when the program starts.","lastModifiedDate":"2023-10-12"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-12"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" public static void printWelcomeMessage() {","lastModifiedDate":"2023-10-09"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-09"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Welcome to KaChinnnngggg! How may i assist you today?\");","lastModifiedDate":"2023-10-09"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-09"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-12"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" * Prints the goodbye message when the program ends.","lastModifiedDate":"2023-10-12"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-12"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" public void printGoodbyeMessage() {","lastModifiedDate":"2023-10-11"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Bye. Hope to see you again soon!\");","lastModifiedDate":"2023-10-09"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" System.out.println(lineDivider);","lastModifiedDate":"2023-10-09"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" * prints the message when the user inputs his income","lastModifiedDate":"2023-10-16"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-16"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" * @param income Income object created from the provided fields","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public static void printIncomeAddedMessage(Income income) {","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Got it. I\u0027ve added this income:\\n\" + income.toString());","lastModifiedDate":"2023-10-12"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * Prints a message indicating the start of the income list display.","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" public void printListIncomeMessage() {","lastModifiedDate":"2023-10-12"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Here are your incomes:\");","lastModifiedDate":"2023-10-12"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":80,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" public static void printExpenseAddedMessage(Expense expense) {","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":83,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"Got it. I\u0027ve added this expense:\\n\" + expense.toString());","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"limyuhching"},"content":" showLineDivider();","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"Hongzhii"},"content":" public void printListExpenseMessage() {","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"Hongzhii"},"content":" System.out.println(\"Here are your expenses:\");","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" public void printMessage(String message) {","lastModifiedDate":"2023-10-23"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" System.out.println(message);","lastModifiedDate":"2023-10-23"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncomes(List\u003cIncome\u003e matchingIncomes) {","lastModifiedDate":"2023-10-23"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" if(matchingIncomes \u003d\u003d null || matchingIncomes.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" System.out.print(\"No matching incomes found.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Here are the matching incomes in your list:\");","lastModifiedDate":"2023-10-23"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" for (Income income : matchingIncomes) {","lastModifiedDate":"2023-10-23"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" System.out.println(income.toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses(List\u003cExpense\u003e matchingExpenses) {","lastModifiedDate":"2023-10-23"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" if (matchingExpenses \u003d\u003d null || matchingExpenses.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" System.out.print(\"No matching expenses found.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" } else {","lastModifiedDate":"2023-10-23"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" System.out.println(\"Here are the matching expenses in your list:\");","lastModifiedDate":"2023-10-23"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" for (Expense expense : matchingExpenses) {","lastModifiedDate":"2023-10-23"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" System.out.println(expense.toString());","lastModifiedDate":"2023-10-23"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"limyuhching":5,"bljhty":102,"Hongzhii":8}},{"path":"src/test/java/seedu/duke/DukeTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"package seedu.duke;","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"class DukeTest {","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" Duke duke;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" duke \u003d new Duke();","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" void loadData_noFileExists_createsFile() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" File file \u003d new File(\"KaChinnnngggg.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" boolean isDeleted \u003d file.delete();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" assertTrue(isDeleted, \"File should have been deleted before the test.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" duke.loadData();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" assertTrue(file.exists(), \"File should have been created\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" void loadData_fileExists_loadsData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" File file \u003d new File(\"KaChinnnngggg.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" boolean isDeleted \u003d file.delete();","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" assertTrue(isDeleted, \"File should have been deleted before the test.\");","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" duke.loadData();","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assertTrue(file.exists(), \"File should have been created\");","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" void executeCommand_validCommand_noExceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"income /de Salary /date 12/10/2023 /amt 5000.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" void executeCommand_invalidCommand_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"income /de Salary /date 12/10/2023 /amt 5000.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" void executeCommand_addIncome_increasesSizeOfIncomeList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" int initialSize \u003d duke.getIncomesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 01/10/2023 /amt 1000.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" assertEquals(initialSize + 1, duke.getIncomesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" void addIncome_invalidIncome_exception() {","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 01/10/2024 /amt 1000.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" void executeCommand_addExpense_increasesSizeOfExpenseList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" int initialSize \u003d duke.getExpensesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add expense /cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" \" /de chicken sandwich /date 01/10/2023 /amt 10.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" assertEquals(initialSize + 1, duke.getExpensesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" void addExpense_invalidExpense_exception() {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e duke.executeCommand(\"add expense /cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" \" /de chicken sandwich /date 01/10/2024 /amt 10.00\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" void executeCommand_deleteIncome_decreasesSizeOfIncomeList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 03/10/2023 /amt 1000.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" int sizeAfterAddition \u003d duke.getIncomesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"delete income 1\"); // Assuming index 1 exists for this test","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" assertEquals(sizeAfterAddition - 1, duke.getIncomesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" void executeCommand_deleteExpense_decreasesSizeOfExpenseList() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add expense /cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" \" /de chicken sandwich /date 03/10/2023 /amt 10.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" int sizeAfterAddition \u003d duke.getExpensesSize();","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"delete expense 1\"); // Assuming index 1 exists for this test","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" assertEquals(sizeAfterAddition - 1, duke.getExpensesSize());","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" void executeCommand_balance_correctOutput() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" // Backup the original system out","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" PrintStream captureStream \u003d new PrintStream(outputStream);","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" System.setOut(captureStream);","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" // Assuming the list starts empty, and you add an income and an expense","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add income /de Bonus /date 03/10/2023 /amt 1000.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"add expense /cat food /type lunch \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" \"/de chicken sandwich /date 01/10/2023 /amt 10.00\");","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" // Clear the outputStream to only capture the balance output","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" outputStream.reset();","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" // Capture balance output","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" duke.executeCommand(\"balance\");","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" String balanceOutput \u003d outputStream.toString().trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" // The expected output based on the given additions","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" String expectedBalanceOutput \u003d","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" \"____________________________________________________________\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" \"Balance: 990.0\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" \"____________________________________________________________\";","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedBalanceOutput, balanceOutput);","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" // Restore the original System.out","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":134,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"bljhty":125,"-":9}},{"path":"src/test/java/seedu/duke/commands/BalanceTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Tests for the {@link Balance} class.","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * This test class provides test cases to check the calculation and reporting","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * of financial balance between income and expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"public class BalanceTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7), 100.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with both income and expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly subtracts expenses from income.","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" public void testGetBalance_withBothIncomeAndExpenses_returnsCorrectDifference() {","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(incomes, expenses);","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" assertEquals(3900.0, balance.getBalance());","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with no records.","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly returns 0.","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" public void testNoRecords() {","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(new ArrayList\u003c\u003e(), new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" assertEquals(0, balance.getBalance(),","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" \"Balance should be 0 when no records are present.\");","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with no expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly returns a positive value equal to income.","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" public void testGetBalance_withNoExpenses_returnsIncomeValue()throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cIncome\u003e incomesOnly \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" incomesOnly.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(incomesOnly, new ArrayList\u003c\u003e());","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" assertEquals(5000.0, balance.getBalance(),","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" \"Balance should equal sum of all incomes when no expenses are present.\");","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" * Test the {@link Balance#getBalance()} method with no incomes.","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * This test case checks if the balance calculation correctly returns a negative value equal to expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public void testGetBalance_withNoIncomes_returnsNegativeExpenseValue()throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" ArrayList\u003cExpense\u003e expensesOnly \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" expensesOnly.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" Balance balance \u003d new Balance(new ArrayList\u003c\u003e(), expensesOnly);","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" assertEquals(-2000.0, balance.getBalance(),","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" \"Balance should be negative sum of all expenses when no incomes are present.\");","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":85}},{"path":"src/test/java/seedu/duke/commands/ClearAllTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link ClearAll} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check the deletion of records in","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":" * both incomes and expenses record list","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"public class ClearAllTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10),","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15),","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5),","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" 2000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7),","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" 100.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with both incomes and expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear all function correctly delete all the record in the income and expenses list.","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" public void testClearAll_withIncomesAndExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with only incomes but not expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear all function correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" * delete all the record in the both list without error.","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" public void testClearAll_withIncomesNoExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with only expenses but no incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear all function correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" * delete all the record in the both list without error.","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" public void testClearAll_withExpensesNoIncomes() {","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearAll#clearAllIncomeAndExpense()} method with no records.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if there is an empty list, whether clear income function will still process correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" public void testNoIncomesAndExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" ClearAll clearAll \u003d new ClearAll(testIncomes, testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" clearAll.clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":99}},{"path":"src/test/java/seedu/duke/commands/ClearExpensesTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link ClearExpenses} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check the deletion of records in","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * expenses record list","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"public class ClearExpensesTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7),","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" 100.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearExpenses#clearAllExpenses()} method with expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear incomes function correctly delete all the record in the income list.","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" public void testClearExpenses_withExpenses() {","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" ClearExpenses clearExpenses \u003d new ClearExpenses(testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" clearExpenses.clearAllExpenses();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearExpenses#clearAllExpenses()} method with no records.","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if there is an empty list, whether clear income function will still process correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" public void testNoExpenses() throws KaChinnnngException{","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" ClearExpenses clearExpenses \u003d new ClearExpenses(testExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" clearExpenses.clearAllExpenses();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":56}},{"path":"src/test/java/seedu/duke/commands/ClearIncomesTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link ClearAll} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check the deletion of records in","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":" * both incomes and expenses record list","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"public class ClearIncomesTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearIncomes#clearAllIncomes()} method with incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if the clear incomes function correctly delete all the record in the income list.","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" public void testClearIncome_withIncomes() {","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncome \u003d new ArrayList\u003c\u003e(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" ClearIncomes clearTestIncome \u003d new ClearIncomes(testIncome);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" clearTestIncome.clearAllIncomes();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncome.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link ClearIncomes#clearAllIncomes()} method with no records.","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * This test case checks if there is an empty list, whether clear income function will still process correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" public void testNoIncomes() {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e testIncome \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" ClearIncomes clearTestIncome \u003d new ClearIncomes(testIncome);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" clearTestIncome.clearAllIncomes();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, testIncome.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":57}},{"path":"src/test/java/seedu/duke/commands/DeleteExpenseCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * This class contains JUnit tests for the DeleteExpenseCommand class.","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":"public class DeleteExpenseCommandTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" private DeleteExpenseCommand deleteExpenseCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private Ui ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" public void setUp() {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" deleteExpenseCommand \u003d new DeleteExpenseCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" ui \u003d new Ui();","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with valid input. The expense should be deleted.","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_expenseDeleted() throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" Expense expense \u003d new Expense(\"Lunch\", LocalDate.now().minusDays(1), 20.00);","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" expenses.add(expense);","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" // Act","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" // Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" assertEquals(0, expenses.size());","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with missing arguments. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" public void testExecute_missingArgument_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense\";","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with an invalid index. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteExpenseCommand with a non-existent expense index.","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" * It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":" public void testExecute_nonExistentExpenseIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete expense 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteExpenseCommand.execute(expenses, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"limyuhching":82}},{"path":"src/test/java/seedu/duke/commands/DeleteIncomeCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-23"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.ui.Ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"/**","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":" * This class contains JUnit tests for the DeleteIncomeCommand class.","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":"public class DeleteIncomeCommandTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" private DeleteIncomeCommand deleteIncomeCommand;","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" private Ui ui;","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-23"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" public void setUp() {","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" deleteIncomeCommand \u003d new DeleteIncomeCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" ui \u003d new Ui();","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with valid input. The income should be deleted.","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_incomeDeleted() throws KaChinnnngException {","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" Income income \u003d new Income(\"Salary\",","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" incomes.add(income);","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" // Act","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" // Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" assertEquals(0, incomes.size());","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with missing arguments. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" public void testExecute_missingArgument_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income\";","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with an invalid index. It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":70,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":71,"author":{"gitId":"limyuhching"},"content":" /**","lastModifiedDate":"2023-10-23"},{"lineNumber":72,"author":{"gitId":"limyuhching"},"content":" * Test the execution of the DeleteIncomeCommand with a non-existent income index.","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"limyuhching"},"content":" * It should throw a KaChinnnngException.","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"limyuhching"},"content":" */","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"limyuhching"},"content":" public void testExecute_nonExistentIncomeIndex_exceptionThrown() {","lastModifiedDate":"2023-10-23"},{"lineNumber":77,"author":{"gitId":"limyuhching"},"content":" // Arrange","lastModifiedDate":"2023-10-23"},{"lineNumber":78,"author":{"gitId":"limyuhching"},"content":" String fullCommand \u003d \"delete income 1\";","lastModifiedDate":"2023-10-23"},{"lineNumber":79,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":80,"author":{"gitId":"limyuhching"},"content":" // Act and Assert","lastModifiedDate":"2023-10-23"},{"lineNumber":81,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e deleteIncomeCommand.execute(incomes, fullCommand, ui));","lastModifiedDate":"2023-10-23"},{"lineNumber":82,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":83,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"limyuhching":83}},{"path":"src/test/java/seedu/duke/commands/EditExpenseCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class EditExpenseCommandTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" public void setUp() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" // Initialize the expenses and fullCommand for testing","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" expenses.add(new Expense(\"Rent\", LocalDate.of(2023, 10, 5), 2000.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" expenses.add(new Expense(\"Groceries\", LocalDate.of(2023, 10, 7), 100.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" fullCommand \u003d \"edit expense 3 expense /cat food /type lunch /de chicken sandwich /date 01/10/2023 /amt 10.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" EditExpenseCommand editExpenseCommand \u003d new EditExpenseCommand(expenses, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" // This test checks if the execute method throws an exception when the index is out of bounds","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" editExpenseCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_expenseEdited() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":" fullCommand \u003d \"edit expense 1 expense /cat food /type lunch /de chicken rice /date 01/10/2023 /amt 10.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" EditExpenseCommand editExpenseCommand \u003d new EditExpenseCommand(expenses, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" // Test if the execute method changes the expense and prints the changes","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e editExpenseCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" // Verify if the expense was updated correctly","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" Expense updatedExpense \u003d expenses.get(0);","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":" assertEquals(\"Food Expense (LUNCH): chicken rice | Date: 01/Oct/2023 | Amount: $10.00\",","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" updatedExpense.toString());","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidExpense_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" // Test if execute method throws a KaChinnnngException for an invalid command","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit expense 1 invalid expense command\";","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" EditExpenseCommand editExpenseCommand \u003d new EditExpenseCommand(expenses, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e editExpenseCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":54,"Hongzhii":4}},{"path":"src/test/java/seedu/duke/commands/EditIncomeCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"public class EditIncomeCommandTest {","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" private EditIncomeCommand editIncomeCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" private String fullCommand;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" public void setUp() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" // Initialize the incomes and fullCommand for testing","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIndex_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit income 3 income /de salary for October /date 01/10/2023 /amt 5000.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand \u003d new EditIncomeCommand(incomes, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" // This test checks if the execute method throws an exception when the index is out of bounds","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand.execute();","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" });","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" public void testExecute_validInput_incomeEdited() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit income 1 income /de salary for October /date 01/10/2023 /amt 5000.00\";","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand \u003d new EditIncomeCommand(incomes, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" // Test if the execute method changes the income and prints the changes","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" assertDoesNotThrow(() -\u003e editIncomeCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" // Verify if the income was updated correctly","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" Income updatedincome \u003d incomes.get(0);","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" assertEquals(\"Income: salary for October | Date: 01/Oct/2023 | Amount: $5000.00\",","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" updatedincome.toString());","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" public void testExecute_invalidIncome_exceptionThrown() throws KaChinnnngException {","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" // Test if execute method throws a KaChinnnngException for an invalid command","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" fullCommand \u003d \"edit income 1 invalid income command\";","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" editIncomeCommand \u003d new EditIncomeCommand(incomes, fullCommand);","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" assertThrows(KaChinnnngException.class, () -\u003e editIncomeCommand.execute());","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"limyuhching":59}},{"path":"src/test/java/seedu/duke/commands/ExpenseManagerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"Hongzhii"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"Hongzhii"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"Hongzhii"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"Hongzhii"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"Hongzhii"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"Hongzhii"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"Hongzhii"},"content":"public class ExpenseManagerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"Hongzhii"},"content":" private ExpenseManager expenseManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"Hongzhii"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"Hongzhii"},"content":" public void setUp() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"Hongzhii"},"content":" // Initialize the expense manager","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"Hongzhii"},"content":" expenseManager \u003d new ExpenseManager(\"/cat food /type lunch /de chicken rice \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"Hongzhii"},"content":" \"/date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"Hongzhii"},"content":" public void testConstructor_objectCreated() {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"Hongzhii"},"content":" assertNotNull(expenseManager);","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_getNewExpense() throws KaChinnnngException{","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"Hongzhii"},"content":" expenseManager.execute();","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"Hongzhii"},"content":" Expense expense \u003d expenseManager.getNewExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"Hongzhii"},"content":" assertNotNull(expense);","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_missingFields_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerMissingFields \u003d new ExpenseManager(\"/type lunch /de chicken rice \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"Hongzhii"},"content":" \"/date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerMissingFields::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_extraFields_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerExtraFields \u003d new ExpenseManager(\"/cat food /type lunch \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2001 /amt 100 /extra extra\");","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerExtraFields::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_wrongOrder_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerWrongOrder \u003d new ExpenseManager(\"/type lunch /cat food \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerWrongOrder::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_upperAndLowerCase_correctParsing() {","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerUpperLowerCase \u003d new ExpenseManager(\"/cat fOoD /type lUNcH \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2001 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"Hongzhii"},"content":" assertNotNull(expenseManagerUpperLowerCase);","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_invalidDate_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerInvalidDate \u003d new ExpenseManager(\"/cat food /type lunch \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 13/13/2000 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerInvalidDate::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_incorrectDateFormat_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerIncorrectDateFormat \u003d new ExpenseManager(\"/cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01-01-2003 /amt 100\");","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerIncorrectDateFormat::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"Hongzhii"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"Hongzhii"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"Hongzhii"},"content":" public void testExecute_incorrectAmountFormat_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"Hongzhii"},"content":" ExpenseManager expenseManagerIncorrectAmountFormat \u003d new ExpenseManager(\"/cat food /type lunch\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"Hongzhii"},"content":" \"/de chicken rice /date 01/01/2003 /amt one hundred\");","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"Hongzhii"},"content":" assertThrows(KaChinnnngException.class, expenseManagerIncorrectAmountFormat::execute);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"Hongzhii"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"Hongzhii":85}},{"path":"src/test/java/seedu/duke/commands/FindCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.MockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":"public class FindCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e testIncomes;","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cExpense\u003e testExpenses;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" private MockUi mockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" testIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" testExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" mockUi \u003d new MockUi(); // Assuming MockUi has a parameterless constructor.","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Food\",","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByDescription() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" \"Burger\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" null, \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByMonth() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" // Adding multiple expenses in October","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food(\"Pizza\", LocalDate.of(2023, 10, 15), 8.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" Food foodExpense3 \u003d new Food(\"Sandwich\", LocalDate.of(2023, 10, 28), 3.0, MealType.BREAKFAST);","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" // Adding an expense from another month for control","lastModifiedDate":"2023-10-29"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" Food foodExpenseOutsideMonth \u003d new Food(\"Salad\", LocalDate.of(2023, 9, 30), 4.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense3);","lastModifiedDate":"2023-10-29"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpenseOutsideMonth);","lastModifiedDate":"2023-10-29"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null, null, \"Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" + \"Food Expense (DINNER): Pizza | Date: 15/Oct/2023 | Amount: $8.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" + \"Food Expense (BREAKFAST): Sandwich | Date: 28/Oct/2023 | Amount: $3.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandExpenseByDate2() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" null, \"10/10/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" void testMultipleMatchingExpenses() throws Exception{","lastModifiedDate":"2023-10-29"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food (\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food (\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023,10,11), 5.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" \"Burger\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" + \"Food Expense (DINNER): Burger | Date: 11/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" void testNoMatchingExpenses() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" \"NonexistentItem\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" assertTrue(mockUi.getPrintedMessages().contains(\"No matching expenses found.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" void testInvalidDateFormat() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" null, \"20231010\", mockUi); // Invalid date format","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Invalid date format.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" void testNullValues() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" null, null, null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandIncomeByDescription() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" \"Salary\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" void testValidFindCommandIncomeByDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" null, \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" void testMultipleIncomeMatches() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":" Income income1 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" Income income2 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income1);","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income2);","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" \"Salary\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" + \"Income: Salary | Date: 11/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" void testNoMatchingIncomes() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":" \"NonexistentItem\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" assertTrue(mockUi.getPrintedMessages().contains(\"No matching incomes found.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" void testIncomesByMonth() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" Income income1 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" Income income2 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":" Income income3 \u003d new Income(\"Salary\", LocalDate.of(2023, 9, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income1);","lastModifiedDate":"2023-10-29"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income2);","lastModifiedDate":"2023-10-29"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income3);","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" null, \"Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" + \"Income: Salary | Date: 11/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":" void testIncomeFutureDate() {","lastModifiedDate":"2023-10-29"},{"lineNumber":247,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":248,"author":{"gitId":"bljhty"},"content":" Income futureIncome \u003d new Income(\"Bonus\", LocalDate.of(2025, 10, 10), 7000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":249,"author":{"gitId":"bljhty"},"content":" testIncomes.add(futureIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":250,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":251,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":252,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Date cannot be in the future!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":253,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":254,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":255,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":256,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDescriptionAndDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":257,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":258,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 11), 5.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":259,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":260,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":261,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":262,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":263,"author":{"gitId":"bljhty"},"content":" \"Burger\", \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":264,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":265,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":266,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":267,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":268,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":269,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":270,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":271,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDescriptionAndCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":272,"author":{"gitId":"bljhty"},"content":" Food foodExpense1 \u003d new Food(\"Burger\", LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":273,"author":{"gitId":"bljhty"},"content":" Food foodExpense2 \u003d new Food(\"Pizza\", LocalDate.of(2023, 10, 11), 5.0, MealType.DINNER);","lastModifiedDate":"2023-10-29"},{"lineNumber":274,"author":{"gitId":"bljhty"},"content":" Transport transportExpense \u003d new Transport(\"Bus\",","lastModifiedDate":"2023-10-29"},{"lineNumber":275,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, TransportationType.BUS);","lastModifiedDate":"2023-10-29"},{"lineNumber":276,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":277,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":278,"author":{"gitId":"bljhty"},"content":" testExpenses.add(transportExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":279,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":280,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Food\",","lastModifiedDate":"2023-10-29"},{"lineNumber":281,"author":{"gitId":"bljhty"},"content":" \"Burger\", null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":282,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":283,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":284,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Food Expense (LUNCH): Burger | Date: 10/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":285,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":286,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":287,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":288,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":289,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDateAndCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":290,"author":{"gitId":"bljhty"},"content":" Transport transportExpense1 \u003d new Transport(\"Bus\",","lastModifiedDate":"2023-10-29"},{"lineNumber":291,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, TransportationType.BUS);","lastModifiedDate":"2023-10-29"},{"lineNumber":292,"author":{"gitId":"bljhty"},"content":" Utilities utilitiesExpense \u003d new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-29"},{"lineNumber":293,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, UtilityType.WATER);","lastModifiedDate":"2023-10-29"},{"lineNumber":294,"author":{"gitId":"bljhty"},"content":" Transport transportExpense2 \u003d new Transport(\"Bus\",","lastModifiedDate":"2023-10-29"},{"lineNumber":295,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, TransportationType.TAXI);","lastModifiedDate":"2023-10-29"},{"lineNumber":296,"author":{"gitId":"bljhty"},"content":" testExpenses.add(transportExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":297,"author":{"gitId":"bljhty"},"content":" testExpenses.add(utilitiesExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":298,"author":{"gitId":"bljhty"},"content":" testExpenses.add(transportExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":299,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":300,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Transport\",","lastModifiedDate":"2023-10-29"},{"lineNumber":301,"author":{"gitId":"bljhty"},"content":" null, \"11/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":302,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":303,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":304,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Transportation Expense (BUS): Bus | Date: 11/Oct/2023 | Amount: $5.00, \"","lastModifiedDate":"2023-10-29"},{"lineNumber":305,"author":{"gitId":"bljhty"},"content":" + \"Transportation Expense (TAXI): Bus | Date: 11/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":306,"author":{"gitId":"bljhty"},"content":" assertTrue(mockUi.getShowExpenses().contains(expectedOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":307,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":308,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":309,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":310,"author":{"gitId":"bljhty"},"content":" void testFindExpenseByDescriptionAndDateAndCategory() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":311,"author":{"gitId":"bljhty"},"content":" Utilities utilitiesExpense1 \u003d new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-29"},{"lineNumber":312,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, UtilityType.ELECTRICITY);","lastModifiedDate":"2023-10-29"},{"lineNumber":313,"author":{"gitId":"bljhty"},"content":" Utilities utilitiesExpense2 \u003d new Utilities(\"Water\",","lastModifiedDate":"2023-10-29"},{"lineNumber":314,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, UtilityType.WATER);","lastModifiedDate":"2023-10-29"},{"lineNumber":315,"author":{"gitId":"bljhty"},"content":" Food foodExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":316,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 11), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":317,"author":{"gitId":"bljhty"},"content":" testExpenses.add(utilitiesExpense1);","lastModifiedDate":"2023-10-29"},{"lineNumber":318,"author":{"gitId":"bljhty"},"content":" testExpenses.add(utilitiesExpense2);","lastModifiedDate":"2023-10-29"},{"lineNumber":319,"author":{"gitId":"bljhty"},"content":" testExpenses.add(foodExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":320,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":321,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"expense\", \"Utilities\",","lastModifiedDate":"2023-10-29"},{"lineNumber":322,"author":{"gitId":"bljhty"},"content":" \"Electricity\", \"11/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":323,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":324,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":325,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Utilities Expense(ELECTRICITY): Electricity | Date: 11/Oct/2023 | Amount: $5.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":326,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowExpenses().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":327,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":328,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":329,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":330,"author":{"gitId":"bljhty"},"content":" void testIncomeByDescriptionAndDate() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":331,"author":{"gitId":"bljhty"},"content":" Income income1 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":332,"author":{"gitId":"bljhty"},"content":" Income income2 \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 11), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":333,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income1);","lastModifiedDate":"2023-10-29"},{"lineNumber":334,"author":{"gitId":"bljhty"},"content":" testIncomes.add(income2);","lastModifiedDate":"2023-10-29"},{"lineNumber":335,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":336,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses, \"income\", null,","lastModifiedDate":"2023-10-29"},{"lineNumber":337,"author":{"gitId":"bljhty"},"content":" \"Salary\", \"10/Oct/2023\", mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":338,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":339,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":340,"author":{"gitId":"bljhty"},"content":" String expectedOutput \u003d \"[Income: Salary | Date: 10/Oct/2023 | Amount: $5000.00]\";","lastModifiedDate":"2023-10-29"},{"lineNumber":341,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedOutput, mockUi.getShowIncomes().get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":342,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":343,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":344,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":345,"author":{"gitId":"bljhty"},"content":" void testNegativeIncomeAmount() {","lastModifiedDate":"2023-10-29"},{"lineNumber":346,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":347,"author":{"gitId":"bljhty"},"content":" Income negativeIncome \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 10), -5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":348,"author":{"gitId":"bljhty"},"content":" testIncomes.add(negativeIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":349,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":350,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":351,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Amount cannot be negative!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":352,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":353,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":354,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":355,"author":{"gitId":"bljhty"},"content":" void testNegativeExpenseAmount() {","lastModifiedDate":"2023-10-29"},{"lineNumber":356,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":357,"author":{"gitId":"bljhty"},"content":" Food negativeExpense \u003d new Food(\"Burger\",","lastModifiedDate":"2023-10-29"},{"lineNumber":358,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), -5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":359,"author":{"gitId":"bljhty"},"content":" testExpenses.add(negativeExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":360,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":361,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":362,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Amount cannot be negative!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":363,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":364,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":365,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":366,"author":{"gitId":"bljhty"},"content":" void testEmptyIncomeDescription() {","lastModifiedDate":"2023-10-29"},{"lineNumber":367,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":368,"author":{"gitId":"bljhty"},"content":" Income emptyDescriptionIncome \u003d new Income(\"\",","lastModifiedDate":"2023-10-29"},{"lineNumber":369,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5000.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":370,"author":{"gitId":"bljhty"},"content":" testIncomes.add(emptyDescriptionIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":371,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":372,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":373,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Description cannot be empty!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":374,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":375,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":376,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":377,"author":{"gitId":"bljhty"},"content":" void testEmptyExpenseDescription() {","lastModifiedDate":"2023-10-29"},{"lineNumber":378,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":379,"author":{"gitId":"bljhty"},"content":" Food emptyDescriptionExpense \u003d new Food(\"\",","lastModifiedDate":"2023-10-29"},{"lineNumber":380,"author":{"gitId":"bljhty"},"content":" LocalDate.of(2023, 10, 10), 5.0, MealType.LUNCH);","lastModifiedDate":"2023-10-29"},{"lineNumber":381,"author":{"gitId":"bljhty"},"content":" testExpenses.add(emptyDescriptionExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":382,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":383,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":384,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Description cannot be empty!\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":385,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":386,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":387,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":388,"author":{"gitId":"bljhty"},"content":" void testInvalidExpenseCategory() {","lastModifiedDate":"2023-10-29"},{"lineNumber":389,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":390,"author":{"gitId":"bljhty"},"content":" // Assuming \u0027Gaming\u0027 is not a valid category in your application","lastModifiedDate":"2023-10-29"},{"lineNumber":391,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":392,"author":{"gitId":"bljhty"},"content":" \"expense\", \"Gaming\", null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":393,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":394,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":395,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":396,"author":{"gitId":"bljhty"},"content":" assertTrue(exception.getMessage().contains(\"Invalid expense category provided! Allowed categories are: \"));","lastModifiedDate":"2023-10-29"},{"lineNumber":397,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":398,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":399,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":400,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":401,"author":{"gitId":"bljhty"},"content":" void testFindCommandWithZeroAmountExpense() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":402,"author":{"gitId":"bljhty"},"content":" Expense zeroAmountExpense \u003d new Expense(\"Zero Amount Expense\", LocalDate.now(), 0.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":403,"author":{"gitId":"bljhty"},"content":" testExpenses.add(zeroAmountExpense);","lastModifiedDate":"2023-10-29"},{"lineNumber":404,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":405,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":406,"author":{"gitId":"bljhty"},"content":" \"expense\", \"Food\", null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":407,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":408,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":409,"author":{"gitId":"bljhty"},"content":" assertFalse(mockUi.getShowExpenses().contains(\"Zero Amount Expense\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":410,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":411,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":412,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":413,"author":{"gitId":"bljhty"},"content":" void testFindCommandWithZeroIncome() throws Exception {","lastModifiedDate":"2023-10-29"},{"lineNumber":414,"author":{"gitId":"bljhty"},"content":" Income zeroAmountIncome \u003d new Income(\"Zero Amount Income\", LocalDate.now(), 0.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":415,"author":{"gitId":"bljhty"},"content":" testIncomes.add(zeroAmountIncome);","lastModifiedDate":"2023-10-29"},{"lineNumber":416,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":417,"author":{"gitId":"bljhty"},"content":" FindCommand findCommand \u003d new FindCommand(testIncomes, testExpenses,","lastModifiedDate":"2023-10-29"},{"lineNumber":418,"author":{"gitId":"bljhty"},"content":" \"income\", null, null, null, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":419,"author":{"gitId":"bljhty"},"content":" findCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":420,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":421,"author":{"gitId":"bljhty"},"content":" assertFalse(mockUi.getShowIncomes().contains(\"Zero Amount Income\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":422,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":423,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":424,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":424}},{"path":"src/test/java/seedu/duke/commands/IncomeListerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import seedu.duke.ui.MockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import java.io.File;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.fail;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":"public class IncomeListerTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" private MockUi mockUi;","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" mockUi \u003d new MockUi();","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" void listIncomes_emptyList_displayNoIncomes() {","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" IncomeLister incomeLister \u003d new IncomeLister(incomes, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" incomeLister.listIncomes();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" List\u003cString\u003e messages \u003d mockUi.getPrintedMessages();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" assertEquals(1, messages.size());","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" assertEquals(\"You have no recorded incomes.\", messages.get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" void listIncomes_nonEmptyList_displaysAllIncomes() {","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd/MM/yyyy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" LocalDate date1 \u003d LocalDate.parse(\"01/01/2023\", formatter);","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" LocalDate date2 \u003d LocalDate.parse(\"02/01/2023\", formatter);","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Description 1\", date1, 50.0));","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" incomes.add(new Income(\"Description 2\", date2, 100.0));","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" IncomeLister incomeLister \u003d new IncomeLister(incomes, mockUi);","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" incomeLister.listIncomes();","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" List\u003cString\u003e messages \u003d mockUi.getPrintedMessages();","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assertEquals(3, messages.size()); // Three messages: header and two income details","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are your incomes:\", messages.get(0));","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" assertEquals(\"1. \" + incomes.get(0).toString(), messages.get(1));","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" assertEquals(\"2. \" + incomes.get(1).toString(), messages.get(2));","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" fail(\"Unexpected exception: \" + e.getMessage());","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" void testIncomeConstructor_negativeAmount() {","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" Exception exception \u003d assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" new Income(\"Test\", LocalDate.now(), -50.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" String expectedMessage \u003d \"Amount cannot be negative!\";","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" String actualMessage \u003d exception.getMessage();","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedMessage, actualMessage); // Using assertEquals for clarity","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" void testToString_validIncome() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Test\", LocalDate.of(2023, 1, 1), 50.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" String expected \u003d \"Income: Test | Date: 01/Jan/2023 | Amount: $50.00\";","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" assertEquals(expected, income.toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" void testLoggerFileCreation() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" new Income(\"Logger Test\", LocalDate.now(), 50.0);","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" File logFile \u003d new File(\"logs/Income.log\");","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" assertTrue(logFile.exists());","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":88}},{"path":"src/test/java/seedu/duke/commands/IncomeManagerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.commands;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"public class IncomeManagerTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" private IncomeManager incomeManager;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" incomeManager \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" void constructor_initializesCorrectly() {","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" assertNotNull(incomeManager);","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" void execute_parsesIncomeSuccessfully() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" incomeManager.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" Income income \u003d incomeManager.getNewIncome();","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" assertNotNull(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" // You may also want to check the properties of `income` to ensure it\u0027s been parsed correctly.","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" void execute_missingFields_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithMissingFields \u003d new IncomeManager(\"/de Grocery /date 29/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithMissingFields::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" void execute_extraFields_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithExtraFields \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" \"/amt 50.0 /extraField Something\");","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithExtraFields::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" void constructor_nullDetails_throwsAssertionError() {","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" assertThrows(AssertionError.class, () -\u003e new IncomeManager(null));","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" void execute_incorrectFieldOrder_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithIncorrectOrder \u003d new IncomeManager(\"/amt 50.0 /de Grocery /date 29/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithIncorrectOrder::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" void execute_spacesInFields_parsedCorrectly() throws KaChinnnngException {","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithSpaces \u003d new IncomeManager(\"/de Grocery Store /date 29/10/2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" managerWithSpaces.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" Income income \u003d managerWithSpaces.getNewIncome();","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" assertNotNull(income);","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" void execute_incorrectDateFormat_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithBadDate \u003d new IncomeManager(\"/de Grocery /date 29-10-2023 /amt 50.0\");","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithBadDate::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" void execute_incorrectAmountFormat_throwsException() {","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" IncomeManager managerWithBadAmount \u003d new IncomeManager(\"/de Grocery /date 29/10/2023 /amt fifty\");","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, managerWithBadAmount::execute);","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":80}},{"path":"src/test/java/seedu/duke/financialrecords/ExchangeRateManagerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertSame;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.fail;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateManagerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager exchangeRateManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":" public void setUp() {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" public void testGetInstance() {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" // Ensure that getInstance returns the same instance of ExchangeRateManager","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager instance1 \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" ExchangeRateManager instance2 \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" assertSame(instance1, instance2);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" public void testSupportedCurrencies() {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" // Ensure that the list of supported currencies is not empty","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" assertFalse(ExchangeRateManager.getSupportedCurrencies().isEmpty());","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" public void testUpdateExchangeRate_validInput_updateSameAsRetrieved() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" String currency \u003d \"USD\";","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" double rate \u003d 1.3;","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" // Update the exchange rate","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":" fail(\"Should not throw an exception\");","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":" // Retrieve and compare the exchange rate","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" double retrievedRate \u003d exchangeRateManager.getExchangeRates().get(currency);","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" assertEquals(rate, retrievedRate);","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" public void testConvertCurrency() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":" String currency \u003d \"USD\";","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" double rate \u003d 1.3;","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" double amount \u003d 100.0;","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" // Update the exchange rate","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(currency, rate);","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" fail(\"Should not throw an exception\");","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" // Convert currency and check the result","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" double convertedAmount \u003d exchangeRateManager.convertCurrency(currency, amount);","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" assertEquals(76.923, convertedAmount, 0.001);","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"limyuhching":68}},{"path":"src/test/java/seedu/duke/financialrecords/ExpenseTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.fail;","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Test suite for the {@link Expense} class.","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * This class contains unit tests to validate the behavior of the Expense class and ensure","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * correctness in the representation and management of financial expenses.","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"public class ExpenseTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" private Expense expense;","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" * Initializes common test fixtures before each test execution.","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" @BeforeEach","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" void setUp() {","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" expense \u003d new Expense(\"Lunch\", LocalDate.now().minusDays(1), 20.00);","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" fail(\"Setup failed due to exception: \" + e.getMessage());","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the description of an Expense object is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" void testExpenseDescription_notEmpty(){","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e new Expense(\"\", LocalDate.now(), 20.00));","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the amount of an Expense object is negative.","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" void testExpenseAmount_notNegative(){","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e new Expense(\"Lunch\", LocalDate.now(), -20.00));","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the date of an Expense object is in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" void testExpenseDate_notFuture(){","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e new Expense(\"Lunch\", LocalDate.now().plusDays(1), 20.00));","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * Tests if the correct description of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" void getDescription() {","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Lunch\", expense.getDescription());","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" * Tests if the correct date of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" void getDate() {","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.now().minusDays(1), expense.getDate());","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" * Tests if the correct amount of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" void getAmount() {","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" assertEquals(20.00, expense.getAmount());","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" * Tests if the correct date string of the Expense object is returned.","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" void getDateString() {","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.now().minusDays(1).format(DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\")),","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" expense.getDateString());","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" * Tests the string representation of the Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" void testToString() {","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Expense: Lunch | Date: \" +","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" LocalDate.now().minusDays(1).format(DateTimeFormatter.ofPattern(\"dd/MMM/yyyy\")) +","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" \" | Amount: $20.00\",","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" expense.toString());","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":101}},{"path":"src/test/java/seedu/duke/financialrecords/IncomeTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.financialrecords;","lastModifiedDate":"2023-10-12"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-12"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertNotNull;","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"public class IncomeTest {","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" public void testIncomeCreation() throws KaChinnnngException {","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" assertNotNull(income);","lastModifiedDate":"2023-10-12"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Salary\", income.getDescription());","lastModifiedDate":"2023-10-12"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.of(2023, 10, 12), income.getDate());","lastModifiedDate":"2023-10-12"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" assertEquals(5000.00, income.getAmount());","lastModifiedDate":"2023-10-12"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" public void testToString() throws KaChinnnngException{","lastModifiedDate":"2023-10-12"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" Income income \u003d new Income(\"Salary\", LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" String expected \u003d \"Income: Salary | Date: 12/Oct/2023 | Amount: $5000.00\";","lastModifiedDate":"2023-10-12"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" assertEquals(expected, income.toString());","lastModifiedDate":"2023-10-12"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" public void testInvalidDescription() {","lastModifiedDate":"2023-10-12"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-12"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" new Income(\"\", LocalDate.of(2023, 10, 12), 5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-12"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" public void testInvalidAmount() {","lastModifiedDate":"2023-10-12"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-12"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" new Income(\"Salary\", LocalDate.of(2023, 10, 12), -5000.00);","lastModifiedDate":"2023-10-12"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-12"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"bljhty":42}},{"path":"src/test/java/seedu/duke/parser/ExpenseParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-18"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-18"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-18"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-18"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-18"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-18"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"public class ExpenseParserTest {","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the date is parsed correctly.","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the parsed date is invalid","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" void parseDate_validDate_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" LocalDate expectedDate \u003d LocalDate.of(2020, 02, 29);","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" LocalDate actualDate \u003d ExpenseParser.parseDate(\"29/02/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" assertEquals(expectedDate, actualDate);","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid day.","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" void parseDate_invalidDay_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseDate(\"32/02/2020\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid year.","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" void parseDate_invalidDate_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseDate(\"10/10/20202\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in ExpenseParser","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse a date that is in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" void parseDate_futureDate_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseDate(\"10/10/3021\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * It verifies if the food category are correctly parsed into an Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException for invalid scenarios","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" void testParseExpense_foodCategory_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, \"lunch\");","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" assertTrue(ExpenseParser.parseExpense(expenseFields) instanceof Food);","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" * It verifies if the transport category are correctly parsed into an Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException for invalid scenarios","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" void testParseExpense_transportCategory_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"transport\");","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, \"bus\");","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"from nus to changi\");","lastModifiedDate":"2023-10-26"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"1.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" assertTrue(ExpenseParser.parseExpense(expenseFields) instanceof Transport);","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" * It verifies if the utilities category are correctly parsed into an Expense object.","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException for invalid scenarios","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" void testParseExpense_utilitiesCategory_success() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"utilities\");","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.TYPE_FIELD, \"electricity\");","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"Hongzhii"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"air con bill\");","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"50.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" assertTrue(ExpenseParser.parseExpense(expenseFields) instanceof Utilities);","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for an unrecognized category.","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" void testParseExpense_invalidCategory_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"invalid\");","lastModifiedDate":"2023-10-18"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for missing amount fields.","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" void testParseExpense_missingAmountField_success() {","lastModifiedDate":"2023-10-18"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for missing description fields.","lastModifiedDate":"2023-10-18"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" void testParseExpense_missingDescriptionFields_success(){","lastModifiedDate":"2023-10-18"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" * This method tests the parseExpense method in ExpenseParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception for missing date fields.","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" void testParseExpense_missingDateField_success(){","lastModifiedDate":"2023-10-18"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"3.50\");","lastModifiedDate":"2023-10-18"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" * Tests if the getIndex method in ExpenseParser throws an exception for a valid index format.","lastModifiedDate":"2023-10-18"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" void testGetIndexValid() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.INDEX_FIELD, \"1\");","lastModifiedDate":"2023-10-18"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":" assertEquals(1, ExpenseParser.getIndex(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" * Tests if the getIndex method in ExpenseParser throws an exception for an invalid index format.","lastModifiedDate":"2023-10-18"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":" void testGetIndexInvalid() {","lastModifiedDate":"2023-10-18"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.INDEX_FIELD, \"a\");","lastModifiedDate":"2023-10-18"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.getIndex(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the provided amount exceeds the limit.","lastModifiedDate":"2023-10-18"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":" void testParseAmount_aboveLimit_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"1000000.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the category field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":" void testParseCategory_emptyString_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"9999.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the description field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":" void testParseDescription_emptyString_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"9999.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the date field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" void testParseDate_emptyString_exceptionThrown(){","lastModifiedDate":"2023-10-18"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":243,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":244,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":245,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"9999.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":246,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":247,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":248,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":249,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":250,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":251,"author":{"gitId":"bljhty"},"content":" * Tests if the expense parsing method throws an exception when the amount field is empty.","lastModifiedDate":"2023-10-18"},{"lineNumber":252,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":253,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":254,"author":{"gitId":"bljhty"},"content":" void testParseAmount_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":255,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e expenseFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":256,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.CATEGORY_FIELD, \"food\");","lastModifiedDate":"2023-10-18"},{"lineNumber":257,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DESCRIPTION_FIELD, \"Chicken Rice\");","lastModifiedDate":"2023-10-18"},{"lineNumber":258,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.DATE_FIELD, \"12/10/2020\");","lastModifiedDate":"2023-10-18"},{"lineNumber":259,"author":{"gitId":"bljhty"},"content":" expenseFields.put(ExpenseParser.AMOUNT_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":260,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":261,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e ExpenseParser.parseExpense(expenseFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":262,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":263,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-18"}],"authorContributionMap":{"bljhty":258,"Hongzhii":5}},{"path":"src/test/java/seedu/duke/parser/FindParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertArrayEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * JUnit test class for FindParser.","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * This class tests if the find command is parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" * It also tests if the correct exceptions are thrown when the command is invalid.","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"public class FindParserTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" * This method tests if the find command is parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the parameters are parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the command format is invalid","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" public void validFindCommand_parsedCorrectly() throws KaChinnnngException{","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" String[] expected \u003d {\"expense\", \"food\", \"lunch\", \"12/Oct/2023\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" String[] result \u003d FindParser.parseFindCommand(\"/t expense /cat food /de lunch /date 12/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" assertArrayEquals(expected, result);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" * This method tests if the correct exception is thrown when the type is missing.","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" public void missingMandatoryTypeField_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/cat food /de lunch /date 12/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" * This method tests if the correct exception is thrown when the type is invalid.","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the correct exception is thrown when the type is not \"expense\" or \"income\".","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" public void usingInvalidParameter_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /cat food /de lunch /date 12/Oct/2023 /invalid\");","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when the full word for type is used instead of the shortcut.","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" public void usingFullWordTypeInsteadOfShortcut_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/type expense /cat food /de lunch /date 12/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when only the mandatory type parameter is provided,","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" * and all other optional parameters are missing.","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void missingAllOptionalFields_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense\");","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when a parameter is provided without its corresponding value.","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" public void missingValueForParameter_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t \");","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /cat \");","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" * Tests the correct parsing of a valid find command with the \"income\" type and no category.","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" * Expects successful parsing into an array of parameters.","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the command format is invalid","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" public void validFindCommandWithIncomeType_noCategoryParsed() throws KaChinnnngException {","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" String[] expected \u003d {\"income\", null, \"bonus\", \"15/Oct/2023\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" String[] result \u003d FindParser.parseFindCommand(\"/t income /de bonus /date 15/Oct/2023\");","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" assertArrayEquals(expected, result);","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" * Tests the correct parsing of a valid find command with only type and category.","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" * Expects successful parsing into an array of parameters.","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the command format is invalid","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":" public void validFindCommandWithOnlyTypeAndCategory_parsedCorrectly() throws KaChinnnngException {","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" String[] expected \u003d {\"expense\", \"food\", null, null};","lastModifiedDate":"2023-10-30"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" String[] result \u003d FindParser.parseFindCommand(\"/t expense /cat food\");","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" assertArrayEquals(expected, result);","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown when deprecated parameter names are used.","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" public void usingOldParameterNames_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /description value\");","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /category food\");","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown for an empty command string.","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" public void emptyCommand_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"\");","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown for a command string consisting only of spaces.","lastModifiedDate":"2023-10-30"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" public void commandWithOnlySpaces_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\" \");","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" * Tests if the correct exception is thrown for a command containing a parameter that doesn\u0027t exist.","lastModifiedDate":"2023-10-30"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" public void findCommandWithNonexistentParameter_throwsException() {","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" FindParser.parseFindCommand(\"/t expense /nonexistent value\");","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" });","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"bljhty":150}},{"path":"src/test/java/seedu/duke/parser/IncomeParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-13"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-13"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-13"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-13"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-13"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-13"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-13"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-13"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" * Contains JUnit tests for the {@code IncomeParser} class. This class ensures that the parsing methods","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" * related to incomes function as expected and handle invalid inputs gracefully.","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"public class IncomeParserTest {","lastModifiedDate":"2023-10-13"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" * This method tests the parseIncome method in IncomeParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" * It verifies if the incomeFields are correctly parsed into an Income object.","lastModifiedDate":"2023-10-18"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" public void testParseIncome() throws KaChinnnngException {","lastModifiedDate":"2023-10-13"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-13"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-13"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-13"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5000.00\");","lastModifiedDate":"2023-10-13"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" Income income \u003d IncomeParser.parseIncome(incomeFields);","lastModifiedDate":"2023-10-13"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Salary\", income.getDescription());","lastModifiedDate":"2023-10-13"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.of(2023, 10, 12), income.getDate());","lastModifiedDate":"2023-10-13"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" assertEquals(5000.00, income.getAmount());","lastModifiedDate":"2023-10-13"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser","lastModifiedDate":"2023-10-18"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if the date is parsed correctly.","lastModifiedDate":"2023-10-18"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" * @throws KaChinnnngException if the parsed date is invalid","lastModifiedDate":"2023-10-18"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" public void testParseDate_validDate() throws KaChinnnngException {","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" LocalDate result \u003d IncomeParser.parseDate(\"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" assertEquals(LocalDate.of(2023, 10, 12), result);","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid date.","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" * @see KaChinnnngException if the parsed date is invalid","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" public void testParseDate_invalidDate() {","lastModifiedDate":"2023-10-13"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseDate(\"12/13/2023\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse a date that is in the future.","lastModifiedDate":"2023-10-18"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" public void testParseDate_futureDate() {","lastModifiedDate":"2023-10-13"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseDate(\"12/10/2025\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" * This method tests the parseDate method in IncomeParser.","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" * Specifically, it tests if a KaChinnnngException is thrown when trying to parse an invalid day.","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" void testParseDate_invalidDay(){","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseDate(\"32/10/2023\"));","lastModifiedDate":"2023-10-18"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" * This method tests the getIndex method in IncomeParser when trying to get index from an empty input.","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-13"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" public void testGetIndex_missingField() {","lastModifiedDate":"2023-10-13"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-13"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-18"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs amount that is above the limit.","lastModifiedDate":"2023-10-18"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" void testParseAmount_aboveLimit_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"1000000000.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an empty string for description.","lastModifiedDate":"2023-10-18"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":" void testParseDescription_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"10.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an empty string for date.","lastModifiedDate":"2023-10-18"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" void testParseDate_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-18"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"10.00\");","lastModifiedDate":"2023-10-18"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an empty string for amount.","lastModifiedDate":"2023-10-18"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" *","lastModifiedDate":"2023-10-18"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" void testParseAmount_emptyString_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-18"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-18"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"\");","lastModifiedDate":"2023-10-18"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-18"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an invalid index.","lastModifiedDate":"2023-10-18"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" * Specifically negative index","lastModifiedDate":"2023-10-18"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":" void testGetIndex_negativeIndex_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" inputMap.put(IncomeParser.INDEX_FIELD, \"-1\");","lastModifiedDate":"2023-10-18"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-18"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-18"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" * This method tests the behaviour when user inputs an invalid index.","lastModifiedDate":"2023-10-18"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":" * Specifically zero index","lastModifiedDate":"2023-10-18"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-18"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" void testGetIndex_zeroIndex_exceptionThrown() {","lastModifiedDate":"2023-10-18"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-18"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" inputMap.put(IncomeParser.INDEX_FIELD, \"0\");","lastModifiedDate":"2023-10-18"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-18"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-13"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" * Tests for an exception when a zero index is provided in the input data.","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" void testParseIncome_nullArguments_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(null));","lastModifiedDate":"2023-10-29"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" * Checks if an exception is thrown when null arguments are passed to the {@code parseIncome} method.","lastModifiedDate":"2023-10-30"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" void testParseIncome_missingDescription_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5000.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":186,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":187,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":188,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bljhty"},"content":" * Tests if an exception is thrown when the date is missing in incomeFields.","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"bljhty"},"content":" void testParseIncome_missingDate_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":193,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":194,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5000.00\");","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":200,"author":{"gitId":"bljhty"},"content":" * Checks if an exception is thrown when the amount is missing in incomeFields.","lastModifiedDate":"2023-10-30"},{"lineNumber":201,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"bljhty"},"content":" void testParseIncome_missingAmount_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"bljhty"},"content":" * Validates that an exception is thrown when the amount in incomeFields has an invalid format.","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":213,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"bljhty"},"content":" void testParseAmount_invalidFormat_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DESCRIPTION_FIELD, \"Salary\");","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.DATE_FIELD, \"12/10/2023\");","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"bljhty"},"content":" incomeFields.put(IncomeParser.AMOUNT_FIELD, \"5,000.00\"); // Comma is not expected","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":223,"author":{"gitId":"bljhty"},"content":" * Tests for an exception when a non-numeric value is provided for the index in the input data.","lastModifiedDate":"2023-10-30"},{"lineNumber":224,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":225,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"bljhty"},"content":" void testGetIndex_invalidFormat_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e inputMap \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":228,"author":{"gitId":"bljhty"},"content":" inputMap.put(IncomeParser.INDEX_FIELD, \"abc\");","lastModifiedDate":"2023-10-29"},{"lineNumber":229,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.getIndex(inputMap));","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"bljhty"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"bljhty"},"content":" * Checks if an exception is thrown when an unrecognized field is provided in incomeFields.","lastModifiedDate":"2023-10-30"},{"lineNumber":234,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":235,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"bljhty"},"content":" void testParseIncome_nonExistingField_exceptionThrown() {","lastModifiedDate":"2023-10-29"},{"lineNumber":237,"author":{"gitId":"bljhty"},"content":" HashMap\u003cString, String\u003e incomeFields \u003d new HashMap\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":238,"author":{"gitId":"bljhty"},"content":" incomeFields.put(\"nonExistingField\", \"Value\");","lastModifiedDate":"2023-10-29"},{"lineNumber":239,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, () -\u003e IncomeParser.parseIncome(incomeFields));","lastModifiedDate":"2023-10-29"},{"lineNumber":240,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":241,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":242,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-13"}],"authorContributionMap":{"bljhty":242}},{"path":"src/test/java/seedu/duke/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"/**","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":" * JUnit test class for Parser.","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" * This class tests if the commands are parsed correctly.","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" * It also tests if the correct exceptions are thrown when the command is invalid.","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"public class ParserTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" public void testParse_exitCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" assertEquals(\"exit\", Parser.parse(\"exit\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" public void testParse_addExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" assertEquals(\"add_expense\",","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" Parser.parse(\"add Expense /de lunch /amt 5.00 /cat food /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" public void testParse_addIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" assertEquals(\"add_income\",","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" Parser.parse(\"add Income /de salary /amt 5000.00 /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" public void testParse_listExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" assertEquals(\"list_expense\", Parser.parse(\"list Expense\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" public void testParse_listIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" assertEquals(\"list_income\", Parser.parse(\"list Income\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" public void testParse_deleteExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" assertEquals(\"delete_expense\", Parser.parse(\"delete Expense /i 1\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" public void testParse_deleteIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" assertEquals(\"delete_income\", Parser.parse(\"delete Income /i 1\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":" public void testParse_findCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" assertEquals(\"find\", Parser.parse(\"find /t expense /cat food /de lunch /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" public void testParse_helpCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" assertEquals(\"help\", Parser.parse(\"help\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" public void testParse_invalidCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" assertEquals(\"invalid\", Parser.parse(\"invalid\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" public void testParse_listCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":" assertEquals(\"list\", Parser.parse(\"list\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" public void testParse_balanceCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" assertEquals(\"balance\", Parser.parse(\"balance\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public void testParse_clearIncomesCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" assertEquals(\"clear_incomes\", Parser.parse(\"clear incomes\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" public void testParse_clearExpensesCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":" assertEquals(\"clear_expenses\", Parser.parse(\"clear expenses\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" public void testParse_clearAllCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" assertEquals(\"clear_all\", Parser.parse(\"clear all\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" public void testParse_editIncomeCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" assertEquals(\"edit_income\", Parser.parse(\"edit income /i 1 /de salary /amt 5000.00 /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":" public void testParse_editExpenseCommand_parsedCorrectly() {","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" assertEquals(\"edit_expense\", Parser.parse(\"edit expense /i 1 /de lunch /amt 5.00 /cat food /date 12/Oct/2023\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"bljhty":101}},{"path":"src/test/java/seedu/duke/storage/ExchangeRateFileHandlerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"limyuhching"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"limyuhching"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"limyuhching"},"content":"import seedu.duke.financialrecords.ExchangeRateManager;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"limyuhching"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"limyuhching"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"limyuhching"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"limyuhching"},"content":"import java.io.PrintWriter;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"limyuhching"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"limyuhching"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"limyuhching"},"content":"public class ExchangeRateFileHandlerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateFileHandler fileHandler;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"limyuhching"},"content":" private ExchangeRateManager exchangeRateManager \u003d ExchangeRateManager.getInstance();","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"limyuhching"},"content":" @BeforeEach","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"limyuhching"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.clear();","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"limyuhching"},"content":" public void testLoad_validFileFormat_exchangeRateMatches() throws FileNotFoundException, KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"limyuhching"},"content":" fileHandler \u003d new ExchangeRateFileHandler(\"./src/test/testData/ExchangeRatesTestLoad.txt\");","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"limyuhching"},"content":" fileHandler.load();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"limyuhching"},"content":" // Verify that the loaded exchange rates match the original ones","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"limyuhching"},"content":" assertEquals(1.0, exchangeRateManager.getExchangeRate(\"USD\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"limyuhching"},"content":" assertEquals(0.85, exchangeRateManager.getExchangeRate(\"EUR\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"limyuhching"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"limyuhching"},"content":" public void testSave_validInput_fileContentMatches() throws KaChinnnngException, FileNotFoundException {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"limyuhching"},"content":" // load or create filepath","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"limyuhching"},"content":" String filePath \u003d \"./src/test/testData/ExchangeRatesTestSave.txt\";","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"limyuhching"},"content":" createFile(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"limyuhching"},"content":" new PrintWriter(filePath).close(); // clears the file","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"limyuhching"},"content":" fileHandler \u003d new ExchangeRateFileHandler(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"limyuhching"},"content":" fileHandler.load();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"limyuhching"},"content":" // Define test data","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"limyuhching"},"content":" exchangeRateManager.updateExchangeRate(\"USD\", 1.0);","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"limyuhching"},"content":" // Save the exchange rates to the file","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"limyuhching"},"content":" fileHandler.save(exchangeRateManager.getExchangeRates());","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"limyuhching"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"limyuhching"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"limyuhching"},"content":" String textLine \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"limyuhching"},"content":" assertEquals(\"USD,1.0\", textLine);","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"limyuhching"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"limyuhching"},"content":" private boolean createFile(String filePath) throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"limyuhching"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"limyuhching"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"limyuhching"},"content":" if (file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"limyuhching"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"limyuhching"},"content":" if (!file.getParentFile().exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"limyuhching"},"content":" file.getParentFile().mkdirs();","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"limyuhching"},"content":" return file.createNewFile();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"limyuhching"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"limyuhching"},"content":" throw new KaChinnnngException(\"Cannot create file; reason: \" + e.getMessage());","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"limyuhching"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"limyuhching"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"limyuhching":69}},{"path":"src/test/java/seedu/duke/storage/GetFromTxtTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearAll;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"public class GetFromTxtTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" private String path;","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" private String []lines \u003d new String[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" path \u003d \"Test.txt\";","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeToTextFile(ArrayList)} method with multiple incomes records without expenses,","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the more than one income from the txt file save to the list correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithMoreThanOneIncomes() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Salary\", newIncomes.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Bonus\", newIncomes.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 10), newIncomes.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 15), newIncomes.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" assertEquals(5000.0, newIncomes.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" assertEquals(1000.0, newIncomes.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link GetFromTxt#getFromTextFile(ArrayList, ArrayList)} method","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" * with different expense type without incomes, This test case checks whether the different type of expenses","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" * from the txt file save to the list correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithDifferentExpenseType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\",","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\",","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 2),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"chicken sandwich\", newExpenses.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Taxi\", newExpenses.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Electricity\", newExpenses.get(2).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 1), newExpenses.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 2), newExpenses.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 3), newExpenses.get(2).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" assertEquals(10.0, newExpenses.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" assertEquals(50.0, newExpenses.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" assertEquals(100.0, newExpenses.get(2).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" assertEquals(MealType.LUNCH, ((Food) newExpenses.get(0)).getMealType());","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" assertEquals(TransportationType.FUEL, ((Transport) newExpenses.get(1)).getTransportationType());","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" assertEquals(UtilityType.ELECTRICITY, ((Utilities) newExpenses.get(2)).getUtilityType());","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link GetFromTxt#getFromTextFile(ArrayList, ArrayList)} method with different expense type and incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the different type of expenses and income record get from","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":" * the txt file save to the list correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithDifferentIncomesAndExpenses() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\",","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\",","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 2),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\",","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\",","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\",","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"KenCheung18"},"content":" LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes,expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"chicken sandwich\", newExpenses.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Taxi\", newExpenses.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Electricity\", newExpenses.get(2).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 1), newExpenses.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 2), newExpenses.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 3), newExpenses.get(2).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"KenCheung18"},"content":" assertEquals(10.0, newExpenses.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"KenCheung18"},"content":" assertEquals(50.0, newExpenses.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"KenCheung18"},"content":" assertEquals(100.0, newExpenses.get(2).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"KenCheung18"},"content":" assertEquals(MealType.LUNCH, ((Food) newExpenses.get(0)).getMealType());","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"KenCheung18"},"content":" assertEquals(TransportationType.FUEL, ((Transport) newExpenses.get(1)).getTransportationType());","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"KenCheung18"},"content":" assertEquals(UtilityType.ELECTRICITY, ((Utilities) newExpenses.get(2)).getUtilityType());","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Salary\", newIncomes.get(0).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"Bonus\", newIncomes.get(1).getDescription());","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 10), newIncomes.get(0).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"KenCheung18"},"content":" assertEquals(LocalDate.of(2023, 10, 15), newIncomes.get(1).getDate());","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"KenCheung18"},"content":" assertEquals(5000.0, newIncomes.get(0).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"KenCheung18"},"content":" assertEquals(1000.0, newIncomes.get(1).getAmount());","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link GetFromTxt#getFromTextFile(ArrayList, ArrayList)} method with Both incorrect format.","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the program still working when user changes the txt file.","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"KenCheung18"},"content":" public void testGetFromTxtWithWrongFormat() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"KenCheung18"},"content":" try (FileWriter fw \u003d new FileWriter(path)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"nolthing special\");","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | 10000000000.0 | 2023-10-01 | 2\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | -1 | 2023-10/01 | 2\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF \\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"ABC | chicken sandwich | 1000.0 | 2023-10-01 | 1\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | 1000.0 | 2023-10-01 | asdf\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"KenCheung18"},"content":" fw.write(\"EF | chicken sandwich | 10000000000.0 | 2023-10-01 | 32\\n\");","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"KenCheung18"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"KenCheung18"},"content":" System.out.println(\"Error\");","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cIncome\u003e newIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"KenCheung18"},"content":" ArrayList\u003cExpense\u003e newExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"KenCheung18"},"content":" GetFromTxt getFromTxt \u003d new GetFromTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"KenCheung18"},"content":" getFromTxt.getFromTextFile(newIncomes, newExpenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, newIncomes.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"KenCheung18"},"content":" assertEquals(0, newExpenses.size());","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":167}},{"path":"src/test/java/seedu/duke/storage/SaveToTxtTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"KenCheung18"},"content":"package seedu.duke.storage;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"KenCheung18"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.ClearAll;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Utilities;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Food;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.Transport;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.MealType;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.TransportationType;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"KenCheung18"},"content":"import seedu.duke.financialrecords.expensetypes.UtilityType;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"KenCheung18"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"KenCheung18"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"KenCheung18"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"KenCheung18"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"KenCheung18"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"KenCheung18"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"KenCheung18"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"KenCheung18"},"content":" * Tests for the {@link SaveToTxt} class.","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"KenCheung18"},"content":" * This test class provides test cases to check whether incomes and expenses records","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"KenCheung18"},"content":" * are saved correctly to the txt file","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"KenCheung18"},"content":"public class SaveToTxtTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cIncome\u003e incomes;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"KenCheung18"},"content":" private ArrayList\u003cExpense\u003e expenses;","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"KenCheung18"},"content":" private String path;","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"KenCheung18"},"content":" private String []lines \u003d new String[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"KenCheung18"},"content":" * Sets up the test fixture.","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"KenCheung18"},"content":" * Called before every test case method.","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"KenCheung18"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"KenCheung18"},"content":" public void setup() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"KenCheung18"},"content":" incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"KenCheung18"},"content":" expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"KenCheung18"},"content":" path \u003d \"Test.txt\";","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeToTextFile(ArrayList)} method with income only.","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the one incomes record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithOneIncome() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file); // Create a Scanner using the File as the source","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"KenCheung18"},"content":" String line \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Salary | 5000.0 | 2023-10-10\", line);","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeToTextFile(ArrayList)} method with incomes only.","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the multiple incomes record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithMoreThanOneIncomes() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeToTextFile(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Salary | 5000.0 | 2023-10-10\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Bonus | 1000.0 | 2023-10-15\" ,lines[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with expense of Food type only.","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the Food expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithFoodType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\", LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EF | chicken sandwich | 10.0 | 2023-10-01 | 2\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with expense of Transportation type only.","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the Transportation type expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithTransportationType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\", LocalDate.of(2023, 10, 1),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"ET | Taxi | 50.0 | 2023-10-01 | 4\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with expense of Utility type only.","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the Utility expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithUtilityType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\", LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EU | Electricity | 100.0 | 2023-10-03 | 2\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveExpenseToTextFile(ArrayList)} method with different expense type but no incomes.","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether the different type of expenses record can save correctly.","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithDifferentExpenseType() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\", LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\", LocalDate.of(2023, 10, 1),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\", LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"KenCheung18"},"content":" test.saveExpenseToTextFile(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EF | chicken sandwich | 10.0 | 2023-10-01 | 2\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"ET | Taxi | 50.0 | 2023-10-01 | 4\", lines[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EU | Electricity | 100.0 | 2023-10-03 | 2\", lines[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"KenCheung18"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"KenCheung18"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"KenCheung18"},"content":" * Test the {@link SaveToTxt#saveIncomeAndExpense(ArrayList, ArrayList)} method with both incomes and expenses.","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"KenCheung18"},"content":" * This test case checks whether both incomes and expenses can save correctly","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"KenCheung18"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"KenCheung18"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"KenCheung18"},"content":" public void testSaveToTxtWithDifferentExpensesAndIncomes() throws KaChinnnngException, IOException {","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"KenCheung18"},"content":" SaveToTxt test \u003d new SaveToTxt(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"KenCheung18"},"content":" new ClearAll(incomes,expenses).clearAllIncomeAndExpense();","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes, expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Salary\", LocalDate.of(2023, 10, 10), 5000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"KenCheung18"},"content":" incomes.add(new Income(\"Bonus\", LocalDate.of(2023, 10, 15), 1000.0));","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Food(\"chicken sandwich\", LocalDate.of(2023, 10, 1),10.0, MealType.LUNCH));","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Transport(\"Taxi\", LocalDate.of(2023, 10, 1),50.0, TransportationType.FUEL));","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"KenCheung18"},"content":" expenses.add(new Utilities(\"Electricity\", LocalDate.of(2023, 10, 3),100.0, UtilityType.ELECTRICITY));","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"KenCheung18"},"content":" test.saveIncomeAndExpense(incomes,expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":187,"author":{"gitId":"KenCheung18"},"content":" File file \u003d new File(path);","lastModifiedDate":"2023-10-31"},{"lineNumber":188,"author":{"gitId":"KenCheung18"},"content":" Scanner s \u003d new Scanner(file);","lastModifiedDate":"2023-10-31"},{"lineNumber":189,"author":{"gitId":"KenCheung18"},"content":" int i \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":190,"author":{"gitId":"KenCheung18"},"content":" while (s.hasNext()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":191,"author":{"gitId":"KenCheung18"},"content":" lines[i] \u003d s.nextLine();","lastModifiedDate":"2023-10-31"},{"lineNumber":192,"author":{"gitId":"KenCheung18"},"content":" i++;","lastModifiedDate":"2023-10-31"},{"lineNumber":193,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":194,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Salary | 5000.0 | 2023-10-10\", lines[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":195,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"I | Bonus | 1000.0 | 2023-10-15\" ,lines[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":196,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EF | chicken sandwich | 10.0 | 2023-10-01 | 2\", lines[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":197,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"ET | Taxi | 50.0 | 2023-10-01 | 4\", lines[3]);","lastModifiedDate":"2023-10-31"},{"lineNumber":198,"author":{"gitId":"KenCheung18"},"content":" assertEquals(\"EU | Electricity | 100.0 | 2023-10-03 | 2\", lines[4]);","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"KenCheung18"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"KenCheung18"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"KenCheung18":200}},{"path":"src/test/java/seedu/duke/ui/MockUi.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.ui;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"public class MockUi extends Ui{","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":" private List\u003cString\u003e printedMessages \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":" private List\u003cString\u003e showIncomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":" private List\u003cString\u003e showExpenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":" public void printMessage(String message) {","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":" printedMessages.add(message);","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncomes(List\u003cIncome\u003e matchingIncomes) {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" showIncomes.add(matchingIncomes.toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses(List\u003cExpense\u003e matchingExpenses) {","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":" showExpenses.add(matchingExpenses.toString());","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":" public List\u003cString\u003e getPrintedMessages() {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" return printedMessages;","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":" public List\u003cString\u003e getShowIncomes() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" return showIncomes;","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" public List\u003cString\u003e getShowExpenses() {","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" return showExpenses;","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"bljhty":40}},{"path":"src/test/java/seedu/duke/ui/UiTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bljhty"},"content":"package seedu.duke.ui;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"bljhty"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"bljhty"},"content":"import seedu.duke.commands.KaChinnnngException;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Income;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"bljhty"},"content":"import seedu.duke.financialrecords.Expense;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"bljhty"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"bljhty"},"content":"import java.io.ByteArrayInputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bljhty"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"bljhty"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bljhty"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"bljhty"},"content":"import java.util.List;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bljhty"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"bljhty"},"content":"public class UiTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"bljhty"},"content":" public void readCommand_validInput_commandReturned() throws KaChinnnngException {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"bljhty"},"content":" // Set up simulated user input","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"bljhty"},"content":" ByteArrayInputStream in \u003d new ByteArrayInputStream(\"testCommand\".getBytes());","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"bljhty"},"content":" System.setIn(in);","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"bljhty"},"content":" // Act","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bljhty"},"content":" String command \u003d ui.readCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"bljhty"},"content":" assertEquals(\"testCommand\", command);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"bljhty"},"content":" public void readCommand_noInput_exceptionThrown() {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"bljhty"},"content":" // Set up simulated user input with no data","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"bljhty"},"content":" ByteArrayInputStream in \u003d new ByteArrayInputStream(\"\".getBytes());","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"bljhty"},"content":" System.setIn(in);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"bljhty"},"content":" // Act and Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"bljhty"},"content":" assertThrows(KaChinnnngException.class, ui::readCommand);","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"bljhty"},"content":" public void printWelcomeMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"bljhty"},"content":" Ui.printWelcomeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"bljhty"},"content":" assertEquals(\"____________________________________________________________\"+ System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"bljhty"},"content":" + \"Welcome to KaChinnnngggg! How may i assist you today?\"+ System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"bljhty"},"content":" + \"____________________________________________________________\"+ System.lineSeparator(),","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bljhty"},"content":" out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"bljhty"},"content":" public void printGoodbyeMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"bljhty"},"content":" ui.printGoodbyeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"bljhty"},"content":" assertEquals(\"____________________________________________________________\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"bljhty"},"content":" + \"Bye. Hope to see you again soon!\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"bljhty"},"content":" + \"____________________________________________________________\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"bljhty"},"content":" , out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"bljhty"},"content":" public void showLineDivider_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"bljhty"},"content":" Ui.showLineDivider();","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"bljhty"},"content":" assertEquals(\"____________________________________________________________\"+ System.lineSeparator(),","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"bljhty"},"content":" out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"bljhty"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"bljhty"},"content":" public void printListIncomeMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"bljhty"},"content":" ui.printListIncomeMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are your incomes:\" + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"bljhty"},"content":" public void printListExpenseMessage_validInput_messagePrinted() {","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bljhty"},"content":" ui.printListExpenseMessage();","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are your expenses:\" + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncomes_nullTest() {","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"bljhty"},"content":" ui.showMatchingIncomes(null);","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"bljhty"},"content":" assertEquals(\"No matching incomes found.\", out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"bljhty"},"content":" public void showMatchingIncome_correctTest(){","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"bljhty"},"content":" Income income \u003d null;","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"bljhty"},"content":" List\u003cIncome\u003e incomes \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"bljhty"},"content":" income \u003d new Income(\"Test Description\", LocalDate.now(), 100.0);","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"bljhty"},"content":" incomes.add(income);","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"bljhty"},"content":" e.printStackTrace();","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"bljhty"},"content":" ui.showMatchingIncomes(incomes);","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are the matching incomes in your list:\" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"bljhty"},"content":" + income.toString() + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses_nullTest() {","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"bljhty"},"content":" ui.showMatchingExpenses(null);","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"bljhty"},"content":" assertEquals(\"No matching expenses found.\", out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"bljhty"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"bljhty"},"content":" public void showMatchingExpenses_correctTest(){","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"bljhty"},"content":" // Set up simulated output stream","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"bljhty"},"content":" ByteArrayOutputStream out \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"bljhty"},"content":" System.setOut(new PrintStream(out));","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":170,"author":{"gitId":"bljhty"},"content":" Ui ui \u003d new Ui();","lastModifiedDate":"2023-10-31"},{"lineNumber":171,"author":{"gitId":"bljhty"},"content":" Expense expense \u003d null;","lastModifiedDate":"2023-10-31"},{"lineNumber":172,"author":{"gitId":"bljhty"},"content":" List\u003cExpense\u003e expenses \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":173,"author":{"gitId":"bljhty"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":174,"author":{"gitId":"bljhty"},"content":" expense \u003d new Expense(\"Test Description\", LocalDate.now(), 100.0);","lastModifiedDate":"2023-10-31"},{"lineNumber":175,"author":{"gitId":"bljhty"},"content":" expenses.add(expense);","lastModifiedDate":"2023-10-31"},{"lineNumber":176,"author":{"gitId":"bljhty"},"content":" } catch (KaChinnnngException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":177,"author":{"gitId":"bljhty"},"content":" e.printStackTrace();","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"bljhty"},"content":" ui.showMatchingExpenses(expenses);","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"bljhty"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"bljhty"},"content":" // Assert","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"bljhty"},"content":" assertEquals(\"Here are the matching expenses in your list:\"","lastModifiedDate":"2023-10-31"},{"lineNumber":183,"author":{"gitId":"bljhty"},"content":" + System.lineSeparator() + expense.toString() + System.lineSeparator(), out.toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":184,"author":{"gitId":"bljhty"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":185,"author":{"gitId":"bljhty"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"bljhty":185}}] diff --git a/AY2324S1-CS2113-T18-3_tp_master/commits.json b/AY2324S1-CS2113-T18-3_tp_master/commits.json index f7e1959..e5b0a77 100644 --- a/AY2324S1-CS2113-T18-3_tp_master/commits.json +++ b/AY2324S1-CS2113-T18-3_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"limyuhching":[{"date":"2023-10-12","commitResults":[{"hash":"7f15c328582d32d223482ccd59a5852f9ad70029","isMergeCommit":false,"messageTitle":"Add Lim Yuh Ching to AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-17","commitResults":[{"hash":"47e7e2474c8c6f73387b9dcd7047da3c77cb619e","isMergeCommit":false,"messageTitle":"Add ListCommand class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":5}}},{"hash":"e176e64efb5cc74bcf08757e82020ae7bc9c656f","isMergeCommit":false,"messageTitle":"Add list option to parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4}}},{"hash":"8a99e6a7dc43fd86423cf7046827ac5f7611f9fa","isMergeCommit":false,"messageTitle":"Add Ui to ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":2}}},{"hash":"54d292397684060fd65c2389c300dea0cb712504","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-list\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ea3da5f550569c65319ff4911fe9fed728a97e64","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n","fileTypesAndContributionMap":{}},{"hash":"fd506a278351582ab91f8f4b974b1db63765cfac","isMergeCommit":false,"messageTitle":"Change imports from .* to individual class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":7}}},{"hash":"9c3010789b6b2bc4f285263b77d6e56b0ce6988f","isMergeCommit":false,"messageTitle":"Add DeleteIncomeCommand and DeleteExpenseCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":73,"deletions":1}}},{"hash":"ecdcbbe69b47d928a759d2cb81efe93cfa538c7b","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-delete\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n","fileTypesAndContributionMap":{}},{"hash":"3ae858c7a01d9a61a3e500510b79b26b23fe6a5c","isMergeCommit":false,"messageTitle":"Minor bug fixes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5}}},{"hash":"69a33bbf033086dc0c4f8e2d314dff052227afd7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"939ddd821d709edc8b7e0f4c6e53bb8648e6a8d8","isMergeCommit":false,"messageTitle":"Remove duplicate import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"e7ee368b163df8c82a81ae2738e2f745f44b9846","isMergeCommit":false,"messageTitle":"Bug fixes - wrong indexing for delete command - inconsistent line divider","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":12}}},{"hash":"192a5b32be615e963b03f1bb584aa7eec161324d","isMergeCommit":true,"messageTitle":"Merge pull request #57 from limyuhching/master","messageBody":"Add list and delete feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"470e50657798752e0cea1cf681a1286ead745f62","isMergeCommit":false,"messageTitle":"Add JavaDoc and JUnit test for DeleteIncomeCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":2},"test-code":{"insertions":81,"deletions":0}}},{"hash":"4b8b9e883d87a6a56300486eb6a1e12affb1f7c1","isMergeCommit":false,"messageTitle":"Changed Ui output of ListCommand and DeleteExpenseCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":6}}},{"hash":"8585f39452170b750700c20306dd0bda7ef4eb7e","isMergeCommit":false,"messageTitle":"Debug style error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":3}}},{"hash":"6230bbe0816a74140c927ef9d79550a43ef2e0ec","isMergeCommit":false,"messageTitle":"Add JUnit and JavaDoc to DeleteExpenseCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":9},"test-code":{"insertions":82,"deletions":0}}},{"hash":"4db459d6ae7b6aeeb759152a49a039f92392198d","isMergeCommit":false,"messageTitle":"Add JavaDoc for ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":0}}},{"hash":"385ced88b50c44c7f8f949dc3fb5fad30e859ffc","isMergeCommit":true,"messageTitle":"Merge pull request #84 from limyuhching/JUnit_DeleteIncomeCommand","messageBody":"Add JUnit for DeleteIncomeCommand","fileTypesAndContributionMap":{}},{"hash":"a675ae9e49ae0699e12bccf1e5ed6e3e76dd6703","isMergeCommit":true,"messageTitle":"Merge pull request #85 from limyuhching/JUnit_DeleteExpenseCommand","messageBody":"Add JUnit and JavaDoc to DeleteExpenseCommand","fileTypesAndContributionMap":{}},{"hash":"dc8741864a20266b1fb0e9bb10170d7dae995c8f","isMergeCommit":true,"messageTitle":"Merge branch \u0027JUnit_DeleteExpenseCommand\u0027 into Yuh.Ching-feature-edit","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"2a77405896563ecf112b2964f15f81df3b8eedbd","isMergeCommit":false,"messageTitle":"Feature: Edit Income and Expense","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":183,"deletions":13},"test-code":{"insertions":116,"deletions":0}}},{"hash":"752ff1c0afa5ea17df7e0bd3065ac353b0a6c410","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-edit\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n#\tsrc/main/java/seedu/duke/parser/Parser.java\n#\tsrc/main/java/seedu/duke/ui/Ui.java\n#\ttext-ui-test/EXPECTED.TXT\n#\ttext-ui-test/input.txt\n","fileTypesAndContributionMap":{}},{"hash":"bbb14a8f04eac545603b09a5d59ad8163f6a35c0","isMergeCommit":true,"messageTitle":"Merge pull request #102 from limyuhching/master","messageBody":"Add Edit Feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"e0942052bab2c4a3db305553cc701d8200eb0634","isMergeCommit":false,"messageTitle":"Add Currency conversion feature and ExchangeRateManager class","messageBody":"ExchangeRateManager class consist of the following main features:\n- Loading exchange rates from a text file specified in the class\n- Saving the exchange rate whenever user updates it\n- Convert currency\n- show supported currecencies\n- show exchange rates\n\nAdd currency conversion function to ExpenseParser class to convert currency if applicable.\n\nDebugs:\n- Change Commands abstract class to Command\n","fileTypesAndContributionMap":{"functional-code":{"insertions":305,"deletions":28},"other":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-31","commitResults":[{"hash":"a2917924094c217791ad99dbaa3e7576ca26d07e","isMergeCommit":false,"messageTitle":"Add ExchangeRateFileHandler","messageBody":"ExchangeRateFileHandler is for loading/saving exchange rates from /data/ExchangeRates.txt to the ExchangeRateManager\n","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":89}}},{"hash":"eeacd7e064efef8ac6f0bf483938d1e9eda7f301","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp into Yuh.Ching-feature-currency.conversion","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n#\tsrc/main/java/seedu/duke/commands/FindCommand.java\n","fileTypesAndContributionMap":{}},{"hash":"c628ebb76ec48ee5b362e2f4cd4ed2c23c6fc04e","isMergeCommit":false,"messageTitle":"Add ExchangeRateManagerTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":68,"deletions":0}}},{"hash":"b058c8d68d570cd7a4fc7e8c2e2ce5a7aaf70eb4","isMergeCommit":false,"messageTitle":"Add ExchangeRateFileHandlerTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3},"test-code":{"insertions":64,"deletions":0}}},{"hash":"b397b4d0aff5d7103f7d825b7adc10ac29725f31","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":2}}},{"hash":"f38dfc2d2767fc97878d75c6cba59754ae259667","isMergeCommit":true,"messageTitle":"Merge pull request #119 from limyuhching/Yuh.Ching-feature-currency.conversion","messageBody":"Yuh.ching feature currency.conversion","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"5602207e56a99ffa1993813731099887b366e775","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"Update add income and expense\r\nAdd edit function","fileTypesAndContributionMap":{"docs":{"insertions":30,"deletions":6}}},{"hash":"05192302fd7b7ea8d3762e90dba7a25b93e38117","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"0b0114196a7ef8d775415a6f50a94a6c93eb20d8","isMergeCommit":false,"messageTitle":"Add currency conversion mechanism to IncomeParser","messageBody":"Update input and expected txt file to test for currency conversion when adding income\n\nDebug:\n- Removed try and catch clause at executeCommand() add income and add expense cases to update\n","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":36}}},{"hash":"45748c470f33e6931e6243cb70f12238556023c4","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-currency.conversion\u0027 of https://github.com/limyuhching/tp into Yuh.Ching-feature-currency.conversion","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5225273eaf522230df787145b2a48093ebb9c620","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Yuh.Ching-feature-currency.conversion","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b19139017c4076258dd7a4d3411b3de18dbce7c8","isMergeCommit":true,"messageTitle":"Merge pull request #122 from limyuhching/Yuh.Ching-feature-currency.conversion","messageBody":"Add currency conversion function to add income command","fileTypesAndContributionMap":{}},{"hash":"8a99decb9ffe87c8f0b6d83c17aa698fab7dd454","isMergeCommit":false,"messageTitle":"Update DG for ExchangeRateManager and UG for currency features","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":51,"deletions":0}}},{"hash":"784d290005e69ab9100dba2781f37b4c8643e0f1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"# Conflicts:\n#\tdocs/DeveloperGuide.md\n#\tdocs/UserGuide.md\n","fileTypesAndContributionMap":{}},{"hash":"a35cbe7f188074820c6b8d8858c9b30cead02f43","isMergeCommit":true,"messageTitle":"Merge pull request #129 from limyuhching/master","messageBody":"Add DG for ExchangeRateManager and Update UG","fileTypesAndContributionMap":{}},{"hash":"09fcfa49828a09ef3a9b2b2c6cdc44d9a26da24e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":10}}},{"hash":"297bf1fee71d8dc7a3dcecb505e9525186eac7de","isMergeCommit":false,"messageTitle":"Update Ui output of list exchange rate","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0},"test-code":{"insertions":6,"deletions":1}}},{"hash":"d1edf71d893b110a6c4539835984e8c0eadbbc24","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T18-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f04ec90e1552e5f131c108cddfc4f2171b6b2cf5","isMergeCommit":true,"messageTitle":"Merge pull request #130 from limyuhching/master","messageBody":"Update Ui output of list exchange rate function","fileTypesAndContributionMap":{}},{"hash":"5f4fdf369e36bc207f6a179f6ab333e6cdb4fa45","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":12}}},{"hash":"bae3a9b1cf7eda968788456495224b5557c2540b","isMergeCommit":true,"messageTitle":"Merge pull request #131 from limyuhching/master","messageBody":"Update DeveloperGuide.md","fileTypesAndContributionMap":{}},{"hash":"3f170811bcd701d25acc27dd864a3cae9846e0e6","isMergeCommit":false,"messageTitle":"Update error messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":9}}},{"hash":"e84a5f0dd978b25275fdc69e472374dfc4a6cdfb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1f63dee278b7d9d3525b4724c8537887b8fa11b5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"82c659491b30fd9e9f04c2f63f059d80a8ef6b4b","isMergeCommit":true,"messageTitle":"Merge pull request #133 from limyuhching/master","messageBody":"Update error messages","tags":["KaChinnnngv2.0"],"fileTypesAndContributionMap":{}},{"hash":"cba014761258c7c6824771a8314c473d61b1bc44","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":5}}}]}],"bljhty":[{"date":"2023-10-05","commitResults":[{"hash":"3647d84668028d5ea5c84d7627894a8ef0ee48fc","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-09","commitResults":[{"hash":"7e60ffed6f6e2ee9a0f983eee8e8a977406dfe5a","isMergeCommit":false,"messageTitle":"edited Duke class, added Ui class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":14}}},{"hash":"d8c20c9389f7a68369aa5fbbfd4ac33184a15975","isMergeCommit":false,"messageTitle":"Revert \"edited Duke class, added Ui class\"","messageBody":"This reverts commit 7e60ffed6f6e2ee9a0f983eee8e8a977406dfe5a.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":11}}},{"hash":"9543dee9ca0e62cad63e6cab349aa53372035467","isMergeCommit":false,"messageTitle":"Revert \"Revert \"edited Duke class, added Ui class\"\"","messageBody":"This reverts commit d8c20c9389f7a68369aa5fbbfd4ac33184a15975.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":14}}},{"hash":"e6e15fd5f670eda63cebf191b00c5da28f019d90","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":0}}}]},{"date":"2023-10-11","commitResults":[{"hash":"d68fb478567a1542650b85e6563e6f62f641bdce","isMergeCommit":true,"messageTitle":"Merge pull request #4 from bljhty/master","messageBody":"Ui class added","fileTypesAndContributionMap":{}},{"hash":"fd522121b4dfe8c849d157c5273ea54a0aefefdd","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"d74d0e8d3dd1acfc47f1f94b3a55afe1245cef5b","isMergeCommit":true,"messageTitle":"Merge pull request #5 from bljhty/Bryan-Ui_Class","messageBody":"Bryan UI class","fileTypesAndContributionMap":{}},{"hash":"ac5e4bffd283c4ada16e720a489c48f40cf62d45","isMergeCommit":false,"messageTitle":"added parser class and \"bye\" command to exit the program","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":2}}},{"hash":"146c1e73d2ce3c3bba44f73c548c824cd6bad416","isMergeCommit":true,"messageTitle":"Merge pull request #6 from bljhty/Bryan-Ui_exit_program","messageBody":"added parser class and \"bye\" command to exit the program","fileTypesAndContributionMap":{}},{"hash":"023a67aa11129e7329f57d108d4b3b071f4dfd7a","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"1e769fe7348a49764e97958bee02138b848c4078","isMergeCommit":false,"messageTitle":"edited code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"56a91fa04831b1e06d8763d46b71d127c4ed2a00","isMergeCommit":false,"messageTitle":"edited code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":10}}},{"hash":"2dd7e20d1facad6c28ac218229a49e0d2512af1a","isMergeCommit":true,"messageTitle":"Merge pull request #7 from bljhty/Bryan-Ui_exit_program","messageBody":"Bryan UI exit program","fileTypesAndContributionMap":{}},{"hash":"bd4a31df6e42d5a903c4fab01439db31d962cf18","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"4e8e8a23056ebd8406321216403edf432b6999e9","isMergeCommit":true,"messageTitle":"Merge pull request #8 from bljhty/Bryan-Ui_exit_program","messageBody":"Bryan minor changes to code","fileTypesAndContributionMap":{}},{"hash":"d0d3b91db4ee5e0246a08beb19f6d5bf1becd689","isMergeCommit":false,"messageTitle":"added KaChinng exception class to handle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":15}}},{"hash":"15235a31b2217e9e7340ec3c94e4760276fa7bb6","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":9}}},{"hash":"402c958dcd6b25b20d588adf6d488ef738dadc52","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}},{"hash":"d3432fa63e6626dd7c9834b0f3c44216ed6a2d2d","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"839899344f669c73d5f8ff23d80e68b66f3e60f5","isMergeCommit":false,"messageTitle":"edited test.sh","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"b384a0a035717caa270226c388abfdc1da60cf7c","isMergeCommit":true,"messageTitle":"Merge pull request #19 from bljhty/Bryan-kachingg_exception_class","messageBody":"Bryan kachingg exception class","fileTypesAndContributionMap":{}},{"hash":"032e9e794b6cad89ea6eab4b8dbe01458b253726","isMergeCommit":false,"messageTitle":"edited aboutus page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"03fd6b2bd1462b8d3696fd96ae44264b386963fa","isMergeCommit":true,"messageTitle":"Merge pull request #20 from bljhty/Bryan-edit_about_us","messageBody":"edited aboutus page","fileTypesAndContributionMap":{}}]},{"date":"2023-10-12","commitResults":[{"hash":"873f424ba9981398334f6299fda0bc3cceb73103","isMergeCommit":true,"messageTitle":"Merge pull request #24 from limyuhching/master","messageBody":"Add Lim Yuh Ching to AboutUs.md","fileTypesAndContributionMap":{}},{"hash":"28a6c552f73b92cece6ec576f68cab9a4f665f0b","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"fac1c519c857b496309e7fe6af4af67b5e73d7e6","isMergeCommit":true,"messageTitle":"Merge pull request #26 from bljhty/Bryan-UI_class_updated","messageBody":"Bryan UI class added","fileTypesAndContributionMap":{}},{"hash":"0aac2612fa5b3b29db3f83bd3f56e9d3df220408","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"dd4c190f169c56878ea072be5116d0ab299b302b","isMergeCommit":true,"messageTitle":"Merge pull request #30 from bljhty/Bryan-ParserClass","messageBody":"Bryan Parser Class","fileTypesAndContributionMap":{}},{"hash":"6e5a21ee4c8e1734c7a134cbf4c1f681fad66fef","isMergeCommit":false,"messageTitle":"Added income class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":83,"deletions":0}}},{"hash":"2d31a0a186af6541c21ffa13d5f7f60da9eaccc8","isMergeCommit":false,"messageTitle":"edited income class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":13}}},{"hash":"3fa46fa0749d6bbaab94cbee2f3ca66b93b9da1f","isMergeCommit":true,"messageTitle":"Merge pull request #32 from bljhty/Bryan-IncomeClass","messageBody":"Bryan income class","fileTypesAndContributionMap":{}},{"hash":"e723c830357b03fc0f01f9d145be1a1d3417c7ed","isMergeCommit":false,"messageTitle":"added commands class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0},"other":{"insertions":2,"deletions":2}}},{"hash":"41eee99740159c15d92884ce1b22bbc2149337a6","isMergeCommit":true,"messageTitle":"Merge pull request #33 from bljhty/Bryan-commandsClass","messageBody":"added commands class","fileTypesAndContributionMap":{}},{"hash":"2ef7421ecd90522a7f5746a96af22b928cc9a5e3","isMergeCommit":false,"messageTitle":"added the add income functionality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":138,"deletions":1}}},{"hash":"0de2467e5781906407d226b74596b4b404c645f6","isMergeCommit":true,"messageTitle":"Merge pull request #35 from bljhty/Bryan-AddIncomeFunction","messageBody":"added the add income functionality","fileTypesAndContributionMap":{}},{"hash":"c1415803bafbc7e40a5307c457495e1e36b2ecd5","isMergeCommit":false,"messageTitle":"added JUnit test for income","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":0}}},{"hash":"029f86a4fc3183c74920521dd3dcee4cceebab78","isMergeCommit":true,"messageTitle":"Merge pull request #37 from bljhty/Bryan-AddIncomeJunit","messageBody":"added JUnit test for income","fileTypesAndContributionMap":{}},{"hash":"f7be2e6b37b7ffaf6f44b59e7a24debacf9c71fb","isMergeCommit":false,"messageTitle":"added the list income function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":0}}},{"hash":"95034b9c866c415fcfdc3c484ee9bb03b07f4822","isMergeCommit":true,"messageTitle":"Merge pull request #38 from bljhty/Bryan-ListCommand","messageBody":"added the list income function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-13","commitResults":[{"hash":"3f5c8ecd561ac20483518ba49f808358d9a31ba6","isMergeCommit":false,"messageTitle":"Added JUnit Test for income parser class,","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"test-code":{"insertions":54,"deletions":0}}},{"hash":"efecaa2ff6828936f318ec93f7fbbaf73b07cc47","isMergeCommit":true,"messageTitle":"Merge pull request #41 from bljhty/Bryan-AddJUnitTestIncomeParser","messageBody":"Added JUnit Test for income parser class edit minor bugs in expense class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"b96b8820f857121283457a520bfb762ef2ca2c6c","isMergeCommit":false,"messageTitle":"minor bug fixing and added javadoc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":207,"deletions":6}}},{"hash":"a70966392c50aeb619d6895abd2a93f46c66e25a","isMergeCommit":true,"messageTitle":"Merge pull request #45 from bljhty/Bryan-bug_fixing","messageBody":"minor bug fixing and added javadoc","fileTypesAndContributionMap":{}},{"hash":"71eb946d765b405e018d22d60330e083e2a3bf13","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":174},"other":{"insertions":0,"deletions":0}}},{"hash":"b8a856dcc26db8ede044ef2bcac0852bcdb3838e","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":174,"deletions":0}}},{"hash":"0789a529e66efa74edc3ba2583b1152f5bd69e45","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"57b072ff69089aa71edecde0e12ab91907656d56","isMergeCommit":true,"messageTitle":"Merge pull request #46 from bljhty/Bryan-bug_fixing","messageBody":"Bryan bug fixing","fileTypesAndContributionMap":{}},{"hash":"c90e926cc7b8751df51dfe7387c0ceacd15a7845","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"dcf55f397a5193fa02c0554cb721f55d6a3c6beb","isMergeCommit":true,"messageTitle":"Merge pull request #48 from bljhty/master","messageBody":"no message","fileTypesAndContributionMap":{}},{"hash":"ac5acc3ceba4fdb5cbc729e88eab16b5edd239d0","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"8f9b494475f77182a35a655b40d0fefb1fcade21","isMergeCommit":true,"messageTitle":"Merge pull request #50 from bljhty/master","messageBody":"no message","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"34f306cc9e5ca4ef28e89e0e87179ab88d3256cf","isMergeCommit":false,"messageTitle":"edited testsh and expected output","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":8}}},{"hash":"670b7ab465c3ec3436b883f873cac7cfdc7acd24","isMergeCommit":true,"messageTitle":"Merge pull request #60 from bljhty/Bryan-edit_testsh","messageBody":"edited testsh and expected output","fileTypesAndContributionMap":{}},{"hash":"c6c923f637432277043fe840fd3fbb92c8a7ef25","isMergeCommit":false,"messageTitle":"added JUnit test for expenseparser class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":183,"deletions":0}}},{"hash":"aac9e86c2c1b463fa8173ffe62fba62f4b6a2ef0","isMergeCommit":true,"messageTitle":"Merge pull request #63 from bljhty/Bryan-Expense_parser_Junit","messageBody":"added JUnit test for expenseparser class","fileTypesAndContributionMap":{}},{"hash":"15fed349abbdcd95755be03abeea18551923713e","isMergeCommit":false,"messageTitle":"updated JUnit for income parser, added javadoc for both expense parsertest and incomeParserTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":2},"test-code":{"insertions":202,"deletions":12}}},{"hash":"a06eab9c52dfff4de8d0dbdb26bc4e9b3e10f380","isMergeCommit":true,"messageTitle":"Merge pull request #64 from bljhty/Bryan-income_parser_Junit_updated","messageBody":"updated JUnit for income parser, added javadoc for both expense parse…","fileTypesAndContributionMap":{}},{"hash":"762b83d89c0b39cc91a5d31d4ad2a67e1b0b36f3","isMergeCommit":false,"messageTitle":"added expense JUnit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":69,"deletions":0}}},{"hash":"1d5706ae2c956e8475671e773ef038d27cd7c6d8","isMergeCommit":true,"messageTitle":"Merge pull request #67 from bljhty/Bryan-expenseTest","messageBody":"added expense JUnit test","fileTypesAndContributionMap":{}},{"hash":"97a9b3858d57d9a4bd339e98ed54c363175e83f4","isMergeCommit":false,"messageTitle":"added balanceTest and javadoc comments for balanceTest and expenseTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":117,"deletions":0}}},{"hash":"433aeba0e3f9ff256e9e6b065a78e1b4f7f5c7e7","isMergeCommit":true,"messageTitle":"Merge pull request #70 from bljhty/Bryan-balanceTest","messageBody":"added balanceTest and javadoc comments for balanceTest and expenseTest","fileTypesAndContributionMap":{}},{"hash":"e76caab50cc07de5b2bc2c5f80489b2d90c27f1b","isMergeCommit":false,"messageTitle":"change \"bye\" to \"exit\" to exit the program","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e6badcdf8a009ff91209efb521c0b17f9286079b","isMergeCommit":true,"messageTitle":"Merge pull request #71 from bljhty/Bryan-balanceTest","messageBody":"change \"bye\" to \"exit\" to exit the program","fileTypesAndContributionMap":{}},{"hash":"03b17833325f95216af8857e242d3b5af65f5219","isMergeCommit":false,"messageTitle":"added logging and assertions for incomeLister, Income, incomeManager, FinancialRecord, IncomeParser and Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":74,"deletions":13},"other":{"insertions":4,"deletions":0}}},{"hash":"4ee809172b0d94fa8ca80d620d1a4bd10557de51","isMergeCommit":true,"messageTitle":"Merge pull request #73 from bljhty/Bryan-logging_and_assertions","messageBody":"added logging and assertions for incomeLister, Income, incomeManager,…","fileTypesAndContributionMap":{}},{"hash":"6bbab986b5e67c176ec482d39cf69b3c983c5e5f","isMergeCommit":false,"messageTitle":"updated userguide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":80,"deletions":18}}},{"hash":"6edfa2b4c4816e4386bf978ec444c8e680f003c0","isMergeCommit":true,"messageTitle":"Merge pull request #74 from bljhty/Bryan-UserGuide_update","messageBody":"updated userguide","tags":["KaChinnnngv1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"62b94094ee4923eefe2d4b8c4d1cefc02f85ed08","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":5}}},{"hash":"37718df880e8caf3a75c0f1c6e3565e6d2642bf2","isMergeCommit":true,"messageTitle":"Merge pull request #75 from bljhty/Bryan-EditCode","messageBody":"no message","fileTypesAndContributionMap":{}},{"hash":"bfd698b4dd26861ced11ba5ea65704c8bb1a847d","isMergeCommit":false,"messageTitle":"edited bug where logger information is being displayed in the output","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":5}}}]},{"date":"2023-10-23","commitResults":[{"hash":"7d763fd902700e4578442d4de7ba7cefd9c09411","isMergeCommit":false,"messageTitle":"added the find function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":75,"deletions":22}}},{"hash":"3f46ad0f1c25480383c5cb30df8dcda0af1ef9e2","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":235,"deletions":0}}},{"hash":"a8cdf9a8a14b68c448977a80a12185508edc01cf","isMergeCommit":true,"messageTitle":"Merge pull request #87 from bljhty/Bryan-Find_function","messageBody":"Bryan find function","fileTypesAndContributionMap":{}},{"hash":"39b7a99a518e790ecf6dd123857df4caab783b36","isMergeCommit":false,"messageTitle":"made it such that the log file will be in a folder instead","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":4}}},{"hash":"7cc042582af15a30ae4e2af2394a3a460eb27e82","isMergeCommit":true,"messageTitle":"Merge pull request #88 from bljhty/Bryan-log_fixing","messageBody":"made it such that the log file will be in a folder instead","fileTypesAndContributionMap":{}},{"hash":"6ff08dd325033acea8bf60352d53eda3ef747616","isMergeCommit":false,"messageTitle":"clean up income manager class and change input formats","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":18}}},{"hash":"10a9c5009055e8bd38e4fe5031d2d4467dd0e41a","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"24ab533265f7e3716b86eb8331f978e71c3a4734","isMergeCommit":true,"messageTitle":"Merge pull request #90 from bljhty/Bryan-edit_IncomeManager","messageBody":"Bryan edit income manager","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"8636ab7ee8656732e70f001cefbaeb15ee4ee6cb","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":73,"deletions":36}}},{"hash":"7eb3bc044234d200d13e2442a134686f1e191bbb","isMergeCommit":true,"messageTitle":"Merge pull request #91 from bljhty/Bryan-logging+assertion_findcommand","messageBody":"added logging and assertions to findCommand class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"106754518beae746363af4b8c58c0193c9674ba4","isMergeCommit":false,"messageTitle":"added DG for incomeManager","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":6},"docs":{"insertions":10,"deletions":0}}},{"hash":"1d7a839da12b7de630333477f4fbbed1adfc6797","isMergeCommit":true,"messageTitle":"Merge pull request #95 from bljhty/Bryan-updating_developerguide","messageBody":"added DG for incomeManager","fileTypesAndContributionMap":{}},{"hash":"5b832a32301924c877b0fb2ef0598806b54b234e","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0},"docs":{"insertions":25,"deletions":5}}},{"hash":"e7dd967864e94d72cc75560ded319bc5e2c2ad28","isMergeCommit":true,"messageTitle":"Merge pull request #101 from bljhty/Bryan-updating_developerguide(2)","messageBody":"updated UserGuide for FindCommand class and edited code snippets","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"56a7e40cb4436f0d20b0ad0e33ce1272451cea1b","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":8}}}]},{"date":"2023-10-27","commitResults":[{"hash":"5b1224aa7da13e18d1570d4b4a09dc4f20e20c14","isMergeCommit":true,"messageTitle":"Merge pull request #103 from bljhty/Bryan-FincCommand_JavaDoc","messageBody":"added javadoc comments for FindCommands","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"b05cd0f22923c8b7d7ae4b9243a60fda79d97f4c","isMergeCommit":false,"messageTitle":"Added JUnit test for find command and handled bugs related to find command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":64,"deletions":25}}},{"hash":"01438403a54ddeaf1132179c5d490712d6d4d031","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":464,"deletions":0}}},{"hash":"09cfe83656699dd449f045a0b1f748e1ef641c1e","isMergeCommit":true,"messageTitle":"Merge pull request #104 from KenCheung18/Javadoc-for-clear-function","messageBody":"Javadoc for clear function","fileTypesAndContributionMap":{}},{"hash":"ec4f5e59793333273e142ceb6ad2c8351ef73f58","isMergeCommit":true,"messageTitle":"Merge pull request #108 from bljhty/Bryan-FindCommand_Test","messageBody":"Bryan find command test","fileTypesAndContributionMap":{}},{"hash":"d612f6f5f0c12db14db802c0f7dea96f1ad19e55","isMergeCommit":false,"messageTitle":"included incomeManager JUnit test and incomeLister JUnit test. edited code and added more tests for incomeParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":23},"test-code":{"insertions":234,"deletions":0}}},{"hash":"aa7b1c7ec44f91b35613a871d7fcb4c695ac0846","isMergeCommit":true,"messageTitle":"Merge pull request #110 from bljhty/Bryan-income_JUnit_improvement","messageBody":"included incomeManager JUnit test and incomeLister JUnit test. edited…","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"cad4358d358566ea33630e4afb8fa3b976e80d6d","isMergeCommit":false,"messageTitle":"Added JUnit tests and javadocs","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":286,"deletions":1}}},{"hash":"016def46a212d025a30e4499702f463ce9b34ee2","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":12}}},{"hash":"c91068b24f593ef376b4649d4de09301ae84db15","isMergeCommit":true,"messageTitle":"Merge pull request #114 from bljhty/Bryan-FindParserTest","messageBody":"Added JUnit tests and javadocs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"9bae724f3dd8aa843f8a0f61e05456ee45db68eb","isMergeCommit":false,"messageTitle":"refactored main class, added JUnit test for dukeclass and DukeTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":169,"deletions":139},"test-code":{"insertions":512,"deletions":4}}},{"hash":"c39186d2cdff33b075f213dab331f3faa78facd6","isMergeCommit":false,"messageTitle":"ediited code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":9,"deletions":5}}},{"hash":"4d64cb99c3cdfe21b799f3a7743ab1758cc9c64c","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":14}}},{"hash":"2f90a79e70d36f1068ea7078780122fdb23c915f","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":3,"deletions":3}}},{"hash":"da5415d6d9866a65d45e56a579c8ff6a072802ac","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":18,"deletions":12}}},{"hash":"85e66db6c2e3c95d8cbf67c6e315c52bdf81891a","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":61,"deletions":55}}},{"hash":"1efd8cbc2a492c9df8c7d04338c505730f7d2b94","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":16,"deletions":8}}},{"hash":"155660078e8366118417760ddff4c840d5ef1e73","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":213}}},{"hash":"b0f115542658b99fd3d9618f60345d06254c77c5","isMergeCommit":true,"messageTitle":"Merge pull request #116 from bljhty/Bryan-moreJUnitTest","messageBody":"Bryan more j unit test","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"df0d58b3dd2bbabeedd35b56e7f97cf50bf21c45","isMergeCommit":false,"messageTitle":"updated DG and edited some code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":4},"docs":{"insertions":126,"deletions":16}}},{"hash":"6da24c75c75a943c692e675a3a83c8504c9e8d3a","isMergeCommit":true,"messageTitle":"Merge pull request #120 from bljhty/Bryan-update_DG2","messageBody":"updated DG and edited some code","fileTypesAndContributionMap":{}},{"hash":"4d38aaad822af717cc6c48291291ada27f1bd7f6","isMergeCommit":true,"messageTitle":"Merge pull request #121 from bljhty/Bryan-update_DG2","messageBody":"uploaded image","fileTypesAndContributionMap":{}},{"hash":"57b8e593605a39dfa014d3cd0d64fb96620fc564","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":7}}},{"hash":"dba8248889441a97ac995f0b661cda14dce5a609","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Bryan-update_UG2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fe5a14ddf971d17ccbe16ebd9ef1a1524a5007a4","isMergeCommit":true,"messageTitle":"Merge pull request #127 from bljhty/Bryan-update_UG2","messageBody":"no message","fileTypesAndContributionMap":{}}]}],"Hongzhii":[{"date":"2023-10-12","commitResults":[{"hash":"374988e8cd3295fcc475bc7750fb4b9fb00876cb","isMergeCommit":false,"messageTitle":"add expense class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":0}}},{"hash":"e2c1a08d38fb0980168c121d98f9a550d41908d9","isMergeCommit":true,"messageTitle":"Merge pull request #39 from Hongzhii/add-expense-class","messageBody":"add expense class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"fdb794183e31163e1516dff81559a932400e697b","isMergeCommit":false,"messageTitle":"add expense categories","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":299,"deletions":2}}},{"hash":"f9620e70b7be8738cd6fad83aac026b9a6e3ac86","isMergeCommit":false,"messageTitle":"fix coding standards issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}}]},{"date":"2023-10-16","commitResults":[{"hash":"098a0492e5d4180fdc5f363384f4dad966b685fd","isMergeCommit":true,"messageTitle":"Merge pull request #43 from Hongzhii/add-expense-class","messageBody":"create different expense categories","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"d0a0911eb6616b1d618539343913144ab3b96c0f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Hongzhii/tp into add-expense-class","messageBody":"* \u0027master\u0027 of https://github.com/Hongzhii/tp:\n no message\n no message\n no message\n no message\n no message\n minor bug fixing and added javadoc\n add the help function\n\n# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n#\tsrc/main/java/seedu/duke/commands/ExpenseLister.java\n#\tsrc/main/java/seedu/duke/commands/ExpenseManager.java\n#\tsrc/main/java/seedu/duke/parser/ExpenseParser.java\n#\tsrc/main/java/seedu/duke/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"6dc33217fab2dad56a7817bcdf9c0bb669e527f4","isMergeCommit":true,"messageTitle":"Merge pull request #52 from Hongzhii/add-expense-class","messageBody":"Add expense class","fileTypesAndContributionMap":{}},{"hash":"2982cf9151c17da188b454e61f5d05a6f1bcd26c","isMergeCommit":true,"messageTitle":"Merge pull request #51 from AY2324S1-CS2113-T18-3/add-expense-class","messageBody":"Add expense class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"ab30caec1cd31ad109d5be413d60a431098f662a","isMergeCommit":false,"messageTitle":"add java doc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":110,"deletions":8}}},{"hash":"c6826012f1f2fa18afe80e27196b98d85a2da144","isMergeCommit":false,"messageTitle":"fix coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"303628c0a8d489a99a106bfe47ec1b5fd3100075","isMergeCommit":true,"messageTitle":"Merge pull request #66 from Hongzhii/master","messageBody":"add java doc","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"7ee4535ebcf6a796938d1ad67f2ab82ca0537831","isMergeCommit":true,"messageTitle":"Merge pull request #82 from bljhty/Bryan_LOGGING_bug","messageBody":"edited bug where logger information is being displayed in the output","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"57091e1603dc4a51c8d4bfa9a65bada3c4bbec1b","isMergeCommit":false,"messageTitle":"change toString method to include enum type information","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"64994adc4f2dd4af9b021e5f8dae61fbd6298882","isMergeCommit":false,"messageTitle":"update parser and expense manager","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":11}}},{"hash":"8b2ce625f1678c12fc73a87d1a8be704963c151e","isMergeCommit":false,"messageTitle":"update unit tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":5},"test-code":{"insertions":9,"deletions":5}}},{"hash":"e3becbb79486d7af284a270c67bc444fe990a487","isMergeCommit":true,"messageTitle":"Merge branch \u0027add-type-functionality-to-expenses\u0027","messageBody":"* add-type-functionality-to-expenses:\n update unit tests\n update i/o tests\n update parser and expense manager\n change toString method to include enum type information\n","fileTypesAndContributionMap":{}},{"hash":"e0ff3d162d26673c9bdac78b0a8713dd7e4ed7b8","isMergeCommit":true,"messageTitle":"Merge pull request #105 from Hongzhii/master","messageBody":"add type functionality to expenses","fileTypesAndContributionMap":{}},{"hash":"15dda310b6cb156064f1f84aaa80d58b27f774eb","isMergeCommit":false,"messageTitle":"update developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":0}}},{"hash":"fd1e0031d8dfc29a95d461b467eda6a3eeff737b","isMergeCommit":true,"messageTitle":"Merge branch \u0027update-developer-guide\u0027","messageBody":"* update-developer-guide:\n update developer guide\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"356e34b25e6d229286bcd1070a0fd092ec09c2c5","isMergeCommit":true,"messageTitle":"Merge pull request #106 from Hongzhii/master","messageBody":"update DG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"aabf8766c925d8dd12a4fc5aa9de20ce1606d9a6","isMergeCommit":false,"messageTitle":"add expenseManager unit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":85,"deletions":0}}},{"hash":"1b9f6c3168d8ed185b878a1df50a79adc8b7b0d1","isMergeCommit":true,"messageTitle":"Merge branch \u0027add-expense-manager-unit-tests\u0027","messageBody":"* add-expense-manager-unit-tests:\n add expenseManager unit tests\n","fileTypesAndContributionMap":{}},{"hash":"2bedde6c82f1a217a3182cf815eddb39b255c2b1","isMergeCommit":true,"messageTitle":"Merge pull request #118 from Hongzhii/master","messageBody":"add expenseManager unit tests","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"07e46c2d0dbd53d1da885aa8e8439e89d152179c","isMergeCommit":false,"messageTitle":"update DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":12}}},{"hash":"a558dd4f88ede75fa5fa45a8f5580eae6e2d25f5","isMergeCommit":true,"messageTitle":"Merge branch \u0027update-expense-manager-uml-diagram\u0027","messageBody":"* update-expense-manager-uml-diagram:\n update DG\n","fileTypesAndContributionMap":{}},{"hash":"f02b68c7c014451c4f9997c97f752d5e5f556500","isMergeCommit":true,"messageTitle":"Merge pull request #124 from Hongzhii/master","messageBody":"update DG","fileTypesAndContributionMap":{}},{"hash":"88855ab16ada236969fdd0bb6425fd7449baed77","isMergeCommit":false,"messageTitle":"add expense class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":1}}},{"hash":"20ac115c6edfdae09bc0491d2898cb989783caa1","isMergeCommit":true,"messageTitle":"Merge branch \u0027add-puml-expense-class-diagram\u0027","messageBody":"* add-puml-expense-class-diagram:\n add expense class diagram\n","fileTypesAndContributionMap":{}},{"hash":"eb00a8c096b3c24d2c71101622ac290a2c201201","isMergeCommit":true,"messageTitle":"Merge pull request #126 from Hongzhii/master","messageBody":"add expense class diagram","fileTypesAndContributionMap":{}},{"hash":"329421bedd1803d719194d6510e6daa4f2790262","isMergeCommit":false,"messageTitle":"update expense manager uml diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":0}}},{"hash":"eb4703269781820de0723c18f6099fb0ca57037e","isMergeCommit":true,"messageTitle":"Merge branch \u0027update-expenseManager-sequence-diagram\u0027","messageBody":"* update-expenseManager-sequence-diagram:\n update expense manager uml diagram\n","fileTypesAndContributionMap":{}},{"hash":"bd8afe1054c69dfd4edb88f832dab011083c4954","isMergeCommit":true,"messageTitle":"Merge pull request #128 from Hongzhii/master","messageBody":"update expense manager uml diagram","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"0cac4961c47c26bb55174810480474927eab3e96","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"6840df4d7450e531e9d7cd2a6a9a6c44b0a47e9e","isMergeCommit":true,"messageTitle":"Merge branch \u0027fix-DG-images\u0027","messageBody":"* fix-DG-images:\n no message\n","fileTypesAndContributionMap":{}},{"hash":"c6d3eaea654352aa3032e1c5b39d772693190ab1","isMergeCommit":true,"messageTitle":"Merge pull request #134 from Hongzhii/master","messageBody":"fix DG images","fileTypesAndContributionMap":{}}]}],"KenCheung18":[{"date":"2023-10-05","commitResults":[{"hash":"ff771b65c44f9dd8452f28d33c98131f6ebdaca3","isMergeCommit":false,"messageTitle":"AboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"169d557cd8aeb41bfc052c8baa84595ffdfb91a6","isMergeCommit":true,"messageTitle":"Merge pull request #3 from KenCheung18/AboutUs","messageBody":"AboutUs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"329946ddf88f470e861a65d067db83b89ac74e38","isMergeCommit":false,"messageTitle":"add the help function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":0}}},{"hash":"4451eda2b70e6fac03872dd33858a8d24c486e4c","isMergeCommit":true,"messageTitle":"Merge pull request #44 from KenCheung18/Usage-instructions","messageBody":"add the help function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"bcae9628b344bc6cb291a079aca607faff1fe7db","isMergeCommit":false,"messageTitle":"Solve conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"85c13e1244776c0f0866cdcce5a35676a6c27715","isMergeCommit":false,"messageTitle":"Solve another conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"10b6b25ca6c8901d81089ea4d3f1914ea47a41df","isMergeCommit":false,"messageTitle":"Solve minor bug on switch statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"d92551230ce733460145529d1b989be404f9e7d2","isMergeCommit":true,"messageTitle":"Merge pull request #53 from KenCheung18/Bug-solve-for-expense-class","messageBody":"Solve merge conflict","fileTypesAndContributionMap":{}},{"hash":"963101c37e2e2463d2b56dbbc75f772ae778bee2","isMergeCommit":false,"messageTitle":"Balance Function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":0}}},{"hash":"b61608b37db593b319f5b214c27c1ed7a2a47202","isMergeCommit":false,"messageTitle":"Minor bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"fb0d1b79960c19af7b291b56b8cd9925b24cb710","isMergeCommit":true,"messageTitle":"Merge pull request #58 from KenCheung18/Balance","messageBody":"Balance Function","fileTypesAndContributionMap":{}},{"hash":"f186609c39c31189eeeebeb89d7dc00b32bea648","isMergeCommit":false,"messageTitle":"Bug fix on balance function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"2796193e5f7ec9efb7eb8c7f92d5ae2b26eadea0","isMergeCommit":true,"messageTitle":"Merge pull request #59 from KenCheung18/Balance-bug-fix","messageBody":"Bug fix on balance function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"39b92cb3edb128ffb3386d0d23a3d6a3a9e47010","isMergeCommit":false,"messageTitle":"javadoc for Balance and UsageInstructions class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":1}}},{"hash":"e8cbb9f2e94ac946debabad31cd1e21edd590e4a","isMergeCommit":false,"messageTitle":"minor bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"b33182fbf46985067b73ce658ac1e1b8966a7a07","isMergeCommit":false,"messageTitle":"javadoc bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"2e540a1baf3784a8c9fff244e353199805ff168c","isMergeCommit":true,"messageTitle":"Merge pull request #65 from KenCheung18/Balance-add-javadoc","messageBody":"Add javadoc on balance class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"beed4e277ab87a56865f2feec2c41315f7618e61","isMergeCommit":false,"messageTitle":"Save the income and expense to txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":0}}},{"hash":"30495ba61c5154c18acdbb12a2c764428fd20547","isMergeCommit":false,"messageTitle":"Get the incomes and expenses from txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":103,"deletions":0}}},{"hash":"44cc8ff64eed0b27d78091d1f94c36906df9c32b","isMergeCommit":false,"messageTitle":"Add javadoc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":56,"deletions":4}}},{"hash":"e1662d922f6415fc120ee9a46ec3707f937553f1","isMergeCommit":false,"messageTitle":"Style correction","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":11}}},{"hash":"10a8106e93484afda5a7bb7cd116372428881158","isMergeCommit":true,"messageTitle":"Merge pull request #93 from KenCheung18/Storage-function","messageBody":"Storage function","fileTypesAndContributionMap":{}},{"hash":"26c32ef86ca87fb6f6602410781caa103fa14a10","isMergeCommit":false,"messageTitle":"Clear income function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":4}}},{"hash":"8a55003d9fe93008935363b856988d29a4ec29a0","isMergeCommit":false,"messageTitle":"Clear expense function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0}}},{"hash":"cfbc0c5c9c5c2ef4805199276fcf827ff906dd42","isMergeCommit":false,"messageTitle":"Clear all and due with the user input","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":0}}},{"hash":"2194afadd9dd4b1617ef8cbd65f4fa2b2a11ca61","isMergeCommit":true,"messageTitle":"Merge pull request #94 from KenCheung18/Clear-function","messageBody":"Clear function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"89ad03ea042f3777bf018efe75838c4e3d533edc","isMergeCommit":false,"messageTitle":"Javadoc for clear expense class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":0}}},{"hash":"d3c68cf8dd447bca268780ceaf2d82c7418d0e27","isMergeCommit":false,"messageTitle":"javadoc for clear income class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":2}}},{"hash":"cddaafdf18b36955f4abd56100af401907d41ae9","isMergeCommit":false,"messageTitle":"javadoc for clear all class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":4}}}]},{"date":"2023-10-27","commitResults":[{"hash":"76c95157c2e101d5b2ea291f63d431c02a2157d6","isMergeCommit":false,"messageTitle":"Create DG for GetFromTxt","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":0}}},{"hash":"7dfba6bfa646fc484614a76326af86af8d7ab514","isMergeCommit":true,"messageTitle":"Merge pull request #107 from KenCheung18/Developer-Guide-GetFromTxt","messageBody":"Create DG for GetFromTxt","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"77f3ccb1abc5bdab5eba90b385c25ed45f981a2b","isMergeCommit":false,"messageTitle":"Add JUnit test for clear function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":114,"deletions":0}}},{"hash":"9224d26bfe0ffa5e388e68d3ffbfca5c5f10048d","isMergeCommit":false,"messageTitle":"JUnit test for all clear functions","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":99,"deletions":7}}},{"hash":"a5d5cf43575be5a476be60346aeceb04477d9451","isMergeCommit":false,"messageTitle":"JavaDoc comments for tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":9,"deletions":5}}},{"hash":"b0034c04efb4b1905313106f11c262cf1be951a0","isMergeCommit":false,"messageTitle":"JUnit test for saveToTextFile","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":195,"deletions":0}}},{"hash":"093b837ffd060a35e7b6fd30a8184e894b6d3bb9","isMergeCommit":false,"messageTitle":"Save to txt test bug fix","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":16,"deletions":16}}},{"hash":"dc07ee1721cf8225ff4cd9a31b14eb0aef48915e","isMergeCommit":false,"messageTitle":"JUnit test for getFromFTxt","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":168,"deletions":0}}},{"hash":"1b4d2168d5cea415ca6a081c41d88dfbadbeced9","isMergeCommit":false,"messageTitle":"Bug fix on JUnit test for clear function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":11,"deletions":9}}},{"hash":"c037720844d97d9b17088cdf3bac60725af90a82","isMergeCommit":false,"messageTitle":"Change back","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"db21169e24ebc3852becf549da1448763e314561","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JUnit-test-for-clear-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2379ef9e6fbfd090339e126b14958d04fdcc2845","isMergeCommit":false,"messageTitle":"Changes to the JUnit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":10,"deletions":6}}},{"hash":"b41f976e47a1161454d0940c7c58df851e651069","isMergeCommit":false,"messageTitle":"Bug Fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"2b926cdd1dac78fc1d77d50a5b43f977d8aad043","isMergeCommit":true,"messageTitle":"Merge branch \u0027JUnit-test-for-clear-function\u0027 of https://github.com/KenCheung18/tp into JUnit-test-for-clear-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d8bb04396d9eec5473f12831e53b9823cb292744","isMergeCommit":true,"messageTitle":"Merge pull request #117 from KenCheung18/JUnit-test-for-Storage","messageBody":"JUnit test for storage","fileTypesAndContributionMap":{}},{"hash":"cb8d827a79b4493642442ad5e2b1513a58e3ce57","isMergeCommit":false,"messageTitle":"Bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"52b40ea3d0e7b128528ec1f525dbbbe978991f75","isMergeCommit":true,"messageTitle":"Merge pull request #115 from KenCheung18/JUnit-test-for-clear-function","messageBody":"J unit test for clear function","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"9ceaf1dd39d6ca49663c42f6395871921b2052bf","isMergeCommit":false,"messageTitle":"Add user guide and minor change to the Usage Instructions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":6},"docs":{"insertions":18,"deletions":3}}},{"hash":"0d0dd72dc381cb5c687c35fe6a1badce35480c2a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into User-guide-and-add-new-content-on-help-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e161409382108b4fcd7ece3ae78fb9d2292c02a5","isMergeCommit":true,"messageTitle":"Merge branch \u0027User-guide-and-add-new-content-on-help-function\u0027 of https://github.com/KenCheung18/tp into User-guide-and-add-new-content-on-help-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c8fbcceac4ea92f4849d589cc9ffe5c88e6a3d50","isMergeCommit":true,"messageTitle":"Merge pull request #123 from KenCheung18/User-guide-and-add-new-content-on-help-function","messageBody":"Add user guide and minor change to the Usage Instructions","fileTypesAndContributionMap":{}},{"hash":"8243f1b1b244f91e9d2fa73aeaf729221b08598e","isMergeCommit":false,"messageTitle":"Change to developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":0}}},{"hash":"e6e3dd6a2ac40e62f50a7b95d312e02d729e7d92","isMergeCommit":true,"messageTitle":"Merge pull request #125 from KenCheung18/Developer-guide-changes","messageBody":"Change to developer guide","fileTypesAndContributionMap":{}},{"hash":"cc4cffd2d86c646768194f84f0c1b2e72586f3db","isMergeCommit":false,"messageTitle":"help function update for currency update","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"cf9b01c8a4b0f39204065b62d07c3bf8fa272687","isMergeCommit":false,"messageTitle":"change to test-ui-test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"01f93937f3d4d507e268a9fdf1d669c9595fc671","isMergeCommit":false,"messageTitle":"bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"4400e4efb109faf83a0bf188fcb764fdd5b24c5a","isMergeCommit":true,"messageTitle":"Merge pull request #132 from KenCheung18/help-function-update","messageBody":"Help function update","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"169b8d750e0eacdad1107bf115150e5c5961c880","isMergeCommit":false,"messageTitle":"DG fix","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":8}}},{"hash":"17e05bc61d623f55c63e37259ca7daa85c8d6dd2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into DG-fix","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a3a88020755f643e2676d8f0afda3e565a99f1d1","isMergeCommit":true,"messageTitle":"Merge pull request #135 from KenCheung18/DG-fix","messageBody":"DG fix","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"limyuhching":{"docs":114,"functional-code":684,"test-code":415},"bljhty":{"docs":214,"functional-code":1261,"test-code":1934,"other":5},"Hongzhii":{"docs":46,"functional-code":428,"test-code":94},"KenCheung18":{"docs":46,"functional-code":435,"test-code":579}},"authorContributionVariance":{"limyuhching":10281.201,"bljhty":72873.414,"Hongzhii":2839.716,"KenCheung18":13226.025},"authorDisplayNameMap":{"limyuhching":"CS2113-T18-3 LIM ..HING","bljhty":"CS2113-T18-3 LEE ..RYAN","Hongzhii":"CS2113-T18-3 EE H.. ZHI","KenCheung18":"CS2113-T18-3 CHEU..YUEN"}} +{"authorDailyContributionsMap":{"limyuhching":[{"date":"2023-10-12","commitResults":[{"hash":"7f15c328582d32d223482ccd59a5852f9ad70029","isMergeCommit":false,"messageTitle":"Add Lim Yuh Ching to AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-17","commitResults":[{"hash":"47e7e2474c8c6f73387b9dcd7047da3c77cb619e","isMergeCommit":false,"messageTitle":"Add ListCommand class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":59,"deletions":5}}},{"hash":"e176e64efb5cc74bcf08757e82020ae7bc9c656f","isMergeCommit":false,"messageTitle":"Add list option to parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4}}},{"hash":"8a99e6a7dc43fd86423cf7046827ac5f7611f9fa","isMergeCommit":false,"messageTitle":"Add Ui to ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":2}}},{"hash":"54d292397684060fd65c2389c300dea0cb712504","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-list\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ea3da5f550569c65319ff4911fe9fed728a97e64","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n","fileTypesAndContributionMap":{}},{"hash":"fd506a278351582ab91f8f4b974b1db63765cfac","isMergeCommit":false,"messageTitle":"Change imports from .* to individual class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":7}}},{"hash":"9c3010789b6b2bc4f285263b77d6e56b0ce6988f","isMergeCommit":false,"messageTitle":"Add DeleteIncomeCommand and DeleteExpenseCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":73,"deletions":1}}},{"hash":"ecdcbbe69b47d928a759d2cb81efe93cfa538c7b","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-delete\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n","fileTypesAndContributionMap":{}},{"hash":"3ae858c7a01d9a61a3e500510b79b26b23fe6a5c","isMergeCommit":false,"messageTitle":"Minor bug fixes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":5}}},{"hash":"69a33bbf033086dc0c4f8e2d314dff052227afd7","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"939ddd821d709edc8b7e0f4c6e53bb8648e6a8d8","isMergeCommit":false,"messageTitle":"Remove duplicate import","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"e7ee368b163df8c82a81ae2738e2f745f44b9846","isMergeCommit":false,"messageTitle":"Bug fixes - wrong indexing for delete command - inconsistent line divider","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":12}}},{"hash":"192a5b32be615e963b03f1bb584aa7eec161324d","isMergeCommit":true,"messageTitle":"Merge pull request #57 from limyuhching/master","messageBody":"Add list and delete feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"470e50657798752e0cea1cf681a1286ead745f62","isMergeCommit":false,"messageTitle":"Add JavaDoc and JUnit test for DeleteIncomeCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":2},"test-code":{"insertions":81,"deletions":0}}},{"hash":"4b8b9e883d87a6a56300486eb6a1e12affb1f7c1","isMergeCommit":false,"messageTitle":"Changed Ui output of ListCommand and DeleteExpenseCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":6}}},{"hash":"8585f39452170b750700c20306dd0bda7ef4eb7e","isMergeCommit":false,"messageTitle":"Debug style error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":3}}},{"hash":"6230bbe0816a74140c927ef9d79550a43ef2e0ec","isMergeCommit":false,"messageTitle":"Add JUnit and JavaDoc to DeleteExpenseCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":9},"test-code":{"insertions":82,"deletions":0}}},{"hash":"4db459d6ae7b6aeeb759152a49a039f92392198d","isMergeCommit":false,"messageTitle":"Add JavaDoc for ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":0}}},{"hash":"385ced88b50c44c7f8f949dc3fb5fad30e859ffc","isMergeCommit":true,"messageTitle":"Merge pull request #84 from limyuhching/JUnit_DeleteIncomeCommand","messageBody":"Add JUnit for DeleteIncomeCommand","fileTypesAndContributionMap":{}},{"hash":"a675ae9e49ae0699e12bccf1e5ed6e3e76dd6703","isMergeCommit":true,"messageTitle":"Merge pull request #85 from limyuhching/JUnit_DeleteExpenseCommand","messageBody":"Add JUnit and JavaDoc to DeleteExpenseCommand","fileTypesAndContributionMap":{}},{"hash":"dc8741864a20266b1fb0e9bb10170d7dae995c8f","isMergeCommit":true,"messageTitle":"Merge branch \u0027JUnit_DeleteExpenseCommand\u0027 into Yuh.Ching-feature-edit","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"2a77405896563ecf112b2964f15f81df3b8eedbd","isMergeCommit":false,"messageTitle":"Feature: Edit Income and Expense","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":183,"deletions":13},"test-code":{"insertions":116,"deletions":0}}},{"hash":"752ff1c0afa5ea17df7e0bd3065ac353b0a6c410","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-edit\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n#\tsrc/main/java/seedu/duke/parser/Parser.java\n#\tsrc/main/java/seedu/duke/ui/Ui.java\n#\ttext-ui-test/EXPECTED.TXT\n#\ttext-ui-test/input.txt\n","fileTypesAndContributionMap":{}},{"hash":"bbb14a8f04eac545603b09a5d59ad8163f6a35c0","isMergeCommit":true,"messageTitle":"Merge pull request #102 from limyuhching/master","messageBody":"Add Edit Feature","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"e0942052bab2c4a3db305553cc701d8200eb0634","isMergeCommit":false,"messageTitle":"Add Currency conversion feature and ExchangeRateManager class","messageBody":"ExchangeRateManager class consist of the following main features:\n- Loading exchange rates from a text file specified in the class\n- Saving the exchange rate whenever user updates it\n- Convert currency\n- show supported currecencies\n- show exchange rates\n\nAdd currency conversion function to ExpenseParser class to convert currency if applicable.\n\nDebugs:\n- Change Commands abstract class to Command\n","fileTypesAndContributionMap":{"functional-code":{"insertions":305,"deletions":28},"other":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-31","commitResults":[{"hash":"a2917924094c217791ad99dbaa3e7576ca26d07e","isMergeCommit":false,"messageTitle":"Add ExchangeRateFileHandler","messageBody":"ExchangeRateFileHandler is for loading/saving exchange rates from /data/ExchangeRates.txt to the ExchangeRateManager\n","fileTypesAndContributionMap":{"functional-code":{"insertions":90,"deletions":89}}},{"hash":"eeacd7e064efef8ac6f0bf483938d1e9eda7f301","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp into Yuh.Ching-feature-currency.conversion","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n#\tsrc/main/java/seedu/duke/commands/FindCommand.java\n","fileTypesAndContributionMap":{}},{"hash":"c628ebb76ec48ee5b362e2f4cd4ed2c23c6fc04e","isMergeCommit":false,"messageTitle":"Add ExchangeRateManagerTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":68,"deletions":0}}},{"hash":"b058c8d68d570cd7a4fc7e8c2e2ce5a7aaf70eb4","isMergeCommit":false,"messageTitle":"Add ExchangeRateFileHandlerTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":3},"test-code":{"insertions":64,"deletions":0}}},{"hash":"b397b4d0aff5d7103f7d825b7adc10ac29725f31","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":2}}},{"hash":"f38dfc2d2767fc97878d75c6cba59754ae259667","isMergeCommit":true,"messageTitle":"Merge pull request #119 from limyuhching/Yuh.Ching-feature-currency.conversion","messageBody":"Yuh.ching feature currency.conversion","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"5602207e56a99ffa1993813731099887b366e775","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"Update add income and expense\r\nAdd edit function","fileTypesAndContributionMap":{"docs":{"insertions":30,"deletions":6}}},{"hash":"05192302fd7b7ea8d3762e90dba7a25b93e38117","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"0b0114196a7ef8d775415a6f50a94a6c93eb20d8","isMergeCommit":false,"messageTitle":"Add currency conversion mechanism to IncomeParser","messageBody":"Update input and expected txt file to test for currency conversion when adding income\n\nDebug:\n- Removed try and catch clause at executeCommand() add income and add expense cases to update\n","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":36}}},{"hash":"45748c470f33e6931e6243cb70f12238556023c4","isMergeCommit":true,"messageTitle":"Merge branch \u0027Yuh.Ching-feature-currency.conversion\u0027 of https://github.com/limyuhching/tp into Yuh.Ching-feature-currency.conversion","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5225273eaf522230df787145b2a48093ebb9c620","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Yuh.Ching-feature-currency.conversion","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b19139017c4076258dd7a4d3411b3de18dbce7c8","isMergeCommit":true,"messageTitle":"Merge pull request #122 from limyuhching/Yuh.Ching-feature-currency.conversion","messageBody":"Add currency conversion function to add income command","fileTypesAndContributionMap":{}},{"hash":"8a99decb9ffe87c8f0b6d83c17aa698fab7dd454","isMergeCommit":false,"messageTitle":"Update DG for ExchangeRateManager and UG for currency features","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":51,"deletions":0}}},{"hash":"784d290005e69ab9100dba2781f37b4c8643e0f1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"# Conflicts:\n#\tdocs/DeveloperGuide.md\n#\tdocs/UserGuide.md\n","fileTypesAndContributionMap":{}},{"hash":"a35cbe7f188074820c6b8d8858c9b30cead02f43","isMergeCommit":true,"messageTitle":"Merge pull request #129 from limyuhching/master","messageBody":"Add DG for ExchangeRateManager and Update UG","fileTypesAndContributionMap":{}},{"hash":"09fcfa49828a09ef3a9b2b2c6cdc44d9a26da24e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":10}}},{"hash":"297bf1fee71d8dc7a3dcecb505e9525186eac7de","isMergeCommit":false,"messageTitle":"Update Ui output of list exchange rate","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":0},"test-code":{"insertions":6,"deletions":1}}},{"hash":"d1edf71d893b110a6c4539835984e8c0eadbbc24","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113-T18-3:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"f04ec90e1552e5f131c108cddfc4f2171b6b2cf5","isMergeCommit":true,"messageTitle":"Merge pull request #130 from limyuhching/master","messageBody":"Update Ui output of list exchange rate function","fileTypesAndContributionMap":{}},{"hash":"5f4fdf369e36bc207f6a179f6ab333e6cdb4fa45","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":12}}},{"hash":"bae3a9b1cf7eda968788456495224b5557c2540b","isMergeCommit":true,"messageTitle":"Merge pull request #131 from limyuhching/master","messageBody":"Update DeveloperGuide.md","fileTypesAndContributionMap":{}},{"hash":"3f170811bcd701d25acc27dd864a3cae9846e0e6","isMergeCommit":false,"messageTitle":"Update error messages","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":23,"deletions":9}}},{"hash":"e84a5f0dd978b25275fdc69e472374dfc4a6cdfb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1f63dee278b7d9d3525b4724c8537887b8fa11b5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/limyuhching/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"82c659491b30fd9e9f04c2f63f059d80a8ef6b4b","isMergeCommit":true,"messageTitle":"Merge pull request #133 from limyuhching/master","messageBody":"Update error messages","tags":["KaChinnnngv2.0"],"fileTypesAndContributionMap":{}},{"hash":"cba014761258c7c6824771a8314c473d61b1bc44","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":5}}}]}],"bljhty":[{"date":"2023-10-05","commitResults":[{"hash":"3647d84668028d5ea5c84d7627894a8ef0ee48fc","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-09","commitResults":[{"hash":"7e60ffed6f6e2ee9a0f983eee8e8a977406dfe5a","isMergeCommit":false,"messageTitle":"edited Duke class, added Ui class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":14}}},{"hash":"d8c20c9389f7a68369aa5fbbfd4ac33184a15975","isMergeCommit":false,"messageTitle":"Revert \"edited Duke class, added Ui class\"","messageBody":"This reverts commit 7e60ffed6f6e2ee9a0f983eee8e8a977406dfe5a.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":11}}},{"hash":"9543dee9ca0e62cad63e6cab349aa53372035467","isMergeCommit":false,"messageTitle":"Revert \"Revert \"edited Duke class, added Ui class\"\"","messageBody":"This reverts commit d8c20c9389f7a68369aa5fbbfd4ac33184a15975.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":14}}},{"hash":"e6e15fd5f670eda63cebf191b00c5da28f019d90","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":0}}}]},{"date":"2023-10-11","commitResults":[{"hash":"d68fb478567a1542650b85e6563e6f62f641bdce","isMergeCommit":true,"messageTitle":"Merge pull request #4 from bljhty/master","messageBody":"Ui class added","fileTypesAndContributionMap":{}},{"hash":"fd522121b4dfe8c849d157c5273ea54a0aefefdd","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"d74d0e8d3dd1acfc47f1f94b3a55afe1245cef5b","isMergeCommit":true,"messageTitle":"Merge pull request #5 from bljhty/Bryan-Ui_Class","messageBody":"Bryan UI class","fileTypesAndContributionMap":{}},{"hash":"ac5e4bffd283c4ada16e720a489c48f40cf62d45","isMergeCommit":false,"messageTitle":"added parser class and \"bye\" command to exit the program","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":2}}},{"hash":"146c1e73d2ce3c3bba44f73c548c824cd6bad416","isMergeCommit":true,"messageTitle":"Merge pull request #6 from bljhty/Bryan-Ui_exit_program","messageBody":"added parser class and \"bye\" command to exit the program","fileTypesAndContributionMap":{}},{"hash":"023a67aa11129e7329f57d108d4b3b071f4dfd7a","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"1e769fe7348a49764e97958bee02138b848c4078","isMergeCommit":false,"messageTitle":"edited code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"56a91fa04831b1e06d8763d46b71d127c4ed2a00","isMergeCommit":false,"messageTitle":"edited code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":10}}},{"hash":"2dd7e20d1facad6c28ac218229a49e0d2512af1a","isMergeCommit":true,"messageTitle":"Merge pull request #7 from bljhty/Bryan-Ui_exit_program","messageBody":"Bryan UI exit program","fileTypesAndContributionMap":{}},{"hash":"bd4a31df6e42d5a903c4fab01439db31d962cf18","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2}}},{"hash":"4e8e8a23056ebd8406321216403edf432b6999e9","isMergeCommit":true,"messageTitle":"Merge pull request #8 from bljhty/Bryan-Ui_exit_program","messageBody":"Bryan minor changes to code","fileTypesAndContributionMap":{}},{"hash":"d0d3b91db4ee5e0246a08beb19f6d5bf1becd689","isMergeCommit":false,"messageTitle":"added KaChinng exception class to handle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":32,"deletions":15}}},{"hash":"15235a31b2217e9e7340ec3c94e4760276fa7bb6","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":9}}},{"hash":"402c958dcd6b25b20d588adf6d488ef738dadc52","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}},{"hash":"d3432fa63e6626dd7c9834b0f3c44216ed6a2d2d","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"839899344f669c73d5f8ff23d80e68b66f3e60f5","isMergeCommit":false,"messageTitle":"edited test.sh","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"b384a0a035717caa270226c388abfdc1da60cf7c","isMergeCommit":true,"messageTitle":"Merge pull request #19 from bljhty/Bryan-kachingg_exception_class","messageBody":"Bryan kachingg exception class","fileTypesAndContributionMap":{}},{"hash":"032e9e794b6cad89ea6eab4b8dbe01458b253726","isMergeCommit":false,"messageTitle":"edited aboutus page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"03fd6b2bd1462b8d3696fd96ae44264b386963fa","isMergeCommit":true,"messageTitle":"Merge pull request #20 from bljhty/Bryan-edit_about_us","messageBody":"edited aboutus page","fileTypesAndContributionMap":{}}]},{"date":"2023-10-12","commitResults":[{"hash":"873f424ba9981398334f6299fda0bc3cceb73103","isMergeCommit":true,"messageTitle":"Merge pull request #24 from limyuhching/master","messageBody":"Add Lim Yuh Ching to AboutUs.md","fileTypesAndContributionMap":{}},{"hash":"28a6c552f73b92cece6ec576f68cab9a4f665f0b","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"fac1c519c857b496309e7fe6af4af67b5e73d7e6","isMergeCommit":true,"messageTitle":"Merge pull request #26 from bljhty/Bryan-UI_class_updated","messageBody":"Bryan UI class added","fileTypesAndContributionMap":{}},{"hash":"0aac2612fa5b3b29db3f83bd3f56e9d3df220408","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"dd4c190f169c56878ea072be5116d0ab299b302b","isMergeCommit":true,"messageTitle":"Merge pull request #30 from bljhty/Bryan-ParserClass","messageBody":"Bryan Parser Class","fileTypesAndContributionMap":{}},{"hash":"6e5a21ee4c8e1734c7a134cbf4c1f681fad66fef","isMergeCommit":false,"messageTitle":"Added income class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":83,"deletions":0}}},{"hash":"2d31a0a186af6541c21ffa13d5f7f60da9eaccc8","isMergeCommit":false,"messageTitle":"edited income class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":13}}},{"hash":"3fa46fa0749d6bbaab94cbee2f3ca66b93b9da1f","isMergeCommit":true,"messageTitle":"Merge pull request #32 from bljhty/Bryan-IncomeClass","messageBody":"Bryan income class","fileTypesAndContributionMap":{}},{"hash":"e723c830357b03fc0f01f9d145be1a1d3417c7ed","isMergeCommit":false,"messageTitle":"added commands class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0},"other":{"insertions":2,"deletions":2}}},{"hash":"41eee99740159c15d92884ce1b22bbc2149337a6","isMergeCommit":true,"messageTitle":"Merge pull request #33 from bljhty/Bryan-commandsClass","messageBody":"added commands class","fileTypesAndContributionMap":{}},{"hash":"2ef7421ecd90522a7f5746a96af22b928cc9a5e3","isMergeCommit":false,"messageTitle":"added the add income functionality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":138,"deletions":1}}},{"hash":"0de2467e5781906407d226b74596b4b404c645f6","isMergeCommit":true,"messageTitle":"Merge pull request #35 from bljhty/Bryan-AddIncomeFunction","messageBody":"added the add income functionality","fileTypesAndContributionMap":{}},{"hash":"c1415803bafbc7e40a5307c457495e1e36b2ecd5","isMergeCommit":false,"messageTitle":"added JUnit test for income","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":42,"deletions":0}}},{"hash":"029f86a4fc3183c74920521dd3dcee4cceebab78","isMergeCommit":true,"messageTitle":"Merge pull request #37 from bljhty/Bryan-AddIncomeJunit","messageBody":"added JUnit test for income","fileTypesAndContributionMap":{}},{"hash":"f7be2e6b37b7ffaf6f44b59e7a24debacf9c71fb","isMergeCommit":false,"messageTitle":"added the list income function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":0}}},{"hash":"95034b9c866c415fcfdc3c484ee9bb03b07f4822","isMergeCommit":true,"messageTitle":"Merge pull request #38 from bljhty/Bryan-ListCommand","messageBody":"added the list income function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-13","commitResults":[{"hash":"3f5c8ecd561ac20483518ba49f808358d9a31ba6","isMergeCommit":false,"messageTitle":"Added JUnit Test for income parser class,","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"test-code":{"insertions":54,"deletions":0}}},{"hash":"efecaa2ff6828936f318ec93f7fbbaf73b07cc47","isMergeCommit":true,"messageTitle":"Merge pull request #41 from bljhty/Bryan-AddJUnitTestIncomeParser","messageBody":"Added JUnit Test for income parser class edit minor bugs in expense class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"b96b8820f857121283457a520bfb762ef2ca2c6c","isMergeCommit":false,"messageTitle":"minor bug fixing and added javadoc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":207,"deletions":6}}},{"hash":"a70966392c50aeb619d6895abd2a93f46c66e25a","isMergeCommit":true,"messageTitle":"Merge pull request #45 from bljhty/Bryan-bug_fixing","messageBody":"minor bug fixing and added javadoc","fileTypesAndContributionMap":{}},{"hash":"71eb946d765b405e018d22d60330e083e2a3bf13","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":174},"other":{"insertions":0,"deletions":0}}},{"hash":"b8a856dcc26db8ede044ef2bcac0852bcdb3838e","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":174,"deletions":0}}},{"hash":"0789a529e66efa74edc3ba2583b1152f5bd69e45","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"57b072ff69089aa71edecde0e12ab91907656d56","isMergeCommit":true,"messageTitle":"Merge pull request #46 from bljhty/Bryan-bug_fixing","messageBody":"Bryan bug fixing","fileTypesAndContributionMap":{}},{"hash":"c90e926cc7b8751df51dfe7387c0ceacd15a7845","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"dcf55f397a5193fa02c0554cb721f55d6a3c6beb","isMergeCommit":true,"messageTitle":"Merge pull request #48 from bljhty/master","messageBody":"no message","fileTypesAndContributionMap":{}},{"hash":"ac5acc3ceba4fdb5cbc729e88eab16b5edd239d0","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"8f9b494475f77182a35a655b40d0fefb1fcade21","isMergeCommit":true,"messageTitle":"Merge pull request #50 from bljhty/master","messageBody":"no message","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"34f306cc9e5ca4ef28e89e0e87179ab88d3256cf","isMergeCommit":false,"messageTitle":"edited testsh and expected output","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":8}}},{"hash":"670b7ab465c3ec3436b883f873cac7cfdc7acd24","isMergeCommit":true,"messageTitle":"Merge pull request #60 from bljhty/Bryan-edit_testsh","messageBody":"edited testsh and expected output","fileTypesAndContributionMap":{}},{"hash":"c6c923f637432277043fe840fd3fbb92c8a7ef25","isMergeCommit":false,"messageTitle":"added JUnit test for expenseparser class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"test-code":{"insertions":183,"deletions":0}}},{"hash":"aac9e86c2c1b463fa8173ffe62fba62f4b6a2ef0","isMergeCommit":true,"messageTitle":"Merge pull request #63 from bljhty/Bryan-Expense_parser_Junit","messageBody":"added JUnit test for expenseparser class","fileTypesAndContributionMap":{}},{"hash":"15fed349abbdcd95755be03abeea18551923713e","isMergeCommit":false,"messageTitle":"updated JUnit for income parser, added javadoc for both expense parsertest and incomeParserTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":2},"test-code":{"insertions":202,"deletions":12}}},{"hash":"a06eab9c52dfff4de8d0dbdb26bc4e9b3e10f380","isMergeCommit":true,"messageTitle":"Merge pull request #64 from bljhty/Bryan-income_parser_Junit_updated","messageBody":"updated JUnit for income parser, added javadoc for both expense parse…","fileTypesAndContributionMap":{}},{"hash":"762b83d89c0b39cc91a5d31d4ad2a67e1b0b36f3","isMergeCommit":false,"messageTitle":"added expense JUnit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":69,"deletions":0}}},{"hash":"1d5706ae2c956e8475671e773ef038d27cd7c6d8","isMergeCommit":true,"messageTitle":"Merge pull request #67 from bljhty/Bryan-expenseTest","messageBody":"added expense JUnit test","fileTypesAndContributionMap":{}},{"hash":"97a9b3858d57d9a4bd339e98ed54c363175e83f4","isMergeCommit":false,"messageTitle":"added balanceTest and javadoc comments for balanceTest and expenseTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":117,"deletions":0}}},{"hash":"433aeba0e3f9ff256e9e6b065a78e1b4f7f5c7e7","isMergeCommit":true,"messageTitle":"Merge pull request #70 from bljhty/Bryan-balanceTest","messageBody":"added balanceTest and javadoc comments for balanceTest and expenseTest","fileTypesAndContributionMap":{}},{"hash":"e76caab50cc07de5b2bc2c5f80489b2d90c27f1b","isMergeCommit":false,"messageTitle":"change \"bye\" to \"exit\" to exit the program","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e6badcdf8a009ff91209efb521c0b17f9286079b","isMergeCommit":true,"messageTitle":"Merge pull request #71 from bljhty/Bryan-balanceTest","messageBody":"change \"bye\" to \"exit\" to exit the program","fileTypesAndContributionMap":{}},{"hash":"03b17833325f95216af8857e242d3b5af65f5219","isMergeCommit":false,"messageTitle":"added logging and assertions for incomeLister, Income, incomeManager, FinancialRecord, IncomeParser and Parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":74,"deletions":13},"other":{"insertions":4,"deletions":0}}},{"hash":"4ee809172b0d94fa8ca80d620d1a4bd10557de51","isMergeCommit":true,"messageTitle":"Merge pull request #73 from bljhty/Bryan-logging_and_assertions","messageBody":"added logging and assertions for incomeLister, Income, incomeManager,…","fileTypesAndContributionMap":{}},{"hash":"6bbab986b5e67c176ec482d39cf69b3c983c5e5f","isMergeCommit":false,"messageTitle":"updated userguide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":80,"deletions":18}}},{"hash":"6edfa2b4c4816e4386bf978ec444c8e680f003c0","isMergeCommit":true,"messageTitle":"Merge pull request #74 from bljhty/Bryan-UserGuide_update","messageBody":"updated userguide","tags":["KaChinnnngv1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"62b94094ee4923eefe2d4b8c4d1cefc02f85ed08","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":5}}},{"hash":"37718df880e8caf3a75c0f1c6e3565e6d2642bf2","isMergeCommit":true,"messageTitle":"Merge pull request #75 from bljhty/Bryan-EditCode","messageBody":"no message","fileTypesAndContributionMap":{}},{"hash":"bfd698b4dd26861ced11ba5ea65704c8bb1a847d","isMergeCommit":false,"messageTitle":"edited bug where logger information is being displayed in the output","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":5}}}]},{"date":"2023-10-23","commitResults":[{"hash":"7d763fd902700e4578442d4de7ba7cefd9c09411","isMergeCommit":false,"messageTitle":"added the find function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":75,"deletions":22}}},{"hash":"3f46ad0f1c25480383c5cb30df8dcda0af1ef9e2","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":235,"deletions":0}}},{"hash":"a8cdf9a8a14b68c448977a80a12185508edc01cf","isMergeCommit":true,"messageTitle":"Merge pull request #87 from bljhty/Bryan-Find_function","messageBody":"Bryan find function","fileTypesAndContributionMap":{}},{"hash":"39b7a99a518e790ecf6dd123857df4caab783b36","isMergeCommit":false,"messageTitle":"made it such that the log file will be in a folder instead","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":4}}},{"hash":"7cc042582af15a30ae4e2af2394a3a460eb27e82","isMergeCommit":true,"messageTitle":"Merge pull request #88 from bljhty/Bryan-log_fixing","messageBody":"made it such that the log file will be in a folder instead","fileTypesAndContributionMap":{}},{"hash":"6ff08dd325033acea8bf60352d53eda3ef747616","isMergeCommit":false,"messageTitle":"clean up income manager class and change input formats","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":18}}},{"hash":"10a9c5009055e8bd38e4fe5031d2d4467dd0e41a","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"24ab533265f7e3716b86eb8331f978e71c3a4734","isMergeCommit":true,"messageTitle":"Merge pull request #90 from bljhty/Bryan-edit_IncomeManager","messageBody":"Bryan edit income manager","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"8636ab7ee8656732e70f001cefbaeb15ee4ee6cb","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":73,"deletions":36}}},{"hash":"7eb3bc044234d200d13e2442a134686f1e191bbb","isMergeCommit":true,"messageTitle":"Merge pull request #91 from bljhty/Bryan-logging+assertion_findcommand","messageBody":"added logging and assertions to findCommand class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"106754518beae746363af4b8c58c0193c9674ba4","isMergeCommit":false,"messageTitle":"added DG for incomeManager","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":6},"docs":{"insertions":10,"deletions":0}}},{"hash":"1d7a839da12b7de630333477f4fbbed1adfc6797","isMergeCommit":true,"messageTitle":"Merge pull request #95 from bljhty/Bryan-updating_developerguide","messageBody":"added DG for incomeManager","fileTypesAndContributionMap":{}},{"hash":"5b832a32301924c877b0fb2ef0598806b54b234e","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0},"docs":{"insertions":25,"deletions":5}}},{"hash":"e7dd967864e94d72cc75560ded319bc5e2c2ad28","isMergeCommit":true,"messageTitle":"Merge pull request #101 from bljhty/Bryan-updating_developerguide(2)","messageBody":"updated UserGuide for FindCommand class and edited code snippets","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"56a7e40cb4436f0d20b0ad0e33ce1272451cea1b","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":8}}}]},{"date":"2023-10-27","commitResults":[{"hash":"5b1224aa7da13e18d1570d4b4a09dc4f20e20c14","isMergeCommit":true,"messageTitle":"Merge pull request #103 from bljhty/Bryan-FincCommand_JavaDoc","messageBody":"added javadoc comments for FindCommands","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"b05cd0f22923c8b7d7ae4b9243a60fda79d97f4c","isMergeCommit":false,"messageTitle":"Added JUnit test for find command and handled bugs related to find command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":64,"deletions":25}}},{"hash":"01438403a54ddeaf1132179c5d490712d6d4d031","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":464,"deletions":0}}},{"hash":"09cfe83656699dd449f045a0b1f748e1ef641c1e","isMergeCommit":true,"messageTitle":"Merge pull request #104 from KenCheung18/Javadoc-for-clear-function","messageBody":"Javadoc for clear function","fileTypesAndContributionMap":{}},{"hash":"ec4f5e59793333273e142ceb6ad2c8351ef73f58","isMergeCommit":true,"messageTitle":"Merge pull request #108 from bljhty/Bryan-FindCommand_Test","messageBody":"Bryan find command test","fileTypesAndContributionMap":{}},{"hash":"d612f6f5f0c12db14db802c0f7dea96f1ad19e55","isMergeCommit":false,"messageTitle":"included incomeManager JUnit test and incomeLister JUnit test. edited code and added more tests for incomeParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":23},"test-code":{"insertions":234,"deletions":0}}},{"hash":"aa7b1c7ec44f91b35613a871d7fcb4c695ac0846","isMergeCommit":true,"messageTitle":"Merge pull request #110 from bljhty/Bryan-income_JUnit_improvement","messageBody":"included incomeManager JUnit test and incomeLister JUnit test. edited…","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"cad4358d358566ea33630e4afb8fa3b976e80d6d","isMergeCommit":false,"messageTitle":"Added JUnit tests and javadocs","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":286,"deletions":1}}},{"hash":"016def46a212d025a30e4499702f463ce9b34ee2","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":12}}},{"hash":"c91068b24f593ef376b4649d4de09301ae84db15","isMergeCommit":true,"messageTitle":"Merge pull request #114 from bljhty/Bryan-FindParserTest","messageBody":"Added JUnit tests and javadocs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"9bae724f3dd8aa843f8a0f61e05456ee45db68eb","isMergeCommit":false,"messageTitle":"refactored main class, added JUnit test for dukeclass and DukeTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":169,"deletions":139},"test-code":{"insertions":512,"deletions":4}}},{"hash":"c39186d2cdff33b075f213dab331f3faa78facd6","isMergeCommit":false,"messageTitle":"ediited code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":9,"deletions":5}}},{"hash":"4d64cb99c3cdfe21b799f3a7743ab1758cc9c64c","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":14}}},{"hash":"2f90a79e70d36f1068ea7078780122fdb23c915f","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":3,"deletions":3}}},{"hash":"da5415d6d9866a65d45e56a579c8ff6a072802ac","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":18,"deletions":12}}},{"hash":"85e66db6c2e3c95d8cbf67c6e315c52bdf81891a","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":61,"deletions":55}}},{"hash":"1efd8cbc2a492c9df8c7d04338c505730f7d2b94","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":16,"deletions":8}}},{"hash":"155660078e8366118417760ddff4c840d5ef1e73","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":213}}},{"hash":"b0f115542658b99fd3d9618f60345d06254c77c5","isMergeCommit":true,"messageTitle":"Merge pull request #116 from bljhty/Bryan-moreJUnitTest","messageBody":"Bryan more j unit test","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"df0d58b3dd2bbabeedd35b56e7f97cf50bf21c45","isMergeCommit":false,"messageTitle":"updated DG and edited some code","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":4},"docs":{"insertions":126,"deletions":16}}},{"hash":"6da24c75c75a943c692e675a3a83c8504c9e8d3a","isMergeCommit":true,"messageTitle":"Merge pull request #120 from bljhty/Bryan-update_DG2","messageBody":"updated DG and edited some code","fileTypesAndContributionMap":{}},{"hash":"4d38aaad822af717cc6c48291291ada27f1bd7f6","isMergeCommit":true,"messageTitle":"Merge pull request #121 from bljhty/Bryan-update_DG2","messageBody":"uploaded image","fileTypesAndContributionMap":{}},{"hash":"57b8e593605a39dfa014d3cd0d64fb96620fc564","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":7}}},{"hash":"dba8248889441a97ac995f0b661cda14dce5a609","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into Bryan-update_UG2","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fe5a14ddf971d17ccbe16ebd9ef1a1524a5007a4","isMergeCommit":true,"messageTitle":"Merge pull request #127 from bljhty/Bryan-update_UG2","messageBody":"no message","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"15c43bb909805fe34d8efc89db50b65a373f5ac2","isMergeCommit":false,"messageTitle":"PE-D bug fixing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":1},"docs":{"insertions":17,"deletions":1}}},{"hash":"14a70e81b3a04287a5f5a377be797df22a6a8524","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":15}}},{"hash":"65a06c4d12e766b5736c9d85a83683eee7b3d45a","isMergeCommit":true,"messageTitle":"Merge pull request #171 from bljhty/Bryan-addincome_bugfixing","messageBody":"Bryan addincome bugfixing","fileTypesAndContributionMap":{}}]}],"Hongzhii":[{"date":"2023-10-12","commitResults":[{"hash":"374988e8cd3295fcc475bc7750fb4b9fb00876cb","isMergeCommit":false,"messageTitle":"add expense class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":0}}},{"hash":"e2c1a08d38fb0980168c121d98f9a550d41908d9","isMergeCommit":true,"messageTitle":"Merge pull request #39 from Hongzhii/add-expense-class","messageBody":"add expense class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"fdb794183e31163e1516dff81559a932400e697b","isMergeCommit":false,"messageTitle":"add expense categories","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":299,"deletions":2}}},{"hash":"f9620e70b7be8738cd6fad83aac026b9a6e3ac86","isMergeCommit":false,"messageTitle":"fix coding standards issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}}]},{"date":"2023-10-16","commitResults":[{"hash":"098a0492e5d4180fdc5f363384f4dad966b685fd","isMergeCommit":true,"messageTitle":"Merge pull request #43 from Hongzhii/add-expense-class","messageBody":"create different expense categories","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"d0a0911eb6616b1d618539343913144ab3b96c0f","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/Hongzhii/tp into add-expense-class","messageBody":"* \u0027master\u0027 of https://github.com/Hongzhii/tp:\n no message\n no message\n no message\n no message\n no message\n minor bug fixing and added javadoc\n add the help function\n\n# Conflicts:\n#\tsrc/main/java/seedu/duke/Duke.java\n#\tsrc/main/java/seedu/duke/commands/ExpenseLister.java\n#\tsrc/main/java/seedu/duke/commands/ExpenseManager.java\n#\tsrc/main/java/seedu/duke/parser/ExpenseParser.java\n#\tsrc/main/java/seedu/duke/parser/Parser.java\n","fileTypesAndContributionMap":{}},{"hash":"6dc33217fab2dad56a7817bcdf9c0bb669e527f4","isMergeCommit":true,"messageTitle":"Merge pull request #52 from Hongzhii/add-expense-class","messageBody":"Add expense class","fileTypesAndContributionMap":{}},{"hash":"2982cf9151c17da188b454e61f5d05a6f1bcd26c","isMergeCommit":true,"messageTitle":"Merge pull request #51 from AY2324S1-CS2113-T18-3/add-expense-class","messageBody":"Add expense class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"ab30caec1cd31ad109d5be413d60a431098f662a","isMergeCommit":false,"messageTitle":"add java doc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":110,"deletions":8}}},{"hash":"c6826012f1f2fa18afe80e27196b98d85a2da144","isMergeCommit":false,"messageTitle":"fix coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"303628c0a8d489a99a106bfe47ec1b5fd3100075","isMergeCommit":true,"messageTitle":"Merge pull request #66 from Hongzhii/master","messageBody":"add java doc","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"7ee4535ebcf6a796938d1ad67f2ab82ca0537831","isMergeCommit":true,"messageTitle":"Merge pull request #82 from bljhty/Bryan_LOGGING_bug","messageBody":"edited bug where logger information is being displayed in the output","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"57091e1603dc4a51c8d4bfa9a65bada3c4bbec1b","isMergeCommit":false,"messageTitle":"change toString method to include enum type information","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"64994adc4f2dd4af9b021e5f8dae61fbd6298882","isMergeCommit":false,"messageTitle":"update parser and expense manager","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":11}}},{"hash":"8b2ce625f1678c12fc73a87d1a8be704963c151e","isMergeCommit":false,"messageTitle":"update unit tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":5},"test-code":{"insertions":9,"deletions":5}}},{"hash":"e3becbb79486d7af284a270c67bc444fe990a487","isMergeCommit":true,"messageTitle":"Merge branch \u0027add-type-functionality-to-expenses\u0027","messageBody":"* add-type-functionality-to-expenses:\n update unit tests\n update i/o tests\n update parser and expense manager\n change toString method to include enum type information\n","fileTypesAndContributionMap":{}},{"hash":"e0ff3d162d26673c9bdac78b0a8713dd7e4ed7b8","isMergeCommit":true,"messageTitle":"Merge pull request #105 from Hongzhii/master","messageBody":"add type functionality to expenses","fileTypesAndContributionMap":{}},{"hash":"15dda310b6cb156064f1f84aaa80d58b27f774eb","isMergeCommit":false,"messageTitle":"update developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":0}}},{"hash":"fd1e0031d8dfc29a95d461b467eda6a3eeff737b","isMergeCommit":true,"messageTitle":"Merge branch \u0027update-developer-guide\u0027","messageBody":"* update-developer-guide:\n update developer guide\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"356e34b25e6d229286bcd1070a0fd092ec09c2c5","isMergeCommit":true,"messageTitle":"Merge pull request #106 from Hongzhii/master","messageBody":"update DG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"aabf8766c925d8dd12a4fc5aa9de20ce1606d9a6","isMergeCommit":false,"messageTitle":"add expenseManager unit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":85,"deletions":0}}},{"hash":"1b9f6c3168d8ed185b878a1df50a79adc8b7b0d1","isMergeCommit":true,"messageTitle":"Merge branch \u0027add-expense-manager-unit-tests\u0027","messageBody":"* add-expense-manager-unit-tests:\n add expenseManager unit tests\n","fileTypesAndContributionMap":{}},{"hash":"2bedde6c82f1a217a3182cf815eddb39b255c2b1","isMergeCommit":true,"messageTitle":"Merge pull request #118 from Hongzhii/master","messageBody":"add expenseManager unit tests","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"07e46c2d0dbd53d1da885aa8e8439e89d152179c","isMergeCommit":false,"messageTitle":"update DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":12}}},{"hash":"a558dd4f88ede75fa5fa45a8f5580eae6e2d25f5","isMergeCommit":true,"messageTitle":"Merge branch \u0027update-expense-manager-uml-diagram\u0027","messageBody":"* update-expense-manager-uml-diagram:\n update DG\n","fileTypesAndContributionMap":{}},{"hash":"f02b68c7c014451c4f9997c97f752d5e5f556500","isMergeCommit":true,"messageTitle":"Merge pull request #124 from Hongzhii/master","messageBody":"update DG","fileTypesAndContributionMap":{}},{"hash":"88855ab16ada236969fdd0bb6425fd7449baed77","isMergeCommit":false,"messageTitle":"add expense class diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":1}}},{"hash":"20ac115c6edfdae09bc0491d2898cb989783caa1","isMergeCommit":true,"messageTitle":"Merge branch \u0027add-puml-expense-class-diagram\u0027","messageBody":"* add-puml-expense-class-diagram:\n add expense class diagram\n","fileTypesAndContributionMap":{}},{"hash":"eb00a8c096b3c24d2c71101622ac290a2c201201","isMergeCommit":true,"messageTitle":"Merge pull request #126 from Hongzhii/master","messageBody":"add expense class diagram","fileTypesAndContributionMap":{}},{"hash":"329421bedd1803d719194d6510e6daa4f2790262","isMergeCommit":false,"messageTitle":"update expense manager uml diagram","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":0}}},{"hash":"eb4703269781820de0723c18f6099fb0ca57037e","isMergeCommit":true,"messageTitle":"Merge branch \u0027update-expenseManager-sequence-diagram\u0027","messageBody":"* update-expenseManager-sequence-diagram:\n update expense manager uml diagram\n","fileTypesAndContributionMap":{}},{"hash":"bd8afe1054c69dfd4edb88f832dab011083c4954","isMergeCommit":true,"messageTitle":"Merge pull request #128 from Hongzhii/master","messageBody":"update expense manager uml diagram","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"0cac4961c47c26bb55174810480474927eab3e96","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"6840df4d7450e531e9d7cd2a6a9a6c44b0a47e9e","isMergeCommit":true,"messageTitle":"Merge branch \u0027fix-DG-images\u0027","messageBody":"* fix-DG-images:\n no message\n","fileTypesAndContributionMap":{}},{"hash":"c6d3eaea654352aa3032e1c5b39d772693190ab1","isMergeCommit":true,"messageTitle":"Merge pull request #134 from Hongzhii/master","messageBody":"fix DG images","fileTypesAndContributionMap":{}}]}],"KenCheung18":[{"date":"2023-10-05","commitResults":[{"hash":"ff771b65c44f9dd8452f28d33c98131f6ebdaca3","isMergeCommit":false,"messageTitle":"AboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}},{"hash":"169d557cd8aeb41bfc052c8baa84595ffdfb91a6","isMergeCommit":true,"messageTitle":"Merge pull request #3 from KenCheung18/AboutUs","messageBody":"AboutUs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"329946ddf88f470e861a65d067db83b89ac74e38","isMergeCommit":false,"messageTitle":"add the help function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":0}}},{"hash":"4451eda2b70e6fac03872dd33858a8d24c486e4c","isMergeCommit":true,"messageTitle":"Merge pull request #44 from KenCheung18/Usage-instructions","messageBody":"add the help function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"bcae9628b344bc6cb291a079aca607faff1fe7db","isMergeCommit":false,"messageTitle":"Solve conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"85c13e1244776c0f0866cdcce5a35676a6c27715","isMergeCommit":false,"messageTitle":"Solve another conflict","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":3}}},{"hash":"10b6b25ca6c8901d81089ea4d3f1914ea47a41df","isMergeCommit":false,"messageTitle":"Solve minor bug on switch statement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"d92551230ce733460145529d1b989be404f9e7d2","isMergeCommit":true,"messageTitle":"Merge pull request #53 from KenCheung18/Bug-solve-for-expense-class","messageBody":"Solve merge conflict","fileTypesAndContributionMap":{}},{"hash":"963101c37e2e2463d2b56dbbc75f772ae778bee2","isMergeCommit":false,"messageTitle":"Balance Function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":0}}},{"hash":"b61608b37db593b319f5b214c27c1ed7a2a47202","isMergeCommit":false,"messageTitle":"Minor bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"fb0d1b79960c19af7b291b56b8cd9925b24cb710","isMergeCommit":true,"messageTitle":"Merge pull request #58 from KenCheung18/Balance","messageBody":"Balance Function","fileTypesAndContributionMap":{}},{"hash":"f186609c39c31189eeeebeb89d7dc00b32bea648","isMergeCommit":false,"messageTitle":"Bug fix on balance function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"2796193e5f7ec9efb7eb8c7f92d5ae2b26eadea0","isMergeCommit":true,"messageTitle":"Merge pull request #59 from KenCheung18/Balance-bug-fix","messageBody":"Bug fix on balance function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"39b92cb3edb128ffb3386d0d23a3d6a3a9e47010","isMergeCommit":false,"messageTitle":"javadoc for Balance and UsageInstructions class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":1}}},{"hash":"e8cbb9f2e94ac946debabad31cd1e21edd590e4a","isMergeCommit":false,"messageTitle":"minor bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"b33182fbf46985067b73ce658ac1e1b8966a7a07","isMergeCommit":false,"messageTitle":"javadoc bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"2e540a1baf3784a8c9fff244e353199805ff168c","isMergeCommit":true,"messageTitle":"Merge pull request #65 from KenCheung18/Balance-add-javadoc","messageBody":"Add javadoc on balance class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-25","commitResults":[{"hash":"beed4e277ab87a56865f2feec2c41315f7618e61","isMergeCommit":false,"messageTitle":"Save the income and expense to txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":66,"deletions":0}}},{"hash":"30495ba61c5154c18acdbb12a2c764428fd20547","isMergeCommit":false,"messageTitle":"Get the incomes and expenses from txt file","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":103,"deletions":0}}},{"hash":"44cc8ff64eed0b27d78091d1f94c36906df9c32b","isMergeCommit":false,"messageTitle":"Add javadoc","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":56,"deletions":4}}},{"hash":"e1662d922f6415fc120ee9a46ec3707f937553f1","isMergeCommit":false,"messageTitle":"Style correction","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":11}}},{"hash":"10a8106e93484afda5a7bb7cd116372428881158","isMergeCommit":true,"messageTitle":"Merge pull request #93 from KenCheung18/Storage-function","messageBody":"Storage function","fileTypesAndContributionMap":{}},{"hash":"26c32ef86ca87fb6f6602410781caa103fa14a10","isMergeCommit":false,"messageTitle":"Clear income function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":38,"deletions":4}}},{"hash":"8a55003d9fe93008935363b856988d29a4ec29a0","isMergeCommit":false,"messageTitle":"Clear expense function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":0}}},{"hash":"cfbc0c5c9c5c2ef4805199276fcf827ff906dd42","isMergeCommit":false,"messageTitle":"Clear all and due with the user input","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":30,"deletions":0}}},{"hash":"2194afadd9dd4b1617ef8cbd65f4fa2b2a11ca61","isMergeCommit":true,"messageTitle":"Merge pull request #94 from KenCheung18/Clear-function","messageBody":"Clear function","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"89ad03ea042f3777bf018efe75838c4e3d533edc","isMergeCommit":false,"messageTitle":"Javadoc for clear expense class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":0}}},{"hash":"d3c68cf8dd447bca268780ceaf2d82c7418d0e27","isMergeCommit":false,"messageTitle":"javadoc for clear income class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":2}}},{"hash":"cddaafdf18b36955f4abd56100af401907d41ae9","isMergeCommit":false,"messageTitle":"javadoc for clear all class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":4}}}]},{"date":"2023-10-27","commitResults":[{"hash":"76c95157c2e101d5b2ea291f63d431c02a2157d6","isMergeCommit":false,"messageTitle":"Create DG for GetFromTxt","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":0}}},{"hash":"7dfba6bfa646fc484614a76326af86af8d7ab514","isMergeCommit":true,"messageTitle":"Merge pull request #107 from KenCheung18/Developer-Guide-GetFromTxt","messageBody":"Create DG for GetFromTxt","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"77f3ccb1abc5bdab5eba90b385c25ed45f981a2b","isMergeCommit":false,"messageTitle":"Add JUnit test for clear function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":114,"deletions":0}}},{"hash":"9224d26bfe0ffa5e388e68d3ffbfca5c5f10048d","isMergeCommit":false,"messageTitle":"JUnit test for all clear functions","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":99,"deletions":7}}},{"hash":"a5d5cf43575be5a476be60346aeceb04477d9451","isMergeCommit":false,"messageTitle":"JavaDoc comments for tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":9,"deletions":5}}},{"hash":"b0034c04efb4b1905313106f11c262cf1be951a0","isMergeCommit":false,"messageTitle":"JUnit test for saveToTextFile","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":195,"deletions":0}}},{"hash":"093b837ffd060a35e7b6fd30a8184e894b6d3bb9","isMergeCommit":false,"messageTitle":"Save to txt test bug fix","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":16,"deletions":16}}},{"hash":"dc07ee1721cf8225ff4cd9a31b14eb0aef48915e","isMergeCommit":false,"messageTitle":"JUnit test for getFromFTxt","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":168,"deletions":0}}},{"hash":"1b4d2168d5cea415ca6a081c41d88dfbadbeced9","isMergeCommit":false,"messageTitle":"Bug fix on JUnit test for clear function","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":11,"deletions":9}}},{"hash":"c037720844d97d9b17088cdf3bac60725af90a82","isMergeCommit":false,"messageTitle":"Change back","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"db21169e24ebc3852becf549da1448763e314561","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JUnit-test-for-clear-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2379ef9e6fbfd090339e126b14958d04fdcc2845","isMergeCommit":false,"messageTitle":"Changes to the JUnit test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":10,"deletions":6}}},{"hash":"b41f976e47a1161454d0940c7c58df851e651069","isMergeCommit":false,"messageTitle":"Bug Fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"2b926cdd1dac78fc1d77d50a5b43f977d8aad043","isMergeCommit":true,"messageTitle":"Merge branch \u0027JUnit-test-for-clear-function\u0027 of https://github.com/KenCheung18/tp into JUnit-test-for-clear-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d8bb04396d9eec5473f12831e53b9823cb292744","isMergeCommit":true,"messageTitle":"Merge pull request #117 from KenCheung18/JUnit-test-for-Storage","messageBody":"JUnit test for storage","fileTypesAndContributionMap":{}},{"hash":"cb8d827a79b4493642442ad5e2b1513a58e3ce57","isMergeCommit":false,"messageTitle":"Bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"52b40ea3d0e7b128528ec1f525dbbbe978991f75","isMergeCommit":true,"messageTitle":"Merge pull request #115 from KenCheung18/JUnit-test-for-clear-function","messageBody":"J unit test for clear function","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"9ceaf1dd39d6ca49663c42f6395871921b2052bf","isMergeCommit":false,"messageTitle":"Add user guide and minor change to the Usage Instructions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":6},"docs":{"insertions":18,"deletions":3}}},{"hash":"0d0dd72dc381cb5c687c35fe6a1badce35480c2a","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into User-guide-and-add-new-content-on-help-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"e161409382108b4fcd7ece3ae78fb9d2292c02a5","isMergeCommit":true,"messageTitle":"Merge branch \u0027User-guide-and-add-new-content-on-help-function\u0027 of https://github.com/KenCheung18/tp into User-guide-and-add-new-content-on-help-function","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"c8fbcceac4ea92f4849d589cc9ffe5c88e6a3d50","isMergeCommit":true,"messageTitle":"Merge pull request #123 from KenCheung18/User-guide-and-add-new-content-on-help-function","messageBody":"Add user guide and minor change to the Usage Instructions","fileTypesAndContributionMap":{}},{"hash":"8243f1b1b244f91e9d2fa73aeaf729221b08598e","isMergeCommit":false,"messageTitle":"Change to developer guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":0}}},{"hash":"e6e3dd6a2ac40e62f50a7b95d312e02d729e7d92","isMergeCommit":true,"messageTitle":"Merge pull request #125 from KenCheung18/Developer-guide-changes","messageBody":"Change to developer guide","fileTypesAndContributionMap":{}},{"hash":"cc4cffd2d86c646768194f84f0c1b2e72586f3db","isMergeCommit":false,"messageTitle":"help function update for currency update","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"cf9b01c8a4b0f39204065b62d07c3bf8fa272687","isMergeCommit":false,"messageTitle":"change to test-ui-test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"01f93937f3d4d507e268a9fdf1d669c9595fc671","isMergeCommit":false,"messageTitle":"bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"4400e4efb109faf83a0bf188fcb764fdd5b24c5a","isMergeCommit":true,"messageTitle":"Merge pull request #132 from KenCheung18/help-function-update","messageBody":"Help function update","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"169b8d750e0eacdad1107bf115150e5c5961c880","isMergeCommit":false,"messageTitle":"DG fix","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":8}}},{"hash":"17e05bc61d623f55c63e37259ca7daa85c8d6dd2","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into DG-fix","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a3a88020755f643e2676d8f0afda3e565a99f1d1","isMergeCommit":true,"messageTitle":"Merge pull request #135 from KenCheung18/DG-fix","messageBody":"DG fix","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"limyuhching":{"docs":114,"functional-code":684,"test-code":415},"bljhty":{"docs":230,"functional-code":1291,"test-code":1921,"other":5},"Hongzhii":{"docs":46,"functional-code":428,"test-code":94},"KenCheung18":{"docs":46,"functional-code":435,"test-code":579}},"authorContributionVariance":{"limyuhching":9886.137,"bljhty":69998.68,"Hongzhii":2722.5894,"KenCheung18":12667.116},"authorDisplayNameMap":{"limyuhching":"CS2113-T18-3 LIM ..HING","bljhty":"CS2113-T18-3 LEE ..RYAN","Hongzhii":"CS2113-T18-3 EE H.. ZHI","KenCheung18":"CS2113-T18-3 CHEU..YUEN"}} diff --git a/AY2324S1-CS2113T-W11-1_tp_master/authorship.json b/AY2324S1-CS2113T-W11-1_tp_master/authorship.json index 317f460..15d5618 100644 --- a/AY2324S1-CS2113T-W11-1_tp_master/authorship.json +++ b/AY2324S1-CS2113T-W11-1_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" mainClass.set(\"seedu.syslib.Syslib\")","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"-"},"content":" archiveBaseName.set(\"duke\")","lastModifiedDate":"2023-09-24"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"000verflow":1,"-":45,"yingx9":1}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"|-------------------------------------------------------------------------|:-------------:|:-----------------------------------------:|:--------------------------------:|","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"| ![yingxia_portfolio.jpg](team/pictures/yingxia_portfolio.jpg) | Loke Ying Xia | [Github](https://github.com/yingx9) | [Portfolio](team/YingXia.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"| ![benjaminng_portfolio.jpeg](team/pictures/benjaminng_portfolio.jpeg) | Benjamin Ng | [Github](https://github.com/bnjm2000) | [Portfolio](team/BenjaminNg.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":"| ![joanneang_portfolio.jpg](team/pictures/joanneang_portfolio.jpg) | Joanne Ang | [Github](https://github.com/JoanneJo) | [Portfolio](team/JoanneAng.md) |","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"| ![ashokbalaji_portfolio.jpg](./team/pictures/ashokbalaji_portfolio.jpg) | Ashok Balaji | [Github](https://github.com/000verflow) | [Portfolio](team/ashokbalaji.md) |","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"| ![wuxingyu_protfolio.jpeg](./team/pictures/wuxingyu_portfolio.jpeg) | Wu Xingyu | [Github](https://github.com/DavinciDelta) | [Portfolio](team/WuXingyu.md) |","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"bnjm2000":2,"JoanneJo":2,"DavinciDelta":1,"-":1,"yingx9":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"## Setting Up \u0026 Getting Started","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"1. Fork the repo at https://github.com/AY2324S1-CS2113T-W11-1/tp.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"2. Clone the fork into your computer.","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"## Design \u0026 Implementation","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":"{Describe the design and implementation of the product. Use UML diagrams and short code snippets where applicable.}","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"### Architecture","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"\u003cimg src\u003d\"images/ArchitectureDiagram.png\" /\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"**Main components of SysLib Architecture**","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"SysLib currently consists of five main components:","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"- `UI`: User Interaction","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"- `Parser`: Parsing User Response ","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"- `Command`: Command Executor","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"- `Data`: Holds the data of SysLib in memory such as the Resource List","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"- `Storage`: Loads data from file in hard disk, and saves data to hard disk on program exit","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":" ","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"### UI Component","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"### Parser Component","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":"### Command Component","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"### Data Component","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":"### Storage Component","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"## Implementation ","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":"This section provides details on how certain features are implemented. ","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"### Find Resource Feature","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":"The `find` command allows users to search for resources based on specified filters such as author (`/a`), ISBN (`/i`), ID (`/id`), and title (`/t`). The results will show all resources that match any of the given filters.","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":"\u003e For non-book resources, `author` refers to `publisher`,`creator` and `brand` for Newspapers, CD\u0027s and Magazines","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"\u003e respectively.","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":"`find` has the following options:","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":"- `find /id [ID]`","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":"- `find /t [TITLE]`","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":"- `find /a [AUTHOR]`","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"- `find /i [ISBN]`","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"Multiple filters can also be combined:","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":"- `find /t [TITLE] /a [AUTHOR]`","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":"#### Implementation","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":"Upon receiving the `find` command, the system will:","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":"1. Parse the filters and their associated values.","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":"2. Filter the resources based on the given filters.","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":"3. Display the matching resources.","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":"**Step 1.** The user inputs the command: `find /a \"F. Scott Fitzgerald\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":"**Step 2.** The `UI` component forwards the input to `SYSLIB`, which then sends it to the `PARSER`.","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":"**Step 3.** The `PARSER` processes the command, extracts the `author` filter, and retrieves all resources written by \"F. Scott Fitzgerald\".","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":"**Step 4.** The matching resources are displayed to the user.","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":"#### Sequence Diagram","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":"\u003cimg src\u003d\"images/FindSequenceDiagram.png\" /\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":"### Examples for Testing","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":"1. **Find by Author**","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":" - Test case: `find /a \"F. Scott Fitzgerald\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" Expected: All resources written by F. Scott Fitzgerald are displayed.","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":"2. **Find by ISBN**","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":" - Test case: `find /i \"9780061120084\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" Expected: The resource with ISBN \"9780061120084\" is displayed, which should be \"To Kill a Mockingbird\" by Harper Lee.","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":"3. **Find by ID**","lastModifiedDate":"2023-10-27"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" - Test case: `find /id 2`","lastModifiedDate":"2023-10-27"},{"lineNumber":100,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":" Expected: The resource with ID \"2\" is displayed, which should be \"To Kill a Mockingbird\" by Harper Lee.","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":"4. **Find by Title**","lastModifiedDate":"2023-10-27"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" - Test case: `find /t \"The Great Gatsby\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":106,"author":{"gitId":"000verflow"},"content":" Expected: The resource titled \"The Great Gatsby\" is displayed.","lastModifiedDate":"2023-10-27"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":"5. **Combining Filters**","lastModifiedDate":"2023-10-27"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" - Test case: `find /a \"F. Scott Fitzgerald\" /t \"The Great Gatsby\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":" Expected: Resources that match both the title \"The Great Gatsby\" and the author \"F. Scott Fitzgerald\" are displayed.","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":"### Add Resource Feature","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":"The `add` feature is responsible for processing user commands to add a new book to SysLib. It is facilitated by ","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":"the `AddCommand` component. It works with `Parser` and `Command` components to parse and validate the user input. ","lastModifiedDate":"2023-10-26"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":"The new book is stored internally in `resourceList` as a `Book`. ","lastModifiedDate":"2023-10-26"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":120,"author":{"gitId":"bnjm2000"},"content":"`add` has seven options:","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":"- add /id [id] /t [title] /a [author] /tag [tag] /i [isbn]","lastModifiedDate":"2023-10-26"},{"lineNumber":122,"author":{"gitId":"bnjm2000"},"content":"- add /id [id] /t [title] /a [author] /tag [tag] /i [isbn] _/g [genre] /s [status]_","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":"#### Implementation","lastModifiedDate":"2023-10-26"},{"lineNumber":125,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":126,"author":{"gitId":"JoanneJo"},"content":"It implements the following operations:","lastModifiedDate":"2023-10-26"},{"lineNumber":127,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":"- `ADDCOMMAND#parseArgument(statement: String)` -- Parses the input command to extract relevant information.","lastModifiedDate":"2023-10-26"},{"lineNumber":129,"author":{"gitId":"JoanneJo"},"content":"- `ADDCOMMAND#validate(statement: String, values: String[])` -- Validates the input statement to ensure that it is valid.","lastModifiedDate":"2023-10-26"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":"- `ADDCOMMAND#createBook(values: String[])` -- Creates a new book based on the parsed and validated values.","lastModifiedDate":"2023-10-26"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-10-26"},{"lineNumber":133,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":"Step 1. The user inputs the command: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-10-26"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":138,"author":{"gitId":"JoanneJo"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`add`). It then calls ","lastModifiedDate":"2023-10-26"},{"lineNumber":139,"author":{"gitId":"JoanneJo"},"content":"`ADDCOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-10-26"},{"lineNumber":140,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":141,"author":{"gitId":"JoanneJo"},"content":"Step 4. The `ADDCOMMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-10-26"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":"- Calls `ADDCOMMAND#parseArgument(statement: String)` to extract values for ID, title, author, ISBN, tag, and genres.","lastModifiedDate":"2023-10-26"},{"lineNumber":143,"author":{"gitId":"JoanneJo"},"content":"- Calls `ADDCOMMAND#validate(statement: String, values: String[])` to ensure the validity of the input command.","lastModifiedDate":"2023-10-26"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":145,"author":{"gitId":"JoanneJo"},"content":"Step 5. The `COMMAND` component processes the input command to ensure that it meets the required format and constraints.","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"JoanneJo"},"content":"It prepares the argument values for further processing.","lastModifiedDate":"2023-10-26"},{"lineNumber":147,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":148,"author":{"gitId":"JoanneJo"},"content":"Step 6. Since the `tag` argument in the input command indicates that it is a book, the `ADDCOMMAND` determines that the","lastModifiedDate":"2023-10-26"},{"lineNumber":149,"author":{"gitId":"JoanneJo"},"content":"key is equal to `b` (ignoring case). It then creates a new `Book` object using the parsed values (title, ISBN, author, ","lastModifiedDate":"2023-10-26"},{"lineNumber":150,"author":{"gitId":"JoanneJo"},"content":"genres, ID).","lastModifiedDate":"2023-10-26"},{"lineNumber":151,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":152,"author":{"gitId":"JoanneJo"},"content":"Step 7. The newly created book is forwarded to the `PARSER` to be added to the `resourceList`.","lastModifiedDate":"2023-10-26"},{"lineNumber":153,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"JoanneJo"},"content":"#### Sequence Diagram","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"JoanneJo"},"content":"The following sequence diagram shows how the add function works:","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"JoanneJo"},"content":"\u003cimg src\u003d\"images/AddSequenceDiagram.png\"/\u003e","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":"### Listing Resources Feature","lastModifiedDate":"2023-10-25"},{"lineNumber":159,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":160,"author":{"gitId":"yingx9"},"content":"The `list` command works with the `Parser` and `Command` component to execute the correct action. ","lastModifiedDate":"2023-10-25"},{"lineNumber":161,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":162,"author":{"gitId":"yingx9"},"content":"`list` has four options:","lastModifiedDate":"2023-10-25"},{"lineNumber":163,"author":{"gitId":"yingx9"},"content":"- list","lastModifiedDate":"2023-10-25"},{"lineNumber":164,"author":{"gitId":"yingx9"},"content":"- list _/tag [tag]_","lastModifiedDate":"2023-10-25"},{"lineNumber":165,"author":{"gitId":"yingx9"},"content":"- list _/g [genre]_","lastModifiedDate":"2023-10-25"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":"- list _/tag [tag]_ _/g [genre]_","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":168,"author":{"gitId":"yingx9"},"content":"When `list` is specified with both `tag` and `genre` filters, it is `AND` inclusive, listing only ","lastModifiedDate":"2023-10-25"},{"lineNumber":169,"author":{"gitId":"yingx9"},"content":"Resources with the same tag and genre. ","lastModifiedDate":"2023-10-25"},{"lineNumber":170,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":171,"author":{"gitId":"yingx9"},"content":"Sequence Diagram:","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":173,"author":{"gitId":"yingx9"},"content":"\u003cimg src\u003d\"images/ListSequenceDiagram.png\" /\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"yingx9"},"content":"When a user enters `list /tag B`, the Parser retrieves the parameters from the input and","lastModifiedDate":"2023-10-26"},{"lineNumber":176,"author":{"gitId":"yingx9"},"content":"calls the `execute` function of ListCommand.","lastModifiedDate":"2023-10-26"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":"ListCommand then calls `parseArg` and `validate` from `Command`, which checks if the parameters are valid. If it passes","lastModifiedDate":"2023-10-26"},{"lineNumber":179,"author":{"gitId":"yingx9"},"content":"the checks, `filterResources` is called to begin the filtering process. First it calls `hasFilters()` check if the user ","lastModifiedDate":"2023-10-26"},{"lineNumber":180,"author":{"gitId":"yingx9"},"content":"selected any filters `[tag/genre/both]` or none. ","lastModifiedDate":"2023-10-26"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":182,"author":{"gitId":"yingx9"},"content":"If hasFilters returns `true`, it filters the `resourceList` with the given keywords and display the details ","lastModifiedDate":"2023-10-26"},{"lineNumber":183,"author":{"gitId":"yingx9"},"content":"of the resources.","lastModifiedDate":"2023-10-26"},{"lineNumber":184,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":185,"author":{"gitId":"yingx9"},"content":"If hasFilters returns `false`, it skips the filtering process and displays the details of all the resources.","lastModifiedDate":"2023-10-26"},{"lineNumber":186,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":187,"author":{"gitId":"DavinciDelta"},"content":"### Event Add Feature","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"DavinciDelta"},"content":"The `eventadd` feature is responsible for processing user commands to add an event to SysLib. It is facilitated by","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"DavinciDelta"},"content":"the `EventAddCommand` component. It works with `Parser` and `Command` components to parse and validate the user input.","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"DavinciDelta"},"content":"The new book is stored internally in `eventList` as a `Event`.","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"DavinciDelta"},"content":"`eventadd` has two options:","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"DavinciDelta"},"content":"- eventadd /t [title] /date [date]","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"DavinciDelta"},"content":"- eventadd /t [title] /date [date] /desc [description]","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"DavinciDelta"},"content":"#### Implementation","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"DavinciDelta"},"content":"It implements the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTADDCOMMAND#parseArgument(statement: String)` -- Parses the input command to extract relevant information.","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTADDCOMMAND#validate(statement: String, values: String[])` -- Validates the input statement to ensure that it is valid.","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTADDCOMMAND#binarySearch(parser: Parser, date: Date)` -- Search for the correct index of event list to add the event.","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"DavinciDelta"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"DavinciDelta"},"content":"Step 1. The user inputs the command: `eventadd /t birthday /date 10-12-2001`","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"DavinciDelta"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"DavinciDelta"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`eventadd`). It then calls","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"DavinciDelta"},"content":"`EVENTADDCOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"DavinciDelta"},"content":"Step 4. The `EVENTADDCOMMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTADDCOMMAND#parseArgument(statement: String)` to extract values for title, date and description.","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTADDCOMMAND#validate(statement: String, values: String[])` to ensure the validity of the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"DavinciDelta"},"content":"Step 5. The `COMMAND` component processes the input command to ensure that it meets the required format and constraints.","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"DavinciDelta"},"content":"It prepares the argument values for further processing.","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"DavinciDelta"},"content":"Step 6. The `EVENTADDCOMMMAND` also calls the component:","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTADDCOMMAND#binarySearch(parser: Parser, date: Date)` to find the correct index based on the date.","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"DavinciDelta"},"content":"The whole eventList is sorted by date order.","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"DavinciDelta"},"content":"Step 7. The newly created event is forwarded to the `PARSER` to be added to the `eventList`.","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"DavinciDelta"},"content":"### Event List Feature","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"DavinciDelta"},"content":"The `eventlist` command works with the `Parser` and `Command` component to execute the correct action. ","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"DavinciDelta"},"content":"This feature is responsible for listing out the events in eventList. ","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"DavinciDelta"},"content":"It is facilitated by the `EventListCommand` component. ","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"DavinciDelta"},"content":"`eventlist` has one option:","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"DavinciDelta"},"content":"- eventlist","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"DavinciDelta"},"content":"#### Implementation","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"DavinciDelta"},"content":"It implements the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTLISTCOMMAND#isEmpty()` -- Check user input has only \u0027eventlist\u0027","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"DavinciDelta"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"DavinciDelta"},"content":"Step 1. The user inputs the command: `eventlist`","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":246,"author":{"gitId":"DavinciDelta"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-11-01"},{"lineNumber":247,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":248,"author":{"gitId":"DavinciDelta"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`eventlist`). It then calls","lastModifiedDate":"2023-11-01"},{"lineNumber":249,"author":{"gitId":"DavinciDelta"},"content":"`EVENTLISTCOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":250,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":251,"author":{"gitId":"DavinciDelta"},"content":"Step 4. The `EVENTLISTCOMMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":252,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTLISTCOMMAND#isEmpty()` to check if the user input any additional redundant arguments.","lastModifiedDate":"2023-11-01"},{"lineNumber":253,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":254,"author":{"gitId":"DavinciDelta"},"content":"Step 5. The `EVENTLISTCOMMAND` then outputs the events in the eventList.","lastModifiedDate":"2023-11-01"},{"lineNumber":255,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":256,"author":{"gitId":"DavinciDelta"},"content":"### Event Delete Feature","lastModifiedDate":"2023-11-01"},{"lineNumber":257,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":258,"author":{"gitId":"DavinciDelta"},"content":"The `eventdelete` feature is responsible for processing user commands to delete an event to SysLib. ","lastModifiedDate":"2023-11-01"},{"lineNumber":259,"author":{"gitId":"DavinciDelta"},"content":"It is facilitated by the `EventDeleteCommand` component. ","lastModifiedDate":"2023-11-01"},{"lineNumber":260,"author":{"gitId":"DavinciDelta"},"content":"It works with `Parser` and `Command` components to parse and validate the input.","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"DavinciDelta"},"content":"The `Event` is removed from `eventList`.","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"DavinciDelta"},"content":"`eventadd` has one options:","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"DavinciDelta"},"content":"- eventdelete /i [index]","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"DavinciDelta"},"content":"#### Implementation","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"DavinciDelta"},"content":"It implements the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":269,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTDELETECOMMAND#parseArgument(statement: String)` -- Parses the input command to extract relevant information.","lastModifiedDate":"2023-11-01"},{"lineNumber":270,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTDELETECOMMAND#validate(statement: String, values: String[])` -- Validates the input statement.","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTDELETECOMMAND#parseCalendarInt(value: String, parser: Parser)` -- Validate the index given.","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"DavinciDelta"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"DavinciDelta"},"content":"Step 1. The user inputs the command: `eventdelete /i 0`","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"DavinciDelta"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":279,"author":{"gitId":"DavinciDelta"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`eventadd`). It then calls","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"DavinciDelta"},"content":"`EVENTDELETECOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":282,"author":{"gitId":"DavinciDelta"},"content":"Step 4. The `EVENTDELETECOMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":283,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTDELETECOMMAND#parseArgument(statement: String)` to extract values for title, date and description.","lastModifiedDate":"2023-11-01"},{"lineNumber":284,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTDELETECOMMAND#validate(statement: String, values: String[])` to ensure the validity of the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":285,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":286,"author":{"gitId":"DavinciDelta"},"content":"Step 5. The `COMMAND` component processes the input command to ensure that it meets the required format and constraints.","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"DavinciDelta"},"content":"It prepares the argument values for further processing.","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"DavinciDelta"},"content":"Step 6. The `EVENTDELETECOMMAND` also calls the component:","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTDELETECOMMAND#parseCalendarInt(value: String, parser: Parser)` to see if the index is an integer and that","lastModifiedDate":"2023-11-01"},{"lineNumber":291,"author":{"gitId":"DavinciDelta"},"content":"it is within range of eventList","lastModifiedDate":"2023-11-01"},{"lineNumber":292,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"DavinciDelta"},"content":"Step 7. The selected event at the index is then deleted from the eventList.","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":296,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":297,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":298,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":299,"author":{"gitId":"DavinciDelta"},"content":"All librarians, not just system librarian!","lastModifiedDate":"2023-10-24"},{"lineNumber":300,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":301,"author":{"gitId":"JoanneJo"},"content":"- Needs to manage inventory with significant number of resources e.g. books","lastModifiedDate":"2023-10-26"},{"lineNumber":302,"author":{"gitId":"JoanneJo"},"content":"- Is a fast typist","lastModifiedDate":"2023-10-26"},{"lineNumber":303,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":304,"author":{"gitId":"JoanneJo"},"content":"### Value Proposition","lastModifiedDate":"2023-10-26"},{"lineNumber":305,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":306,"author":{"gitId":"DavinciDelta"},"content":"To provide a platform to help librarians to quickly find the information they need to assist patrons.","lastModifiedDate":"2023-10-24"},{"lineNumber":307,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":308,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":309,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":310,"author":{"gitId":"-"},"content":"| Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2020-05-24"},{"lineNumber":311,"author":{"gitId":"bnjm2000"},"content":"|---------|-----------|--------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-26"},{"lineNumber":312,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | view a list of books that the library has | have an overview of all the books |","lastModifiedDate":"2023-10-24"},{"lineNumber":313,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | add new books to our inventory by entering their title, author, ISBN, and publication year | keep our collection up-to-date |","lastModifiedDate":"2023-10-24"},{"lineNumber":314,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | delete books from the database | let the patrons know our library no longer carries it |","lastModifiedDate":"2023-10-24"},{"lineNumber":315,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | tag a book as physical medium like newspapers, audio cds, books or online like eJournals | patrons can know what type are available |","lastModifiedDate":"2023-10-24"},{"lineNumber":316,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | have a help function | know the commands of this programme |","lastModifiedDate":"2023-10-24"},{"lineNumber":317,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | quickly find out how many books we have of a particular author and the names of the books | know how many books are related to the author |","lastModifiedDate":"2023-10-24"},{"lineNumber":318,"author":{"gitId":"bnjm2000"},"content":"| v2.0 | librarian | import/export our library\u0027s inventory data to a file format | easily share with other libraries to be used for backup and archival purposes. |","lastModifiedDate":"2023-10-26"},{"lineNumber":319,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | find a to-do item by name | locate a to-do without having to go through the entire list |","lastModifiedDate":"2023-10-27"},{"lineNumber":320,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | get the status of an item | know if it is available |","lastModifiedDate":"2023-10-27"},{"lineNumber":321,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | update the details of a resource | fix any mistakes and maintain consistency |","lastModifiedDate":"2023-10-27"},{"lineNumber":322,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | add in different types of resources | differentiate between resources such as magazines, cds... |","lastModifiedDate":"2023-10-27"},{"lineNumber":323,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":324,"author":{"gitId":"JoanneJo"},"content":"## Use Cases","lastModifiedDate":"2023-10-26"},{"lineNumber":325,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":326,"author":{"gitId":"JoanneJo"},"content":"(For all use cases below, the System is the SysLib and the Actor is the user, unless specified otherwise)","lastModifiedDate":"2023-10-26"},{"lineNumber":327,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":328,"author":{"gitId":"JoanneJo"},"content":"### Use case: Add a book","lastModifiedDate":"2023-10-26"},{"lineNumber":329,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":330,"author":{"gitId":"JoanneJo"},"content":"#### MSS","lastModifiedDate":"2023-10-26"},{"lineNumber":331,"author":{"gitId":"JoanneJo"},"content":"1. User requests to add a book","lastModifiedDate":"2023-10-26"},{"lineNumber":332,"author":{"gitId":"JoanneJo"},"content":"2. AddressBook adds the book","lastModifiedDate":"2023-10-26"},{"lineNumber":333,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":334,"author":{"gitId":"JoanneJo"},"content":" Use case ends.","lastModifiedDate":"2023-10-26"},{"lineNumber":335,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":336,"author":{"gitId":"JoanneJo"},"content":"#### Extensions","lastModifiedDate":"2023-10-26"},{"lineNumber":337,"author":{"gitId":"JoanneJo"},"content":"- 1a. The given ID is invalid.","lastModifiedDate":"2023-10-26"},{"lineNumber":338,"author":{"gitId":"JoanneJo"},"content":" - 1a1. SysLib shows an error message.","lastModifiedDate":"2023-10-26"},{"lineNumber":339,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":340,"author":{"gitId":"JoanneJo"},"content":" Use case ends.","lastModifiedDate":"2023-10-26"},{"lineNumber":341,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":342,"author":{"gitId":"JoanneJo"},"content":"- 1b. Insufficient data given.","lastModifiedDate":"2023-10-26"},{"lineNumber":343,"author":{"gitId":"JoanneJo"},"content":" - 1b1. SysLib shows an error message.","lastModifiedDate":"2023-10-26"},{"lineNumber":344,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":345,"author":{"gitId":"JoanneJo"},"content":" Use case ends.","lastModifiedDate":"2023-10-26"},{"lineNumber":346,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":347,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":348,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":349,"author":{"gitId":"-"},"content":"{Give non-functional requirements}","lastModifiedDate":"2020-05-24"},{"lineNumber":350,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":351,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":352,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":353,"author":{"gitId":"-"},"content":"* *glossary item* - Definition","lastModifiedDate":"2020-05-24"},{"lineNumber":354,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":355,"author":{"gitId":"JoanneJo"},"content":"## Instructions for Manual Testing","lastModifiedDate":"2023-10-26"},{"lineNumber":356,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":357,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":358,"author":{"gitId":"bnjm2000"},"content":"help","lastModifiedDate":"2023-10-26"},{"lineNumber":359,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":360,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":361,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":362,"author":{"gitId":"bnjm2000"},"content":"Commands available:","lastModifiedDate":"2023-10-26"},{"lineNumber":363,"author":{"gitId":"bnjm2000"},"content":"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE])","lastModifiedDate":"2023-10-26"},{"lineNumber":364,"author":{"gitId":"bnjm2000"},"content":"delete: deletes the resource with the specified ID from the library inventory. (e.g. delete /id 123456789)","lastModifiedDate":"2023-10-26"},{"lineNumber":365,"author":{"gitId":"bnjm2000"},"content":"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction","lastModifiedDate":"2023-10-26"},{"lineNumber":366,"author":{"gitId":"bnjm2000"},"content":"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)","lastModifiedDate":"2023-10-26"},{"lineNumber":367,"author":{"gitId":"bnjm2000"},"content":"edit: Edit a listing by entering its isbn to update its details. (e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)","lastModifiedDate":"2023-10-30"},{"lineNumber":368,"author":{"gitId":"bnjm2000"},"content":"exit: displays a farewell message and exits the program (e.g. exit)","lastModifiedDate":"2023-10-26"},{"lineNumber":369,"author":{"gitId":"bnjm2000"},"content":"For more information, please refer to our user guide at:https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html","lastModifiedDate":"2023-10-26"},{"lineNumber":370,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":371,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":372,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":373,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":374,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":375,"author":{"gitId":"bnjm2000"},"content":"add /id 1 /t The Great Gatsby /a F. Scott Fitzgerald /tag B /i 9780023381201 /g Novel, Fiction, Tragedy /s lost","lastModifiedDate":"2023-10-30"},{"lineNumber":376,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":377,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":378,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":379,"author":{"gitId":"bnjm2000"},"content":"This book is added: The Great Gatsby","lastModifiedDate":"2023-10-26"},{"lineNumber":380,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":381,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":382,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":383,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":384,"author":{"gitId":"bnjm2000"},"content":"add /id 2 /t To Kill a Mockingbird /a Harper Lee /tag B /i 9780061120084 /g Novel, Bildungsroman, Southern Gothic, Domestic Fiction, Thriller, Legal Story","lastModifiedDate":"2023-10-26"},{"lineNumber":385,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":386,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":387,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":388,"author":{"gitId":"bnjm2000"},"content":"This book is added: To Kill a Mockingbird","lastModifiedDate":"2023-10-26"},{"lineNumber":389,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":390,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":391,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":392,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":393,"author":{"gitId":"bnjm2000"},"content":"list","lastModifiedDate":"2023-10-26"},{"lineNumber":394,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":395,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":396,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":397,"author":{"gitId":"bnjm2000"},"content":"Listing all resources in the Library:","lastModifiedDate":"2023-10-26"},{"lineNumber":398,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":399,"author":{"gitId":"bnjm2000"},"content":"1. [B] ID: 1 Title: The Great Gatsby ISBN: 9780023381201 Author: F. Scott Fitzgerald Genre: Novel, Fiction, Tragedy Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":400,"author":{"gitId":"bnjm2000"},"content":"2. [B] ID: 2 Title: To Kill a Mockingbird ISBN: 9780061120084 Author: Harper Lee Genre: Novel, Bildungsroman, Southern Gothic Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":401,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":402,"author":{"gitId":"bnjm2000"},"content":"There are currently 2 resource(s).","lastModifiedDate":"2023-10-26"},{"lineNumber":403,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":404,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":405,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":406,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":407,"author":{"gitId":"bnjm2000"},"content":"delete /id 1","lastModifiedDate":"2023-10-26"},{"lineNumber":408,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":409,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":410,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":411,"author":{"gitId":"bnjm2000"},"content":"Looking for ID: 1...","lastModifiedDate":"2023-10-26"},{"lineNumber":412,"author":{"gitId":"bnjm2000"},"content":"This resource is removed: ","lastModifiedDate":"2023-10-26"},{"lineNumber":413,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 1 Title: The Great Gatsby ISBN: 9780023381201 Author: F. Scott Fitzgerald Genre: Novel, Fiction, Tragedy Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":414,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":415,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":416,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":417,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":418,"author":{"gitId":"bnjm2000"},"content":"exit","lastModifiedDate":"2023-10-26"},{"lineNumber":419,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":420,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":421,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":422,"author":{"gitId":"bnjm2000"},"content":"Bye, hope to see you again soon!","lastModifiedDate":"2023-10-26"},{"lineNumber":423,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":424,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":425,"author":{"gitId":"JoanneJo"},"content":"### Launch and Shutdown","lastModifiedDate":"2023-10-26"},{"lineNumber":426,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":427,"author":{"gitId":"JoanneJo"},"content":"1. Initial launch","lastModifiedDate":"2023-10-26"},{"lineNumber":428,"author":{"gitId":"JoanneJo"},"content":" 1. Download the jar file and copy it into an empty folder.","lastModifiedDate":"2023-10-26"},{"lineNumber":429,"author":{"gitId":"JoanneJo"},"content":" 2. Open the command prompt and run `java -jar SysLib.jar`.","lastModifiedDate":"2023-10-26"},{"lineNumber":430,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":431,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":432,"author":{"gitId":"JoanneJo"},"content":"### Adding a Book","lastModifiedDate":"2023-10-26"},{"lineNumber":433,"author":{"gitId":"JoanneJo"},"content":"1. Add a book","lastModifiedDate":"2023-10-26"},{"lineNumber":434,"author":{"gitId":"JoanneJo"},"content":" 1. Test case: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B`","lastModifiedDate":"2023-10-26"},{"lineNumber":435,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":436,"author":{"gitId":"JoanneJo"},"content":" Expected: A book with ID: 0005, Title: Frankenstein, Author: Mary Shelley, and ISBN: FKS0001 is created and added ","lastModifiedDate":"2023-10-26"},{"lineNumber":437,"author":{"gitId":"JoanneJo"},"content":" into the list. A message is shown to acknowledge that the book has been added successfully.","lastModifiedDate":"2023-10-26"},{"lineNumber":438,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":439,"author":{"gitId":"JoanneJo"},"content":" 2. Test case: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":440,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":441,"author":{"gitId":"JoanneJo"},"content":" Expected: A book with ID: 0005, Title: Frankenstein, Author: Mary Shelley, ISBN: FKS0001, and ","lastModifiedDate":"2023-10-26"},{"lineNumber":442,"author":{"gitId":"JoanneJo"},"content":" Genres: Gothic, Fiction is created and added into the list. A message is shown to acknowledge that the book ","lastModifiedDate":"2023-10-26"},{"lineNumber":443,"author":{"gitId":"JoanneJo"},"content":" has been added successfully.","lastModifiedDate":"2023-10-26"},{"lineNumber":444,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":445,"author":{"gitId":"JoanneJo"},"content":" 3. Test case: `add /id abcd /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":446,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":447,"author":{"gitId":"JoanneJo"},"content":" Expected: No book is added. An error message is shown to indicate that the id is invalid.","lastModifiedDate":"2023-10-26"},{"lineNumber":448,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":449,"author":{"gitId":"JoanneJo"},"content":" 4. Test case: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag A /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":450,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":451,"author":{"gitId":"JoanneJo"},"content":" Expected: No book is added. An error message is shown to indicate that the tag is invalid.","lastModifiedDate":"2023-10-26"},{"lineNumber":452,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":453,"author":{"gitId":"JoanneJo"},"content":" 5. Test case: `add /id 0005 /t Frankenstein`","lastModifiedDate":"2023-10-26"},{"lineNumber":454,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":455,"author":{"gitId":"JoanneJo"},"content":" Expected: No book is added. An error message is shown to indicate that the input is incomplete.","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"000verflow":71,"bnjm2000":73,"JoanneJo":105,"DavinciDelta":115,"-":31,"yingx9":60}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"# Syslib","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"SysLib CLI is a robust command-line tool designed for system librarians to efficiently handle inventory, events, and patron assistance. With quick command-based actions, manage your library\u0027s resources and events seamlessly. Simplify administrative tasks, so you can focus on serving patrons better.","lastModifiedDate":"2023-10-14"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":6,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"bnjm2000":3,"-":6}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"# Syslib User guide","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"SysLib is a program designed specially for system librarians to manage their work and responsibilities. Using intuitive commands, view, add, delete, and find books from the library inventory without any hassle.","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"This user guide is for System Librarians to ensure optimal use of Syslib","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"## Contents","lastModifiedDate":"2023-10-06"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"* [Quick start](#quick-start--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"* [Features](#features--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":" * [Add a listing: `add`](#add-a-listing-add--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":" * [Delete a listing: `delete`](#delete-a-listing-delete--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":" * [List items: `list`](#list-all-items-list--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":" * [Find listing by search parameter: `find`](#find-specific-listings-find--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" * [Edit a listing: `edit`](#edit-a-listing-edit--return-to-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" * [Events](#events--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" * [Event adding: `eventadd`](#event-adding-eventadd--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" * [Event listing: `eventlist`](#event-listing-eventlist--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" * [Event delete: `eventdelete`](#event-delete-eventdelete--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":" * [Exiting the program : `exit`](#exiting-the-program--exit--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" * [Get help: `help`](#viewing-help--help--return-to-contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"* [FAQ](#faq--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"* [Known Issues](#known-issues--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"* [Command summary](#command-summary--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":"## Quick start | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":"1. Make sure that you have Java 11 or above installed on your computer.","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" - Open terminal and type `java --version`","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" - [How do I check the version of my Java](https://www.java.com/en/download/help/version_manual.html)","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":"2. [Download the latest release](https://github.com/AY2324S1-CS2113T-W11-1/tp/releases/tag/v1.0) of `Syslib.jar`","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"3. Copy the `Syslib.jar` file into a folder on its own.","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":"4. Open a command terminal, type `cd \u003cFILE_DIRECTORY\u003e`, where \u003cFILE_DIRECTORY\u003e refers to the directory to the `Syslib.jar` file.","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"5. Run the following command: `java -jar Syslib.jar`. You should see the following welcome screen.","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" ____ _ _ _ ____ _ ___ ","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":"/ ___| _ _ ___| | (_) |__ / ___| | |_ _|","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":"\\___ \\| | | / __| | | | \u0027_ \\ | | | | | | ","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" ___) | |_| \\__ \\ |___| | |_) | | |___| |___ | | ","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":"|____/ \\__, |___/_____|_|_.__/ \\____|_____|___|","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" |___/ ","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":"What would you like to do?","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"## Features | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"\u003e Note:","lastModifiedDate":"2023-10-06"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":"\u003e - Items in square brackets `[]` are optional arguments.","lastModifiedDate":"2023-10-06"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":"\u003e - Items with `...` after them can be used multiple times","lastModifiedDate":"2023-10-06"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" \u003e * e.g `[/g GENRE]` ... can be used as `/g Horror /g Fantasy`","lastModifiedDate":"2023-10-06"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":"\u003e - All resources and events in current list will be saved into an offline file \"storage.txt\" on exit.","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"\u003e - Resources and events from \"storage.txt\" will be loaded into the program at every start.","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":"## Add a listing: `add` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":"Adds a new resource to the library inventory.","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"#### Types of tags:","lastModifiedDate":"2023-10-06"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"`[B]` - Books","lastModifiedDate":"2023-10-06"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"`[CD]` - CDs","lastModifiedDate":"2023-10-06"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"`[M]` - Magazines","lastModifiedDate":"2023-10-06"},{"lineNumber":62,"author":{"gitId":"JoanneJo"},"content":"`[N]` - Newspapers","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":"\u003e Note:","lastModifiedDate":"2023-10-06"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":"\u003e - Anything with `e` prior is an electronic version ","lastModifiedDate":"2023-10-06"},{"lineNumber":66,"author":{"gitId":"JoanneJo"},"content":"\u003e i.e. `[eB]` is an eBook, `[eM]` is an eMagazine, `[eN]` is an eNewspaper","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"JoanneJo"},"content":"\u003e - Anything with `e` prior is an electronic version","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"JoanneJo"},"content":"\u003e i.e. `[eB]` is an eBook, `[eM]` is an eMagazine","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":70,"author":{"gitId":"JoanneJo"},"content":"### Add Book","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about genre:","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Multiple genres are allowed for a single resource. You can separate the different genres using comma followed by a space `, `.","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":74,"author":{"gitId":"bnjm2000"},"content":"Format: `add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]...`","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":76,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":78,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Moby Dick /a Herman Melville /tag B /i 9780763630188 /g Adventure, Fiction","lastModifiedDate":"2023-10-15"},{"lineNumber":79,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Harry Squatter /a J.K. /tag B /i 9780763630187 /g History /s lost","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":81,"author":{"gitId":"bnjm2000"},"content":"**Example response:**","lastModifiedDate":"2023-10-28"},{"lineNumber":82,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":83,"author":{"gitId":"bnjm2000"},"content":"This book is added: Moby Dick","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":87,"author":{"gitId":"JoanneJo"},"content":"### (NOTE: Addition of resources other than Book is only available in v2.1)","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":"### Add eBook","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about genre:","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Multiple genres are allowed for a single resource. You can separate the different genres using comma followed by a space `, `.","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN /l LINK [/g GENRE /s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Moby Dick /a Herman Melville /tag eB /i 9780763630188 /l abc.com /g Adventure, Fiction","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"JoanneJo"},"content":"This eBook is added: Moby Dick","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"JoanneJo"},"content":"### Add CD","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /c CREATOR /ty TYPE /tag TAG /i ISBN [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Moby Dick /c Herman Melville /ty Audio Book /tag CD /i 9780763630188 ","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":"This CD is added: Moby Dick","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":"### Add Magazine","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /b BRAND /is ISSUE /tag TAG /i ISBN [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t 2023 Hottest Trends /b Vogue /is AY23-01 /tag M /i 9780763630188 ","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"JoanneJo"},"content":"This magazine is added: 2023 Hottest Trends","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":"### Add eMagazine","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /b BRAND /is ISSUE /tag TAG /i ISBN /l LINK [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t 2023 Hottest Trends /b Vogue /is AY23-01 /tag eM /i 9780763630188 /l abc.com","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"JoanneJo"},"content":"This eMagazine is added: 2023 Hottest Trends","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":"### Add Newspaper","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /p PUBLISHER /ed EDITION /tag TAG /i ISBN [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Forbes 30 Under 30 2023 /p The Straits Times /ed AY23-30 /tag N /i 9780763630188","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"JoanneJo"},"content":"This newspaper is added: Forbes 30 Under 30 2023","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"JoanneJo"},"content":"### Add eNewspaper","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /p PUBLISHER /ed EDITION /tag TAG /i ISBN /l LINK [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Forbes 30 Under 30 2023 /p The Straits Times /ed AY23-30 /tag eN /i 9780763630188 /l abc.com","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"JoanneJo"},"content":"This eNewspaper is added: Forbes 30 Under 30 2023","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"bnjm2000"},"content":"## Delete a listing: `delete` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":171,"author":{"gitId":"bnjm2000"},"content":"Deletes the resource with the specified ID from the library inventory. You can find the ID using the `list` command.","lastModifiedDate":"2023-10-28"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":"Format: `delete /id ID`","lastModifiedDate":"2023-10-06"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":175,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":177,"author":{"gitId":"000verflow"},"content":"delete /id 123456789","lastModifiedDate":"2023-10-06"},{"lineNumber":178,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":179,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":181,"author":{"gitId":"bnjm2000"},"content":"Looking for ID: 123456789...","lastModifiedDate":"2023-10-28"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":"This resource is removed: ","lastModifiedDate":"2023-10-28"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 123456789 Title: Moby Dick ISBN: 9780763630188 Author: Herman Melville Genre: Adventure, Fiction Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":186,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":"## List all items: `list` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":"List all resources OR filter by certain tags or genre.","lastModifiedDate":"2023-10-28"},{"lineNumber":189,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":190,"author":{"gitId":"yingx9"},"content":"Format: `list [/tag TAG /g GENRE /s STATUS]`","lastModifiedDate":"2023-11-04"},{"lineNumber":191,"author":{"gitId":"yingx9"},"content":"- Including more than one filter will only list resources satisfying **ALL** given filters:","lastModifiedDate":"2023-11-04"},{"lineNumber":192,"author":{"gitId":"yingx9"},"content":" - Example: `list /tag B /g Horror` will list Books with Horror genre.","lastModifiedDate":"2023-11-04"},{"lineNumber":193,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":194,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":195,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":196,"author":{"gitId":"000verflow"},"content":"list","lastModifiedDate":"2023-10-06"},{"lineNumber":197,"author":{"gitId":"yingx9"},"content":"list /tag B","lastModifiedDate":"2023-10-16"},{"lineNumber":198,"author":{"gitId":"yingx9"},"content":"list /tag B /g Fiction","lastModifiedDate":"2023-10-16"},{"lineNumber":199,"author":{"gitId":"JoanneJo"},"content":"list /g Thrill","lastModifiedDate":"2023-10-15"},{"lineNumber":200,"author":{"gitId":"yingx9"},"content":"list /s Available","lastModifiedDate":"2023-11-04"},{"lineNumber":201,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":202,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":203,"author":{"gitId":"bnjm2000"},"content":"**Example output:**","lastModifiedDate":"2023-10-28"},{"lineNumber":204,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":205,"author":{"gitId":"bnjm2000"},"content":"Listing all resources in the Library:","lastModifiedDate":"2023-10-28"},{"lineNumber":206,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":207,"author":{"gitId":"bnjm2000"},"content":"1. [B] ID: 1 Title: Moby Dick ISBN: 9780763630188 Author: Herman Melville Genre: Adventure, Fiction Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":208,"author":{"gitId":"bnjm2000"},"content":"2. [M] ID: 2 Title: Harry Squatter ISBN: 9780763630187 Author: J.K. Genre: History Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":209,"author":{"gitId":"bnjm2000"},"content":"3. [B] ID: 3 Title: Frankenstein ISBN: FKS0001 Author: Mary Shelley Genre: - Status: BORROWED","lastModifiedDate":"2023-10-30"},{"lineNumber":210,"author":{"gitId":"bnjm2000"},"content":"4. [B] ID: 4 Title: The Great Gatsby ISBN: 9780023381201 Author: F. Scott Fitzgerald Genre: Novel, Fiction, Tragedy Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"bnjm2000"},"content":"5. [B] ID: 5 Title: To Kill a Mockingbird ISBN: 9780061120084 Author: Harper Lee Genre: Novel, Bildungsroman, Southern Gothic, Domestic Fiction, Thriller, Legal Story Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":213,"author":{"gitId":"bnjm2000"},"content":"There are currently 5 resource(s).","lastModifiedDate":"2023-10-28"},{"lineNumber":214,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":215,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":216,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":217,"author":{"gitId":"bnjm2000"},"content":"## Find specific listings: `find` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":218,"author":{"gitId":"yingx9"},"content":"Find a resource by title, author, ISBN or given id.","lastModifiedDate":"2023-10-16"},{"lineNumber":219,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":220,"author":{"gitId":"000verflow"},"content":"You can use multiple filters, and only results that match ALL the given criteria will be returned.","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"000verflow"},"content":"\u003e For non-book resources, `author` refers to `publisher`,`creator` and `brand` for Newspapers, CD\u0027s and Magazines ","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"000verflow"},"content":"\u003e respectively.","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":225,"author":{"gitId":"JoanneJo"},"content":"Format: `find [/t TITLE OR /i ISBN OR /a AUTHOR OR /id ID]`","lastModifiedDate":"2023-10-15"},{"lineNumber":226,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":227,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":228,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":229,"author":{"gitId":"JoanneJo"},"content":"find /t Moby Dick","lastModifiedDate":"2023-10-15"},{"lineNumber":230,"author":{"gitId":"JoanneJo"},"content":"find /i 9780763630188","lastModifiedDate":"2023-10-15"},{"lineNumber":231,"author":{"gitId":"000verflow"},"content":"find /a J. K. Rowling","lastModifiedDate":"2023-10-06"},{"lineNumber":232,"author":{"gitId":"000verflow"},"content":"find /id 123456789","lastModifiedDate":"2023-10-06"},{"lineNumber":233,"author":{"gitId":"000verflow"},"content":"find /id 123456789 /i 9780763630188 ","lastModifiedDate":"2023-11-02"},{"lineNumber":234,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":235,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":236,"author":{"gitId":"bnjm2000"},"content":"**Example output:**","lastModifiedDate":"2023-10-30"},{"lineNumber":237,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":238,"author":{"gitId":"bnjm2000"},"content":"Here are resources that matched the given filters:","lastModifiedDate":"2023-10-30"},{"lineNumber":239,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 123456789 Title: Moby Dick ISBN: 9780763630188 Author: Herman Melville Genre: Adventure, Fiction","lastModifiedDate":"2023-10-30"},{"lineNumber":240,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-30"},{"lineNumber":241,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":242,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":243,"author":{"gitId":"yingx9"},"content":"## Edit a listing: `edit` | [Return to contents](#contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":244,"author":{"gitId":"yingx9"},"content":"Edit a listing by entering its `isbn` to update its details.","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":246,"author":{"gitId":"yingx9"},"content":"Format: `edit /i ISBN /argumentname ARGUMENT`","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":248,"author":{"gitId":"yingx9"},"content":"Argument Names:","lastModifiedDate":"2023-10-30"},{"lineNumber":249,"author":{"gitId":"bnjm2000"},"content":"- `/t TITLE `","lastModifiedDate":"2023-10-30"},{"lineNumber":250,"author":{"gitId":"bnjm2000"},"content":"- `/a AUTHOR `","lastModifiedDate":"2023-10-30"},{"lineNumber":251,"author":{"gitId":"bnjm2000"},"content":"- `/tag TAG`","lastModifiedDate":"2023-10-30"},{"lineNumber":252,"author":{"gitId":"bnjm2000"},"content":"- `/g GENRES`","lastModifiedDate":"2023-10-30"},{"lineNumber":253,"author":{"gitId":"yingx9"},"content":" - If you\u0027re inputting **multiple genres**, separate them by with comma `,`. For example:","lastModifiedDate":"2023-10-30"},{"lineNumber":254,"author":{"gitId":"yingx9"},"content":" `/g Horror, Fantasy`","lastModifiedDate":"2023-10-30"},{"lineNumber":255,"author":{"gitId":"bnjm2000"},"content":"- `/s STATUS`","lastModifiedDate":"2023-10-30"},{"lineNumber":256,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":257,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":258,"author":{"gitId":"yingx9"},"content":"**Example input:**","lastModifiedDate":"2023-10-30"},{"lineNumber":259,"author":{"gitId":"yingx9"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":260,"author":{"gitId":"yingx9"},"content":"edit /i 123 /t NEW_TITLE","lastModifiedDate":"2023-10-30"},{"lineNumber":261,"author":{"gitId":"yingx9"},"content":"edit /i 123 /t NEW_TITLE /a NEW_AUTHOR","lastModifiedDate":"2023-10-30"},{"lineNumber":262,"author":{"gitId":"yingx9"},"content":"edit /i 123 /g Horror, Adventure","lastModifiedDate":"2023-10-30"},{"lineNumber":263,"author":{"gitId":"bnjm2000"},"content":"edit /i 123 /s lost","lastModifiedDate":"2023-10-30"},{"lineNumber":264,"author":{"gitId":"yingx9"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":265,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":266,"author":{"gitId":"bnjm2000"},"content":"**Example output:**","lastModifiedDate":"2023-10-28"},{"lineNumber":267,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":268,"author":{"gitId":"yingx9"},"content":"Successfully updated! Your updated resource: ","lastModifiedDate":"2023-10-30"},{"lineNumber":269,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":270,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 12312 Title: Mary ISBN: 123 Author: John Genre: Horror, Adventure Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":271,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":272,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":273,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"DavinciDelta"},"content":"## Events | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":275,"author":{"gitId":"DavinciDelta"},"content":"\u003eNote:","lastModifiedDate":"2023-11-03"},{"lineNumber":276,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Events are stored separately from resources","lastModifiedDate":"2023-11-03"},{"lineNumber":277,"author":{"gitId":"DavinciDelta"},"content":"\u003e - They are stored in chronological order(events that are happening sooner are closer to index 0)","lastModifiedDate":"2023-11-03"},{"lineNumber":278,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":279,"author":{"gitId":"DavinciDelta"},"content":"## Event adding: `eventadd` | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":280,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about description:","lastModifiedDate":"2023-11-03"},{"lineNumber":281,"author":{"gitId":"DavinciDelta"},"content":"\u003e - `desc` is optional for all events","lastModifiedDate":"2023-11-03"},{"lineNumber":282,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Event without descriptions with have it as `null`","lastModifiedDate":"2023-11-03"},{"lineNumber":283,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":284,"author":{"gitId":"DavinciDelta"},"content":"Add an event to the eventList","lastModifiedDate":"2023-11-03"},{"lineNumber":285,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":286,"author":{"gitId":"DavinciDelta"},"content":"Format: `eventadd /t TITLE /date DATE [/desc DESCRIPTION]`","lastModifiedDate":"2023-11-03"},{"lineNumber":287,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"DavinciDelta"},"content":"**Example input:**","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"DavinciDelta"},"content":"eventadd /t Fan meetup for xxx /date 11-11-2001","lastModifiedDate":"2023-11-03"},{"lineNumber":291,"author":{"gitId":"DavinciDelta"},"content":"eventadd /t Meet and Greet for xxx /date 10-11-2010 /desc buffet style","lastModifiedDate":"2023-11-03"},{"lineNumber":292,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":294,"author":{"gitId":"DavinciDelta"},"content":"**Example output:**","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"DavinciDelta"},"content":"Event inserted at: 0","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"DavinciDelta"},"content":"____________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":300,"author":{"gitId":"DavinciDelta"},"content":"## Event listing: `eventlist` | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":301,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":302,"author":{"gitId":"DavinciDelta"},"content":"Display all events in the eventList","lastModifiedDate":"2023-11-03"},{"lineNumber":303,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"DavinciDelta"},"content":"Format: `eventlist`","lastModifiedDate":"2023-11-01"},{"lineNumber":305,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":306,"author":{"gitId":"DavinciDelta"},"content":"**Example input:**","lastModifiedDate":"2023-11-01"},{"lineNumber":307,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":308,"author":{"gitId":"DavinciDelta"},"content":"eventlist","lastModifiedDate":"2023-11-01"},{"lineNumber":309,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":310,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":311,"author":{"gitId":"DavinciDelta"},"content":"**Example output:**","lastModifiedDate":"2023-11-03"},{"lineNumber":312,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":313,"author":{"gitId":"DavinciDelta"},"content":"This is the current event list:","lastModifiedDate":"2023-11-03"},{"lineNumber":314,"author":{"gitId":"DavinciDelta"},"content":"0: Fan meetup for xxx | 11-11-2001 | null","lastModifiedDate":"2023-11-03"},{"lineNumber":315,"author":{"gitId":"DavinciDelta"},"content":"1: Meet and Greet for xxx | 10-11-2010 | buffet style","lastModifiedDate":"2023-11-03"},{"lineNumber":316,"author":{"gitId":"DavinciDelta"},"content":"____________________________________________________________","lastModifiedDate":"2023-11-03"},{"lineNumber":317,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":318,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":319,"author":{"gitId":"DavinciDelta"},"content":"## Event delete: `eventdelete` | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":320,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about INDEX:","lastModifiedDate":"2023-11-03"},{"lineNumber":321,"author":{"gitId":"DavinciDelta"},"content":"\u003e - INDEX starts from 0 and can be viewed by calling `eventlist`","lastModifiedDate":"2023-11-03"},{"lineNumber":322,"author":{"gitId":"DavinciDelta"},"content":"\u003e - INDEX might change as those with earlier dates are sorted first","lastModifiedDate":"2023-11-03"},{"lineNumber":323,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":324,"author":{"gitId":"DavinciDelta"},"content":"Delete an event to the eventList","lastModifiedDate":"2023-11-03"},{"lineNumber":325,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":326,"author":{"gitId":"DavinciDelta"},"content":"Format: `eventdelete /i INDEX`","lastModifiedDate":"2023-11-01"},{"lineNumber":327,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":328,"author":{"gitId":"DavinciDelta"},"content":"**Example input:**","lastModifiedDate":"2023-11-01"},{"lineNumber":329,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":330,"author":{"gitId":"DavinciDelta"},"content":"eventdelete /i 0","lastModifiedDate":"2023-11-01"},{"lineNumber":331,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":332,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":333,"author":{"gitId":"DavinciDelta"},"content":"**Example output:**","lastModifiedDate":"2023-11-03"},{"lineNumber":334,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":335,"author":{"gitId":"DavinciDelta"},"content":"This event is removed:","lastModifiedDate":"2023-11-03"},{"lineNumber":336,"author":{"gitId":"DavinciDelta"},"content":"Fan meetup for xxx | 11-11-2001 | null","lastModifiedDate":"2023-11-03"},{"lineNumber":337,"author":{"gitId":"DavinciDelta"},"content":"____________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":338,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":339,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":340,"author":{"gitId":"bnjm2000"},"content":"## Exiting the program : `exit` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":341,"author":{"gitId":"bnjm2000"},"content":"Displays a farewell message and exits the program.","lastModifiedDate":"2023-10-28"},{"lineNumber":342,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":343,"author":{"gitId":"000verflow"},"content":"Format: `exit`","lastModifiedDate":"2023-10-06"},{"lineNumber":344,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":345,"author":{"gitId":"bnjm2000"},"content":"**Example**","lastModifiedDate":"2023-10-28"},{"lineNumber":346,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":347,"author":{"gitId":"bnjm2000"},"content":"Bye, hope to see you again soon!","lastModifiedDate":"2023-10-28"},{"lineNumber":348,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":349,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":350,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":351,"author":{"gitId":"bnjm2000"},"content":"## Viewing help : `help` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":352,"author":{"gitId":"bnjm2000"},"content":"Displays a list of available commands with examples and their syntax format.","lastModifiedDate":"2023-10-28"},{"lineNumber":353,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":354,"author":{"gitId":"bnjm2000"},"content":"Format: `help`","lastModifiedDate":"2023-10-28"},{"lineNumber":355,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":356,"author":{"gitId":"bnjm2000"},"content":"Example:","lastModifiedDate":"2023-10-28"},{"lineNumber":357,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":358,"author":{"gitId":"bnjm2000"},"content":"Commands available:","lastModifiedDate":"2023-10-28"},{"lineNumber":359,"author":{"gitId":"bnjm2000"},"content":"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE])","lastModifiedDate":"2023-10-28"},{"lineNumber":360,"author":{"gitId":"bnjm2000"},"content":"delete: deletes the resource with the specified ID from the library inventory. (e.g. delete /id 123456789)","lastModifiedDate":"2023-10-28"},{"lineNumber":361,"author":{"gitId":"bnjm2000"},"content":"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction","lastModifiedDate":"2023-10-28"},{"lineNumber":362,"author":{"gitId":"000verflow"},"content":"find: find a resource by title, author(same as publisher/creator/brand), ISBN or given id. (e.g. find /i 9780763630188)","lastModifiedDate":"2023-11-03"},{"lineNumber":363,"author":{"gitId":"bnjm2000"},"content":"edit: Edit a listing by entering its isbn to update its details. (e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)","lastModifiedDate":"2023-10-30"},{"lineNumber":364,"author":{"gitId":"000verflow"},"content":"eventadd: Add an event to the event list (e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])","lastModifiedDate":"2023-11-02"},{"lineNumber":365,"author":{"gitId":"000verflow"},"content":"eventlist: List out all the event list (e.g. eventlist)","lastModifiedDate":"2023-11-02"},{"lineNumber":366,"author":{"gitId":"000verflow"},"content":"eventdelete: Delete an event in the event list based on the index (e.g. eventdelete /i INDEX)","lastModifiedDate":"2023-11-02"},{"lineNumber":367,"author":{"gitId":"bnjm2000"},"content":"exit: displays a farewell message and exits the program (e.g. exit)","lastModifiedDate":"2023-10-28"},{"lineNumber":368,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":369,"author":{"gitId":"bnjm2000"},"content":"For more information, please refer to our user guide at:https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html","lastModifiedDate":"2023-10-28"},{"lineNumber":370,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":371,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":372,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":373,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":374,"author":{"gitId":"bnjm2000"},"content":"## FAQ | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":375,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":376,"author":{"gitId":"000verflow"},"content":"...","lastModifiedDate":"2023-10-06"},{"lineNumber":377,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":378,"author":{"gitId":"bnjm2000"},"content":"## Known Issues | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":379,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":380,"author":{"gitId":"000verflow"},"content":"...","lastModifiedDate":"2023-10-06"},{"lineNumber":381,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":382,"author":{"gitId":"bnjm2000"},"content":"## Command summary | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":383,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":384,"author":{"gitId":"000verflow"},"content":"| Action | Command |","lastModifiedDate":"2023-10-06"},{"lineNumber":385,"author":{"gitId":"JoanneJo"},"content":"|-----------------------|------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-15"},{"lineNumber":386,"author":{"gitId":"JoanneJo"},"content":"| Add listing | `add /t \u003ctitle of listing\u003e /a \u003cauthor of item\u003e /tag \u003ctype of item\u003e /i \u003cISBN of item\u003e [/g \u003cgenre of item\u003e]` |","lastModifiedDate":"2023-10-15"},{"lineNumber":387,"author":{"gitId":"000verflow"},"content":"| Delete listing | `delete /id \u003cid of listing\u003e` |","lastModifiedDate":"2023-10-06"},{"lineNumber":388,"author":{"gitId":"yingx9"},"content":"| Listing all items | `list [/tag \u003ctype of item\u003e /g \u003cgenre of item\u003e /s \u003cstatus of item\u003e]` |","lastModifiedDate":"2023-11-04"},{"lineNumber":389,"author":{"gitId":"JoanneJo"},"content":"| Find specific listing | `find [/t \u003ctitle of listing\u003e OR /i \u003cISBN of item\u003e OR /a AUTHOR OR /id ID]` |","lastModifiedDate":"2023-10-15"},{"lineNumber":390,"author":{"gitId":"yingx9"},"content":"| Edit a listing | `edit /i ISBN [/t \u003ctitle of listing\u003e /a AUTHOR /id ID /tag \u003ctype of item\u003e /g \u003cgenre of item\u003e] /s \u003cstatus\u003e` |","lastModifiedDate":"2023-11-02"},{"lineNumber":391,"author":{"gitId":"000verflow"},"content":"| Exit | `exit` |","lastModifiedDate":"2023-10-06"},{"lineNumber":392,"author":{"gitId":"DavinciDelta"},"content":"| Event Add | `eventadd /t TITLE /date DATE [/desc DESCRIPTION]` (Format for date DD-MM-YYYY) |","lastModifiedDate":"2023-11-03"},{"lineNumber":393,"author":{"gitId":"DavinciDelta"},"content":"| Event Delete | `eventdelete /i INDEX` |","lastModifiedDate":"2023-11-03"},{"lineNumber":394,"author":{"gitId":"DavinciDelta"},"content":"| Event Listing | `eventlist` |","lastModifiedDate":"2023-11-03"},{"lineNumber":395,"author":{"gitId":"000verflow"},"content":"| View help | `help` |","lastModifiedDate":"2023-10-06"},{"lineNumber":396,"author":{"gitId":"000verflow"},"content":"| Exit | `exit` |","lastModifiedDate":"2023-11-02"},{"lineNumber":397,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":398,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"000verflow":72,"bnjm2000":107,"JoanneJo":87,"DavinciDelta":81,"-":21,"yingx9":30}},{"path":"docs/diagram/AddSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"!include Style.puml","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"skinparam ArrowFontStyle plain","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"participant \":SysLib\" as SYSLIB SYSLIB_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":"participant \":UI\" as UI UI_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"actor User as USER USER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"participant \":Parser\" as PARSER PARSER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"box Command","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"participant \":AddCommand\" as ADDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"participant \":Command\" as COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"end box","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"SYSLIB -[SYSLIB_COLOR]\u003e UI : readCommand()","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":"activate SYSLIB SYSLIB_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":"activate UI UI_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":"USER -[USER_COLOR]\u003e UI : \"add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\"","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":"UI --[UI_COLOR]\u003e SYSLIB : input: String","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"deactivate UI","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"SYSLIB -[SYSLIB_COLOR]\u003e PARSER : process(\"add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\")","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":"alt containsKey","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" PARSER-[PARSER_COLOR]\u003e PARSER: removeFirstWord(add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction)","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" PARSER --[PARSER_COLOR]\u003e PARSER : \"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\": String","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" deactivate PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" PARSER -[PARSER_COLOR]\u003e ADDCOMMAND : execute(\"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\")","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" activate ADDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":"else noKey","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" PARSER --[PARSER_COLOR]\u003e SYSLIB","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":"ADDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : parseArgument(\"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\")","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":"activate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":"COMMAND --[COMMAND_COLOR]\u003e ADDCOMMAND : values: String[]","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":"ADDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : validate(\"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\", values)","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":"COMMAND --[COMMAND_COLOR]\u003e ADDCOMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":"deactivate COMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":"alt equalsIgnoreCase(\"b\")","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" ADDCOMMAND -[COMMAND_COLOR]\u003e PARSER : createBook(values)","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" PARSER --[PARSER_COLOR]\u003e ADDCOMMAND : new Book (title, isbn, author, genres, id)","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" ADDCOMMAND --[COMMAND_COLOR]\u003e PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":"else notEqualsIgnoreCase(\"b\")","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" ADDCOMMAND --[COMMAND_COLOR]\u003e PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" deactivate ADDCOMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":"PARSER --[PARSER_COLOR]\u003e SYSLIB","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"JoanneJo"},"content":"deactivate PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"JoanneJo":59}},{"path":"docs/diagram/Architecture.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/globe_internet\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/documents\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Users/user\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"!include style.puml","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"Package \" \"\u003c\u003cRectangle\u003e\u003e{","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" Class UI UI_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" Class Parser PARSER_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" Class Command COMMAND_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":" Class Main #grey","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" Class Storage STORAGE_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":" Class Data DATA_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"Class \"\u003c$user\u003e\" as User STORAGE_COLOR_T2","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"Class \"\u003c$documents\u003e\" as File UI_COLOR_T1","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"User ..\u003e UI","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"Main -[#grey]-\u003e UI","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"Main -[#grey]-\u003e Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"UI -[#green]-\u003eParser","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"Main -[#grey]-\u003e Storage","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"Parser -[#blue]-\u003e Command","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"Command ..\u003eParser","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"Parser -[#blue]-\u003e Data","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"Storage -[STORAGE_COLOR]-\u003eData","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"Storage ..\u003eFile","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"yingx9":36}},{"path":"docs/diagram/FindSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"!include Style.puml","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"!include \u003coffice/Concepts/globe_internet\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"!include \u003coffice/Concepts/documents\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"!include \u003coffice/Users/user\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"skinparam ArrowFontStyle plain","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"Actor User as user USER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"participant \":UI\" as UI UI_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"participant \":Parser\" as PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"box Command","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"participant \":FindCommand\" as FINDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"participant \":Command\" as COMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"end box","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"participant \":Resource\" as RESOURCE","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"user -[USER_COLOR]\u003e UI : \"find /t TITLE\"","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"activate UI UI_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":"UI -[UI_COLOR]\u003e PARSER : process(\"find /t TITLE\")","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":"alt containsKey","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" PARSER -[PARSER_COLOR]\u003e PARSER: removeFirstWord(\"find /t TITLE\")","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" PARSER -[PARSER_COLOR]\u003e FINDCOMMAND: execute(\"/t TITLE\")","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" activate FINDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":"else noKey","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" PARSER --[PARSER_COLOR]\u003e UI :","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : parseArg(\"/t TITLE\")","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":"activate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":"COMMAND --[COMMAND_COLOR]\u003e FINDCOMMAND : String[] values","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : validate(\"/t TITLE\", values)","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":"COMMAND --[COMMAND_COLOR]\u003e FINDCOMMAND :","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":"deactivate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -[COMMAND_COLOR]\u003e PARSER : resourceList","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":"PARSER --[PARSER_COLOR]\u003e FINDCOMMAND : List of resources","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":"deactivate PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"loop for each Resource in resourceList","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" FINDCOMMAND -[COMMAND_COLOR]\u003e RESOURCE: getId(), getISBN(), getTitle(), getTag()","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" activate RESOURCE","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" RESOURCE --[COMMAND_COLOR]\u003e FINDCOMMAND","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" deactivate RESOURCE","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" FINDCOMMAND -\u003e FINDCOMMAND : Check and filter based on Id, ISBN, Title, and Tag","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":" alt isMatch","lastModifiedDate":"2023-11-04"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" FINDCOMMAND -\u003e FINDCOMMAND : Add to matchedResources","lastModifiedDate":"2023-11-04"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" end","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -\u003e FINDCOMMAND : Check if matchedResources is empty","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -\u003e UI : showLine()","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"deactivate FINDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":"deactivate UI UI_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"000verflow":63}},{"path":"docs/diagram/ListSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"!include Style.puml","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/globe_internet\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/documents\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Users/user\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"skinparam ArrowFontStyle plain","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"participant \":Main\" as MAIN #grey","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"participant \":UI\" as UI UI_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"Actor User as user USER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"participant \":Parser\" as PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"box Command","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"participant \":ListCommand\" as LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"participant \":Command\" as COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"end box","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"MAIN -[#grey]\u003e UI : readcommand()","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"activate MAIN #grey","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"activate UI UI_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"user -[USER_COLOR]\u003e UI : \"list /tag B\"","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"UI --[UI_COLOR]\u003e MAIN : \"list /tag B\"","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"deactivate UI UI_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"MAIN -[#grey]\u003e PARSER : process(\"list /tag B\")","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"alt containsKey","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" PARSER -[PARSER_COLOR]\u003e PARSER: removeFirstWord(\"list /tag B\")","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" PARSER --[PARSER_COLOR]\u003e PARSER : \"/tag B\"","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" deactivate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" PARSER -[PARSER_COLOR]\u003e LISTCOMMAND: execute(\"/tag B\")","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"else noKey","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" PARSER --[PARSER_COLOR]\u003e MAIN :","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":"end","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e COMMAND : parseArg(\"/tag B)","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":"activate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":"COMMAND --[COMMAND_COLOR]\u003e LISTCOMMAND : String[] values","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e COMMAND : validate(\"/tag B\", values)","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":"COMMAND --[COMMAND_COLOR]\u003e LISTCOMMAND :","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":"deactivate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e LISTCOMMAND : filterResources()","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":"activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e LISTCOMMAND : hasFilters()","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":"activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND --[COMMAND_COLOR]\u003e LISTCOMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e LISTCOMMAND : displayResourcesDetails()","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":"activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND --[COMMAND_COLOR]\u003e PARSER","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":"PARSER --[PARSER_COLOR]\u003e MAIN :","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":"deactivate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"yingx9":75}},{"path":"docs/diagram/Style.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"/\u0027","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":" \u0027Commonly used styles and colors across diagrams.","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":" \u0027Refer to https://plantuml-documentation.readthedocs.io/en/latest for a more","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":" \u0027comprehensive list of skinparams.","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":" \u0027/","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"\u0027T1 through T4 are shades of the original color from lightest to darkest","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"!define SYSLIB_COLOR #grey","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR #1D8900","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T1 #83E769","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T2 #3FC71B","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T3 #166800","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T4 #0E4100","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR #3333C4","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T1 #C8C8FA","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T2 #6A6ADC","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T3 #1616B0","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T4 #101086","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR #9D0012","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T1 #F97181","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T2 #E41F36","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T3 #7B000E","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T4 #51000A","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR #A38300","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_COLOR_T1 #FFE374","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_T2 #EDC520","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_T3 #806600","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_T2 #544400","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"!define DATA_COLOR #544400","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"!define USER_COLOR #000000","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"skinparam Package {","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" BackgroundColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" BorderThickness 1","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" FontSize 16","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":"skinparam Class {","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" FontColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" FontSize 15","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" BorderThickness 1","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" BorderColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" StereotypeFontColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" FontName Arial","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":"skinparam Actor {","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" BorderColor USER_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" Color USER_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" FontName Arial","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"skinparam Sequence {","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" MessageAlign center","lastModifiedDate":"2023-10-24"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":" BoxFontSize 15","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" BoxPadding 0","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" BoxFontColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" FontName Arial","lastModifiedDate":"2023-10-24"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":"skinparam Participant {","lastModifiedDate":"2023-10-24"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" FontColor #FFFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" Padding 20","lastModifiedDate":"2023-10-24"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":"skinparam ArrowFontStyle bold","lastModifiedDate":"2023-10-24"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"skinparam MinClassWidth 50","lastModifiedDate":"2023-10-24"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":"skinparam ParticipantPadding 10","lastModifiedDate":"2023-10-24"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":"skinparam Shadowing false","lastModifiedDate":"2023-10-24"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":"skinparam DefaultTextAlignment center","lastModifiedDate":"2023-10-24"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":"skinparam packageStyle Rectangle","lastModifiedDate":"2023-10-24"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":"hide footbox","lastModifiedDate":"2023-10-24"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":"hide members","lastModifiedDate":"2023-10-24"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":"hide circle","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"JoanneJo":2,"yingx9":81}},{"path":"docs/team/BenjaminNg.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"# Benjamin Ng - Project Portfolio Page","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"## Overview","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"bnjm2000":6}},{"path":"docs/team/JoanneAng.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"# Joanne Ang - Project Portfolio Page","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"## Overview","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"JoanneJo":6}},{"path":"docs/team/WuXingyu.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"# Wu Xingyu - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"DavinciDelta":6}},{"path":"docs/team/YingXia.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"# Loke Ying Xia - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"yingx9":6}},{"path":"docs/team/ashokbalaji.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"# Ashok Balaji - Project Portfolio Page","lastModifiedDate":"2023-10-06"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"## Overview","lastModifiedDate":"2023-10-06"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-06"}],"authorContributionMap":{"000verflow":6}},{"path":"src/main/java/seedu/commands/AddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"import seedu.data.CreateResource;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.Book.BOOK_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.CD.CD_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.Magazine.MAGAZINE_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.Newspaper.NEWSPAPER_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.EBook.EBOOK_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.EMagazine.EMAGAZINE_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.ENewspaper.ENEWSPAPER_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"import static seedu.ui.UI.LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":"public class AddCommand extends Command{","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public AddCommand(){","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" args \u003d new String[]{\"id\", \"t\", \"a\", \"tag\", \"i\", \"g\", \"s\", \"l\", \"c\", \"b\", \"p\", \"ty\", \"is\", \"ed\"};","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" required \u003d new boolean[]{true, true, false, true, true, false, false, false, false, false, false, false, false","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" , false};","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" IllegalStateException, NumberFormatException, SysLibException {","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" validateStatement(statement, values);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" String title \u003d values[1];","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" String tag \u003d values[3];","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" if (tag.equalsIgnoreCase(BOOK_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createBook(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This book is added: \" + title);","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(EBOOK_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createEBook(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This eBook is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(CD_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createCD(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This CD is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(MAGAZINE_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createMagazine(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This magazine is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(EMAGAZINE_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createEMagazine(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This eMagazine is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(NEWSPAPER_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createNewspaper(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This newspaper is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(ENEWSPAPER_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createENewspaper(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This eNewspaper is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" throw new SysLibException(\"Please enter a valid tag.\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":" LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"JoanneJo"},"content":" System.out.println(LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":8,"bnjm2000":2,"JoanneJo":37,"DavinciDelta":10,"yingx9":7}},{"path":"src/main/java/seedu/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" protected String[] args;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" protected boolean[] required;","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":" public abstract CommandResult execute(String statement, Parser parser) throws","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" IllegalArgumentException, IllegalStateException, SysLibException;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" * A method to check if statement given is valid compared to the values extracted","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The input of user","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" * @param values The extracted value(s) from the statement","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" * @throws IllegalArgumentException The invalid arguments given","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" public void validateStatement(String statement, String[] values) throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" statement \u003d statement.toLowerCase();","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" for(int pointer \u003d 0; pointer \u003c args.length; pointer ++) {","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" if(values[pointer] !\u003d null){","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" String arg \u003d checkDuplicate(statement, pointer);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" statement \u003d statement.replaceAll(arg+ \"\\\\s*\" + Pattern.quote(values[pointer].toLowerCase()), \"\");","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" if (!statement.isBlank()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Unknown variable/command: \" + statement);","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" * A method to check if for duplicate argument calls","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The input of user","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" * @param pointer The index of args being checked","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" * @return The argument being checked","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" public String checkDuplicate(String statement, int pointer) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" String arg \u003d \"/\" + args[pointer] + \" \";","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" int firstIndex \u003d statement.indexOf(arg);","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" if (firstIndex \u003d\u003d -1) {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" return arg;","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" int secondIndex \u003d statement.indexOf(arg, firstIndex + arg.length());","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" if(secondIndex !\u003d -1) {","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Duplicate instances of \" + arg);","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" return arg;","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"DavinciDelta"},"content":" * A method to get information from user input to a list","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The input of user","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"DavinciDelta"},"content":" * @return The list of information for each argument required","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":" * @throws IllegalArgumentException The missing argument that is required","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":" public String[] parseArgument(String statement) throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" String[] orderedArgs \u003d new String[args.length];","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" for(int pointer \u003d 0; pointer \u003c args.length; pointer ++) {","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" orderedArgs[pointer] \u003d getMatch(statement, pointer);","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" if(orderedArgs[pointer] \u003d\u003d null \u0026\u0026 required[pointer]){","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bnjm2000"},"content":" throw new IllegalArgumentException(args[pointer] + \" is missing in the argument!\"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bnjm2000"},"content":" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"DavinciDelta"},"content":" return orderedArgs;","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"DavinciDelta"},"content":" * Match the required argument to one in the user\u0027s input","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The user input","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"DavinciDelta"},"content":" * @param pointer The index of the required argument","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"DavinciDelta"},"content":" * @return The matched argument information, null otherwise","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"DavinciDelta"},"content":" public String getMatch(String statement, int pointer) {","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"DavinciDelta"},"content":" String key \u003d args[pointer];","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"DavinciDelta"},"content":" Pattern pattern \u003d Pattern.compile(\"/\" + key + \" (.+?)(?\u003d\\\\s?/|$)\", Pattern.CASE_INSENSITIVE);","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"DavinciDelta"},"content":" Matcher matcher \u003d pattern.matcher(statement);","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"DavinciDelta"},"content":" if (matcher.find()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"DavinciDelta"},"content":" return matcher.group(1).trim();","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"DavinciDelta"},"content":" return null;","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":90,"author":{"gitId":"DavinciDelta"},"content":" public int parseInt(String value) {","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-10-14"},{"lineNumber":92,"author":{"gitId":"DavinciDelta"},"content":" int tempNum \u003d Integer.parseInt(value);","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"DavinciDelta"},"content":" if (0 \u003c\u003d tempNum){","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"DavinciDelta"},"content":" return tempNum;","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":96,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException (\"The argument for id is not a valid number!\");","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-14"},{"lineNumber":98,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException (\"The argument for id is not a number!\");","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":3,"bnjm2000":4,"JoanneJo":1,"DavinciDelta":82,"yingx9":12}},{"path":"src/main/java/seedu/commands/CommandResult.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"public class CommandResult {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" public CommandResult(String feedbackToUser) {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"yingx9":13}},{"path":"src/main/java/seedu/commands/DeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"public class DeleteCommand extends Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" public DeleteCommand(){","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" args \u003d new String[]{\"id\"};","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" required \u003d new boolean[]{true};","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws SysLibException {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" int id \u003d parseInt(parseArgument(statement)[0]);","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" assert id \u003e 0;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" ArrayList\u003cResource\u003e removals \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"Looking for ID: \" + id + \"...\");","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" for (Resource r: parser.resourceList){","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" Book b \u003d (Book) r;","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" if (b.getId() \u003d\u003d id){","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This resource is removed: \");","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" System.out.println(b + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" removals.add(r);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" if(removals.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"No resources with id matching \" + id + System.lineSeparator() + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" } else {","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" parser.resourceList.removeAll(removals);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":5,"bnjm2000":4,"JoanneJo":1,"DavinciDelta":20,"yingx9":10}},{"path":"src/main/java/seedu/commands/EditCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import java.io.File;","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLastLineDivider;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLineSeparator;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"public class EditCommand extends Command{","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":" public static final String MISSING_ARG_MESSAGE \u003d formatLastLineDivider(\"Please provide at least \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":" \"one detail to edit!\");","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" public static final String NOT_BOOK_ERROR \u003d formatLastLineDivider(\"Your resource is not a book!\");","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" public static final String RESOURCE_NOT_FOUND \u003d formatLastLineDivider(\"No such resource with given ISBN\");","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" public static final String EDIT_SUCCESS \u003d formatLineSeparator(\"Successfully updated! Your updated resource:\");","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" private static final Logger EDIT_LOGGER \u003d Logger.getLogger(EditCommand.class.getName());","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" private static int resourceIndex;","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" static {","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" FileHandler editFileHandler \u003d null;","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" String loggingDirectoryPath \u003d System.getProperty(\"user.dir\") + \"/logs\";","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" String logFilePath \u003d loggingDirectoryPath + \"/editCommandLogs.log\";","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" File directory \u003d new File(loggingDirectoryPath);","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" if (!directory.exists()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" directory.mkdir();","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" editFileHandler \u003d new FileHandler(logFilePath, true);","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.log(Level.SEVERE, \"Failed to initialize edit logging handler.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" editFileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.addHandler(editFileHandler);","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" public EditCommand(){","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" args \u003d new String[]{\"i\", \"t\", \"a\", \"tag\", \"g\", \"s\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" required \u003d new boolean[]{true, false, false, false, false, false};","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws SysLibException, IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.info(\"Edit Command execute with \" + statement);","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" String[] givenParameters \u003d parseArgument(statement);","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" validateStatement(statement, givenParameters);","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" if (hasOneArg(givenParameters)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" String givenISBN \u003d givenParameters[0];","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" Resource foundResource \u003d findResourceByISBN(givenISBN, parser.resourceList);","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" if(foundResource !\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" Resource updatedResource \u003d editResource(foundResource, givenParameters);","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":" assert updatedResource !\u003d null;","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":" assert resourceIndex \u003c parser.resourceList.size();","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":" parser.resourceList.set(resourceIndex, updatedResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d EDIT_SUCCESS + formatLastLineDivider(updatedResource.toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.info(\"Edit success\");","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d RESOURCE_NOT_FOUND;","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.warning(feedbackToUser);","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.warning(MISSING_ARG_MESSAGE);","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(MISSING_ARG_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":" public boolean hasOneArg(String[] givenParameters){","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"yingx9"},"content":" for (int i \u003d1; i\u003cgivenParameters.length; i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" if (givenParameters[i] !\u003d null){","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":" public Resource findResourceByISBN(String givenISBN, List\u003cResource\u003e resourceList){","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" Resource foundResource \u003d null;","lastModifiedDate":"2023-10-30"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" for (int i\u003d0;i \u003c resourceList.size(); i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"yingx9"},"content":" Resource tempResource \u003d resourceList.get(i);","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":109,"author":{"gitId":"yingx9"},"content":" String resourceISBN \u003d tempResource.getISBN();","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"yingx9"},"content":" if (resourceISBN.equals(givenISBN)){","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"yingx9"},"content":" foundResource \u003d tempResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"yingx9"},"content":" resourceIndex \u003d i;","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" return foundResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"yingx9"},"content":" public Resource editResource(Resource foundResource, String[] givenParameters) throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"yingx9"},"content":" String newValue;","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"yingx9"},"content":" for(int i\u003d1; i\u003cgivenParameters.length;i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"yingx9"},"content":" if(givenParameters[i] \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"yingx9"},"content":" continue;","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"yingx9"},"content":" newValue \u003d givenParameters[i];","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":131,"author":{"gitId":"yingx9"},"content":" switch(i) {","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":133,"author":{"gitId":"yingx9"},"content":" case 1:","lastModifiedDate":"2023-10-30"},{"lineNumber":134,"author":{"gitId":"yingx9"},"content":" foundResource.setTitle(newValue);","lastModifiedDate":"2023-10-30"},{"lineNumber":135,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":136,"author":{"gitId":"yingx9"},"content":" case 2:","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"yingx9"},"content":" Book bookResource\u003d castResourceToBook(foundResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"yingx9"},"content":" bookResource.setAuthor(newValue);","lastModifiedDate":"2023-10-30"},{"lineNumber":139,"author":{"gitId":"yingx9"},"content":" foundResource \u003d bookResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":141,"author":{"gitId":"yingx9"},"content":" case 3:","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"yingx9"},"content":" foundResource.setTag(newValue);","lastModifiedDate":"2023-10-30"},{"lineNumber":143,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":144,"author":{"gitId":"yingx9"},"content":" case 4:","lastModifiedDate":"2023-10-30"},{"lineNumber":145,"author":{"gitId":"yingx9"},"content":" Book book\u003d castResourceToBook(foundResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"yingx9"},"content":" String[] newGenres \u003d newValue.split(\", \");","lastModifiedDate":"2023-10-30"},{"lineNumber":147,"author":{"gitId":"yingx9"},"content":" book.setGenre(newGenres);","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"yingx9"},"content":" foundResource \u003d book;","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"bnjm2000"},"content":" case 5:","lastModifiedDate":"2023-10-30"},{"lineNumber":151,"author":{"gitId":"bnjm2000"},"content":" if (foundResource instanceof Book) {","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"bnjm2000"},"content":" Book bookStatus \u003d castResourceToBook(foundResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"bnjm2000"},"content":" bookStatus.setStatus(getStatusFromString(newValue));","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"bnjm2000"},"content":" foundResource \u003d bookStatus;","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"bnjm2000"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":" default:","lastModifiedDate":"2023-10-30"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(\"Input error\");","lastModifiedDate":"2023-10-30"},{"lineNumber":159,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":160,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":161,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":162,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"yingx9"},"content":" return foundResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":168,"author":{"gitId":"yingx9"},"content":" public Book castResourceToBook(Resource resource) throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":169,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"yingx9"},"content":" Book book;","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"yingx9"},"content":" if (resource instanceof Book) {","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"yingx9"},"content":" book \u003d (Book) resource;","lastModifiedDate":"2023-10-30"},{"lineNumber":174,"author":{"gitId":"yingx9"},"content":" } else{","lastModifiedDate":"2023-10-30"},{"lineNumber":175,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.warning(NOT_BOOK_ERROR);","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(NOT_BOOK_ERROR);","lastModifiedDate":"2023-10-30"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":179,"author":{"gitId":"yingx9"},"content":" return book;","lastModifiedDate":"2023-10-30"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":" public Status getStatusFromString(String statusString) {","lastModifiedDate":"2023-10-30"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":" statusString \u003d statusString.toLowerCase().trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":" if (statusString.equals(\"borrowed\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":" return Status.BORROWED;","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"bnjm2000"},"content":" } else if (statusString.equals(\"lost\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":" return Status.LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bnjm2000"},"content":" return Status.AVAILABLE;","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"000verflow":3,"bnjm2000":20,"DavinciDelta":1,"yingx9":169}},{"path":"src/main/java/seedu/commands/ExitCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":" * Command to print exit message","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":"public class ExitCommand extends Command{","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" static {","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" // remove logs from showing in stdout","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" for (java.util.logging.Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" if (handler instanceof java.util.logging.ConsoleHandler) {","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" FileHandler fileHandler \u003d new FileHandler(\"logs/exitCommandLogs.log\", true);","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":" fileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":" LOGGER.addHandler(fileHandler);","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" LOGGER.setLevel(Level.INFO);","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" LOGGER.log(Level.SEVERE, \"Failed to set up log file handler\", e);","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"bnjm2000"},"content":" assert statement !\u003d null : \"Statement to execute cannot be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"bnjm2000"},"content":" assert parser !\u003d null : \"Parser must not be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"bnjm2000"},"content":" LOGGER.log(Level.INFO, \"Executing ExitCommand...\");","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" UI ui \u003d new UI();","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" ui.showExitMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"bnjm2000":54,"yingx9":4}},{"path":"src/main/java/seedu/commands/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":" public static final int FIRST_INDEX \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" public static final int SECOND_INDEX \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" public static final int THIRD_INDEX \u003d 2;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" public static final int FOURTH_INDEX \u003d 3;","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" private static final String INVALID_ARGUMENT_MESSAGE \u003d \"Please use the format \u0027find [/t TITLE OR \"","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" + \"/i ISBN OR /a AUTHOR OR /id ID]\u0027\\n\" + \"____________________________________________________________\";","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" private static final String NO_RESOURCE_FOUND_MESSAGE \u003d \"There are no resources found matching the given filters.\";","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" private static final String RESOURCE_FOUND_MESSAGE \u003d \"Here are resources that matched the given filters:\";","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" static {","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" // remove logs from showing in stdout","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" for (java.util.logging.Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":" if (handler instanceof java.util.logging.ConsoleHandler) {","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":" FileHandler fileHandler \u003d new FileHandler(\"logs/findCommandLogs.log\", true);","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" fileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":" LOGGER.addHandler(fileHandler);","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" LOGGER.setLevel(Level.INFO);","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" LOGGER.log(Level.SEVERE, \"Failed to set up log file handler\", e);","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" protected String title;","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" protected String author;","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" protected String isbn;","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":" protected String id;","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" protected UI ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" public FindCommand(){","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" args \u003d new String[]{\"id\", \"i\", \"a\", \"t\"};","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" required \u003d new boolean[]{false, false, false, false};","lastModifiedDate":"2023-11-04"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":" ui \u003d new UI();","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":" LOGGER.info(\"FindCommand instance created.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":" public void setTitle(String title){","lastModifiedDate":"2023-10-17"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" this.title \u003d title;","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":" public String getTitle(){","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":" return this.title;","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" public void setAuthor(String author){","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" this.author \u003d author;","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" public String getAuthor(){","lastModifiedDate":"2023-10-17"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" return this.author;","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" public void setISBN(String isbn){","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":" this.isbn \u003d isbn;","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":" public String getISBN(){","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" return this.isbn;","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":" public void setID(String id){","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":" this.id \u003d id;","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":" public String getID(){","lastModifiedDate":"2023-10-17"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" return this.id;","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws IllegalArgumentException, SysLibException {","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" assert parser !\u003d null : \"Parser cannot be null!\";","lastModifiedDate":"2023-10-17"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" validateStatement(statement, values);","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":" // all null","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":" if (values[FOURTH_INDEX]\u003d\u003dnull \u0026\u0026 values[THIRD_INDEX]\u003d\u003dnull \u0026\u0026 values[SECOND_INDEX]\u003d\u003dnull","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":" \u0026\u0026 values[FIRST_INDEX]\u003d\u003dnull) {","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" throw new IllegalArgumentException(INVALID_ARGUMENT_MESSAGE + System.lineSeparator());","lastModifiedDate":"2023-10-17"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":106,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":" ArrayList\u003cResource\u003e matchedResources \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":" for (Resource resource: parser.resourceList){","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" boolean isMatch \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":" String resourceType \u003d resource.getTag();","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":" if (values[FIRST_INDEX] !\u003d null \u0026\u0026 resource.getId() !\u003d Integer.parseInt(values[FIRST_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"000verflow"},"content":" if (values[SECOND_INDEX] !\u003d null \u0026\u0026 !resource.getISBN().equalsIgnoreCase(values[SECOND_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"000verflow"},"content":" switch (resourceType) {","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"000verflow"},"content":" case \"B\":","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"000verflow"},"content":" case \"EB\":","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"000verflow"},"content":" Book b \u003d (Book) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !b.getAuthor().trim().equalsIgnoreCase((values[THIRD_INDEX]))) {","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"000verflow"},"content":" case \"M\":","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"000verflow"},"content":" case \"EM\":","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"000verflow"},"content":" Magazine m \u003d (Magazine) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !m.getBrand().trim().equalsIgnoreCase(values[THIRD_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"000verflow"},"content":" case \"N\":","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"000verflow"},"content":" case \"EN\":","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"000verflow"},"content":" Newspaper n \u003d (Newspaper) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !n.getPublisher().trim().equalsIgnoreCase(values[THIRD_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"000verflow"},"content":" case \"CD\":","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"000verflow"},"content":" CD cd \u003d (CD) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !cd.getCreator().trim().equalsIgnoreCase(values[THIRD_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"000verflow"},"content":" default:","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown resource type found.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"000verflow"},"content":" if (values[FOURTH_INDEX] !\u003d null \u0026\u0026 !resource.getTitle().equalsIgnoreCase(values[FOURTH_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"000verflow"},"content":" // If all non-null criteria matched, add the book to the list","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"000verflow"},"content":" if (isMatch) {","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"000verflow"},"content":" LOGGER.info(String.format(\"Resource with name: %s matched given arguments.\", resource.getTitle()));","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"000verflow"},"content":" matchedResources.add(resource);","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":163,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":164,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":165,"author":{"gitId":"000verflow"},"content":" if (matchedResources.isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":166,"author":{"gitId":"000verflow"},"content":" LOGGER.info(\"No resources matched the given filters.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"000verflow"},"content":" System.out.println(NO_RESOURCE_FOUND_MESSAGE);","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"000verflow"},"content":" ui.showLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":170,"author":{"gitId":"000verflow"},"content":" LOGGER.info(\"Resources matched the given filters.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":171,"author":{"gitId":"000verflow"},"content":" System.out.println(RESOURCE_FOUND_MESSAGE);","lastModifiedDate":"2023-10-17"},{"lineNumber":172,"author":{"gitId":"000verflow"},"content":" for (Resource r : matchedResources) {","lastModifiedDate":"2023-10-15"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":" System.out.println(r);","lastModifiedDate":"2023-10-15"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":175,"author":{"gitId":"000verflow"},"content":" ui.showLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":180,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":169,"yingx9":12}},{"path":"src/main/java/seedu/commands/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":" * Command to print help message","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" private static final Logger logger \u003d Logger.getLogger(HelpCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" static {","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" // remove logs from showing in stdout","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" for (java.util.logging.Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" if (handler instanceof java.util.logging.ConsoleHandler) {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" FileHandler fileHandler \u003d new FileHandler(\"logs/helpCommandLogs.log\", true);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" fileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" LOGGER.addHandler(fileHandler);","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" LOGGER.setLevel(Level.INFO);","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":" LOGGER.log(Level.SEVERE, \"Failed to set up log file handler\", e);","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" assert statement !\u003d null : \"Statement to execute cannot be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" assert parser !\u003d null : \"Parser must not be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" UI ui \u003d new UI();","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" logger.log(Level.INFO, \"Executing HelpCommand\");","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" ui.showHelpMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":2,"bnjm2000":50,"yingx9":11}},{"path":"src/main/java/seedu/commands/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"import java.io.File;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLineSeparator;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLastLineDivider;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatFirstLine;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" public static final String FILTER_MESSAGE \u003d formatFirstLine(\"Listing resources matching given filters: \");","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" public static final String GENERIC_MESSAGE \u003d formatFirstLine(\"Listing all resources in the Library:\");","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" public static final String ZERO_RESOURCES_MESSAGE \u003d formatLastLineDivider(\"There are currently 0 resources.\");","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" public static List\u003cResource\u003e matchedResources;","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" private static final Logger LIST_LOGGER \u003d Logger.getLogger(ListCommand.class.getName());","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":" private static String tagKeyword;","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" private static String genreKeyword;","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" private static String statusKeyword;","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" static {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" FileHandler editFileHandler \u003d null;","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" String loggingDirectoryPath \u003d System.getProperty(\"user.dir\") + \"/logs\";","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" String logFilePath \u003d loggingDirectoryPath + \"/editCommandLogs.log\";","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" File directory \u003d new File(loggingDirectoryPath);","lastModifiedDate":"2023-11-04"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" if (!directory.exists()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" directory.mkdir();","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" editFileHandler \u003d new FileHandler(logFilePath, true);","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.log(Level.SEVERE, \"Failed to initialize list logging handler.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":" editFileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-11-04"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.addHandler(editFileHandler);","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" public ListCommand(){","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" args \u003d new String[]{\"tag\", \"g\", \"s\"};","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" required \u003d new boolean[]{false, false, false};","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws SysLibException, IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.info(\"List Command execute with \" + statement);","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-19"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":" validateStatement(statement, values);","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" filterResources(values, parser.resourceList);","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.info(\"List Command ends\");","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" public void filterResources(String[] values, List\u003cResource\u003e resourceList) throws SysLibException{","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" boolean hasFilters \u003d hasFilters((values));","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":" matchedResources \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"yingx9"},"content":" if(hasFilters){","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"yingx9"},"content":" boolean isTagEqualToKeyword \u003d true;","lastModifiedDate":"2023-10-19"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" boolean isGenreEqualToKeyword \u003d true;","lastModifiedDate":"2023-10-19"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":" boolean isStatusEqualToKeyword \u003d true;","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"bnjm2000"},"content":" for (Resource resource : resourceList) {","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":92,"author":{"gitId":"yingx9"},"content":" if (tagKeyword !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"yingx9"},"content":" String resourceTag \u003d resource.getTag();","lastModifiedDate":"2023-10-19"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" isTagEqualToKeyword \u003d resourceTag.equals(tagKeyword);","lastModifiedDate":"2023-10-19"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" if (genreKeyword !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":" isGenreEqualToKeyword \u003d Resource.hasGenre(resource, genreKeyword);","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":" if (statusKeyword !\u003d null) {","lastModifiedDate":"2023-11-04"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":" Status resourceStatus \u003d resource.getStatus();","lastModifiedDate":"2023-11-04"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" isStatusEqualToKeyword \u003d statusKeyword.equals(resourceStatus.name());","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"yingx9"},"content":" if (isTagEqualToKeyword \u0026\u0026 isGenreEqualToKeyword \u0026\u0026 isStatusEqualToKeyword) {","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"yingx9"},"content":" matchedResources.add(resource);","lastModifiedDate":"2023-10-19"},{"lineNumber":110,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":111,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":112,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":113,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d FILTER_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":114,"author":{"gitId":"yingx9"},"content":" displayResourcesDetails(matchedResources);","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d GENERIC_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":118,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":119,"author":{"gitId":"yingx9"},"content":" displayResourcesDetails(resourceList);","lastModifiedDate":"2023-10-26"},{"lineNumber":120,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":121,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":122,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":123,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":124,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"yingx9"},"content":" public static String displayResourcesDetails(List\u003cResource\u003e resourcesList) {","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"yingx9"},"content":" String messageToDisplay \u003d \"\";","lastModifiedDate":"2023-10-26"},{"lineNumber":128,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"yingx9"},"content":" if (resourcesList.isEmpty()){","lastModifiedDate":"2023-10-19"},{"lineNumber":130,"author":{"gitId":"yingx9"},"content":" messageToDisplay +\u003d ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":131,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":132,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-19"},{"lineNumber":133,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":134,"author":{"gitId":"yingx9"},"content":" for (int i \u003d 0; i \u003c resourcesList.size(); i +\u003d 1) {","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"yingx9"},"content":" String resourceDetails \u003d resourcesList.get(i).toString();","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"yingx9"},"content":" messageToDisplay +\u003d formatLineSeparator(i+1 + \". \" + resourceDetails);","lastModifiedDate":"2023-10-26"},{"lineNumber":137,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":138,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":139,"author":{"gitId":"yingx9"},"content":" messageToDisplay +\u003d formatLastLineDivider(\"There are currently \" + resourcesList.size() +","lastModifiedDate":"2023-10-26"},{"lineNumber":140,"author":{"gitId":"yingx9"},"content":" \" resource(s).\");","lastModifiedDate":"2023-10-26"},{"lineNumber":141,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":142,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":143,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":144,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d messageToDisplay;","lastModifiedDate":"2023-10-26"},{"lineNumber":145,"author":{"gitId":"yingx9"},"content":" return messageToDisplay;","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":147,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":148,"author":{"gitId":"yingx9"},"content":" public static boolean hasFilters(String[] values) throws SysLibException {","lastModifiedDate":"2023-10-26"},{"lineNumber":149,"author":{"gitId":"yingx9"},"content":" tagKeyword \u003d null;","lastModifiedDate":"2023-10-26"},{"lineNumber":150,"author":{"gitId":"yingx9"},"content":" genreKeyword \u003d null;","lastModifiedDate":"2023-10-26"},{"lineNumber":151,"author":{"gitId":"yingx9"},"content":" statusKeyword \u003d null;","lastModifiedDate":"2023-11-04"},{"lineNumber":152,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":153,"author":{"gitId":"yingx9"},"content":" boolean hasFilters \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"yingx9"},"content":" if (values[0] \u003d\u003d null \u0026\u0026 values[1] \u003d\u003d null \u0026\u0026 values[2] \u003d\u003d null) {","lastModifiedDate":"2023-11-04"},{"lineNumber":155,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":" if (values[0] !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":159,"author":{"gitId":"yingx9"},"content":" tagKeyword \u003d values[0];","lastModifiedDate":"2023-10-26"},{"lineNumber":160,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":161,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":162,"author":{"gitId":"yingx9"},"content":" if (values[1] !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":163,"author":{"gitId":"yingx9"},"content":" genreKeyword \u003d values[1];","lastModifiedDate":"2023-10-26"},{"lineNumber":164,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":165,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":" if (values[2] !\u003d null){","lastModifiedDate":"2023-11-04"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":" statusKeyword \u003d values[2].toUpperCase();","lastModifiedDate":"2023-11-04"},{"lineNumber":168,"author":{"gitId":"yingx9"},"content":" validateStatus();","lastModifiedDate":"2023-11-04"},{"lineNumber":169,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":170,"author":{"gitId":"yingx9"},"content":" return hasFilters;","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":172,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"yingx9"},"content":" public static void validateStatus() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":174,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":175,"author":{"gitId":"yingx9"},"content":" switch(statusKeyword){","lastModifiedDate":"2023-11-04"},{"lineNumber":176,"author":{"gitId":"yingx9"},"content":" case \"AVAILABLE\":","lastModifiedDate":"2023-11-04"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":" //fallthrough","lastModifiedDate":"2023-11-04"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":" case \"BORROWED\":","lastModifiedDate":"2023-11-04"},{"lineNumber":179,"author":{"gitId":"yingx9"},"content":" //fallthrough","lastModifiedDate":"2023-11-04"},{"lineNumber":180,"author":{"gitId":"yingx9"},"content":" case \"LOST\":","lastModifiedDate":"2023-11-04"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-11-04"},{"lineNumber":182,"author":{"gitId":"yingx9"},"content":" default:","lastModifiedDate":"2023-11-04"},{"lineNumber":183,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(\"Please enter a valid status: AVAILABLE / BORROWED / LOST\");","lastModifiedDate":"2023-11-04"},{"lineNumber":184,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":185,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":186,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":187,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":4,"bnjm2000":2,"DavinciDelta":1,"yingx9":180}},{"path":"src/main/java/seedu/commands/events/EventAddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.data.Event;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"import java.text.ParseException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import java.text.SimpleDateFormat;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import java.util.Date;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventAddCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" public EventAddCommand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" args \u003d new String[]{\"t\", \"date\", \"desc\"};","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" required \u003d new boolean[]{true, true, false};","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser)","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" throws IllegalArgumentException, IllegalStateException, SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" Date currentDate \u003d parseDate(values[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" int index \u003d binarySearch(parser, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" parser.eventList.add(index, new Event(values[0], currentDate, values[2]));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"Event inserted at: \" + index);","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" public static int binarySearch(Parser parser, Date key) {","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" if(parser.eventList.isEmpty()){","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" return 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" int low \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" int high \u003d parser.eventList.size() - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" while (low \u003c\u003d high) {","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" int mid \u003d (low + high)/2;","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" Date midVal \u003d parser.eventList.get(mid).getDate();","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" int cmp \u003d midVal.compareTo(key);","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" if (cmp \u003c 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" low \u003d mid + 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" } else if (cmp \u003e 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" high \u003d mid - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" return mid;","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"DavinciDelta"},"content":" return low;","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"DavinciDelta"},"content":" public static Date parseDate(String date) throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":" SimpleDateFormat sdf \u003d new SimpleDateFormat(\"dd-MM-yyyy\");","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":" return sdf.parse(date);","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" } catch (ParseException e){","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Please enter a valid date in the format dd-mm-yyyy\"","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" + \"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":59,"yingx9":8}},{"path":"src/main/java/seedu/commands/events/EventDeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"public class EventDeleteCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":" public EventDeleteCommand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" args \u003d new String[]{\"i\"};","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" required \u003d new boolean[]{true};","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser)","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" throws IllegalArgumentException, IllegalStateException, SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" int index \u003d parseCalendarInt(values[0], parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"This event is removed:\");","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(parser.eventList.get(index).toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" parser.eventList.remove(index);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" public int parseCalendarInt(String value, Parser parser) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" int index \u003d parseInt(value);","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" int size \u003d parser.eventList.size();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" if (index \u003e\u003d size || index \u003c 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Index is out of range of the event list!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" return index;","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":30,"yingx9":6}},{"path":"src/main/java/seedu/commands/events/EventListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"public class EventListCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" IllegalArgumentException, IllegalStateException, SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" if (!statement.isEmpty()){","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"\u0027eventlist\u0027 command does not require arguments!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" if(parser.eventList.isEmpty()){","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"The event list is empty!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"This is the current event list:\");","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" for(int index \u003d 0; index \u003c parser.eventList.size(); index +\u003d 1){","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(index + \": \" + parser.eventList.get(index).toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":4,"DavinciDelta":21,"yingx9":7}},{"path":"src/main/java/seedu/common/FormatMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.common;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"import static seedu.ui.UI.LINESEPARATOR;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"public class FormatMessages {","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" public static String formatFirstLine(String message){","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" return LINESEPARATOR + message + LINESEPARATOR + LINESEPARATOR;","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":" public static String formatLineSeparator(String message){","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" return message + LINESEPARATOR;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":" public static String formatLastLineDivider(String message){","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":" return LINESEPARATOR + message + SEPARATOR_LINEDIVIDER + LINESEPARATOR;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"yingx9":17}},{"path":"src/main/java/seedu/data/CreateResource.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"package seedu.data;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EBook;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EMagazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.ENewspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"import static seedu.parser.Parser.getStatusFromString;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"public class CreateResource {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public static Book createBook(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" String author \u003d args[2];","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" String genre;","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" String[] genres \u003d new String[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" if (args[5] !\u003d null) {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" genre \u003d args[5];","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" genres \u003d genre.split(\", \");","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" return new Book(title, isbn, author, genres, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" public static EBook createEBook(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" String author \u003d args[2];","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]); // Get the status from the provided string","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" String link \u003d args[7];","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" String genre;","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":" String[] genres \u003d new String[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" if (args[5] !\u003d null) {","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":" genre \u003d args[5];","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"JoanneJo"},"content":" genres \u003d genre.split(\", \");","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"JoanneJo"},"content":" return new EBook(title, isbn, author, genres, id, status, link);","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"JoanneJo"},"content":" public static CD createCD(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"JoanneJo"},"content":" String creator \u003d args[8];","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"JoanneJo"},"content":" String type \u003d args[11];","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"JoanneJo"},"content":" return new CD(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"JoanneJo"},"content":" public static Magazine createMagazine(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":" String brand \u003d args[9];","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"JoanneJo"},"content":" String issue \u003d args[12];","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"JoanneJo"},"content":" return new Magazine(title, isbn, brand, issue, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"JoanneJo"},"content":" public static Magazine createEMagazine(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"JoanneJo"},"content":" String brand \u003d args[9];","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"JoanneJo"},"content":" String issue \u003d args[12];","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"JoanneJo"},"content":" String link \u003d args[7];","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"JoanneJo"},"content":" return new EMagazine(title, isbn, brand, issue, id, status, link);","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"JoanneJo"},"content":" public static Newspaper createNewspaper(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":" String publisher \u003d args[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"JoanneJo"},"content":" String edition \u003d args[13];","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"JoanneJo"},"content":" return new Newspaper(title, isbn, publisher, edition, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":" public static ENewspaper createENewspaper(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"JoanneJo"},"content":" String publisher \u003d args[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":" String edition \u003d args[13];","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"JoanneJo"},"content":" String link \u003d args[7];","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"JoanneJo"},"content":" return new ENewspaper(title, isbn, publisher, edition, id, status, link);","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":8,"JoanneJo":141}},{"path":"src/main/java/seedu/data/Event.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.data;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import java.text.SimpleDateFormat;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"import java.util.Date;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"public class Event {","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":" private final String name;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":" private final Date date;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":" private final String description;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":" public Event(String name, Date date, String description) {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" this.date \u003d date;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" public Date getDate() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" return date;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" public String getName() {","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" return name;","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" public String getDescription() {","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" return description;","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" SimpleDateFormat sdf \u003d new SimpleDateFormat(\"dd-MM-yyyy\");","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" return name + \" | \" + sdf.format(date) + \" | \" + description;","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":11,"DavinciDelta":23}},{"path":"src/main/java/seedu/data/Status.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.data;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"public enum Status {","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":" AVAILABLE,","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":" BORROWED,","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":" LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"bnjm2000":7}},{"path":"src/main/java/seedu/data/resources/Book.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"public class Book extends Resource {","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String BOOK_TAG \u003d \"B\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":" private String author;","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" //private String synopsis;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" private String[] genres;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":" public Book(String title, String isbn, String author, String[] genres, int id, Status status) {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setTag(BOOK_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" setAuthor(author);","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" //setSynopsis(synopsis);","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" setGenre(genres);","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" public String getAuthor() {","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" return author;","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" public void setAuthor(String author) {","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" this.author \u003d author;","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" /*public String getSynopsis() {","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" return synopsis;","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" public void setSynopsis(String synopsis) {","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" this.synopsis \u003d synopsis;","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" }*/","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String[] getGenre() {","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return genres;","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":" public void setGenre(String[] genres) {","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" this.genres \u003d genres;","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" public String getGenreString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":" return String.join(\", \", genres);","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" public String toString() {","lastModifiedDate":"2023-10-14"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" StringBuilder genreString \u003d new StringBuilder();","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" if (getGenre()[0] \u003d\u003d null) {","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" genreString.append(\"-\");","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" genreString.append(java.util.Arrays.toString(getGenre()).replace(\"[\", \"\").replace(\"]\", \"\"));","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Author: \"","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" + getAuthor() + \" Genre: \" + genreString + \" Status: \" + getStatus().name() + \" Received Date: \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" getDateReceived();","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-14"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":3,"bnjm2000":1,"JoanneJo":29,"DavinciDelta":21,"yingx9":6}},{"path":"src/main/java/seedu/data/resources/CD.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class CD extends Resource {","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String CD_TAG \u003d \"CD\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String creator;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" private String type;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" public CD(String title, String isbn, String creator, String type, int id, Status status) {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setTag(CD_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setCreator(creator);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":" setType(type);","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" public String getCreator() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" return creator;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" public void setCreator(String creator) {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" this.creator \u003d creator;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" public String getType() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" return type;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" public void setType(String type) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" this.type \u003d type;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN()","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" + \" Creator: \" + getCreator() + \" Type: \" + getType() + \" Status: \" + getStatus().name();","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":35}},{"path":"src/main/java/seedu/data/resources/EBook.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class EBook extends Book{","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String EBOOK_TAG \u003d \"EB\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String link;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" public EBook(String title, String isbn, String author, String[] genres, int id, Status status, String link) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, author, genres, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" setTag(EBOOK_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setLink(link);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public String getLink() {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" return link;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public void setLink(String link) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" this.link \u003d link;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" StringBuilder genreString \u003d new StringBuilder();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" if (getGenre()[0] \u003d\u003d null) {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" genreString.append(\"-\");","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" genreString.append(java.util.Arrays.toString(getGenre()).replace(\"[\", \"\").replace(\"]\", \"\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Author: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" + getAuthor() + \" Genre: \" + genreString + \" Link: \" + getLink();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":32}},{"path":"src/main/java/seedu/data/resources/EMagazine.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class EMagazine extends Magazine {","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String EMAGAZINE_TAG \u003d \"EM\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String link;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" public EMagazine(String title, String isbn, String creator, String type, int id, Status status, String link) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" setTag(EMAGAZINE_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setLink(link);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public String getLink() {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" return link;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public void setLink(String link) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" this.link \u003d link;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Brand: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" + getBrand() + \" Issue: \" + getIssue() + \" Link: \" + getLink();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":25}},{"path":"src/main/java/seedu/data/resources/ENewspaper.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class ENewspaper extends Newspaper{","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String ENEWSPAPER_TAG \u003d \"EN\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String link;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" public ENewspaper(String title, String isbn, String creator, String type, int id, Status status, String link) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" setTag(ENEWSPAPER_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setLink(link);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public String getLink() {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" return link;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public void setLink(String link) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" this.link \u003d link;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN()","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" + \" Publisher: \" + getPublisher() + \" Edition: \" + getEdition() + \" Link: \" + getLink();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":25}},{"path":"src/main/java/seedu/data/resources/Magazine.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class Magazine extends Resource {","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String MAGAZINE_TAG \u003d \"M\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String brand;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" private String issue;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" public Magazine(String title, String isbn, String brand, String issue, int id, Status status) {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setTag(MAGAZINE_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setBrand(brand);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":" setIssue(issue);","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" public String getBrand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" return brand;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" public void setBrand(String brand) {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" this.brand \u003d brand;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" public String getIssue() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" return issue;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" public void setIssue(String issue) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" this.issue \u003d issue;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Brand: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" + getBrand() + \" Issue: \" + getIssue() + \" Status: \" + getStatus().name();","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":35}},{"path":"src/main/java/seedu/data/resources/Newspaper.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class Newspaper extends Resource {","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String NEWSPAPER_TAG \u003d \"N\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String publisher;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" private String edition;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" public Newspaper(String title, String isbn, String publisher, String edition, int id, Status status) {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setTag(NEWSPAPER_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setPublisher(publisher);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":" setEdition(edition);","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" public String getPublisher() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" return publisher;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" public void setPublisher(String publisher) {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" this.publisher \u003d publisher;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" public String getEdition() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" return edition;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" public void setEdition(String edition) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" this.edition \u003d edition;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN()","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" + \" Publisher: \" + getPublisher() + \" Edition: \" + getEdition() + \" Status: \" + getStatus().name();","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":35}},{"path":"src/main/java/seedu/data/resources/Resource.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"import java.time.LocalDateTime;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"public class Resource {","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":" private String title;","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":" private boolean isBorrowed;","lastModifiedDate":"2023-10-14"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":" private Integer copies;","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":" private String tag;","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" private String isbn;","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" private int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":" private Status status;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":" private LocalDateTime dateReceived; //To keep track of when the resource was entered into the system","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public Resource(String title, String isbn, int id, Status status){","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" setTitle(title);","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" setBorrowed(false);","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" setISBN(isbn);","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" setCopies(1);","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":" setTag(\"\");","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" setStatus(status);","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" setReceivedDate();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" public String getTitle() {","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" return title;","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" public void setTitle(String title) {","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" this.title \u003d title;","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" public boolean isBorrowed() {","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" return isBorrowed;","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" public void setBorrowed(boolean borrowed) {","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" isBorrowed \u003d borrowed;","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" public Integer getCopies() {","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" return copies;","lastModifiedDate":"2023-10-14"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" public void setCopies(Integer copies) {","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" this.copies \u003d copies;","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":53,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":54,"author":{"gitId":"DavinciDelta"},"content":" public String getTag() {","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"DavinciDelta"},"content":" return tag;","lastModifiedDate":"2023-10-14"},{"lineNumber":56,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"DavinciDelta"},"content":" public void setTag(String tag) {","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":" this.tag \u003d tag;","lastModifiedDate":"2023-10-14"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" public String getISBN() {","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" return isbn;","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"DavinciDelta"},"content":" public void setISBN(String isbn) {","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"DavinciDelta"},"content":" this.isbn \u003d isbn;","lastModifiedDate":"2023-10-14"},{"lineNumber":68,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":69,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"JoanneJo"},"content":" public int getId() {","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"JoanneJo"},"content":" return id;","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"JoanneJo"},"content":" public void setId(int id) {","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"JoanneJo"},"content":" this.id \u003d id;","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":" public String getDateReceived(){","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd MMM yyyy\");","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bnjm2000"},"content":" return dateReceived.format(formatter);","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" public LocalDateTime getDateReceivedUnparsed(){","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" return dateReceived;","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" public void setReceivedDate(){","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":" dateReceived \u003d LocalDateTime.now();","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" public void setReceivedDateCustom(LocalDateTime ldt){","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" dateReceived \u003d ldt;","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" public String toString() {","lastModifiedDate":"2023-10-14"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":" return \"[\" + tag + \"] \" + title;","lastModifiedDate":"2023-10-14"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" public static boolean hasGenre(Resource resource, String genre){","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":" Book bookResource;","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":" if (resource instanceof Book) {","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" bookResource \u003d (Book) resource;","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":" String[] genres \u003d bookResource.getGenre();","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" if (genres[0] \u003d\u003d null ){","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":107,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"bnjm2000"},"content":" for (String s : genres) {","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bnjm2000"},"content":" if (s.equals(genre)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"yingx9"},"content":" return true;","lastModifiedDate":"2023-10-26"},{"lineNumber":112,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":113,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":114,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"bnjm2000"},"content":" public void setStatus(Status status){","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"bnjm2000"},"content":" this.status \u003d status;","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"bnjm2000"},"content":" public Status getStatus(){","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"bnjm2000"},"content":" return status;","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":11,"bnjm2000":16,"JoanneJo":13,"DavinciDelta":52,"yingx9":32}},{"path":"src/main/java/seedu/exception/SysLibException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.exception;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"public class SysLibException extends Exception {","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":" public SysLibException(String message) {","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":" super(message);","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"000verflow":1,"JoanneJo":6}},{"path":"src/main/java/seedu/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.events.EventAddCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.events.EventDeleteCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.events.EventListCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"import seedu.data.Event;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.AddCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.DeleteCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.FindCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.ListCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.HelpCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.ExitCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import seedu.commands.EditCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"public class Parser {","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" public List\u003cResource\u003e resourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" public List\u003cEvent\u003e eventList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" public HashMap\u003cString, Command\u003e commandProcessor \u003d new HashMap\u003c\u003e() {","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" {","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" put(\"list\", new ListCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" put(\"delete\", new DeleteCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" put(\"find\", new FindCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" put(\"help\", new HelpCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" put(\"exit\", new ExitCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" put(\"add\", new AddCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" put(\"edit\", new EditCommand());","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" put(\"eventadd\", new EventAddCommand());","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" put(\"eventdelete\", new EventDeleteCommand());","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" put(\"eventlist\", new EventListCommand());","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" };","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" public void process(String response) {","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" String command \u003d response.split(\" \")[0].toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" if (commandProcessor.containsKey(command)) {","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" String statement \u003d removeFirstWord(response);","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-10-14"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" CommandResult commandResult \u003d commandProcessor.get(command).execute(statement, this);","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" System.out.print(commandResult.feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" } catch (IllegalArgumentException | IllegalStateException | SysLibException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" System.out.println(\"no commands found. Enter \\\"help\\\" for a list of commands.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":" ","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" public static String removeFirstWord(String response) {","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" int index \u003d response.indexOf(\" \");","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" if (index \u003d\u003d -1) {","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" return \"\";","lastModifiedDate":"2023-10-14"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" return response.substring(index + 1);","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"JoanneJo"},"content":" public List\u003cResource\u003e getResourceList() {","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"JoanneJo"},"content":" return resourceList;","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" public void setResourceList(List\u003cResource\u003e resourcelist) {","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":" this.resourceList \u003d resourcelist;","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":" public List\u003cEvent\u003e getEventList() {","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":" return eventList;","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"JoanneJo"},"content":" public static String[] parseAddCommand(String statement) throws SysLibException {","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"JoanneJo"},"content":" String inputPattern \u003d \"(.+?) /tag (.)(.+)\";","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"JoanneJo"},"content":" Pattern pattern \u003d Pattern.compile(inputPattern);","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"JoanneJo"},"content":" Matcher matcher \u003d pattern.matcher(statement);","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":" boolean matchFound \u003d matcher.find();","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":91,"author":{"gitId":"JoanneJo"},"content":" if (matchFound) {","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"JoanneJo"},"content":" if (matcher.group(2).equalsIgnoreCase(\"b\")) {","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"JoanneJo"},"content":" return parseAddBook(statement);","lastModifiedDate":"2023-10-15"},{"lineNumber":94,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":95,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":96,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\"","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"bnjm2000"},"content":" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":99,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":100,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":101,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":103,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":104,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":105,"author":{"gitId":"bnjm2000"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bnjm2000"},"content":" * @param statement input of the user","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bnjm2000"},"content":" * @return string array with arguments of the user","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bnjm2000"},"content":" * @throws SysLibException missing arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"bnjm2000"},"content":" * @throws IllegalStateException","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"JoanneJo"},"content":" public static String[] parseAddBook(String statement) throws SysLibException, IllegalStateException {","lastModifiedDate":"2023-10-15"},{"lineNumber":112,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":113,"author":{"gitId":"JoanneJo"},"content":" String inputPattern \u003d \"/id (.+?) /t (.+?) /a (.+?) /tag (.+?) /i (.+)\";","lastModifiedDate":"2023-10-15"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":" String genrePattern \u003d \"(.+) /g (.+)\";","lastModifiedDate":"2023-10-15"},{"lineNumber":115,"author":{"gitId":"bnjm2000"},"content":" String statusPattern \u003d \"(.+) /s (.+)\";","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":" Pattern pattern \u003d Pattern.compile(inputPattern);","lastModifiedDate":"2023-10-15"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":" Matcher matcher \u003d pattern.matcher(statement);","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":" boolean matchFound \u003d matcher.find();","lastModifiedDate":"2023-10-15"},{"lineNumber":120,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":" Pattern gPattern \u003d Pattern.compile(genrePattern);","lastModifiedDate":"2023-10-15"},{"lineNumber":122,"author":{"gitId":"JoanneJo"},"content":" Matcher gMatcher \u003d gPattern.matcher(matcher.group(5));","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":" boolean gMatchFound \u003d gMatcher.find();","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"bnjm2000"},"content":" Pattern sPattern \u003d Pattern.compile(statusPattern);","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"bnjm2000"},"content":" Matcher sMatcher \u003d sPattern.matcher(matcher.group(5));","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"bnjm2000"},"content":" boolean sMatchFound \u003d sMatcher.find();","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"bnjm2000"},"content":" String[] args \u003d new String[7]; // Increase the array size to accommodate status","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":" if (matchFound) {","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":" args[0] \u003d matcher.group(1).trim(); // id","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"JoanneJo"},"content":" args[1] \u003d matcher.group(2).trim(); // title","lastModifiedDate":"2023-10-15"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":" args[2] \u003d matcher.group(3).trim(); // author","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":" args[3] \u003d matcher.group(4).trim(); // tag","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":" if (gMatchFound) {","lastModifiedDate":"2023-10-15"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":" args[4] \u003d gMatcher.group(1).trim(); // isbn","lastModifiedDate":"2023-10-15"},{"lineNumber":138,"author":{"gitId":"bnjm2000"},"content":" if (sMatchFound){","lastModifiedDate":"2023-10-30"},{"lineNumber":139,"author":{"gitId":"bnjm2000"},"content":" args[5] \u003d gMatcher.group(2).split(\"/s\")[0].trim(); // genre","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"bnjm2000"},"content":" args[6] \u003d sMatcher.group(2).trim(); // status","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"bnjm2000"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":" args[5] \u003d gMatcher.group(2).trim(); // genre","lastModifiedDate":"2023-10-15"},{"lineNumber":143,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":145,"author":{"gitId":"bnjm2000"},"content":" args[5] \u003d null; //genre","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"bnjm2000"},"content":" if (sMatchFound) {","lastModifiedDate":"2023-10-30"},{"lineNumber":147,"author":{"gitId":"bnjm2000"},"content":" args[4] \u003d sMatcher.group(1).trim(); // isbn","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"bnjm2000"},"content":" args[6] \u003d sMatcher.group(2).trim(); // status","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"bnjm2000"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"bnjm2000"},"content":" args[4] \u003d matcher.group(5).trim(); // isbn","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"bnjm2000"},"content":" args[6] \u003d \"Available\";","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"JoanneJo"},"content":" if (args[0].isEmpty() || args[1].isEmpty() || args[2].isEmpty() || args[3].isEmpty()","lastModifiedDate":"2023-10-15"},{"lineNumber":156,"author":{"gitId":"JoanneJo"},"content":" || args[4].isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":157,"author":{"gitId":"bnjm2000"},"content":" throw new SysLibException(\"Please state the id, title, author, tag, and ISBN.\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":" SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-19"},{"lineNumber":159,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":160,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":161,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":162,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"bnjm2000"},"content":" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":165,"author":{"gitId":"JoanneJo"},"content":" return args;","lastModifiedDate":"2023-10-15"},{"lineNumber":166,"author":{"gitId":"JoanneJo"},"content":" } catch (IllegalStateException | SysLibException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":167,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":168,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":170,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":171,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":172,"author":{"gitId":"000verflow"},"content":" public Matcher parseFindCommand(String command) throws SysLibException{","lastModifiedDate":"2023-10-15"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":" // Define a regular expression pattern to match optional flags and their values","lastModifiedDate":"2023-10-15"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":" Pattern pattern \u003d Pattern.compile(\"/(t|a|i|id)\\\\s+([^/]+)\");","lastModifiedDate":"2023-10-15"},{"lineNumber":175,"author":{"gitId":"000verflow"},"content":" return pattern.matcher(command);","lastModifiedDate":"2023-10-15"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":177,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"bnjm2000"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"bnjm2000"},"content":" * @param statusString input string status","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":" * @return Status object","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":" public static Status getStatusFromString(String statusString) {","lastModifiedDate":"2023-10-30"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":" if (statusString !\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":" statusString \u003d statusString.toLowerCase().trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":" if (statusString.equalsIgnoreCase(\"borrowed\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"bnjm2000"},"content":" return Status.BORROWED;","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":" } else if (statusString.equalsIgnoreCase(\"lost\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":" return Status.LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"bnjm2000"},"content":" // Default to Available if the status is not provided or unrecognized","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"bnjm2000"},"content":" return Status.AVAILABLE;","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":20,"bnjm2000":53,"JoanneJo":67,"DavinciDelta":11,"yingx9":43}},{"path":"src/main/java/seedu/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.storage;","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import java.io.File;","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import java.time.LocalDateTime;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import java.util.List;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EBook;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EMagazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.ENewspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"import seedu.data.Event;","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"public class Storage {","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" public static final int FIRST_INDEX \u003d 0;","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" public static final int SECOND_INDEX \u003d 1;","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" public static final int THIRD_INDEX \u003d 2;","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" public static final int FOURTH_INDEX \u003d 3;","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" public static final int FIFTH_INDEX \u003d 4;","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":" public static final int SIXTH_INDEX \u003d 5;","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" public static final int SEVENTH_INDEX \u003d 6;","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" public static final int EIGHTH_INDEX \u003d 7;","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":" public static final int NINTH_INDEX \u003d 8;","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" public static final int TENTH_INDEX \u003d 9;","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" public static final int ELEVENTH_INDEX \u003d 10;","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":" public static final int TWELFTH_INDEX \u003d 11;","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" protected File dataFile;","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":" protected String filePath;","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":" protected Parser parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" public Storage(String filePath, Parser parser) {","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":" this.filePath \u003d filePath;","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" this.dataFile \u003d new File(filePath);","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" this.parser \u003d parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" public List\u003cResource\u003e load() throws SysLibException {","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" List\u003cResource\u003e resources \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" if (this.dataFile.createNewFile()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":" System.out.println(\"Data file not found @ \" + this.filePath +","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" \"\\nCreating new data file @ \" + this.filePath);","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" Scanner dataScanner \u003d new Scanner(dataFile);","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" while (dataScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" String dataLine \u003d dataScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":" String[] splitLineArguments \u003d dataLine.split(\" \\\\| \");","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":" if (splitLineArguments[FIRST_INDEX].equals(\"R\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":" String title \u003d splitLineArguments[SECOND_INDEX].trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":" boolean isBorrowed \u003d Boolean.parseBoolean(splitLineArguments[THIRD_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" String isbn \u003d splitLineArguments[FOURTH_INDEX].trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" int copies \u003d Integer.parseInt(splitLineArguments[FIFTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":" String tag \u003d splitLineArguments[SIXTH_INDEX].trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":" int id \u003d Integer.parseInt(splitLineArguments[SEVENTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":" Status status \u003d Status.valueOf(splitLineArguments[EIGHTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" LocalDateTime ldt \u003d LocalDateTime.parse(splitLineArguments[NINTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" switch(tag){","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" case \"B\":","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":" String author \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":" String[] genres \u003d splitLineArguments[ELEVENTH_INDEX].split(\",\");","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" Book bookToAdd \u003d new Book(title, isbn, author, genres, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" bookToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" bookToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":" bookToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" resources.add(bookToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":" case \"EB\":","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":" String eauthor \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" String[] egenres \u003d splitLineArguments[ELEVENTH_INDEX].split(\",\");","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" String blink \u003d splitLineArguments[11];","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"JoanneJo"},"content":" EBook ebookToAdd \u003d new EBook(title, isbn, eauthor, egenres, id, status, blink);","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":" ebookToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":" ebookToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":" ebookToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":" resources.add(ebookToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" case \"N\":","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":" String publisher \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":" String edition \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"000verflow"},"content":" Newspaper newspaperToAdd \u003d new Newspaper(title, isbn, publisher, edition, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" newspaperToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"000verflow"},"content":" newspaperToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":" newspaperToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" resources.add(newspaperToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":" case \"EN\":","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":" String epublisher \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" String eedition \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"000verflow"},"content":" String nlink \u003d splitLineArguments[11];","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"JoanneJo"},"content":" ENewspaper enewspaperToAdd \u003d new ENewspaper(title, isbn, epublisher, eedition,","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":" id, status, nlink);","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":" enewspaperToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" enewspaperToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":" enewspaperToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":" resources.add(enewspaperToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":114,"author":{"gitId":"000verflow"},"content":" case \"M\":","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"000verflow"},"content":" String brand \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"000verflow"},"content":" String issue \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"000verflow"},"content":" Magazine magazineToAdd \u003d new Magazine(title, isbn, brand, issue, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"000verflow"},"content":" magazineToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"000verflow"},"content":" magazineToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"000verflow"},"content":" magazineToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"000verflow"},"content":" resources.add(magazineToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":124,"author":{"gitId":"000verflow"},"content":" case \"EM\":","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"000verflow"},"content":" String ebrand \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"000verflow"},"content":" String eissue \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":127,"author":{"gitId":"000verflow"},"content":" String mlink \u003d splitLineArguments[TWELFTH_INDEX];","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":" EMagazine emagazineToAdd \u003d new EMagazine(title, isbn, ebrand, eissue, id,","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"000verflow"},"content":" status, mlink);","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"000verflow"},"content":" emagazineToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"000verflow"},"content":" emagazineToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"000verflow"},"content":" emagazineToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"000verflow"},"content":" resources.add(emagazineToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"000verflow"},"content":" case \"CD\":","lastModifiedDate":"2023-11-02"},{"lineNumber":137,"author":{"gitId":"000verflow"},"content":" String creator \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"000verflow"},"content":" String type \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":139,"author":{"gitId":"000verflow"},"content":" CD cdToAdd \u003d new CD(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"000verflow"},"content":" cdToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":141,"author":{"gitId":"000verflow"},"content":" cdToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":142,"author":{"gitId":"000verflow"},"content":" cdToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"000verflow"},"content":" resources.add(cdToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":145,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"000verflow"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown resource type found, data corrupted.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"000verflow"},"content":" }else if (splitLineArguments[FIRST_INDEX].equals(\"E\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":151,"author":{"gitId":"000verflow"},"content":" // String name \u003d splitLineArguments[SECOND_INDEX];","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"000verflow"},"content":" // String description \u003d splitLineArguments[THIRD_INDEX];","lastModifiedDate":"2023-11-02"},{"lineNumber":153,"author":{"gitId":"000verflow"},"content":" // Date eventldt \u003d parseDate(splitLineArguments[FOURTH_INDEX]);","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"000verflow"},"content":" // Event newEventToAdd \u003d new Event(name, eventldt, description);","lastModifiedDate":"2023-11-02"},{"lineNumber":155,"author":{"gitId":"000verflow"},"content":" System.out.println(\"Event loading not implemented yet.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":157,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown data type found, data corrupted.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":158,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":159,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":160,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"000verflow"},"content":" } catch (IOException IOEx) {","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unable to create storage file. Please try to run with admin permissions.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"000verflow"},"content":" return resources;","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":167,"author":{"gitId":"000verflow"},"content":" public void save() throws SysLibException {","lastModifiedDate":"2023-11-02"},{"lineNumber":168,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":169,"author":{"gitId":"000verflow"},"content":" FileWriter fw \u003d new FileWriter(this.filePath);","lastModifiedDate":"2023-11-02"},{"lineNumber":170,"author":{"gitId":"000verflow"},"content":" List\u003cResource\u003e resourcelist \u003d parser.getResourceList();","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"000verflow"},"content":" List\u003cEvent\u003e eventlist \u003d parser.getEventList();","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"000verflow"},"content":" for (Resource resourceToSave : resourcelist){","lastModifiedDate":"2023-11-02"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":" String resourceSaveFormat \u003d \"\";","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":" switch (resourceToSave.getTag()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"000verflow"},"content":" case \"B\": // Book","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":" Book book \u003d (Book) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":178,"author":{"gitId":"000verflow"},"content":" book.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":179,"author":{"gitId":"000verflow"},"content":" book.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":180,"author":{"gitId":"000verflow"},"content":" book.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":181,"author":{"gitId":"000verflow"},"content":" book.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":182,"author":{"gitId":"000verflow"},"content":" book.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"000verflow"},"content":" book.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":184,"author":{"gitId":"000verflow"},"content":" book.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":185,"author":{"gitId":"000verflow"},"content":" book.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":186,"author":{"gitId":"000verflow"},"content":" book.getAuthor(),","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"000verflow"},"content":" String.join(\",\", book.getGenre()));","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":189,"author":{"gitId":"000verflow"},"content":" case \"EB\": // eBook","lastModifiedDate":"2023-11-02"},{"lineNumber":190,"author":{"gitId":"JoanneJo"},"content":" EBook ebook \u003d (EBook) resourceToSave;","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":192,"author":{"gitId":"000verflow"},"content":" ebook.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":193,"author":{"gitId":"000verflow"},"content":" ebook.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"000verflow"},"content":" ebook.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":195,"author":{"gitId":"000verflow"},"content":" ebook.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":196,"author":{"gitId":"000verflow"},"content":" ebook.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":197,"author":{"gitId":"000verflow"},"content":" ebook.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":198,"author":{"gitId":"000verflow"},"content":" ebook.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":199,"author":{"gitId":"000verflow"},"content":" ebook.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":200,"author":{"gitId":"000verflow"},"content":" ebook.getAuthor(),","lastModifiedDate":"2023-11-02"},{"lineNumber":201,"author":{"gitId":"000verflow"},"content":" String.join(\",\", ebook.getGenre()),","lastModifiedDate":"2023-11-02"},{"lineNumber":202,"author":{"gitId":"000verflow"},"content":" ebook.getLink());","lastModifiedDate":"2023-11-02"},{"lineNumber":203,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":204,"author":{"gitId":"000verflow"},"content":" case \"CD\": // CD","lastModifiedDate":"2023-11-02"},{"lineNumber":205,"author":{"gitId":"000verflow"},"content":" CD cd \u003d (CD) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":206,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":207,"author":{"gitId":"000verflow"},"content":" cd.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":208,"author":{"gitId":"000verflow"},"content":" cd.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":209,"author":{"gitId":"000verflow"},"content":" cd.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":210,"author":{"gitId":"000verflow"},"content":" cd.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":211,"author":{"gitId":"000verflow"},"content":" cd.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":212,"author":{"gitId":"000verflow"},"content":" cd.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":213,"author":{"gitId":"000verflow"},"content":" cd.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":214,"author":{"gitId":"000verflow"},"content":" cd.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":215,"author":{"gitId":"000verflow"},"content":" cd.getCreator(),","lastModifiedDate":"2023-11-02"},{"lineNumber":216,"author":{"gitId":"000verflow"},"content":" cd.getType());","lastModifiedDate":"2023-11-02"},{"lineNumber":217,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":218,"author":{"gitId":"000verflow"},"content":" case \"M\": // Magazine","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"000verflow"},"content":" Magazine magazine \u003d (Magazine) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":220,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":221,"author":{"gitId":"000verflow"},"content":" magazine.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":222,"author":{"gitId":"000verflow"},"content":" magazine.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":223,"author":{"gitId":"000verflow"},"content":" magazine.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":224,"author":{"gitId":"000verflow"},"content":" magazine.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":225,"author":{"gitId":"000verflow"},"content":" magazine.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":226,"author":{"gitId":"000verflow"},"content":" magazine.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":227,"author":{"gitId":"000verflow"},"content":" magazine.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":228,"author":{"gitId":"000verflow"},"content":" magazine.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":229,"author":{"gitId":"000verflow"},"content":" magazine.getBrand(),","lastModifiedDate":"2023-11-02"},{"lineNumber":230,"author":{"gitId":"000verflow"},"content":" magazine.getIssue());","lastModifiedDate":"2023-11-02"},{"lineNumber":231,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":232,"author":{"gitId":"000verflow"},"content":" case \"EM\": // eMagazine","lastModifiedDate":"2023-11-02"},{"lineNumber":233,"author":{"gitId":"JoanneJo"},"content":" EMagazine emagazine \u003d (EMagazine) resourceToSave;","lastModifiedDate":"2023-11-03"},{"lineNumber":234,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":235,"author":{"gitId":"000verflow"},"content":" emagazine.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":236,"author":{"gitId":"000verflow"},"content":" emagazine.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":237,"author":{"gitId":"000verflow"},"content":" emagazine.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":238,"author":{"gitId":"000verflow"},"content":" emagazine.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":239,"author":{"gitId":"000verflow"},"content":" emagazine.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":240,"author":{"gitId":"000verflow"},"content":" emagazine.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":241,"author":{"gitId":"000verflow"},"content":" emagazine.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":242,"author":{"gitId":"000verflow"},"content":" emagazine.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":243,"author":{"gitId":"000verflow"},"content":" emagazine.getLink());","lastModifiedDate":"2023-11-02"},{"lineNumber":244,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":245,"author":{"gitId":"000verflow"},"content":" case \"N\": // Newspaper","lastModifiedDate":"2023-11-02"},{"lineNumber":246,"author":{"gitId":"000verflow"},"content":" Newspaper newspaper \u003d (Newspaper) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":247,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":248,"author":{"gitId":"000verflow"},"content":" newspaper.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":249,"author":{"gitId":"000verflow"},"content":" newspaper.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":250,"author":{"gitId":"000verflow"},"content":" newspaper.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":251,"author":{"gitId":"000verflow"},"content":" newspaper.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":252,"author":{"gitId":"000verflow"},"content":" newspaper.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":253,"author":{"gitId":"000verflow"},"content":" newspaper.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":254,"author":{"gitId":"000verflow"},"content":" newspaper.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":255,"author":{"gitId":"000verflow"},"content":" newspaper.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":256,"author":{"gitId":"000verflow"},"content":" newspaper.getPublisher(),","lastModifiedDate":"2023-11-02"},{"lineNumber":257,"author":{"gitId":"000verflow"},"content":" newspaper.getEdition());","lastModifiedDate":"2023-11-02"},{"lineNumber":258,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":259,"author":{"gitId":"000verflow"},"content":" case \"EN\": // eNewspaper","lastModifiedDate":"2023-11-02"},{"lineNumber":260,"author":{"gitId":"JoanneJo"},"content":" ENewspaper enewspaper \u003d (ENewspaper) resourceToSave;","lastModifiedDate":"2023-11-03"},{"lineNumber":261,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":262,"author":{"gitId":"000verflow"},"content":" enewspaper.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":263,"author":{"gitId":"000verflow"},"content":" enewspaper.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":264,"author":{"gitId":"000verflow"},"content":" enewspaper.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":265,"author":{"gitId":"000verflow"},"content":" enewspaper.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":266,"author":{"gitId":"000verflow"},"content":" enewspaper.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":267,"author":{"gitId":"000verflow"},"content":" enewspaper.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":268,"author":{"gitId":"000verflow"},"content":" enewspaper.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":269,"author":{"gitId":"000verflow"},"content":" enewspaper.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":270,"author":{"gitId":"000verflow"},"content":" enewspaper.getLink());","lastModifiedDate":"2023-11-02"},{"lineNumber":271,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":272,"author":{"gitId":"000verflow"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":273,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown data type in list. Can\u0027t store it in file.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":274,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":275,"author":{"gitId":"000verflow"},"content":" fw.write(resourceSaveFormat);","lastModifiedDate":"2023-11-02"},{"lineNumber":276,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":277,"author":{"gitId":"000verflow"},"content":" for (Event eventToSave : eventlist){","lastModifiedDate":"2023-11-02"},{"lineNumber":278,"author":{"gitId":"000verflow"},"content":" String eventSaveFormat \u003d String.format(\"E | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":279,"author":{"gitId":"000verflow"},"content":" eventToSave.getName(),","lastModifiedDate":"2023-11-02"},{"lineNumber":280,"author":{"gitId":"000verflow"},"content":" eventToSave.getDescription(),","lastModifiedDate":"2023-11-02"},{"lineNumber":281,"author":{"gitId":"000verflow"},"content":" eventToSave.getDate());","lastModifiedDate":"2023-11-02"},{"lineNumber":282,"author":{"gitId":"000verflow"},"content":" fw.write(eventSaveFormat);","lastModifiedDate":"2023-11-02"},{"lineNumber":283,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":284,"author":{"gitId":"000verflow"},"content":" fw.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":285,"author":{"gitId":"000verflow"},"content":" } catch (IOException IOex){","lastModifiedDate":"2023-11-02"},{"lineNumber":286,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unable to save to find @ ./storage.txt\");","lastModifiedDate":"2023-11-02"},{"lineNumber":287,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":288,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":289,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":290,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":291,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"000verflow":285,"JoanneJo":6}},{"path":"src/main/java/seedu/syslib/Syslib.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.syslib;","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.storage.Storage;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import java.util.List;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"public class Syslib {","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":" * Main entry-point for the java.duke.Duke application.","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":" public static final String FILEPATH \u003d \".\\\\storage.txt\";","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":" private static UI ui;","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":" private static Parser parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":" private static Storage storage;","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":" public Syslib(String filePath) {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" ui \u003d new UI();","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" parser \u003d new Parser();","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" storage \u003d new Storage(filePath, parser);","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" try{","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" List\u003cResource\u003e resourceListLoad \u003d storage.load();","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" if (!resourceListLoad.isEmpty()){","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" ui.showLoadMessage(filePath, resourceListLoad);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" parser.setResourceList(resourceListLoad);","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" } catch (SysLibException SysLibEx){","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" System.out.println(SysLibEx);","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":" public static void main(String[] args) {","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" new Syslib(FILEPATH).run();","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":" public void run() {","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" ui.showWelcomeMessage();","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":" while (true) {","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" String response \u003d ui.readCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" parser.process(response);","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":" storage.save();","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" } catch (SysLibException SysLibEx){","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" System.out.println(SysLibEx);","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" if (response.equalsIgnoreCase(\"exit\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"000verflow":58}},{"path":"src/main/java/seedu/ui/UI.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.ui;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import java.util.List;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"public class UI {","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" public static final String LINESEPARATOR \u003d System.lineSeparator();","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" public static final String LINEDIVIDER \u003d \"____________________________________________________________\";","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" public static final String SEPARATOR_LINEDIVIDER \u003d LINESEPARATOR + LINEDIVIDER;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":" protected static String logo \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":" \" ____ _ _ _ ____ _ ___ \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":" \"/ ___| _ _ ___| | (_) |__ / ___| | |_ _|\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":" \"\\\\___ \\\\| | | / __| | | | \u0027_ \\\\ | | | | | | \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":" \" ___) | |_| \\\\__ \\\\ |___| | |_) | | |___| |___ | | \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":" \"|____/ \\\\__, |___/_____|_|_.__/ \\\\____|_____|___|\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":" \" |___/ \";","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":" protected Scanner myScanner;","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" public UI(){","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" this.myScanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" public void showWelcomeMessage(){","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" System.out.println(logo);","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"What would you like to do?\");","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" public void showExitMessage(){","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"Bye, hope to see you again soon!\");","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" public void showHelpMessage(){","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"Commands available:\");","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"add: adds a new resource to the library inventory.\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS])\");","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"delete: deletes the resource with the specified ID from the library inventory. \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. delete /id 123456789)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"list: list all resources OR filter by certain tags or genre.\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" \"(e.g. list /tag B /g Fiction\");","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"edit: Edit a listing by entering its isbn to update its details. \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"eventadd: Add an event to the event list \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])\");","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"eventlist: List out all the event list (e.g. eventlist)\");","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"eventdelete: Delete an event in the event list based on the index \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventdelete /i INDEX)\");","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"exit: displays a farewell message and exits the program (e.g. exit)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"For more information, please refer to our user guide at:\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" \"https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html\");","lastModifiedDate":"2023-10-14"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":" public void showError(Exception e){","lastModifiedDate":"2023-10-14"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":" System.out.println(e);","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" public String readCommand(){","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" System.out.print(\"\u003e \");","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":" return myScanner.nextLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" public void showLoadMessage(String filepath, List\u003cResource\u003e resourcelist){","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" System.out.println(\"Storage file found @ \" + filepath);","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" System.out.printf(\"Loaded %d listings!%n\", resourcelist.size());","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" public void showLine(){","lastModifiedDate":"2023-10-14"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" System.out.println(LINEDIVIDER);","lastModifiedDate":"2023-10-14"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":49,"bnjm2000":18,"DavinciDelta":5,"yingx9":5}},{"path":"src/test/java/seedu/DukeTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"class DukeTest {","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":" public void sampleTest() {","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"000verflow":1,"-":11}},{"path":"src/test/java/seedu/commands/AddCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"public class AddCommandTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" private final AddCommand addCommand \u003d new AddCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" public void addCommandValidData() throws SysLibException {","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" \"/g Non-Fiction, Biography /s lost\", parser);","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" Book newBook \u003d (Book) parser.getResourceList().get(0);","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getId(), 123456789);","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getTitle(), \"The Minds of Billy Milligan\");","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getAuthor(), \"Daniel Keyes\");","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getTag(), \"B\");","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getISBN(), \"987654321\");","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getGenreString(), \"Non-Fiction, Biography\");","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" assertEquals(newBook.getStatus(), Status.LOST);","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" public void addCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":" \"/g Non-Fiction, Biography\", parser);","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" String expectedOutput \u003d \"This book is added: The Minds of Billy Milligan\" + System.lineSeparator() +","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" public void addCommandInvalidId() {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eaddCommand.execute(\"/id abcd \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" \"/t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321\", parser));","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"JoanneJo"},"content":" public void addCommandInsufficientData() {","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eaddCommand.execute(\"/id \", parser));","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"000verflow":2,"bnjm2000":3,"JoanneJo":55}},{"path":"src/test/java/seedu/commands/DeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"import static seedu.util.TestUtil.getCurrentDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":"public class DeleteCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" private final AddCommand addCommand \u003d new AddCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" private final DeleteCommand deleteCommand \u003d new DeleteCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public void deleteCommandValidData() throws SysLibException {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" , parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" deleteCommand.execute(\"/id 123456789\", parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(parser.resourceList.size(), 0);","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" public void deleteCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" , parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" deleteCommand.execute(\"/id 123456789\", parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"Looking for ID: 123456789...\" + System.lineSeparator()+","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" \"This resource is removed: \" + System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" \"[B] ID: 123456789 Title: The Minds of Billy Milligan ISBN: 987654321 Author: Daniel Keyes Genre: - \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" \"Status: AVAILABLE \" + \"Received Date: \" + getCurrentDate() + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" public void deleteCommandInvalidId() {","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e deleteCommand.execute(\"\", parser));","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":46,"yingx9":2}},{"path":"src/test/java/seedu/commands/EditCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.BeforeAll;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import seedu.util.TestUtil;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.EditCommand.RESOURCE_NOT_FOUND;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.EditCommand.EDIT_SUCCESS;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLastLineDivider;","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"public class EditCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":" private static List\u003cResource\u003e testResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" private Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" private List\u003cResource\u003e emptyResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" private TestUtil testUtil \u003d new TestUtil();","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" private Command editCommand \u003d new EditCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" @BeforeAll","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" public static void setup() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":" testResourceList \u003d TestUtil.fillTestList();","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" public void testEditResourceNotFound() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(editCommand, \"/i 123 /t NEWTITLE\", emptyResourceList);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d RESOURCE_NOT_FOUND;","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" public void testNoArgumentGiven() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" assertThrows(SysLibException.class, ()-\u003eeditCommand.execute(\"/i 123\", parser));","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" public void testNotBookBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" assertThrows(SysLibException.class, ()-\u003eeditCommand.execute(\"/i 1 /g Horror\", parser));","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" public void testEditTitleBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":" executeEditSuccessBehavior(\"/i 2 /t NEWTITLE\");","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" public void testEditAuthorBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" executeEditSuccessBehavior(\"/i 2 /a NEWAUTHOR\");","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" public void testEditGenreBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" executeEditSuccessBehavior(\"/i 2 /g Horror, Action, Fantasy\");","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" private void executeEditSuccessBehavior(String argument) throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(editCommand, argument, testResourceList);","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d EDIT_SUCCESS + formatLastLineDivider((testResourceList.get(1)).toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"000verflow":2,"yingx9":71}},{"path":"src/test/java/seedu/commands/ExitCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"class ExitCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":" void execute() {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" ExitCommand exitCommand \u003d new ExitCommand();","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":" exitCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Bye, hope to see you again soon!\" + System.lineSeparator()+","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bnjm2000":28}},{"path":"src/test/java/seedu/commands/FindCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":"public class FindCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" private FindCommand findCommand;","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" private Parser parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" private final ByteArrayOutputStream outContent \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" @BeforeEach","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":" void setUp() {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" findCommand \u003d new FindCommand();","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" parser \u003d new Parser();","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" parser.resourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new Book(\"Title1\", \"ISBN1\", \"Author1\", new String[]{\"horror\"}, 1234, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new Magazine(\"Title2\", \"ISBN2\", \"VOGUE2\", \"1234\", 5678, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new Newspaper(\"Title3\", \"ISBN3\", \"Publisher3\", \"1234\", 9101, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new CD(\"Title4\", \"Creator4\", \"Creator4\", \"1234\", 1121, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":" outContent.reset();","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":" System.setOut(new PrintStream(outContent));","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" @AfterEach","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" void tearDown() {","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" void testSetAndGetTitle() {","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" findCommand.setTitle(\"TitleTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":" assertEquals(\"TitleTest\", findCommand.getTitle());","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" void testSetAndGetAuthor() {","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" findCommand.setAuthor(\"AuthorTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":" assertEquals(\"AuthorTest\", findCommand.getAuthor());","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":" void testSetAndGetISBN() {","lastModifiedDate":"2023-10-17"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" findCommand.setISBN(\"ISBNTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" assertEquals(\"ISBNTest\", findCommand.getISBN());","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" void testSetAndGetID() {","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":" findCommand.setID(\"IDTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" assertEquals(\"IDTest\", findCommand.getID());","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" void testExecuteWithInvalidFlag() {","lastModifiedDate":"2023-10-17"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e findCommand.execute(\"/x InvalidFlag\", parser));","lastModifiedDate":"2023-10-17"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":" void testExecuteWithNoFilter() {","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e findCommand.execute(\"\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" void testExecuteFindTitleMatch() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/t Title1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Title1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":" void testExecuteFindAuthorMatch() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a Author1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Author1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":95,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" void testExecuteFindISBNMatch() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":97,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/i ISBN1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"ISBN1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":100,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":" void testExecuteNoMatchesFound() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/t NonexistentTitle\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"There are no resources found matching the given filters.\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":105,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":106,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":" void testExecuteFindMagazineBrandMatch() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a VOGUE2\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"VOGUE2\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"000verflow"},"content":" void testExecuteFindNewspaperPublisherMatch() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":115,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a Publisher3\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Publisher3\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":118,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":119,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"000verflow"},"content":" void testExecuteFindCDMatch() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a Creator4\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Creator4\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":124,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":125,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":127,"author":{"gitId":"000verflow"},"content":" void testExecuteMultipleFilters() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":128,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/t Title1 /a Author1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":129,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Title1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":130,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Author1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":131,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":132,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":133,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":134,"author":{"gitId":"000verflow"},"content":" void testExecuteInvalidFormat() {","lastModifiedDate":"2023-10-17"},{"lineNumber":135,"author":{"gitId":"000verflow"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e findCommand.execute(\"find /z Invalid\", parser));","lastModifiedDate":"2023-10-17"},{"lineNumber":136,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":137,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"000verflow":137,"bnjm2000":1}},{"path":"src/test/java/seedu/commands/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"class HelpCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":" void execute() {","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":" HelpCommand helpCommand \u003d new HelpCommand();","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" helpCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Commands available:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" \"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" \"/tag TAG /i ISBN [/g GENRE /s STATUS])\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" \"delete: deletes the resource with the specified ID from the library inventory. \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. delete /id 123456789)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" \"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" \"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":" System.lineSeparator() + \"edit: Edit a listing by entering its isbn to update its details. \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" \"eventadd: Add an event to the event list (e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventlist: List out all the event list (e.g. eventlist)\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventdelete: Delete an event in the event list based on the index \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventdelete /i INDEX)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" \"exit: displays a farewell message and exits the program (e.g. exit)\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" \"For more information, please refer to our user guide at:\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" \"https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bnjm2000":40,"DavinciDelta":4,"yingx9":1}},{"path":"src/test/java/seedu/commands/ListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.BeforeAll;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import seedu.util.TestUtil;","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.GENERIC_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.FILTER_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.displayResourcesDetails;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.matchedResources;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"public class ListCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" private static List\u003cResource\u003e testResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" private Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" private List\u003cResource\u003e emptyResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" private TestUtil testUtil \u003d new TestUtil();","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" private Command listCommand \u003d new ListCommand();","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" @BeforeAll","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" public static void setup() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" testResourceList \u003d TestUtil.fillTestList();","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" public void testEmptyListMessage() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(listCommand, \"\", emptyResourceList);","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d GENERIC_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" expectedMessage +\u003d ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" public void testNoTagArgBehavior() {","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003elistCommand.execute(\"/tag\", parser));","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" public void testNoGenreArgBehavior() {","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003elistCommand.execute(\"/g\", parser));","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" public void testNoStatusArgBehavior() {","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-11-04"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003elistCommand.execute(\"/s\", parser));","lastModifiedDate":"2023-11-04"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" public void testListByTagFilterBehavior() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/tag B\");","lastModifiedDate":"2023-11-04"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":" public void testListByGenreFilterBehavior() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/g Horror\");","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/g Adventure\");","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/g Fiction\");","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"yingx9"},"content":" public void testListByStatusFilterBehavior() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":85,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/s AVAILABLE\");","lastModifiedDate":"2023-11-04"},{"lineNumber":86,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":" public void executeListFilterBehavior(String argument) throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(listCommand, argument, testResourceList);","lastModifiedDate":"2023-11-04"},{"lineNumber":93,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d FILTER_MESSAGE + displayResourcesDetails(matchedResources);","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" public void testNoFilteredListDisplay() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(listCommand, \"/g Thriller\", testResourceList);","lastModifiedDate":"2023-10-19"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d FILTER_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":" expectedMessage +\u003d ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"000verflow":2,"yingx9":104}},{"path":"src/test/java/seedu/commands/events/EventAddCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventAddCommandTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final EventAddCommand eventAddCommand \u003d new EventAddCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandValidData() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1-12-2001 /desc testing 123\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d parser.eventList.get(0).toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"testrun | 01-12-2001 | testing 123\";","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(output, expectedOutput);","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1-12-2001 /desc testing 123\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"Event inserted at: 0\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandInvalidId() {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" String input \u003d \"/t testrun /date 1 May 2001 /desc testing 123\";","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventAddCommand.execute(","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" \"/t testrun /date 1 May 2001 /desc testing 123\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandInsufficientData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventAddCommand.execute(\"/t \", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":47}},{"path":"src/test/java/seedu/commands/events/EventDeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventDeleteCommandTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final EventAddCommand eventAddCommand \u003d new EventAddCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" private final EventDeleteCommand eventDeleteCommand \u003d new EventDeleteCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public void eventDeleteCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1-12-2001 /desc testing 123\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" eventDeleteCommand.execute(\"/i 0\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"This event is removed:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" \"testrun | 01-12-2001 | testing 123\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" public void eventDeleteCommandInvalidIndex() {","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventDeleteCommand.execute(","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" \"/i aaaaa\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" public void eventDeleteCommandInsufficientData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventDeleteCommand.execute(\"/i \", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":41}},{"path":"src/test/java/seedu/commands/events/EventListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventListCommandTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" private final EventAddCommand eventAddCommand \u003d new EventAddCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" private final EventListCommand eventListCommand \u003d new EventListCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" public void eventListCommandOutputEmpty() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" eventListCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"The event list is empty!\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(output, expectedOutput);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" public void eventListCommandOutputMultiple() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1-12-2001 /desc testing 123\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun2 /date 1-12-2002 /desc testing 1234\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" eventListCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"This is the current event list:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" \"0: testrun | 01-12-2001 | testing 123\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" \"1: testrun2 | 01-12-2002 | testing 1234\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" public void eventListCommandInvalidInput() {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventListCommand.execute(","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" \"random\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":50}},{"path":"src/test/java/seedu/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"import seedu.data.CreateResource;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertArrayEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertNull;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import static seedu.util.TestUtil.getCurrentDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":"class ParserTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" public void testProcessExitCommand() {","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"exit\";","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Bye, hope to see you again soon!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" public void testProcessHelpCommand() {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"help\";","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Commands available:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bnjm2000"},"content":" \"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"bnjm2000"},"content":" \"/tag TAG /i ISBN [/g GENRE /s STATUS])\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" \"delete: deletes the resource with the specified ID from the library inventory. \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. delete /id 123456789)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" \"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" \"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":" System.lineSeparator() + \"edit: Edit a listing by entering its isbn to update its details. \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" \"eventadd: Add an event to the event list (e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventlist: List out all the event list (e.g. eventlist)\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventdelete: Delete an event in the event list based on the index \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventdelete /i INDEX)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" \"exit: displays a farewell message and exits the program (e.g. exit)\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bnjm2000"},"content":" \"For more information, please refer to our user guide at:\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bnjm2000"},"content":" \"https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bnjm2000"},"content":" public void testProcessUnknownCommand() {","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"bye\";","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":80,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":81,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"no commands found. Enter \\\"help\\\" for a list of commands.\";","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"____________________________________________________________\";","lastModifiedDate":"2023-10-16"},{"lineNumber":89,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bnjm2000"},"content":" public void testProcessCommands() {","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"bnjm2000"},"content":" //Test add","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"add /id 1 /t Surrounded by Idiots /a Thomas Erikson \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"bnjm2000"},"content":" \"/tag B /i 9781250255174 /g Self-help\";","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":102,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":107,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":108,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"This book is added: Surrounded by Idiots\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":109,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();;","lastModifiedDate":"2023-10-16"},{"lineNumber":110,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":111,"author":{"gitId":"bnjm2000"},"content":" //Add second book","lastModifiedDate":"2023-10-16"},{"lineNumber":112,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"add /id 2 /t The Subtle Art of Not Giving a F*ck /a Mark Manson \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":113,"author":{"gitId":"bnjm2000"},"content":" \"/tag B /i 9780062457714 /g Self-help\";","lastModifiedDate":"2023-10-16"},{"lineNumber":114,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":115,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"This book is added: The Subtle Art of Not Giving a F*ck\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" \"____________________________________________________________\" + System.lineSeparator()","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator();;","lastModifiedDate":"2023-10-26"},{"lineNumber":118,"author":{"gitId":"bnjm2000"},"content":" //Test list","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"list\";","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Listing all resources in the Library:\" + System.lineSeparator() + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"bnjm2000"},"content":" \"1. [B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Erikson Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"bnjm2000"},"content":" \"2. [B] ID: 2 Title: The Subtle Art of Not Giving a F*ck ISBN: 9780062457714 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":126,"author":{"gitId":"yingx9"},"content":" \"Author: Mark Manson Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator() + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"yingx9"},"content":" \"There are currently 2 resource(s).\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":130,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"bnjm2000"},"content":" //Test find","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"find /t The Subtle Art of Not Giving a F*ck\";","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":136,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Here are resources that matched the given filters:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":137,"author":{"gitId":"bnjm2000"},"content":" \"[B] ID: 2 Title: The Subtle Art of Not Giving a F*ck ISBN: 9780062457714 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":138,"author":{"gitId":"yingx9"},"content":" \"Author: Mark Manson Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate() +","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"yingx9"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();;","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":142,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":143,"author":{"gitId":"bnjm2000"},"content":" //Negative find test","lastModifiedDate":"2023-10-16"},{"lineNumber":144,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"find /t No Such Book\";","lastModifiedDate":"2023-10-16"},{"lineNumber":145,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":146,"author":{"gitId":"000verflow"},"content":" expectedOutput +\u003d \"There are no resources found matching the given filters.\" + System.lineSeparator() +","lastModifiedDate":"2023-10-17"},{"lineNumber":147,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();;","lastModifiedDate":"2023-10-16"},{"lineNumber":148,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":149,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":150,"author":{"gitId":"bnjm2000"},"content":" //Test edit","lastModifiedDate":"2023-10-30"},{"lineNumber":151,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"edit /i 9781250255174 /a Thomas\";","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Successfully updated! Your updated resource:\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"bnjm2000"},"content":" + System.lineSeparator() + \"[B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":" +System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-30"},{"lineNumber":159,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-30"},{"lineNumber":160,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":161,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"edit /i 9781250255174 /s lost\";","lastModifiedDate":"2023-10-30"},{"lineNumber":162,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Successfully updated! Your updated resource:\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"bnjm2000"},"content":" + System.lineSeparator() + \"[B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Genre: Self-help Status: LOST\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":" +System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-30"},{"lineNumber":169,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"bnjm2000"},"content":" //Test delete","lastModifiedDate":"2023-10-16"},{"lineNumber":171,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"delete /id 1\";","lastModifiedDate":"2023-10-16"},{"lineNumber":172,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":173,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":174,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Looking for ID: 1...\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":175,"author":{"gitId":"bnjm2000"},"content":" \"This resource is removed: \" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":176,"author":{"gitId":"bnjm2000"},"content":" \"[B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Genre: Self-help Status: LOST\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":181,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":" public void testParseAddCommand() throws SysLibException {","lastModifiedDate":"2023-10-16"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":" // Test case 1: Valid input with both genre and status","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"bnjm2000"},"content":" String statement1 \u003d \"add /id 123456789 /t Moby Dick /a Herman Melville /tag B /i 9780763630188 \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":" \"/g Adventure, Fiction /s lost\";","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":" String[] result \u003d Parser.parseAddCommand(statement1);","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"123456789\", result[0]);","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Moby Dick\", result[1]);","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Herman Melville\", result[2]);","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"B\", result[3]);","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"9780763630188\", result[4]);","lastModifiedDate":"2023-10-30"},{"lineNumber":195,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Adventure, Fiction\", result[5]);","lastModifiedDate":"2023-10-30"},{"lineNumber":196,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"lost\", result[6]);","lastModifiedDate":"2023-10-30"},{"lineNumber":197,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":198,"author":{"gitId":"bnjm2000"},"content":" // Test case 2: Valid input without genre","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"bnjm2000"},"content":" String statement2 \u003d \"add /id 123 /t Moby Dick /a Herman Melville /tag B /i 9780763630188 /s lost\";","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"bnjm2000"},"content":" result \u003d Parser.parseAddCommand(statement2);","lastModifiedDate":"2023-10-31"},{"lineNumber":201,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":202,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"123\", result[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":203,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Moby Dick\", result[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":204,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Herman Melville\", result[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":205,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"B\", result[3]);","lastModifiedDate":"2023-10-31"},{"lineNumber":206,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"9780763630188\", result[4]);","lastModifiedDate":"2023-10-31"},{"lineNumber":207,"author":{"gitId":"bnjm2000"},"content":" assertNull(result[5]);","lastModifiedDate":"2023-10-31"},{"lineNumber":208,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"lost\", result[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":209,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":210,"author":{"gitId":"bnjm2000"},"content":" // Test case 3: Valid input without status and genre","lastModifiedDate":"2023-10-31"},{"lineNumber":211,"author":{"gitId":"bnjm2000"},"content":" String statement3 \u003d \"add /id 456 /t Moby Dick /a Herman Melville /tag B /i 9780763630188\";","lastModifiedDate":"2023-10-31"},{"lineNumber":212,"author":{"gitId":"bnjm2000"},"content":" result \u003d Parser.parseAddCommand(statement3);","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":214,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"456\", result[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":215,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Moby Dick\", result[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":216,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Herman Melville\", result[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":217,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"B\", result[3]);","lastModifiedDate":"2023-10-31"},{"lineNumber":218,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"9780763630188\", result[4]);","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"bnjm2000"},"content":" assertNull(result[5]);","lastModifiedDate":"2023-10-31"},{"lineNumber":220,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Available\", result[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":221,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":222,"author":{"gitId":"bnjm2000"},"content":" // Test case 4: Invalid input (missing /tag b)","lastModifiedDate":"2023-10-31"},{"lineNumber":223,"author":{"gitId":"bnjm2000"},"content":" String statement4 \u003d \"add /id 123456789 /t Moby Dick /a Herman Melville /tag C /i 9780763630188 \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"bnjm2000"},"content":" \"/g Adventure, Fiction /s Borrowed\";","lastModifiedDate":"2023-10-30"},{"lineNumber":225,"author":{"gitId":"bnjm2000"},"content":" assertThrows(SysLibException.class, () -\u003e Parser.parseAddCommand(statement4));","lastModifiedDate":"2023-10-31"},{"lineNumber":226,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":227,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":228,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":229,"author":{"gitId":"bnjm2000"},"content":" public void testParseAddBook() throws SysLibException {","lastModifiedDate":"2023-10-16"},{"lineNumber":230,"author":{"gitId":"bnjm2000"},"content":" // Test case 1: Valid input with /g GENRE and /s STATUS","lastModifiedDate":"2023-10-30"},{"lineNumber":231,"author":{"gitId":"bnjm2000"},"content":" String statement1 \u003d \"/id ID /t TITLE /a AUTHOR /tag b /i ISBN /g GENRE /s lost\";","lastModifiedDate":"2023-10-30"},{"lineNumber":232,"author":{"gitId":"bnjm2000"},"content":" String[] expectedArgs1 \u003d {\"ID\", \"TITLE\", \"AUTHOR\", \"b\", \"ISBN\", \"GENRE\", \"lost\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"bnjm2000"},"content":" assertArrayEquals(expectedArgs1, Parser.parseAddBook(statement1));","lastModifiedDate":"2023-10-16"},{"lineNumber":234,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":235,"author":{"gitId":"bnjm2000"},"content":" // Test case 2: Valid input without /g GENRE or /s STATUS","lastModifiedDate":"2023-10-30"},{"lineNumber":236,"author":{"gitId":"bnjm2000"},"content":" String statement2 \u003d \"/id ID /t TITLE /a AUTHOR /tag b /i ISBN\";","lastModifiedDate":"2023-10-16"},{"lineNumber":237,"author":{"gitId":"bnjm2000"},"content":" String[] expectedArgs2 \u003d {\"ID\", \"TITLE\", \"AUTHOR\", \"b\", \"ISBN\", null, \"Available\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":238,"author":{"gitId":"bnjm2000"},"content":" assertArrayEquals(expectedArgs2, Parser.parseAddBook(statement2));","lastModifiedDate":"2023-10-16"},{"lineNumber":239,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":240,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":241,"author":{"gitId":"JoanneJo"},"content":" // CreateResourceTest","lastModifiedDate":"2023-10-31"},{"lineNumber":242,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":243,"author":{"gitId":"bnjm2000"},"content":" public void testCreateBook() {","lastModifiedDate":"2023-10-16"},{"lineNumber":244,"author":{"gitId":"bnjm2000"},"content":" String[] args \u003d {\"123\", \"CS2113T\", \"W11\", \"B\", \"1234\", \"Horror\", \"lost\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":246,"author":{"gitId":"bnjm2000"},"content":" Book book \u003d null;","lastModifiedDate":"2023-10-16"},{"lineNumber":247,"author":{"gitId":"JoanneJo"},"content":" book \u003d CreateResource.createBook(args);","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":249,"author":{"gitId":"bnjm2000"},"content":" int expectedId \u003d 123;","lastModifiedDate":"2023-10-16"},{"lineNumber":250,"author":{"gitId":"bnjm2000"},"content":" String expectedTitle \u003d \"CS2113T\";","lastModifiedDate":"2023-10-16"},{"lineNumber":251,"author":{"gitId":"bnjm2000"},"content":" String expectedAuthor \u003d \"W11\";","lastModifiedDate":"2023-10-16"},{"lineNumber":252,"author":{"gitId":"bnjm2000"},"content":" String expectedIsbn \u003d \"1234\";","lastModifiedDate":"2023-10-16"},{"lineNumber":253,"author":{"gitId":"bnjm2000"},"content":" String[] expectedGenres \u003d { \"Horror\" };","lastModifiedDate":"2023-10-16"},{"lineNumber":254,"author":{"gitId":"bnjm2000"},"content":" Status expectedStatus \u003d Status.LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":255,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":256,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedId, book.getId());","lastModifiedDate":"2023-10-16"},{"lineNumber":257,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedTitle, book.getTitle());","lastModifiedDate":"2023-10-16"},{"lineNumber":258,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedAuthor, book.getAuthor());","lastModifiedDate":"2023-10-16"},{"lineNumber":259,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedIsbn, book.getISBN());","lastModifiedDate":"2023-10-16"},{"lineNumber":260,"author":{"gitId":"bnjm2000"},"content":" assertArrayEquals(expectedGenres, book.getGenre());","lastModifiedDate":"2023-10-16"},{"lineNumber":261,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedStatus, book.getStatus());","lastModifiedDate":"2023-10-30"},{"lineNumber":262,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":263,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":264,"author":{"gitId":"bnjm2000"},"content":" public void testCreateBookInvalidId() {","lastModifiedDate":"2023-10-16"},{"lineNumber":265,"author":{"gitId":"bnjm2000"},"content":" String[] args \u003d {\"not_a_number\", \"Sample Title\", \"Sample Author\", \"\", \"Sample ISBN\", \"Sample Genre\"};","lastModifiedDate":"2023-10-16"},{"lineNumber":266,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":267,"author":{"gitId":"JoanneJo"},"content":" assertThrows(NumberFormatException.class, () -\u003e CreateResource.createBook(args));","lastModifiedDate":"2023-10-31"},{"lineNumber":268,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":269,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"000verflow":3,"bnjm2000":239,"JoanneJo":4,"DavinciDelta":6,"yingx9":17}},{"path":"src/test/java/seedu/util/TestUtil.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.util;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import java.time.LocalDateTime;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"import java.util.List;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":"public class TestUtil {","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":" public String getOutputMessage(Command c, String m, List\u003cResource\u003e resourceList) throws SysLibException {","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" parser.resourceList \u003d resourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":" CommandResult commandResult \u003d c.execute(m, parser);","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":" return commandResult.feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" public static String getCurrentDate(){","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" LocalDateTime dateReceived \u003d LocalDateTime.now();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd MMM yyyy\");","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" String formattedDate \u003d dateReceived.format(formatter);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" return formattedDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" public static List\u003cResource\u003e fillTestList() {","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" List\u003cResource\u003e testResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" String[] genres \u003d {\"Horror\", \"Fiction\"};","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" String[] genresAdventure \u003d {\"Adventure\"};","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" String[] genresNull \u003d {null};","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" Resource test1 \u003d new Resource(\"title1\", \"1\", 12345, Status.AVAILABLE);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" Book testBook \u003d new Book(\"title2\", \"2\", \"author\", genres, 123123, Status.AVAILABLE);","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" Book testBook2 \u003d new Book(\"title3\", \"3\", \"author\", genresAdventure, 123123,","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":" Status.AVAILABLE);","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" Book testBook3 \u003d new Book(\"title3\", \"4\", \"author\", genresNull, 123123, Status.AVAILABLE);","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" testResourceList.add(test1);","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" testResourceList.add(testBook);","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" testResourceList.add(testBook2);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" testResourceList.add(testBook3);","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" return testResourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"000verflow":3,"bnjm2000":22,"JoanneJo":1,"yingx9":25}}] +[{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" mainClass.set(\"seedu.syslib.Syslib\")","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"-"},"content":" archiveBaseName.set(\"duke\")","lastModifiedDate":"2023-09-24"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"000verflow":1,"-":45,"yingx9":1}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"|-------------------------------------------------------------------------|:-------------:|:-----------------------------------------:|:--------------------------------:|","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"| ![yingxia_portfolio.jpg](team/pictures/yingxia_portfolio.jpg) | Loke Ying Xia | [Github](https://github.com/yingx9) | [Portfolio](team/YingXia.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"| ![benjaminng_portfolio.jpeg](team/pictures/benjaminng_portfolio.jpeg) | Benjamin Ng | [Github](https://github.com/bnjm2000) | [Portfolio](team/BenjaminNg.md) |","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":"| ![joanneang_portfolio.jpg](team/pictures/joanneang_portfolio.jpg) | Joanne Ang | [Github](https://github.com/JoanneJo) | [Portfolio](team/JoanneAng.md) |","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"| ![ashokbalaji_portfolio.jpg](./team/pictures/ashokbalaji_portfolio.jpg) | Ashok Balaji | [Github](https://github.com/000verflow) | [Portfolio](team/ashokbalaji.md) |","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"| ![wuxingyu_protfolio.jpeg](./team/pictures/wuxingyu_portfolio.jpeg) | Wu Xingyu | [Github](https://github.com/DavinciDelta) | [Portfolio](team/WuXingyu.md) |","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"bnjm2000":2,"JoanneJo":2,"DavinciDelta":1,"-":1,"yingx9":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# Developer Guide","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"## Acknowledgements","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"{list here sources of all reused/adapted ideas, code, documentation, and third-party libraries -- include links to the original source as well}","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"## Setting Up \u0026 Getting Started","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"1. Fork the repo at https://github.com/AY2324S1-CS2113T-W11-1/tp.","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"2. Clone the fork into your computer.","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"## Design \u0026 Implementation","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":14,"author":{"gitId":"-"},"content":"{Describe the design and implementation of the product. Use UML diagrams and short code snippets where applicable.}","lastModifiedDate":"2020-05-24"},{"lineNumber":15,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"### Architecture","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"\u003cimg src\u003d\"images/ArchitectureDiagram.png\" /\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"**Main components of SysLib Architecture**","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"SysLib currently consists of five main components:","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"- `UI`: User Interaction","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"- `Parser`: Parsing User Response ","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"- `Command`: Command Executor","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"- `Data`: Holds the data of SysLib in memory such as the Resource List","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"- `Storage`: Loads data from file in hard disk, and saves data to hard disk on program exit","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":" ","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"### UI Component","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"### Parser Component","lastModifiedDate":"2023-10-25"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":"### Command Component","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"### Data Component","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":"### Storage Component","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"## Implementation ","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":"This section provides details on how certain features are implemented. ","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"### Find Resource Feature","lastModifiedDate":"2023-10-27"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":"The `find` command allows users to search for resources based on specified filters such as author (`/a`), ISBN (`/i`), ID (`/id`), and title (`/t`). The results will show all resources that match any of the given filters.","lastModifiedDate":"2023-10-27"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":"\u003e For non-book resources, `author` refers to `publisher`,`creator` and `brand` for Newspapers, CD\u0027s and Magazines","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"\u003e respectively.","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":"`find` has the following options:","lastModifiedDate":"2023-10-27"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":"- `find /id [ID]`","lastModifiedDate":"2023-10-27"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":"- `find /t [TITLE]`","lastModifiedDate":"2023-10-27"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":"- `find /a [AUTHOR]`","lastModifiedDate":"2023-10-27"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"- `find /i [ISBN]`","lastModifiedDate":"2023-10-27"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"Multiple filters can also be combined:","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":"- `find /t [TITLE] /a [AUTHOR]`","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":"#### Implementation","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":"Upon receiving the `find` command, the system will:","lastModifiedDate":"2023-10-27"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":"1. Parse the filters and their associated values.","lastModifiedDate":"2023-10-27"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":"2. Filter the resources based on the given filters.","lastModifiedDate":"2023-10-27"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":"3. Display the matching resources.","lastModifiedDate":"2023-10-27"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-10-27"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":"**Step 1.** The user inputs the command: `find /a \"F. Scott Fitzgerald\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":"**Step 2.** The `UI` component forwards the input to `SYSLIB`, which then sends it to the `PARSER`.","lastModifiedDate":"2023-10-27"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":"**Step 3.** The `PARSER` processes the command, extracts the `author` filter, and retrieves all resources written by \"F. Scott Fitzgerald\".","lastModifiedDate":"2023-10-27"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":"**Step 4.** The matching resources are displayed to the user.","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":"#### Sequence Diagram","lastModifiedDate":"2023-10-27"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":"\u003cimg src\u003d\"images/FindSequenceDiagram.png\" /\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":"### Examples for Testing","lastModifiedDate":"2023-10-27"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":"1. **Find by Author**","lastModifiedDate":"2023-10-27"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":" - Test case: `find /a \"F. Scott Fitzgerald\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" Expected: All resources written by F. Scott Fitzgerald are displayed.","lastModifiedDate":"2023-10-27"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":"2. **Find by ISBN**","lastModifiedDate":"2023-10-27"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":" - Test case: `find /i \"9780061120084\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":95,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" Expected: The resource with ISBN \"9780061120084\" is displayed, which should be \"To Kill a Mockingbird\" by Harper Lee.","lastModifiedDate":"2023-10-27"},{"lineNumber":97,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":"3. **Find by ID**","lastModifiedDate":"2023-10-27"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" - Test case: `find /id 2`","lastModifiedDate":"2023-10-27"},{"lineNumber":100,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":" Expected: The resource with ID \"2\" is displayed, which should be \"To Kill a Mockingbird\" by Harper Lee.","lastModifiedDate":"2023-10-27"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":"4. **Find by Title**","lastModifiedDate":"2023-10-27"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" - Test case: `find /t \"The Great Gatsby\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":105,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":106,"author":{"gitId":"000verflow"},"content":" Expected: The resource titled \"The Great Gatsby\" is displayed.","lastModifiedDate":"2023-10-27"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":"5. **Combining Filters**","lastModifiedDate":"2023-10-27"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" - Test case: `find /a \"F. Scott Fitzgerald\" /t \"The Great Gatsby\"`","lastModifiedDate":"2023-10-27"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":" Expected: Resources that match both the title \"The Great Gatsby\" and the author \"F. Scott Fitzgerald\" are displayed.","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":"### Add Resource Feature","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":"The `add` feature is responsible for processing user commands to add a new book to SysLib. It is facilitated by ","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":"the `AddCommand` component. It works with `Parser` and `Command` components to parse and validate the user input. ","lastModifiedDate":"2023-10-26"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":"The new book is stored internally in `resourceList` as a `Book`. ","lastModifiedDate":"2023-10-26"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":120,"author":{"gitId":"bnjm2000"},"content":"`add` has seven options:","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":"- add /id [id] /t [title] /a [author] /tag [tag] /i [isbn]","lastModifiedDate":"2023-10-26"},{"lineNumber":122,"author":{"gitId":"bnjm2000"},"content":"- add /id [id] /t [title] /a [author] /tag [tag] /i [isbn] _/g [genre] /s [status]_","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":"#### Implementation","lastModifiedDate":"2023-10-26"},{"lineNumber":125,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":126,"author":{"gitId":"JoanneJo"},"content":"It implements the following operations:","lastModifiedDate":"2023-10-26"},{"lineNumber":127,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":"- `ADDCOMMAND#parseArgument(statement: String)` -- Parses the input command to extract relevant information.","lastModifiedDate":"2023-10-26"},{"lineNumber":129,"author":{"gitId":"JoanneJo"},"content":"- `ADDCOMMAND#validate(statement: String, values: String[])` -- Validates the input statement to ensure that it is valid.","lastModifiedDate":"2023-10-26"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":"- `ADDCOMMAND#createBook(values: String[])` -- Creates a new book based on the parsed and validated values.","lastModifiedDate":"2023-10-26"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-10-26"},{"lineNumber":133,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":"Step 1. The user inputs the command: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-10-26"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":138,"author":{"gitId":"JoanneJo"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`add`). It then calls ","lastModifiedDate":"2023-10-26"},{"lineNumber":139,"author":{"gitId":"JoanneJo"},"content":"`ADDCOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-10-26"},{"lineNumber":140,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":141,"author":{"gitId":"JoanneJo"},"content":"Step 4. The `ADDCOMMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-10-26"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":"- Calls `ADDCOMMAND#parseArgument(statement: String)` to extract values for ID, title, author, ISBN, tag, and genres.","lastModifiedDate":"2023-10-26"},{"lineNumber":143,"author":{"gitId":"JoanneJo"},"content":"- Calls `ADDCOMMAND#validate(statement: String, values: String[])` to ensure the validity of the input command.","lastModifiedDate":"2023-10-26"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":145,"author":{"gitId":"JoanneJo"},"content":"Step 5. The `COMMAND` component processes the input command to ensure that it meets the required format and constraints.","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"JoanneJo"},"content":"It prepares the argument values for further processing.","lastModifiedDate":"2023-10-26"},{"lineNumber":147,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":148,"author":{"gitId":"JoanneJo"},"content":"Step 6. Since the `tag` argument in the input command indicates that it is a book, the `ADDCOMMAND` determines that the","lastModifiedDate":"2023-10-26"},{"lineNumber":149,"author":{"gitId":"JoanneJo"},"content":"key is equal to `b` (ignoring case). It then creates a new `Book` object using the parsed values (title, ISBN, author, ","lastModifiedDate":"2023-10-26"},{"lineNumber":150,"author":{"gitId":"JoanneJo"},"content":"genres, ID).","lastModifiedDate":"2023-10-26"},{"lineNumber":151,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":152,"author":{"gitId":"JoanneJo"},"content":"Step 7. The newly created book is forwarded to the `PARSER` to be added to the `resourceList`.","lastModifiedDate":"2023-10-26"},{"lineNumber":153,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"JoanneJo"},"content":"#### Sequence Diagram","lastModifiedDate":"2023-10-26"},{"lineNumber":155,"author":{"gitId":"JoanneJo"},"content":"The following sequence diagram shows how the add function works:","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"JoanneJo"},"content":"\u003cimg src\u003d\"images/AddSequenceDiagram.png\"/\u003e","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":"### Listing Resources Feature","lastModifiedDate":"2023-10-25"},{"lineNumber":159,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":160,"author":{"gitId":"yingx9"},"content":"The `list` command works with the `Parser` and `Command` component to execute the correct action. ","lastModifiedDate":"2023-10-25"},{"lineNumber":161,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":162,"author":{"gitId":"yingx9"},"content":"`list` has four options:","lastModifiedDate":"2023-10-25"},{"lineNumber":163,"author":{"gitId":"yingx9"},"content":"- list","lastModifiedDate":"2023-10-25"},{"lineNumber":164,"author":{"gitId":"yingx9"},"content":"- list _/tag [tag]_","lastModifiedDate":"2023-10-25"},{"lineNumber":165,"author":{"gitId":"yingx9"},"content":"- list _/g [genre]_","lastModifiedDate":"2023-10-25"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":"- list _/tag [tag]_ _/g [genre]_","lastModifiedDate":"2023-10-25"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":168,"author":{"gitId":"yingx9"},"content":"When `list` is specified with both `tag` and `genre` filters, it is `AND` inclusive, listing only ","lastModifiedDate":"2023-10-25"},{"lineNumber":169,"author":{"gitId":"yingx9"},"content":"Resources with the same tag and genre. ","lastModifiedDate":"2023-10-25"},{"lineNumber":170,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":171,"author":{"gitId":"yingx9"},"content":"Sequence Diagram:","lastModifiedDate":"2023-10-25"},{"lineNumber":172,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":173,"author":{"gitId":"yingx9"},"content":"\u003cimg src\u003d\"images/ListSequenceDiagram.png\" /\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":174,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":175,"author":{"gitId":"yingx9"},"content":"When a user enters `list /tag B`, the Parser retrieves the parameters from the input and","lastModifiedDate":"2023-10-26"},{"lineNumber":176,"author":{"gitId":"yingx9"},"content":"calls the `execute` function of ListCommand.","lastModifiedDate":"2023-10-26"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":"ListCommand then calls `parseArg` and `validate` from `Command`, which checks if the parameters are valid. If it passes","lastModifiedDate":"2023-10-26"},{"lineNumber":179,"author":{"gitId":"yingx9"},"content":"the checks, `filterResources` is called to begin the filtering process. First it calls `hasFilters()` check if the user ","lastModifiedDate":"2023-10-26"},{"lineNumber":180,"author":{"gitId":"yingx9"},"content":"selected any filters `[tag/genre/both]` or none. ","lastModifiedDate":"2023-10-26"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":182,"author":{"gitId":"yingx9"},"content":"If hasFilters returns `true`, it filters the `resourceList` with the given keywords and display the details ","lastModifiedDate":"2023-10-26"},{"lineNumber":183,"author":{"gitId":"yingx9"},"content":"of the resources.","lastModifiedDate":"2023-10-26"},{"lineNumber":184,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":185,"author":{"gitId":"yingx9"},"content":"If hasFilters returns `false`, it skips the filtering process and displays the details of all the resources.","lastModifiedDate":"2023-10-26"},{"lineNumber":186,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":187,"author":{"gitId":"DavinciDelta"},"content":"### Event Add Feature","lastModifiedDate":"2023-11-01"},{"lineNumber":188,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":189,"author":{"gitId":"DavinciDelta"},"content":"The `eventadd` feature is responsible for processing user commands to add an event to SysLib. It is facilitated by","lastModifiedDate":"2023-11-01"},{"lineNumber":190,"author":{"gitId":"DavinciDelta"},"content":"the `EventAddCommand` component. It works with `Parser` and `Command` components to parse and validate the user input.","lastModifiedDate":"2023-11-01"},{"lineNumber":191,"author":{"gitId":"DavinciDelta"},"content":"The new book is stored internally in `eventList` as a `Event`.","lastModifiedDate":"2023-11-01"},{"lineNumber":192,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":193,"author":{"gitId":"DavinciDelta"},"content":"`eventadd` has two options:","lastModifiedDate":"2023-11-01"},{"lineNumber":194,"author":{"gitId":"DavinciDelta"},"content":"- eventadd /t [title] /date [date]","lastModifiedDate":"2023-11-01"},{"lineNumber":195,"author":{"gitId":"DavinciDelta"},"content":"- eventadd /t [title] /date [date] /desc [description]","lastModifiedDate":"2023-11-01"},{"lineNumber":196,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":197,"author":{"gitId":"DavinciDelta"},"content":"#### Implementation","lastModifiedDate":"2023-11-01"},{"lineNumber":198,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":199,"author":{"gitId":"DavinciDelta"},"content":"It implements the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":200,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":201,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTADDCOMMAND#parseArgument(statement: String)` -- Parses the input command to extract relevant information.","lastModifiedDate":"2023-11-01"},{"lineNumber":202,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTADDCOMMAND#validate(statement: String, values: String[])` -- Validates the input statement to ensure that it is valid.","lastModifiedDate":"2023-11-01"},{"lineNumber":203,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTADDCOMMAND#binarySearch(parser: Parser, date: Date)` -- Search for the correct index of event list to add the event.","lastModifiedDate":"2023-11-01"},{"lineNumber":204,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":205,"author":{"gitId":"DavinciDelta"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-11-01"},{"lineNumber":206,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":207,"author":{"gitId":"DavinciDelta"},"content":"Step 1. The user inputs the command: `eventadd /t birthday /date 10-12-2001`","lastModifiedDate":"2023-11-01"},{"lineNumber":208,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":209,"author":{"gitId":"DavinciDelta"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-11-01"},{"lineNumber":210,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":211,"author":{"gitId":"DavinciDelta"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`eventadd`). It then calls","lastModifiedDate":"2023-11-01"},{"lineNumber":212,"author":{"gitId":"DavinciDelta"},"content":"`EVENTADDCOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"DavinciDelta"},"content":"Step 4. The `EVENTADDCOMMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTADDCOMMAND#parseArgument(statement: String)` to extract values for title, date and description.","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTADDCOMMAND#validate(statement: String, values: String[])` to ensure the validity of the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"DavinciDelta"},"content":"Step 5. The `COMMAND` component processes the input command to ensure that it meets the required format and constraints.","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"DavinciDelta"},"content":"It prepares the argument values for further processing.","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"DavinciDelta"},"content":"Step 6. The `EVENTADDCOMMMAND` also calls the component:","lastModifiedDate":"2023-11-01"},{"lineNumber":222,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTADDCOMMAND#binarySearch(parser: Parser, date: Date)` to find the correct index based on the date.","lastModifiedDate":"2023-11-01"},{"lineNumber":223,"author":{"gitId":"DavinciDelta"},"content":"The whole eventList is sorted by date order.","lastModifiedDate":"2023-11-01"},{"lineNumber":224,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":225,"author":{"gitId":"DavinciDelta"},"content":"Step 7. The newly created event is forwarded to the `PARSER` to be added to the `eventList`.","lastModifiedDate":"2023-11-01"},{"lineNumber":226,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":227,"author":{"gitId":"DavinciDelta"},"content":"### Event List Feature","lastModifiedDate":"2023-11-01"},{"lineNumber":228,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":229,"author":{"gitId":"DavinciDelta"},"content":"The `eventlist` command works with the `Parser` and `Command` component to execute the correct action. ","lastModifiedDate":"2023-11-01"},{"lineNumber":230,"author":{"gitId":"DavinciDelta"},"content":"This feature is responsible for listing out the events in eventList. ","lastModifiedDate":"2023-11-01"},{"lineNumber":231,"author":{"gitId":"DavinciDelta"},"content":"It is facilitated by the `EventListCommand` component. ","lastModifiedDate":"2023-11-01"},{"lineNumber":232,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":233,"author":{"gitId":"DavinciDelta"},"content":"`eventlist` has one option:","lastModifiedDate":"2023-11-01"},{"lineNumber":234,"author":{"gitId":"DavinciDelta"},"content":"- eventlist","lastModifiedDate":"2023-11-01"},{"lineNumber":235,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":236,"author":{"gitId":"DavinciDelta"},"content":"#### Implementation","lastModifiedDate":"2023-11-01"},{"lineNumber":237,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":238,"author":{"gitId":"DavinciDelta"},"content":"It implements the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":239,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":240,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTLISTCOMMAND#isEmpty()` -- Check user input has only \u0027eventlist\u0027","lastModifiedDate":"2023-11-01"},{"lineNumber":241,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":242,"author":{"gitId":"DavinciDelta"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-11-01"},{"lineNumber":243,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":244,"author":{"gitId":"DavinciDelta"},"content":"Step 1. The user inputs the command: `eventlist`","lastModifiedDate":"2023-11-01"},{"lineNumber":245,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":246,"author":{"gitId":"DavinciDelta"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-11-01"},{"lineNumber":247,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":248,"author":{"gitId":"DavinciDelta"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`eventlist`). It then calls","lastModifiedDate":"2023-11-01"},{"lineNumber":249,"author":{"gitId":"DavinciDelta"},"content":"`EVENTLISTCOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":250,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":251,"author":{"gitId":"DavinciDelta"},"content":"Step 4. The `EVENTLISTCOMMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":252,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTLISTCOMMAND#isEmpty()` to check if the user input any additional redundant arguments.","lastModifiedDate":"2023-11-01"},{"lineNumber":253,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":254,"author":{"gitId":"DavinciDelta"},"content":"Step 5. The `EVENTLISTCOMMAND` then outputs the events in the eventList.","lastModifiedDate":"2023-11-01"},{"lineNumber":255,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":256,"author":{"gitId":"DavinciDelta"},"content":"### Event Delete Feature","lastModifiedDate":"2023-11-01"},{"lineNumber":257,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":258,"author":{"gitId":"DavinciDelta"},"content":"The `eventdelete` feature is responsible for processing user commands to delete an event to SysLib. ","lastModifiedDate":"2023-11-01"},{"lineNumber":259,"author":{"gitId":"DavinciDelta"},"content":"It is facilitated by the `EventDeleteCommand` component. ","lastModifiedDate":"2023-11-01"},{"lineNumber":260,"author":{"gitId":"DavinciDelta"},"content":"It works with `Parser` and `Command` components to parse and validate the input.","lastModifiedDate":"2023-11-01"},{"lineNumber":261,"author":{"gitId":"DavinciDelta"},"content":"The `Event` is removed from `eventList`.","lastModifiedDate":"2023-11-01"},{"lineNumber":262,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":263,"author":{"gitId":"DavinciDelta"},"content":"`eventadd` has one options:","lastModifiedDate":"2023-11-01"},{"lineNumber":264,"author":{"gitId":"DavinciDelta"},"content":"- eventdelete /i [index]","lastModifiedDate":"2023-11-01"},{"lineNumber":265,"author":{"gitId":"DavinciDelta"},"content":"#### Implementation","lastModifiedDate":"2023-11-01"},{"lineNumber":266,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":267,"author":{"gitId":"DavinciDelta"},"content":"It implements the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":268,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":269,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTDELETECOMMAND#parseArgument(statement: String)` -- Parses the input command to extract relevant information.","lastModifiedDate":"2023-11-01"},{"lineNumber":270,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTDELETECOMMAND#validate(statement: String, values: String[])` -- Validates the input statement.","lastModifiedDate":"2023-11-01"},{"lineNumber":271,"author":{"gitId":"DavinciDelta"},"content":"- `EVENTDELETECOMMAND#parseCalendarInt(value: String, parser: Parser)` -- Validate the index given.","lastModifiedDate":"2023-11-01"},{"lineNumber":272,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":273,"author":{"gitId":"DavinciDelta"},"content":"#### Example Usage Scenario","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":275,"author":{"gitId":"DavinciDelta"},"content":"Step 1. The user inputs the command: `eventdelete /i 0`","lastModifiedDate":"2023-11-01"},{"lineNumber":276,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":277,"author":{"gitId":"DavinciDelta"},"content":"Step 2. The `UI` component forwards the input to `SYSLIB`, which in turn passes it to the `PARSER`.","lastModifiedDate":"2023-11-01"},{"lineNumber":278,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":279,"author":{"gitId":"DavinciDelta"},"content":"Step 3. The `PARSER` processes the command and determines that it contains a valid key (`eventadd`). It then calls","lastModifiedDate":"2023-11-01"},{"lineNumber":280,"author":{"gitId":"DavinciDelta"},"content":"`EVENTDELETECOMMAND#execute(statement: String, this: Parser)` with the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":281,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":282,"author":{"gitId":"DavinciDelta"},"content":"Step 4. The `EVENTDELETECOMMAND` component receives the command and performs the following operations:","lastModifiedDate":"2023-11-01"},{"lineNumber":283,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTDELETECOMMAND#parseArgument(statement: String)` to extract values for title, date and description.","lastModifiedDate":"2023-11-01"},{"lineNumber":284,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTDELETECOMMAND#validate(statement: String, values: String[])` to ensure the validity of the input command.","lastModifiedDate":"2023-11-01"},{"lineNumber":285,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":286,"author":{"gitId":"DavinciDelta"},"content":"Step 5. The `COMMAND` component processes the input command to ensure that it meets the required format and constraints.","lastModifiedDate":"2023-11-01"},{"lineNumber":287,"author":{"gitId":"DavinciDelta"},"content":"It prepares the argument values for further processing.","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"DavinciDelta"},"content":"Step 6. The `EVENTDELETECOMMAND` also calls the component:","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"DavinciDelta"},"content":"- Calls `EVENTDELETECOMMAND#parseCalendarInt(value: String, parser: Parser)` to see if the index is an integer and that","lastModifiedDate":"2023-11-01"},{"lineNumber":291,"author":{"gitId":"DavinciDelta"},"content":"it is within range of eventList","lastModifiedDate":"2023-11-01"},{"lineNumber":292,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"DavinciDelta"},"content":"Step 7. The selected event at the index is then deleted from the eventList.","lastModifiedDate":"2023-11-01"},{"lineNumber":294,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"-"},"content":"## Product scope","lastModifiedDate":"2020-05-24"},{"lineNumber":296,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":297,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":298,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":299,"author":{"gitId":"DavinciDelta"},"content":"All librarians, not just system librarian!","lastModifiedDate":"2023-10-24"},{"lineNumber":300,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":301,"author":{"gitId":"JoanneJo"},"content":"- Needs to manage inventory with significant number of resources e.g. books","lastModifiedDate":"2023-10-26"},{"lineNumber":302,"author":{"gitId":"JoanneJo"},"content":"- Is a fast typist","lastModifiedDate":"2023-10-26"},{"lineNumber":303,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":304,"author":{"gitId":"JoanneJo"},"content":"### Value Proposition","lastModifiedDate":"2023-10-26"},{"lineNumber":305,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":306,"author":{"gitId":"DavinciDelta"},"content":"To provide a platform to help librarians to quickly find the information they need to assist patrons.","lastModifiedDate":"2023-10-24"},{"lineNumber":307,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":308,"author":{"gitId":"-"},"content":"## User Stories","lastModifiedDate":"2020-05-24"},{"lineNumber":309,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":310,"author":{"gitId":"-"},"content":"| Version | As a ... | I want to ... | So that I can ... |","lastModifiedDate":"2020-05-24"},{"lineNumber":311,"author":{"gitId":"bnjm2000"},"content":"|---------|-----------|--------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-26"},{"lineNumber":312,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | view a list of books that the library has | have an overview of all the books |","lastModifiedDate":"2023-10-24"},{"lineNumber":313,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | add new books to our inventory by entering their title, author, ISBN, and publication year | keep our collection up-to-date |","lastModifiedDate":"2023-10-24"},{"lineNumber":314,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | delete books from the database | let the patrons know our library no longer carries it |","lastModifiedDate":"2023-10-24"},{"lineNumber":315,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | tag a book as physical medium like newspapers, audio cds, books or online like eJournals | patrons can know what type are available |","lastModifiedDate":"2023-10-24"},{"lineNumber":316,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | have a help function | know the commands of this programme |","lastModifiedDate":"2023-10-24"},{"lineNumber":317,"author":{"gitId":"DavinciDelta"},"content":"| v1.0 | librarian | quickly find out how many books we have of a particular author and the names of the books | know how many books are related to the author |","lastModifiedDate":"2023-10-24"},{"lineNumber":318,"author":{"gitId":"bnjm2000"},"content":"| v2.0 | librarian | import/export our library\u0027s inventory data to a file format | easily share with other libraries to be used for backup and archival purposes. |","lastModifiedDate":"2023-10-26"},{"lineNumber":319,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | find a to-do item by name | locate a to-do without having to go through the entire list |","lastModifiedDate":"2023-10-27"},{"lineNumber":320,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | get the status of an item | know if it is available |","lastModifiedDate":"2023-10-27"},{"lineNumber":321,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | update the details of a resource | fix any mistakes and maintain consistency |","lastModifiedDate":"2023-10-27"},{"lineNumber":322,"author":{"gitId":"000verflow"},"content":"| v2.0 | librarian | add in different types of resources | differentiate between resources such as magazines, cds... |","lastModifiedDate":"2023-10-27"},{"lineNumber":323,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":324,"author":{"gitId":"JoanneJo"},"content":"## Use Cases","lastModifiedDate":"2023-10-26"},{"lineNumber":325,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":326,"author":{"gitId":"JoanneJo"},"content":"(For all use cases below, the System is the SysLib and the Actor is the user, unless specified otherwise)","lastModifiedDate":"2023-10-26"},{"lineNumber":327,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":328,"author":{"gitId":"JoanneJo"},"content":"### Use case: Add a book","lastModifiedDate":"2023-10-26"},{"lineNumber":329,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":330,"author":{"gitId":"JoanneJo"},"content":"#### MSS","lastModifiedDate":"2023-10-26"},{"lineNumber":331,"author":{"gitId":"JoanneJo"},"content":"1. User requests to add a book","lastModifiedDate":"2023-10-26"},{"lineNumber":332,"author":{"gitId":"JoanneJo"},"content":"2. AddressBook adds the book","lastModifiedDate":"2023-10-26"},{"lineNumber":333,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":334,"author":{"gitId":"JoanneJo"},"content":" Use case ends.","lastModifiedDate":"2023-10-26"},{"lineNumber":335,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":336,"author":{"gitId":"JoanneJo"},"content":"#### Extensions","lastModifiedDate":"2023-10-26"},{"lineNumber":337,"author":{"gitId":"JoanneJo"},"content":"- 1a. The given ID is invalid.","lastModifiedDate":"2023-10-26"},{"lineNumber":338,"author":{"gitId":"JoanneJo"},"content":" - 1a1. SysLib shows an error message.","lastModifiedDate":"2023-10-26"},{"lineNumber":339,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":340,"author":{"gitId":"JoanneJo"},"content":" Use case ends.","lastModifiedDate":"2023-10-26"},{"lineNumber":341,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":342,"author":{"gitId":"JoanneJo"},"content":"- 1b. Insufficient data given.","lastModifiedDate":"2023-10-26"},{"lineNumber":343,"author":{"gitId":"JoanneJo"},"content":" - 1b1. SysLib shows an error message.","lastModifiedDate":"2023-10-26"},{"lineNumber":344,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":345,"author":{"gitId":"JoanneJo"},"content":" Use case ends.","lastModifiedDate":"2023-10-26"},{"lineNumber":346,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":347,"author":{"gitId":"-"},"content":"## Non-Functional Requirements","lastModifiedDate":"2020-05-24"},{"lineNumber":348,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":349,"author":{"gitId":"-"},"content":"{Give non-functional requirements}","lastModifiedDate":"2020-05-24"},{"lineNumber":350,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":351,"author":{"gitId":"-"},"content":"## Glossary","lastModifiedDate":"2020-05-24"},{"lineNumber":352,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":353,"author":{"gitId":"-"},"content":"* *glossary item* - Definition","lastModifiedDate":"2020-05-24"},{"lineNumber":354,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":355,"author":{"gitId":"JoanneJo"},"content":"## Instructions for Manual Testing","lastModifiedDate":"2023-10-26"},{"lineNumber":356,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":357,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":358,"author":{"gitId":"bnjm2000"},"content":"help","lastModifiedDate":"2023-10-26"},{"lineNumber":359,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":360,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":361,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":362,"author":{"gitId":"bnjm2000"},"content":"Commands available:","lastModifiedDate":"2023-10-26"},{"lineNumber":363,"author":{"gitId":"bnjm2000"},"content":"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE])","lastModifiedDate":"2023-10-26"},{"lineNumber":364,"author":{"gitId":"bnjm2000"},"content":"delete: deletes the resource with the specified ID from the library inventory. (e.g. delete /id 123456789)","lastModifiedDate":"2023-10-26"},{"lineNumber":365,"author":{"gitId":"bnjm2000"},"content":"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction","lastModifiedDate":"2023-10-26"},{"lineNumber":366,"author":{"gitId":"bnjm2000"},"content":"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)","lastModifiedDate":"2023-10-26"},{"lineNumber":367,"author":{"gitId":"bnjm2000"},"content":"edit: Edit a listing by entering its isbn to update its details. (e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)","lastModifiedDate":"2023-10-30"},{"lineNumber":368,"author":{"gitId":"bnjm2000"},"content":"exit: displays a farewell message and exits the program (e.g. exit)","lastModifiedDate":"2023-10-26"},{"lineNumber":369,"author":{"gitId":"bnjm2000"},"content":"For more information, please refer to our user guide at:https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html","lastModifiedDate":"2023-10-26"},{"lineNumber":370,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":371,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":372,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":373,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":374,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":375,"author":{"gitId":"bnjm2000"},"content":"add /id 1 /t The Great Gatsby /a F. Scott Fitzgerald /tag B /i 9780023381201 /g Novel, Fiction, Tragedy /s lost","lastModifiedDate":"2023-10-30"},{"lineNumber":376,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":377,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":378,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":379,"author":{"gitId":"bnjm2000"},"content":"This book is added: The Great Gatsby","lastModifiedDate":"2023-10-26"},{"lineNumber":380,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":381,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":382,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":383,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":384,"author":{"gitId":"bnjm2000"},"content":"add /id 2 /t To Kill a Mockingbird /a Harper Lee /tag B /i 9780061120084 /g Novel, Bildungsroman, Southern Gothic, Domestic Fiction, Thriller, Legal Story","lastModifiedDate":"2023-10-26"},{"lineNumber":385,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":386,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":387,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":388,"author":{"gitId":"bnjm2000"},"content":"This book is added: To Kill a Mockingbird","lastModifiedDate":"2023-10-26"},{"lineNumber":389,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":390,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":391,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":392,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":393,"author":{"gitId":"bnjm2000"},"content":"list","lastModifiedDate":"2023-10-26"},{"lineNumber":394,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":395,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":396,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":397,"author":{"gitId":"bnjm2000"},"content":"Listing all resources in the Library:","lastModifiedDate":"2023-10-26"},{"lineNumber":398,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":399,"author":{"gitId":"bnjm2000"},"content":"1. [B] ID: 1 Title: The Great Gatsby ISBN: 9780023381201 Author: F. Scott Fitzgerald Genre: Novel, Fiction, Tragedy Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":400,"author":{"gitId":"bnjm2000"},"content":"2. [B] ID: 2 Title: To Kill a Mockingbird ISBN: 9780061120084 Author: Harper Lee Genre: Novel, Bildungsroman, Southern Gothic Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":401,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":402,"author":{"gitId":"bnjm2000"},"content":"There are currently 2 resource(s).","lastModifiedDate":"2023-10-26"},{"lineNumber":403,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":404,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":405,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":406,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":407,"author":{"gitId":"bnjm2000"},"content":"delete /id 1","lastModifiedDate":"2023-10-26"},{"lineNumber":408,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":409,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":410,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":411,"author":{"gitId":"bnjm2000"},"content":"Looking for ID: 1...","lastModifiedDate":"2023-10-26"},{"lineNumber":412,"author":{"gitId":"bnjm2000"},"content":"This resource is removed: ","lastModifiedDate":"2023-10-26"},{"lineNumber":413,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 1 Title: The Great Gatsby ISBN: 9780023381201 Author: F. Scott Fitzgerald Genre: Novel, Fiction, Tragedy Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":414,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":415,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":416,"author":{"gitId":"bnjm2000"},"content":"Example input:","lastModifiedDate":"2023-10-26"},{"lineNumber":417,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":418,"author":{"gitId":"bnjm2000"},"content":"exit","lastModifiedDate":"2023-10-26"},{"lineNumber":419,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":420,"author":{"gitId":"bnjm2000"},"content":"Example response:","lastModifiedDate":"2023-10-26"},{"lineNumber":421,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":422,"author":{"gitId":"bnjm2000"},"content":"Bye, hope to see you again soon!","lastModifiedDate":"2023-10-26"},{"lineNumber":423,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-26"},{"lineNumber":424,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-26"},{"lineNumber":425,"author":{"gitId":"JoanneJo"},"content":"### Launch and Shutdown","lastModifiedDate":"2023-10-26"},{"lineNumber":426,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":427,"author":{"gitId":"JoanneJo"},"content":"1. Initial launch","lastModifiedDate":"2023-10-26"},{"lineNumber":428,"author":{"gitId":"JoanneJo"},"content":" 1. Download the jar file and copy it into an empty folder.","lastModifiedDate":"2023-10-26"},{"lineNumber":429,"author":{"gitId":"JoanneJo"},"content":" 2. Open the command prompt and run `java -jar SysLib.jar`.","lastModifiedDate":"2023-10-26"},{"lineNumber":430,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":431,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":432,"author":{"gitId":"JoanneJo"},"content":"### Adding a Book","lastModifiedDate":"2023-10-26"},{"lineNumber":433,"author":{"gitId":"JoanneJo"},"content":"1. Add a book","lastModifiedDate":"2023-10-26"},{"lineNumber":434,"author":{"gitId":"JoanneJo"},"content":" 1. Test case: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B`","lastModifiedDate":"2023-10-26"},{"lineNumber":435,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":436,"author":{"gitId":"JoanneJo"},"content":" Expected: A book with ID: 0005, Title: Frankenstein, Author: Mary Shelley, and ISBN: FKS0001 is created and added ","lastModifiedDate":"2023-10-26"},{"lineNumber":437,"author":{"gitId":"JoanneJo"},"content":" into the list. A message is shown to acknowledge that the book has been added successfully.","lastModifiedDate":"2023-10-26"},{"lineNumber":438,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":439,"author":{"gitId":"JoanneJo"},"content":" 2. Test case: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":440,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":441,"author":{"gitId":"JoanneJo"},"content":" Expected: A book with ID: 0005, Title: Frankenstein, Author: Mary Shelley, ISBN: FKS0001, and ","lastModifiedDate":"2023-10-26"},{"lineNumber":442,"author":{"gitId":"JoanneJo"},"content":" Genres: Gothic, Fiction is created and added into the list. A message is shown to acknowledge that the book ","lastModifiedDate":"2023-10-26"},{"lineNumber":443,"author":{"gitId":"JoanneJo"},"content":" has been added successfully.","lastModifiedDate":"2023-10-26"},{"lineNumber":444,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":445,"author":{"gitId":"JoanneJo"},"content":" 3. Test case: `add /id abcd /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":446,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":447,"author":{"gitId":"JoanneJo"},"content":" Expected: No book is added. An error message is shown to indicate that the id is invalid.","lastModifiedDate":"2023-10-26"},{"lineNumber":448,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":449,"author":{"gitId":"JoanneJo"},"content":" 4. Test case: `add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag A /g Gothic, Fiction`","lastModifiedDate":"2023-10-26"},{"lineNumber":450,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":451,"author":{"gitId":"JoanneJo"},"content":" Expected: No book is added. An error message is shown to indicate that the tag is invalid.","lastModifiedDate":"2023-10-26"},{"lineNumber":452,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":453,"author":{"gitId":"JoanneJo"},"content":" 5. Test case: `add /id 0005 /t Frankenstein`","lastModifiedDate":"2023-10-26"},{"lineNumber":454,"author":{"gitId":"JoanneJo"},"content":" ","lastModifiedDate":"2023-10-26"},{"lineNumber":455,"author":{"gitId":"JoanneJo"},"content":" Expected: No book is added. An error message is shown to indicate that the input is incomplete.","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"000verflow":71,"bnjm2000":73,"JoanneJo":105,"DavinciDelta":115,"-":31,"yingx9":60}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"# Syslib","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"SysLib CLI is a robust command-line tool designed for system librarians to efficiently handle inventory, events, and patron assistance. With quick command-based actions, manage your library\u0027s resources and events seamlessly. Simplify administrative tasks, so you can focus on serving patrons better.","lastModifiedDate":"2023-10-14"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":6,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"* [User Guide](UserGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"* [Developer Guide](DeveloperGuide.md)","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"* [About Us](AboutUs.md)","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"bnjm2000":3,"-":6}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"# Syslib User guide","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"SysLib is a program designed specially for system librarians to manage their work and responsibilities. Using intuitive commands, view, add, delete, and find books from the library inventory without any hassle.","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"This user guide is for System Librarians to ensure optimal use of Syslib","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"## Contents","lastModifiedDate":"2023-10-06"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"* [Quick start](#quick-start--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"* [Features](#features--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":" * [Add a listing: `add`](#add-a-listing-add--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":" * [Delete a listing: `delete`](#delete-a-listing-delete--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":" * [List items: `list`](#list-all-items-list--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":" * [Find listing by search parameter: `find`](#find-specific-listings-find--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" * [Edit a listing: `edit`](#edit-a-listing-edit--return-to-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" * [Events](#events--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" * [Event adding: `eventadd`](#event-adding-eventadd--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" * [Event listing: `eventlist`](#event-listing-eventlist--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" * [Event delete: `eventdelete`](#event-delete-eventdelete--return-to-contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":" * [Exiting the program : `exit`](#exiting-the-program--exit--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" * [Get help: `help`](#viewing-help--help--return-to-contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"* [FAQ](#faq--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"* [Known Issues](#known-issues--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"* [Command summary](#command-summary--return-to-contents)","lastModifiedDate":"2023-10-06"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":"## Quick start | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":"1. Make sure that you have Java 11 or above installed on your computer.","lastModifiedDate":"2023-10-28"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" - Open terminal and type `java --version`","lastModifiedDate":"2023-10-28"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" - [How do I check the version of my Java](https://www.java.com/en/download/help/version_manual.html)","lastModifiedDate":"2023-10-28"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":"2. [Download the latest release](https://github.com/AY2324S1-CS2113T-W11-1/tp/releases/tag/v1.0) of `Syslib.jar`","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"3. Copy the `Syslib.jar` file into a folder on its own.","lastModifiedDate":"2023-10-28"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":"4. Open a command terminal, type `cd \u003cFILE_DIRECTORY\u003e`, where \u003cFILE_DIRECTORY\u003e refers to the directory to the `Syslib.jar` file.","lastModifiedDate":"2023-10-28"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"5. Run the following command: `java -jar Syslib.jar`. You should see the following welcome screen.","lastModifiedDate":"2023-10-28"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" ____ _ _ _ ____ _ ___ ","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":"/ ___| _ _ ___| | (_) |__ / ___| | |_ _|","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":"\\___ \\| | | / __| | | | \u0027_ \\ | | | | | | ","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" ___) | |_| \\__ \\ |___| | |_) | | |___| |___ | | ","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":"|____/ \\__, |___/_____|_|_.__/ \\____|_____|___|","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" |___/ ","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":"What would you like to do?","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"## Features | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"\u003e Note:","lastModifiedDate":"2023-10-06"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":"\u003e - Items in square brackets `[]` are optional arguments.","lastModifiedDate":"2023-10-06"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":"\u003e - Items with `...` after them can be used multiple times","lastModifiedDate":"2023-10-06"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" \u003e * e.g `[/g GENRE]` ... can be used as `/g Horror /g Fantasy`","lastModifiedDate":"2023-10-06"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":"\u003e - All resources and events in current list will be saved into an offline file \"storage.txt\" on exit.","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"\u003e - Resources and events from \"storage.txt\" will be loaded into the program at every start.","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":"## Add a listing: `add` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":"Adds a new resource to the library inventory.","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"#### Types of tags:","lastModifiedDate":"2023-10-06"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"`[B]` - Books","lastModifiedDate":"2023-10-06"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"`[CD]` - CDs","lastModifiedDate":"2023-10-06"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"`[M]` - Magazines","lastModifiedDate":"2023-10-06"},{"lineNumber":62,"author":{"gitId":"JoanneJo"},"content":"`[N]` - Newspapers","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":"\u003e Note:","lastModifiedDate":"2023-10-06"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":"\u003e - Anything with `e` prior is an electronic version ","lastModifiedDate":"2023-10-06"},{"lineNumber":66,"author":{"gitId":"JoanneJo"},"content":"\u003e i.e. `[eB]` is an eBook, `[eM]` is an eMagazine, `[eN]` is an eNewspaper","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"JoanneJo"},"content":"\u003e - Anything with `e` prior is an electronic version","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"JoanneJo"},"content":"\u003e i.e. `[eB]` is an eBook, `[eM]` is an eMagazine","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":70,"author":{"gitId":"JoanneJo"},"content":"### Add Book","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about genre:","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Multiple genres are allowed for a single resource. You can separate the different genres using comma followed by a space `, `.","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":74,"author":{"gitId":"bnjm2000"},"content":"Format: `add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]...`","lastModifiedDate":"2023-10-30"},{"lineNumber":75,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":76,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":78,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Moby Dick /a Herman Melville /tag B /i 9780763630188 /g Adventure, Fiction","lastModifiedDate":"2023-10-15"},{"lineNumber":79,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Harry Squatter /a J.K. /tag B /i 9780763630187 /g History /s lost","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":81,"author":{"gitId":"bnjm2000"},"content":"**Example response:**","lastModifiedDate":"2023-10-28"},{"lineNumber":82,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":83,"author":{"gitId":"bnjm2000"},"content":"This book is added: Moby Dick","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":87,"author":{"gitId":"JoanneJo"},"content":"### (NOTE: Addition of resources other than Book is only available in v2.1)","lastModifiedDate":"2023-11-03"},{"lineNumber":88,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":"### Add eBook","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about genre:","lastModifiedDate":"2023-11-03"},{"lineNumber":91,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Multiple genres are allowed for a single resource. You can separate the different genres using comma followed by a space `, `.","lastModifiedDate":"2023-11-03"},{"lineNumber":92,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN /l LINK [/g GENRE /s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Moby Dick /a Herman Melville /tag eB /i 9780763630188 /l abc.com /g Adventure, Fiction","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"JoanneJo"},"content":"This eBook is added: Moby Dick","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"JoanneJo"},"content":"### Add CD","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /c CREATOR /ty TYPE /tag TAG /i ISBN [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Moby Dick /c Herman Melville /ty Audio Book /tag CD /i 9780763630188 ","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":113,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":"This CD is added: Moby Dick","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":"### Add Magazine","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /b BRAND /is ISSUE /tag TAG /i ISBN [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t 2023 Hottest Trends /b Vogue /is AY23-01 /tag M /i 9780763630188 ","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"JoanneJo"},"content":"This magazine is added: 2023 Hottest Trends","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":"### Add eMagazine","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /b BRAND /is ISSUE /tag TAG /i ISBN /l LINK [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":133,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t 2023 Hottest Trends /b Vogue /is AY23-01 /tag eM /i 9780763630188 /l abc.com","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"JoanneJo"},"content":"This eMagazine is added: 2023 Hottest Trends","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":"### Add Newspaper","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /p PUBLISHER /ed EDITION /tag TAG /i ISBN [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Forbes 30 Under 30 2023 /p The Straits Times /ed AY23-30 /tag N /i 9780763630188","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"JoanneJo"},"content":"This newspaper is added: Forbes 30 Under 30 2023","lastModifiedDate":"2023-10-31"},{"lineNumber":153,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":155,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"JoanneJo"},"content":"### Add eNewspaper","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"JoanneJo"},"content":"Format: `add /id ID /t TITLE /p PUBLISHER /ed EDITION /tag TAG /i ISBN /l LINK [/s STATUS]...`","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"JoanneJo"},"content":"**Example input:**","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"JoanneJo"},"content":"add /id 123456789 /t Forbes 30 Under 30 2023 /p The Straits Times /ed AY23-30 /tag eN /i 9780763630188 /l abc.com","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"JoanneJo"},"content":"**Example response:**","lastModifiedDate":"2023-10-31"},{"lineNumber":164,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":165,"author":{"gitId":"JoanneJo"},"content":"This eNewspaper is added: Forbes 30 Under 30 2023","lastModifiedDate":"2023-10-31"},{"lineNumber":166,"author":{"gitId":"JoanneJo"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"JoanneJo"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"bnjm2000"},"content":"## Delete a listing: `delete` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":171,"author":{"gitId":"bnjm2000"},"content":"Deletes the resource with the specified ID from the library inventory. You can find the ID using the `list` command.","lastModifiedDate":"2023-10-28"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":"Format: `delete /id ID`","lastModifiedDate":"2023-10-06"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":175,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":177,"author":{"gitId":"000verflow"},"content":"delete /id 123456789","lastModifiedDate":"2023-10-06"},{"lineNumber":178,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":179,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":181,"author":{"gitId":"bnjm2000"},"content":"Looking for ID: 123456789...","lastModifiedDate":"2023-10-28"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":"This resource is removed: ","lastModifiedDate":"2023-10-28"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 123456789 Title: Moby Dick ISBN: 9780763630188 Author: Herman Melville Genre: Adventure, Fiction Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":186,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":"## List all items: `list` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":"List all resources OR filter by certain tags or genre.","lastModifiedDate":"2023-10-28"},{"lineNumber":189,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":190,"author":{"gitId":"yingx9"},"content":"Format: `list [/tag TAG /g GENRE /s STATUS]`","lastModifiedDate":"2023-11-04"},{"lineNumber":191,"author":{"gitId":"yingx9"},"content":"- Including more than one filter will only list resources satisfying **ALL** given filters:","lastModifiedDate":"2023-11-04"},{"lineNumber":192,"author":{"gitId":"yingx9"},"content":" - Example: `list /tag B /g Horror` will list Books with Horror genre.","lastModifiedDate":"2023-11-04"},{"lineNumber":193,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":194,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":195,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":196,"author":{"gitId":"000verflow"},"content":"list","lastModifiedDate":"2023-10-06"},{"lineNumber":197,"author":{"gitId":"yingx9"},"content":"list /tag B","lastModifiedDate":"2023-10-16"},{"lineNumber":198,"author":{"gitId":"yingx9"},"content":"list /tag B /g Fiction","lastModifiedDate":"2023-10-16"},{"lineNumber":199,"author":{"gitId":"JoanneJo"},"content":"list /g Thrill","lastModifiedDate":"2023-10-15"},{"lineNumber":200,"author":{"gitId":"yingx9"},"content":"list /s Available","lastModifiedDate":"2023-11-04"},{"lineNumber":201,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":202,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":203,"author":{"gitId":"bnjm2000"},"content":"**Example output:**","lastModifiedDate":"2023-10-28"},{"lineNumber":204,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":205,"author":{"gitId":"bnjm2000"},"content":"Listing all resources in the Library:","lastModifiedDate":"2023-10-28"},{"lineNumber":206,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":207,"author":{"gitId":"bnjm2000"},"content":"1. [B] ID: 1 Title: Moby Dick ISBN: 9780763630188 Author: Herman Melville Genre: Adventure, Fiction Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":208,"author":{"gitId":"bnjm2000"},"content":"2. [M] ID: 2 Title: Harry Squatter ISBN: 9780763630187 Author: J.K. Genre: History Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":209,"author":{"gitId":"bnjm2000"},"content":"3. [B] ID: 3 Title: Frankenstein ISBN: FKS0001 Author: Mary Shelley Genre: - Status: BORROWED","lastModifiedDate":"2023-10-30"},{"lineNumber":210,"author":{"gitId":"bnjm2000"},"content":"4. [B] ID: 4 Title: The Great Gatsby ISBN: 9780023381201 Author: F. Scott Fitzgerald Genre: Novel, Fiction, Tragedy Status: AVAILABLE","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"bnjm2000"},"content":"5. [B] ID: 5 Title: To Kill a Mockingbird ISBN: 9780061120084 Author: Harper Lee Genre: Novel, Bildungsroman, Southern Gothic, Domestic Fiction, Thriller, Legal Story Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":213,"author":{"gitId":"bnjm2000"},"content":"There are currently 5 resource(s).","lastModifiedDate":"2023-10-28"},{"lineNumber":214,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":215,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":216,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":217,"author":{"gitId":"bnjm2000"},"content":"## Find specific listings: `find` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":218,"author":{"gitId":"yingx9"},"content":"Find a resource by title, author, ISBN or given id.","lastModifiedDate":"2023-10-16"},{"lineNumber":219,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":220,"author":{"gitId":"000verflow"},"content":"You can use multiple filters, and only results that match ALL the given criteria will be returned.","lastModifiedDate":"2023-11-03"},{"lineNumber":221,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":222,"author":{"gitId":"000verflow"},"content":"\u003e For non-book resources, `author` refers to `publisher`,`creator` and `brand` for Newspapers, CD\u0027s and Magazines ","lastModifiedDate":"2023-11-03"},{"lineNumber":223,"author":{"gitId":"000verflow"},"content":"\u003e respectively.","lastModifiedDate":"2023-11-03"},{"lineNumber":224,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":225,"author":{"gitId":"JoanneJo"},"content":"Format: `find [/t TITLE OR /i ISBN OR /a AUTHOR OR /id ID]`","lastModifiedDate":"2023-10-15"},{"lineNumber":226,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":227,"author":{"gitId":"bnjm2000"},"content":"**Example input:**","lastModifiedDate":"2023-10-28"},{"lineNumber":228,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":229,"author":{"gitId":"JoanneJo"},"content":"find /t Moby Dick","lastModifiedDate":"2023-10-15"},{"lineNumber":230,"author":{"gitId":"JoanneJo"},"content":"find /i 9780763630188","lastModifiedDate":"2023-10-15"},{"lineNumber":231,"author":{"gitId":"000verflow"},"content":"find /a J. K. Rowling","lastModifiedDate":"2023-10-06"},{"lineNumber":232,"author":{"gitId":"000verflow"},"content":"find /id 123456789","lastModifiedDate":"2023-10-06"},{"lineNumber":233,"author":{"gitId":"000verflow"},"content":"find /id 123456789 /i 9780763630188 ","lastModifiedDate":"2023-11-02"},{"lineNumber":234,"author":{"gitId":"000verflow"},"content":"```","lastModifiedDate":"2023-10-06"},{"lineNumber":235,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":236,"author":{"gitId":"bnjm2000"},"content":"**Example output:**","lastModifiedDate":"2023-10-30"},{"lineNumber":237,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":238,"author":{"gitId":"bnjm2000"},"content":"Here are resources that matched the given filters:","lastModifiedDate":"2023-10-30"},{"lineNumber":239,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 123456789 Title: Moby Dick ISBN: 9780763630188 Author: Herman Melville Genre: Adventure, Fiction","lastModifiedDate":"2023-10-30"},{"lineNumber":240,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-30"},{"lineNumber":241,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":242,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":243,"author":{"gitId":"yingx9"},"content":"## Edit a listing: `edit` | [Return to contents](#contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":244,"author":{"gitId":"yingx9"},"content":"Edit a listing by entering its `isbn` to update its details.","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":246,"author":{"gitId":"yingx9"},"content":"Format: `edit /i ISBN /argumentname ARGUMENT`","lastModifiedDate":"2023-10-30"},{"lineNumber":247,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":248,"author":{"gitId":"yingx9"},"content":"Argument Names:","lastModifiedDate":"2023-10-30"},{"lineNumber":249,"author":{"gitId":"bnjm2000"},"content":"- `/t TITLE `","lastModifiedDate":"2023-10-30"},{"lineNumber":250,"author":{"gitId":"bnjm2000"},"content":"- `/a AUTHOR `","lastModifiedDate":"2023-10-30"},{"lineNumber":251,"author":{"gitId":"bnjm2000"},"content":"- `/tag TAG`","lastModifiedDate":"2023-10-30"},{"lineNumber":252,"author":{"gitId":"bnjm2000"},"content":"- `/g GENRES`","lastModifiedDate":"2023-10-30"},{"lineNumber":253,"author":{"gitId":"yingx9"},"content":" - If you\u0027re inputting **multiple genres**, separate them by with comma `,`. For example:","lastModifiedDate":"2023-10-30"},{"lineNumber":254,"author":{"gitId":"yingx9"},"content":" `/g Horror, Fantasy`","lastModifiedDate":"2023-10-30"},{"lineNumber":255,"author":{"gitId":"bnjm2000"},"content":"- `/s STATUS`","lastModifiedDate":"2023-10-30"},{"lineNumber":256,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":257,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":258,"author":{"gitId":"yingx9"},"content":"**Example input:**","lastModifiedDate":"2023-10-30"},{"lineNumber":259,"author":{"gitId":"yingx9"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":260,"author":{"gitId":"yingx9"},"content":"edit /i 123 /t NEW_TITLE","lastModifiedDate":"2023-10-30"},{"lineNumber":261,"author":{"gitId":"yingx9"},"content":"edit /i 123 /t NEW_TITLE /a NEW_AUTHOR","lastModifiedDate":"2023-10-30"},{"lineNumber":262,"author":{"gitId":"yingx9"},"content":"edit /i 123 /g Horror, Adventure","lastModifiedDate":"2023-10-30"},{"lineNumber":263,"author":{"gitId":"bnjm2000"},"content":"edit /i 123 /s lost","lastModifiedDate":"2023-10-30"},{"lineNumber":264,"author":{"gitId":"yingx9"},"content":"```","lastModifiedDate":"2023-10-30"},{"lineNumber":265,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":266,"author":{"gitId":"bnjm2000"},"content":"**Example output:**","lastModifiedDate":"2023-10-28"},{"lineNumber":267,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":268,"author":{"gitId":"yingx9"},"content":"Successfully updated! Your updated resource: ","lastModifiedDate":"2023-10-30"},{"lineNumber":269,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":270,"author":{"gitId":"bnjm2000"},"content":"[B] ID: 12312 Title: Mary ISBN: 123 Author: John Genre: Horror, Adventure Status: LOST","lastModifiedDate":"2023-10-30"},{"lineNumber":271,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":272,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":273,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":274,"author":{"gitId":"DavinciDelta"},"content":"## Events | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":275,"author":{"gitId":"DavinciDelta"},"content":"\u003eNote:","lastModifiedDate":"2023-11-03"},{"lineNumber":276,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Events are stored separately from resources","lastModifiedDate":"2023-11-03"},{"lineNumber":277,"author":{"gitId":"DavinciDelta"},"content":"\u003e - They are stored in chronological order(events that are happening sooner are closer to index 0)","lastModifiedDate":"2023-11-03"},{"lineNumber":278,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":279,"author":{"gitId":"DavinciDelta"},"content":"## Event adding: `eventadd` | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":280,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about description:","lastModifiedDate":"2023-11-03"},{"lineNumber":281,"author":{"gitId":"DavinciDelta"},"content":"\u003e - `desc` is optional for all events","lastModifiedDate":"2023-11-03"},{"lineNumber":282,"author":{"gitId":"DavinciDelta"},"content":"\u003e - Event without descriptions with have it as `null`","lastModifiedDate":"2023-11-03"},{"lineNumber":283,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":284,"author":{"gitId":"DavinciDelta"},"content":"Add an event to the eventList","lastModifiedDate":"2023-11-03"},{"lineNumber":285,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":286,"author":{"gitId":"DavinciDelta"},"content":"Format: `eventadd /t TITLE /date DATE [/desc DESCRIPTION]`","lastModifiedDate":"2023-11-03"},{"lineNumber":287,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":288,"author":{"gitId":"DavinciDelta"},"content":"**Example input:**","lastModifiedDate":"2023-11-01"},{"lineNumber":289,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":290,"author":{"gitId":"DavinciDelta"},"content":"eventadd /t Fan meetup for xxx /date 11-11-2001","lastModifiedDate":"2023-11-03"},{"lineNumber":291,"author":{"gitId":"DavinciDelta"},"content":"eventadd /t Meet and Greet for xxx /date 10-11-2010 /desc buffet style","lastModifiedDate":"2023-11-03"},{"lineNumber":292,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":293,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":294,"author":{"gitId":"DavinciDelta"},"content":"**Example output:**","lastModifiedDate":"2023-11-01"},{"lineNumber":295,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":296,"author":{"gitId":"DavinciDelta"},"content":"Event inserted at: 0","lastModifiedDate":"2023-11-01"},{"lineNumber":297,"author":{"gitId":"DavinciDelta"},"content":"____________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":298,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":299,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":300,"author":{"gitId":"DavinciDelta"},"content":"## Event listing: `eventlist` | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":301,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":302,"author":{"gitId":"DavinciDelta"},"content":"Display all events in the eventList","lastModifiedDate":"2023-11-03"},{"lineNumber":303,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":304,"author":{"gitId":"DavinciDelta"},"content":"Format: `eventlist`","lastModifiedDate":"2023-11-01"},{"lineNumber":305,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":306,"author":{"gitId":"DavinciDelta"},"content":"**Example input:**","lastModifiedDate":"2023-11-01"},{"lineNumber":307,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":308,"author":{"gitId":"DavinciDelta"},"content":"eventlist","lastModifiedDate":"2023-11-01"},{"lineNumber":309,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":310,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":311,"author":{"gitId":"DavinciDelta"},"content":"**Example output:**","lastModifiedDate":"2023-11-03"},{"lineNumber":312,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":313,"author":{"gitId":"DavinciDelta"},"content":"This is the current event list:","lastModifiedDate":"2023-11-03"},{"lineNumber":314,"author":{"gitId":"DavinciDelta"},"content":"0: Fan meetup for xxx | 11-11-2001 | null","lastModifiedDate":"2023-11-03"},{"lineNumber":315,"author":{"gitId":"DavinciDelta"},"content":"1: Meet and Greet for xxx | 10-11-2010 | buffet style","lastModifiedDate":"2023-11-03"},{"lineNumber":316,"author":{"gitId":"DavinciDelta"},"content":"____________________________________________________________","lastModifiedDate":"2023-11-03"},{"lineNumber":317,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":318,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":319,"author":{"gitId":"DavinciDelta"},"content":"## Event delete: `eventdelete` | [Return to contents](#contents)","lastModifiedDate":"2023-11-03"},{"lineNumber":320,"author":{"gitId":"DavinciDelta"},"content":"\u003eNotes about INDEX:","lastModifiedDate":"2023-11-03"},{"lineNumber":321,"author":{"gitId":"DavinciDelta"},"content":"\u003e - INDEX starts from 0 and can be viewed by calling `eventlist`","lastModifiedDate":"2023-11-03"},{"lineNumber":322,"author":{"gitId":"DavinciDelta"},"content":"\u003e - INDEX might change as those with earlier dates are sorted first","lastModifiedDate":"2023-11-03"},{"lineNumber":323,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":324,"author":{"gitId":"DavinciDelta"},"content":"Delete an event to the eventList","lastModifiedDate":"2023-11-03"},{"lineNumber":325,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":326,"author":{"gitId":"DavinciDelta"},"content":"Format: `eventdelete /i INDEX`","lastModifiedDate":"2023-11-01"},{"lineNumber":327,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":328,"author":{"gitId":"DavinciDelta"},"content":"**Example input:**","lastModifiedDate":"2023-11-01"},{"lineNumber":329,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":330,"author":{"gitId":"DavinciDelta"},"content":"eventdelete /i 0","lastModifiedDate":"2023-11-01"},{"lineNumber":331,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":332,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":333,"author":{"gitId":"DavinciDelta"},"content":"**Example output:**","lastModifiedDate":"2023-11-03"},{"lineNumber":334,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-03"},{"lineNumber":335,"author":{"gitId":"DavinciDelta"},"content":"This event is removed:","lastModifiedDate":"2023-11-03"},{"lineNumber":336,"author":{"gitId":"DavinciDelta"},"content":"Fan meetup for xxx | 11-11-2001 | null","lastModifiedDate":"2023-11-03"},{"lineNumber":337,"author":{"gitId":"DavinciDelta"},"content":"____________________________________________________________","lastModifiedDate":"2023-11-01"},{"lineNumber":338,"author":{"gitId":"DavinciDelta"},"content":"```","lastModifiedDate":"2023-11-01"},{"lineNumber":339,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":340,"author":{"gitId":"bnjm2000"},"content":"## Exiting the program : `exit` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":341,"author":{"gitId":"bnjm2000"},"content":"Displays a farewell message and exits the program.","lastModifiedDate":"2023-10-28"},{"lineNumber":342,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":343,"author":{"gitId":"000verflow"},"content":"Format: `exit`","lastModifiedDate":"2023-10-06"},{"lineNumber":344,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":345,"author":{"gitId":"bnjm2000"},"content":"**Example**","lastModifiedDate":"2023-10-28"},{"lineNumber":346,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":347,"author":{"gitId":"bnjm2000"},"content":"Bye, hope to see you again soon!","lastModifiedDate":"2023-10-28"},{"lineNumber":348,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":349,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":350,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":351,"author":{"gitId":"bnjm2000"},"content":"## Viewing help : `help` | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":352,"author":{"gitId":"bnjm2000"},"content":"Displays a list of available commands with examples and their syntax format.","lastModifiedDate":"2023-10-28"},{"lineNumber":353,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":354,"author":{"gitId":"bnjm2000"},"content":"Format: `help`","lastModifiedDate":"2023-10-28"},{"lineNumber":355,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":356,"author":{"gitId":"bnjm2000"},"content":"Example:","lastModifiedDate":"2023-10-28"},{"lineNumber":357,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":358,"author":{"gitId":"bnjm2000"},"content":"Commands available:","lastModifiedDate":"2023-10-28"},{"lineNumber":359,"author":{"gitId":"bnjm2000"},"content":"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE])","lastModifiedDate":"2023-10-28"},{"lineNumber":360,"author":{"gitId":"bnjm2000"},"content":"delete: deletes the resource with the specified ID from the library inventory. (e.g. delete /id 123456789)","lastModifiedDate":"2023-10-28"},{"lineNumber":361,"author":{"gitId":"bnjm2000"},"content":"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction","lastModifiedDate":"2023-10-28"},{"lineNumber":362,"author":{"gitId":"000verflow"},"content":"find: find a resource by title, author(same as publisher/creator/brand), ISBN or given id. (e.g. find /i 9780763630188)","lastModifiedDate":"2023-11-03"},{"lineNumber":363,"author":{"gitId":"bnjm2000"},"content":"edit: Edit a listing by entering its isbn to update its details. (e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)","lastModifiedDate":"2023-10-30"},{"lineNumber":364,"author":{"gitId":"000verflow"},"content":"eventadd: Add an event to the event list (e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])","lastModifiedDate":"2023-11-02"},{"lineNumber":365,"author":{"gitId":"000verflow"},"content":"eventlist: List out all the event list (e.g. eventlist)","lastModifiedDate":"2023-11-02"},{"lineNumber":366,"author":{"gitId":"000verflow"},"content":"eventdelete: Delete an event in the event list based on the index (e.g. eventdelete /i INDEX)","lastModifiedDate":"2023-11-02"},{"lineNumber":367,"author":{"gitId":"bnjm2000"},"content":"exit: displays a farewell message and exits the program (e.g. exit)","lastModifiedDate":"2023-10-28"},{"lineNumber":368,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":369,"author":{"gitId":"bnjm2000"},"content":"For more information, please refer to our user guide at:https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html","lastModifiedDate":"2023-10-28"},{"lineNumber":370,"author":{"gitId":"bnjm2000"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-28"},{"lineNumber":371,"author":{"gitId":"bnjm2000"},"content":"```","lastModifiedDate":"2023-10-28"},{"lineNumber":372,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":373,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":374,"author":{"gitId":"bnjm2000"},"content":"## FAQ | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":375,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":376,"author":{"gitId":"000verflow"},"content":"...","lastModifiedDate":"2023-10-06"},{"lineNumber":377,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":378,"author":{"gitId":"bnjm2000"},"content":"## Known Issues | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":379,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":380,"author":{"gitId":"000verflow"},"content":"...","lastModifiedDate":"2023-10-06"},{"lineNumber":381,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":382,"author":{"gitId":"bnjm2000"},"content":"## Command summary | [Return to contents](#contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":383,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":384,"author":{"gitId":"000verflow"},"content":"| Action | Command |","lastModifiedDate":"2023-10-06"},{"lineNumber":385,"author":{"gitId":"JoanneJo"},"content":"|-----------------------|------------------------------------------------------------------------------------------------------------|","lastModifiedDate":"2023-10-15"},{"lineNumber":386,"author":{"gitId":"JoanneJo"},"content":"| Add listing | `add /t \u003ctitle of listing\u003e /a \u003cauthor of item\u003e /tag \u003ctype of item\u003e /i \u003cISBN of item\u003e [/g \u003cgenre of item\u003e]` |","lastModifiedDate":"2023-10-15"},{"lineNumber":387,"author":{"gitId":"000verflow"},"content":"| Delete listing | `delete /id \u003cid of listing\u003e` |","lastModifiedDate":"2023-10-06"},{"lineNumber":388,"author":{"gitId":"yingx9"},"content":"| Listing all items | `list [/tag \u003ctype of item\u003e /g \u003cgenre of item\u003e /s \u003cstatus of item\u003e]` |","lastModifiedDate":"2023-11-04"},{"lineNumber":389,"author":{"gitId":"JoanneJo"},"content":"| Find specific listing | `find [/t \u003ctitle of listing\u003e OR /i \u003cISBN of item\u003e OR /a AUTHOR OR /id ID]` |","lastModifiedDate":"2023-10-15"},{"lineNumber":390,"author":{"gitId":"yingx9"},"content":"| Edit a listing | `edit /i ISBN [/t \u003ctitle of listing\u003e /a AUTHOR /id ID /tag \u003ctype of item\u003e /g \u003cgenre of item\u003e] /s \u003cstatus\u003e` |","lastModifiedDate":"2023-11-02"},{"lineNumber":391,"author":{"gitId":"000verflow"},"content":"| Exit | `exit` |","lastModifiedDate":"2023-10-06"},{"lineNumber":392,"author":{"gitId":"DavinciDelta"},"content":"| Event Add | `eventadd /t TITLE /date DATE [/desc DESCRIPTION]` (Format for date DD-MM-YYYY) |","lastModifiedDate":"2023-11-03"},{"lineNumber":393,"author":{"gitId":"DavinciDelta"},"content":"| Event Delete | `eventdelete /i INDEX` |","lastModifiedDate":"2023-11-03"},{"lineNumber":394,"author":{"gitId":"DavinciDelta"},"content":"| Event Listing | `eventlist` |","lastModifiedDate":"2023-11-03"},{"lineNumber":395,"author":{"gitId":"000verflow"},"content":"| View help | `help` |","lastModifiedDate":"2023-10-06"},{"lineNumber":396,"author":{"gitId":"000verflow"},"content":"| Exit | `exit` |","lastModifiedDate":"2023-11-02"},{"lineNumber":397,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":398,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"000verflow":72,"bnjm2000":107,"JoanneJo":87,"DavinciDelta":81,"-":21,"yingx9":30}},{"path":"docs/diagram/AddSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"@startuml","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"!include Style.puml","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"skinparam ArrowFontStyle plain","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"participant \":SysLib\" as SYSLIB SYSLIB_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":"participant \":UI\" as UI UI_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"actor User as USER USER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"participant \":Parser\" as PARSER PARSER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"box Command","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"participant \":AddCommand\" as ADDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"participant \":Command\" as COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"end box","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"SYSLIB -[SYSLIB_COLOR]\u003e UI : readCommand()","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":"activate SYSLIB SYSLIB_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":"activate UI UI_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":"USER -[USER_COLOR]\u003e UI : \"add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\"","lastModifiedDate":"2023-10-26"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":"UI --[UI_COLOR]\u003e SYSLIB : input: String","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"deactivate UI","lastModifiedDate":"2023-10-26"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"SYSLIB -[SYSLIB_COLOR]\u003e PARSER : process(\"add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\")","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":"alt containsKey","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" PARSER-[PARSER_COLOR]\u003e PARSER: removeFirstWord(add /id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction)","lastModifiedDate":"2023-10-26"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" PARSER --[PARSER_COLOR]\u003e PARSER : \"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\": String","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" deactivate PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" PARSER -[PARSER_COLOR]\u003e ADDCOMMAND : execute(\"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\")","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" activate ADDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":"else noKey","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" PARSER --[PARSER_COLOR]\u003e SYSLIB","lastModifiedDate":"2023-10-26"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":"ADDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : parseArgument(\"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\")","lastModifiedDate":"2023-10-26"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":"activate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":"COMMAND --[COMMAND_COLOR]\u003e ADDCOMMAND : values: String[]","lastModifiedDate":"2023-10-26"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":"ADDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : validate(\"/id 0005 /t Frankenstein /a Mary Shelley /i FKS0001 /tag B /g Gothic, Fiction\", values)","lastModifiedDate":"2023-10-26"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":"COMMAND --[COMMAND_COLOR]\u003e ADDCOMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":"deactivate COMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":"alt equalsIgnoreCase(\"b\")","lastModifiedDate":"2023-10-26"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" ADDCOMMAND -[COMMAND_COLOR]\u003e PARSER : createBook(values)","lastModifiedDate":"2023-10-26"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" PARSER --[PARSER_COLOR]\u003e ADDCOMMAND : new Book (title, isbn, author, genres, id)","lastModifiedDate":"2023-10-26"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" ADDCOMMAND --[COMMAND_COLOR]\u003e PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":"else notEqualsIgnoreCase(\"b\")","lastModifiedDate":"2023-10-26"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" ADDCOMMAND --[COMMAND_COLOR]\u003e PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" deactivate ADDCOMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":"end","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":"PARSER --[PARSER_COLOR]\u003e SYSLIB","lastModifiedDate":"2023-10-26"},{"lineNumber":57,"author":{"gitId":"JoanneJo"},"content":"deactivate PARSER","lastModifiedDate":"2023-10-26"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":"@enduml","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"JoanneJo":59}},{"path":"docs/diagram/Architecture.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"@startuml","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/globe_internet\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/documents\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Users/user\u003e","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"!include style.puml","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"Package \" \"\u003c\u003cRectangle\u003e\u003e{","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" Class UI UI_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" Class Parser PARSER_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" Class Command COMMAND_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":" Class Main #grey","lastModifiedDate":"2023-10-24"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" Class Storage STORAGE_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":" Class Data DATA_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"Class \"\u003c$user\u003e\" as User STORAGE_COLOR_T2","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"Class \"\u003c$documents\u003e\" as File UI_COLOR_T1","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"User ..\u003e UI","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"Main -[#grey]-\u003e UI","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"Main -[#grey]-\u003e Parser","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"UI -[#green]-\u003eParser","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"Main -[#grey]-\u003e Storage","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"Parser -[#blue]-\u003e Command","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"Command ..\u003eParser","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"Parser -[#blue]-\u003e Data","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"Storage -[STORAGE_COLOR]-\u003eData","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"Storage ..\u003eFile","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"@enduml","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"yingx9":36}},{"path":"docs/diagram/FindSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"!include Style.puml","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"!include \u003coffice/Concepts/globe_internet\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"!include \u003coffice/Concepts/documents\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"!include \u003coffice/Users/user\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"skinparam ArrowFontStyle plain","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"Actor User as user USER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"participant \":UI\" as UI UI_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"participant \":Parser\" as PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"box Command","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"participant \":FindCommand\" as FINDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"participant \":Command\" as COMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"end box","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"participant \":Resource\" as RESOURCE","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"user -[USER_COLOR]\u003e UI : \"find /t TITLE\"","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"activate UI UI_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":"UI -[UI_COLOR]\u003e PARSER : process(\"find /t TITLE\")","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":"alt containsKey","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" PARSER -[PARSER_COLOR]\u003e PARSER: removeFirstWord(\"find /t TITLE\")","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" PARSER -[PARSER_COLOR]\u003e FINDCOMMAND: execute(\"/t TITLE\")","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" activate FINDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":"else noKey","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" PARSER --[PARSER_COLOR]\u003e UI :","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : parseArg(\"/t TITLE\")","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":"activate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":"COMMAND --[COMMAND_COLOR]\u003e FINDCOMMAND : String[] values","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -[COMMAND_COLOR]\u003e COMMAND : validate(\"/t TITLE\", values)","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":"COMMAND --[COMMAND_COLOR]\u003e FINDCOMMAND :","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":"deactivate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -[COMMAND_COLOR]\u003e PARSER : resourceList","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":"PARSER --[PARSER_COLOR]\u003e FINDCOMMAND : List of resources","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":"deactivate PARSER PARSER_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"loop for each Resource in resourceList","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" FINDCOMMAND -[COMMAND_COLOR]\u003e RESOURCE: getId(), getISBN(), getTitle(), getTag()","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" activate RESOURCE","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" RESOURCE --[COMMAND_COLOR]\u003e FINDCOMMAND","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" deactivate RESOURCE","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" FINDCOMMAND -\u003e FINDCOMMAND : Check and filter based on Id, ISBN, Title, and Tag","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":" alt isMatch","lastModifiedDate":"2023-11-04"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" FINDCOMMAND -\u003e FINDCOMMAND : Add to matchedResources","lastModifiedDate":"2023-11-04"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" end","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":"end","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -\u003e FINDCOMMAND : Check if matchedResources is empty","lastModifiedDate":"2023-11-04"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"FINDCOMMAND -\u003e UI : showLine()","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"deactivate FINDCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":"deactivate UI UI_COLOR","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"000verflow":63}},{"path":"docs/diagram/ListSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"@startuml","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"!include Style.puml","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/globe_internet\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Concepts/documents\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"!include \u003coffice/Users/user\u003e","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"skinparam ArrowFontStyle plain","lastModifiedDate":"2023-10-25"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"participant \":Main\" as MAIN #grey","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"participant \":UI\" as UI UI_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"Actor User as user USER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"participant \":Parser\" as PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"box Command","lastModifiedDate":"2023-10-25"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"participant \":ListCommand\" as LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"participant \":Command\" as COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"end box","lastModifiedDate":"2023-10-25"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"MAIN -[#grey]\u003e UI : readcommand()","lastModifiedDate":"2023-10-25"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"activate MAIN #grey","lastModifiedDate":"2023-10-25"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"activate UI UI_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"user -[USER_COLOR]\u003e UI : \"list /tag B\"","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"UI --[UI_COLOR]\u003e MAIN : \"list /tag B\"","lastModifiedDate":"2023-10-26"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"deactivate UI UI_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"MAIN -[#grey]\u003e PARSER : process(\"list /tag B\")","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"alt containsKey","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" PARSER -[PARSER_COLOR]\u003e PARSER: removeFirstWord(\"list /tag B\")","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" activate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" PARSER --[PARSER_COLOR]\u003e PARSER : \"/tag B\"","lastModifiedDate":"2023-10-26"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" deactivate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" PARSER -[PARSER_COLOR]\u003e LISTCOMMAND: execute(\"/tag B\")","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"else noKey","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" PARSER --[PARSER_COLOR]\u003e MAIN :","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":"end","lastModifiedDate":"2023-10-25"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e COMMAND : parseArg(\"/tag B)","lastModifiedDate":"2023-10-25"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":"activate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":"COMMAND --[COMMAND_COLOR]\u003e LISTCOMMAND : String[] values","lastModifiedDate":"2023-10-25"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e COMMAND : validate(\"/tag B\", values)","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":"COMMAND --[COMMAND_COLOR]\u003e LISTCOMMAND :","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":"deactivate COMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e LISTCOMMAND : filterResources()","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":"activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e LISTCOMMAND : hasFilters()","lastModifiedDate":"2023-10-26"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":"activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND --[COMMAND_COLOR]\u003e LISTCOMMAND","lastModifiedDate":"2023-10-26"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND -[COMMAND_COLOR]\u003e LISTCOMMAND : displayResourcesDetails()","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":"activate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":"LISTCOMMAND --[COMMAND_COLOR]\u003e PARSER","lastModifiedDate":"2023-10-25"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":"deactivate LISTCOMMAND COMMAND_COLOR","lastModifiedDate":"2023-10-26"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":"PARSER --[PARSER_COLOR]\u003e MAIN :","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":"deactivate PARSER PARSER_COLOR","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"@enduml","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"yingx9":75}},{"path":"docs/diagram/Style.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"/\u0027","lastModifiedDate":"2023-10-24"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":" \u0027Commonly used styles and colors across diagrams.","lastModifiedDate":"2023-10-24"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":" \u0027Refer to https://plantuml-documentation.readthedocs.io/en/latest for a more","lastModifiedDate":"2023-10-24"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":" \u0027comprehensive list of skinparams.","lastModifiedDate":"2023-10-24"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":" \u0027/","lastModifiedDate":"2023-10-24"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"\u0027T1 through T4 are shades of the original color from lightest to darkest","lastModifiedDate":"2023-10-24"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"!define SYSLIB_COLOR #grey","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR #1D8900","lastModifiedDate":"2023-10-24"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T1 #83E769","lastModifiedDate":"2023-10-24"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T2 #3FC71B","lastModifiedDate":"2023-10-24"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T3 #166800","lastModifiedDate":"2023-10-24"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"!define UI_COLOR_T4 #0E4100","lastModifiedDate":"2023-10-24"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR #3333C4","lastModifiedDate":"2023-10-24"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T1 #C8C8FA","lastModifiedDate":"2023-10-24"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T2 #6A6ADC","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T3 #1616B0","lastModifiedDate":"2023-10-24"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"!define PARSER_COLOR_T4 #101086","lastModifiedDate":"2023-10-24"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR #9D0012","lastModifiedDate":"2023-10-24"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T1 #F97181","lastModifiedDate":"2023-10-24"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T2 #E41F36","lastModifiedDate":"2023-10-24"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T3 #7B000E","lastModifiedDate":"2023-10-24"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"!define STORAGE_COLOR_T4 #51000A","lastModifiedDate":"2023-10-24"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR #A38300","lastModifiedDate":"2023-10-24"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_COLOR_T1 #FFE374","lastModifiedDate":"2023-10-24"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_T2 #EDC520","lastModifiedDate":"2023-10-24"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_T3 #806600","lastModifiedDate":"2023-10-24"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"!define COMMAND_COLOR_T2 #544400","lastModifiedDate":"2023-10-24"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"!define DATA_COLOR #544400","lastModifiedDate":"2023-10-24"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"!define USER_COLOR #000000","lastModifiedDate":"2023-10-24"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"skinparam Package {","lastModifiedDate":"2023-10-24"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" BackgroundColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" BorderThickness 1","lastModifiedDate":"2023-10-24"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" FontSize 16","lastModifiedDate":"2023-10-24"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":"skinparam Class {","lastModifiedDate":"2023-10-24"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" FontColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" FontSize 15","lastModifiedDate":"2023-10-24"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" BorderThickness 1","lastModifiedDate":"2023-10-24"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" BorderColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" StereotypeFontColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" FontName Arial","lastModifiedDate":"2023-10-24"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":"skinparam Actor {","lastModifiedDate":"2023-10-24"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" BorderColor USER_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" Color USER_COLOR","lastModifiedDate":"2023-10-24"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" FontName Arial","lastModifiedDate":"2023-10-24"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"skinparam Sequence {","lastModifiedDate":"2023-10-24"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" MessageAlign center","lastModifiedDate":"2023-10-24"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":" BoxFontSize 15","lastModifiedDate":"2023-10-24"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" BoxPadding 0","lastModifiedDate":"2023-10-24"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" BoxFontColor #FFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" FontName Arial","lastModifiedDate":"2023-10-24"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":"skinparam Participant {","lastModifiedDate":"2023-10-24"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" FontColor #FFFFFFF","lastModifiedDate":"2023-10-24"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" Padding 20","lastModifiedDate":"2023-10-24"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-24"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":"skinparam ArrowFontStyle bold","lastModifiedDate":"2023-10-24"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"skinparam MinClassWidth 50","lastModifiedDate":"2023-10-24"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":"skinparam ParticipantPadding 10","lastModifiedDate":"2023-10-24"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":"skinparam Shadowing false","lastModifiedDate":"2023-10-24"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":"skinparam DefaultTextAlignment center","lastModifiedDate":"2023-10-24"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":"skinparam packageStyle Rectangle","lastModifiedDate":"2023-10-24"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-24"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":"hide footbox","lastModifiedDate":"2023-10-24"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":"hide members","lastModifiedDate":"2023-10-24"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":"hide circle","lastModifiedDate":"2023-10-24"}],"authorContributionMap":{"JoanneJo":2,"yingx9":81}},{"path":"docs/team/BenjaminNg.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"# Benjamin Ng - Project Portfolio Page","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"## Overview","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"bnjm2000":6}},{"path":"docs/team/JoanneAng.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"# Joanne Ang - Project Portfolio Page","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"## Overview","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"JoanneJo":6}},{"path":"docs/team/WuXingyu.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"# Wu Xingyu - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"DavinciDelta":6}},{"path":"docs/team/YingXia.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"# Loke Ying Xia - Project Portfolio Page","lastModifiedDate":"2023-10-05"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"## Overview","lastModifiedDate":"2023-10-05"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-05"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-05"}],"authorContributionMap":{"yingx9":6}},{"path":"docs/team/ashokbalaji.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"# Ashok Balaji - Project Portfolio Page","lastModifiedDate":"2023-10-06"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"## Overview","lastModifiedDate":"2023-10-06"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-06"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"### Summary of Contributions","lastModifiedDate":"2023-10-06"}],"authorContributionMap":{"000verflow":6}},{"path":"src/main/java/seedu/commands/AddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"import seedu.data.CreateResource;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.Book.BOOK_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.CD.CD_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.Magazine.MAGAZINE_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.Newspaper.NEWSPAPER_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.EBook.EBOOK_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.EMagazine.EMAGAZINE_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"import static seedu.data.resources.ENewspaper.ENEWSPAPER_TAG;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"import static seedu.ui.UI.LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":"public class AddCommand extends Command{","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public AddCommand(){","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" args \u003d new String[]{\"id\", \"t\", \"a\", \"tag\", \"i\", \"g\", \"s\", \"l\", \"c\", \"b\", \"p\", \"ty\", \"is\", \"ed\"};","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" required \u003d new boolean[]{true, true, false, true, true, false, false, false, false, false, false, false, false","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" , false};","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" IllegalStateException, NumberFormatException, SysLibException {","lastModifiedDate":"2023-10-15"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-26"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" validateStatement(statement, values);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" String title \u003d values[1];","lastModifiedDate":"2023-10-26"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" String tag \u003d values[3];","lastModifiedDate":"2023-10-26"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" if (tag.equalsIgnoreCase(BOOK_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createBook(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This book is added: \" + title);","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(EBOOK_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createEBook(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This eBook is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(CD_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createCD(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This CD is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(MAGAZINE_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createMagazine(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This magazine is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(EMAGAZINE_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createEMagazine(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This eMagazine is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(NEWSPAPER_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createNewspaper(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This newspaper is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" } else if (tag.equalsIgnoreCase(ENEWSPAPER_TAG)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":" parser.resourceList.add(CreateResource.createENewspaper(values));","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This eNewspaper is added: \" + title);","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" throw new SysLibException(\"Please enter a valid tag.\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":" LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":60,"author":{"gitId":"JoanneJo"},"content":" System.out.println(LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":8,"bnjm2000":2,"JoanneJo":37,"DavinciDelta":10,"yingx9":7}},{"path":"src/main/java/seedu/commands/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-18"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-18"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" protected String[] args;","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" protected boolean[] required;","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":" public abstract CommandResult execute(String statement, Parser parser) throws","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" IllegalArgumentException, IllegalStateException, SysLibException;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" * A method to check if statement given is valid compared to the values extracted","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The input of user","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" * @param values The extracted value(s) from the statement","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" * @throws IllegalArgumentException The invalid arguments given","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-18"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" public void validateStatement(String statement, String[] values) throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" statement \u003d statement.toLowerCase();","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" for(int pointer \u003d 0; pointer \u003c args.length; pointer ++) {","lastModifiedDate":"2023-10-18"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" if(values[pointer] !\u003d null){","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" String arg \u003d checkDuplicate(statement, pointer);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" statement \u003d statement.replaceAll(arg+ \"\\\\s*\" + Pattern.quote(values[pointer].toLowerCase()), \"\");","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" if (!statement.isBlank()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Unknown variable/command: \" + statement);","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" * A method to check if for duplicate argument calls","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The input of user","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" * @param pointer The index of args being checked","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" * @return The argument being checked","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" public String checkDuplicate(String statement, int pointer) {","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" String arg \u003d \"/\" + args[pointer] + \" \";","lastModifiedDate":"2023-10-18"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" int firstIndex \u003d statement.indexOf(arg);","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" if (firstIndex \u003d\u003d -1) {","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" return arg;","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" int secondIndex \u003d statement.indexOf(arg, firstIndex + arg.length());","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" if(secondIndex !\u003d -1) {","lastModifiedDate":"2023-10-18"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Duplicate instances of \" + arg);","lastModifiedDate":"2023-10-18"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" return arg;","lastModifiedDate":"2023-10-18"},{"lineNumber":53,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":54,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"DavinciDelta"},"content":" * A method to get information from user input to a list","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The input of user","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"DavinciDelta"},"content":" * @return The list of information for each argument required","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":" * @throws IllegalArgumentException The missing argument that is required","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":" public String[] parseArgument(String statement) throws IllegalArgumentException {","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" String[] orderedArgs \u003d new String[args.length];","lastModifiedDate":"2023-10-18"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" for(int pointer \u003d 0; pointer \u003c args.length; pointer ++) {","lastModifiedDate":"2023-10-18"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" orderedArgs[pointer] \u003d getMatch(statement, pointer);","lastModifiedDate":"2023-10-18"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" if(orderedArgs[pointer] \u003d\u003d null \u0026\u0026 required[pointer]){","lastModifiedDate":"2023-10-18"},{"lineNumber":66,"author":{"gitId":"bnjm2000"},"content":" throw new IllegalArgumentException(args[pointer] + \" is missing in the argument!\"","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"bnjm2000"},"content":" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":69,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":70,"author":{"gitId":"DavinciDelta"},"content":" return orderedArgs;","lastModifiedDate":"2023-10-18"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":72,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":73,"author":{"gitId":"DavinciDelta"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"DavinciDelta"},"content":" * Match the required argument to one in the user\u0027s input","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"DavinciDelta"},"content":" * @param statement The user input","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"DavinciDelta"},"content":" * @param pointer The index of the required argument","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"DavinciDelta"},"content":" * @return The matched argument information, null otherwise","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"DavinciDelta"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"DavinciDelta"},"content":" public String getMatch(String statement, int pointer) {","lastModifiedDate":"2023-10-18"},{"lineNumber":81,"author":{"gitId":"DavinciDelta"},"content":" String key \u003d args[pointer];","lastModifiedDate":"2023-10-18"},{"lineNumber":82,"author":{"gitId":"DavinciDelta"},"content":" Pattern pattern \u003d Pattern.compile(\"/\" + key + \" (.+?)(?\u003d\\\\s?/|$)\", Pattern.CASE_INSENSITIVE);","lastModifiedDate":"2023-10-18"},{"lineNumber":83,"author":{"gitId":"DavinciDelta"},"content":" Matcher matcher \u003d pattern.matcher(statement);","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"DavinciDelta"},"content":" if (matcher.find()) {","lastModifiedDate":"2023-10-18"},{"lineNumber":85,"author":{"gitId":"DavinciDelta"},"content":" return matcher.group(1).trim();","lastModifiedDate":"2023-10-18"},{"lineNumber":86,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"DavinciDelta"},"content":" return null;","lastModifiedDate":"2023-10-18"},{"lineNumber":88,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-18"},{"lineNumber":89,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":90,"author":{"gitId":"DavinciDelta"},"content":" public static int parseInt(String value) {","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-10-14"},{"lineNumber":92,"author":{"gitId":"DavinciDelta"},"content":" int tempNum \u003d Integer.parseInt(value);","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"DavinciDelta"},"content":" if (0 \u003c\u003d tempNum){","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"DavinciDelta"},"content":" return tempNum;","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":96,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException (\"The argument for id is not a valid number!\");","lastModifiedDate":"2023-10-18"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-14"},{"lineNumber":98,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException (\"The argument for id is not a number!\");","lastModifiedDate":"2023-10-18"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":3,"bnjm2000":4,"JoanneJo":1,"DavinciDelta":82,"yingx9":12}},{"path":"src/main/java/seedu/commands/CommandResult.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"public class CommandResult {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":" public final String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" public CommandResult(String feedbackToUser) {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" this.feedbackToUser \u003d feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"yingx9":13}},{"path":"src/main/java/seedu/commands/DeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"public class DeleteCommand extends Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" public DeleteCommand(){","lastModifiedDate":"2023-10-18"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" args \u003d new String[]{\"id\"};","lastModifiedDate":"2023-10-18"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" required \u003d new boolean[]{true};","lastModifiedDate":"2023-10-18"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws SysLibException {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" int id \u003d parseInt(parseArgument(statement)[0]);","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" assert id \u003e 0;","lastModifiedDate":"2023-10-24"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" ArrayList\u003cResource\u003e removals \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"Looking for ID: \" + id + \"...\");","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" for (Resource r: parser.resourceList){","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" Book b \u003d (Book) r;","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" if (b.getId() \u003d\u003d id){","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" System.out.println(\"This resource is removed: \");","lastModifiedDate":"2023-10-15"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" System.out.println(b + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" removals.add(r);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" if(removals.isEmpty()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"No resources with id matching \" + id + System.lineSeparator() + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" } else {","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" parser.resourceList.removeAll(removals);","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":5,"bnjm2000":4,"JoanneJo":1,"DavinciDelta":20,"yingx9":10}},{"path":"src/main/java/seedu/commands/EditCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import java.io.File;","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLastLineDivider;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLineSeparator;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"public class EditCommand extends Command{","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":" public static final String MISSING_ARG_MESSAGE \u003d formatLastLineDivider(\"Please provide at least \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":" \"one detail to edit!\");","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" public static final String NOT_BOOK_ERROR \u003d formatLastLineDivider(\"Your resource is not a book!\");","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" public static final String RESOURCE_NOT_FOUND \u003d formatLastLineDivider(\"No such resource with given ISBN\");","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" public static final String EDIT_SUCCESS \u003d formatLineSeparator(\"Successfully updated! Your updated resource:\");","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" private static final Logger EDIT_LOGGER \u003d Logger.getLogger(EditCommand.class.getName());","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" private static int resourceIndex;","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" static {","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" FileHandler editFileHandler \u003d null;","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" String loggingDirectoryPath \u003d System.getProperty(\"user.dir\") + \"/logs\";","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" String logFilePath \u003d loggingDirectoryPath + \"/editCommandLogs.log\";","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" File directory \u003d new File(loggingDirectoryPath);","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" if (!directory.exists()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" directory.mkdir();","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" editFileHandler \u003d new FileHandler(logFilePath, true);","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.log(Level.SEVERE, \"Failed to initialize edit logging handler.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" editFileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.addHandler(editFileHandler);","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" public EditCommand(){","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" args \u003d new String[]{\"i\", \"t\", \"a\", \"tag\", \"g\", \"s\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" required \u003d new boolean[]{true, false, false, false, false, false};","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws SysLibException, IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.info(\"Edit Command execute with \" + statement);","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" String[] givenParameters \u003d parseArgument(statement);","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" validateStatement(statement, givenParameters);","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" if (hasOneArg(givenParameters)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" String givenISBN \u003d givenParameters[0];","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" Resource foundResource \u003d findResourceByISBN(givenISBN, parser.resourceList);","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" if(foundResource !\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" Resource updatedResource \u003d editResource(foundResource, givenParameters);","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":" assert updatedResource !\u003d null;","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":" assert resourceIndex \u003c parser.resourceList.size();","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":" parser.resourceList.set(resourceIndex, updatedResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d EDIT_SUCCESS + formatLastLineDivider(updatedResource.toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.info(\"Edit success\");","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d RESOURCE_NOT_FOUND;","lastModifiedDate":"2023-10-30"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.warning(feedbackToUser);","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":84,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":85,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.warning(MISSING_ARG_MESSAGE);","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(MISSING_ARG_MESSAGE);","lastModifiedDate":"2023-10-30"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":90,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":" public boolean hasOneArg(String[] givenParameters){","lastModifiedDate":"2023-10-30"},{"lineNumber":92,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":93,"author":{"gitId":"yingx9"},"content":" for (int i \u003d1; i\u003cgivenParameters.length; i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" if (givenParameters[i] !\u003d null){","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":" public Resource findResourceByISBN(String givenISBN, List\u003cResource\u003e resourceList){","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" Resource foundResource \u003d null;","lastModifiedDate":"2023-10-30"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" for (int i\u003d0;i \u003c resourceList.size(); i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"yingx9"},"content":" Resource tempResource \u003d resourceList.get(i);","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":109,"author":{"gitId":"yingx9"},"content":" String resourceISBN \u003d tempResource.getISBN();","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"yingx9"},"content":" if (resourceISBN.equals(givenISBN)){","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"yingx9"},"content":" foundResource \u003d tempResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"yingx9"},"content":" resourceIndex \u003d i;","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":115,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" return foundResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":117,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"yingx9"},"content":" public Resource editResource(Resource foundResource, String[] givenParameters) throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"yingx9"},"content":" String newValue;","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"yingx9"},"content":" for(int i\u003d1; i\u003cgivenParameters.length;i++) {","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"yingx9"},"content":" if(givenParameters[i] \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"yingx9"},"content":" continue;","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"yingx9"},"content":" newValue \u003d givenParameters[i];","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":131,"author":{"gitId":"yingx9"},"content":" switch(i) {","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":133,"author":{"gitId":"yingx9"},"content":" case 1:","lastModifiedDate":"2023-10-30"},{"lineNumber":134,"author":{"gitId":"yingx9"},"content":" foundResource.setTitle(newValue);","lastModifiedDate":"2023-10-30"},{"lineNumber":135,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":136,"author":{"gitId":"yingx9"},"content":" case 2:","lastModifiedDate":"2023-10-30"},{"lineNumber":137,"author":{"gitId":"yingx9"},"content":" Book bookResource\u003d castResourceToBook(foundResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":138,"author":{"gitId":"yingx9"},"content":" bookResource.setAuthor(newValue);","lastModifiedDate":"2023-10-30"},{"lineNumber":139,"author":{"gitId":"yingx9"},"content":" foundResource \u003d bookResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":141,"author":{"gitId":"yingx9"},"content":" case 3:","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"yingx9"},"content":" foundResource.setTag(newValue);","lastModifiedDate":"2023-10-30"},{"lineNumber":143,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":144,"author":{"gitId":"yingx9"},"content":" case 4:","lastModifiedDate":"2023-10-30"},{"lineNumber":145,"author":{"gitId":"yingx9"},"content":" Book book\u003d castResourceToBook(foundResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"yingx9"},"content":" String[] newGenres \u003d newValue.split(\", \");","lastModifiedDate":"2023-10-30"},{"lineNumber":147,"author":{"gitId":"yingx9"},"content":" book.setGenre(newGenres);","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"yingx9"},"content":" foundResource \u003d book;","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"bnjm2000"},"content":" case 5:","lastModifiedDate":"2023-10-30"},{"lineNumber":151,"author":{"gitId":"bnjm2000"},"content":" if (foundResource instanceof Book) {","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"bnjm2000"},"content":" Book bookStatus \u003d castResourceToBook(foundResource);","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"bnjm2000"},"content":" bookStatus.setStatus(getStatusFromString(newValue));","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"bnjm2000"},"content":" foundResource \u003d bookStatus;","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"bnjm2000"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":" default:","lastModifiedDate":"2023-10-30"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(\"Input error\");","lastModifiedDate":"2023-10-30"},{"lineNumber":159,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":160,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":161,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":162,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"yingx9"},"content":" return foundResource;","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":168,"author":{"gitId":"yingx9"},"content":" public Book castResourceToBook(Resource resource) throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":169,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"yingx9"},"content":" Book book;","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"yingx9"},"content":" if (resource instanceof Book) {","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"yingx9"},"content":" book \u003d (Book) resource;","lastModifiedDate":"2023-10-30"},{"lineNumber":174,"author":{"gitId":"yingx9"},"content":" } else{","lastModifiedDate":"2023-10-30"},{"lineNumber":175,"author":{"gitId":"yingx9"},"content":" EDIT_LOGGER.warning(NOT_BOOK_ERROR);","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(NOT_BOOK_ERROR);","lastModifiedDate":"2023-10-30"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":179,"author":{"gitId":"yingx9"},"content":" return book;","lastModifiedDate":"2023-10-30"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":" public Status getStatusFromString(String statusString) {","lastModifiedDate":"2023-10-30"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":" statusString \u003d statusString.toLowerCase().trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":" if (statusString.equals(\"borrowed\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":" return Status.BORROWED;","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"bnjm2000"},"content":" } else if (statusString.equals(\"lost\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":" return Status.LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bnjm2000"},"content":" return Status.AVAILABLE;","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"000verflow":3,"bnjm2000":20,"DavinciDelta":1,"yingx9":169}},{"path":"src/main/java/seedu/commands/ExitCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":" * Command to print exit message","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":"public class ExitCommand extends Command{","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" static {","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" // remove logs from showing in stdout","lastModifiedDate":"2023-10-17"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" for (java.util.logging.Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" if (handler instanceof java.util.logging.ConsoleHandler) {","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" FileHandler fileHandler \u003d new FileHandler(\"logs/exitCommandLogs.log\", true);","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":" fileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":" LOGGER.addHandler(fileHandler);","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" LOGGER.setLevel(Level.INFO);","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" LOGGER.log(Level.SEVERE, \"Failed to set up log file handler\", e);","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"bnjm2000"},"content":" assert statement !\u003d null : \"Statement to execute cannot be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"bnjm2000"},"content":" assert parser !\u003d null : \"Parser must not be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"bnjm2000"},"content":" LOGGER.log(Level.INFO, \"Executing ExitCommand...\");","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" UI ui \u003d new UI();","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" ui.showExitMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"bnjm2000":54,"yingx9":4}},{"path":"src/main/java/seedu/commands/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":" public static final int FIRST_INDEX \u003d 0;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" public static final int SECOND_INDEX \u003d 1;","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" public static final int THIRD_INDEX \u003d 2;","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" public static final int FOURTH_INDEX \u003d 3;","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" private static final String INVALID_ARGUMENT_MESSAGE \u003d \"Please use the format \u0027find [/t TITLE OR \"","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" + \"/i ISBN OR /a AUTHOR OR /id ID]\u0027\\n\" + \"____________________________________________________________\";","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" private static final String NO_RESOURCE_FOUND_MESSAGE \u003d \"There are no resources found matching the given filters.\";","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" private static final String RESOURCE_FOUND_MESSAGE \u003d \"Here are resources that matched the given filters:\";","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" static {","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" // remove logs from showing in stdout","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" for (java.util.logging.Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":" if (handler instanceof java.util.logging.ConsoleHandler) {","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":" FileHandler fileHandler \u003d new FileHandler(\"logs/findCommandLogs.log\", true);","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" fileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":" LOGGER.addHandler(fileHandler);","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" LOGGER.setLevel(Level.INFO);","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" LOGGER.log(Level.SEVERE, \"Failed to set up log file handler\", e);","lastModifiedDate":"2023-10-17"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" protected String title;","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" protected String author;","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" protected String isbn;","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":" protected String id;","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" protected UI ui;","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" public FindCommand(){","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" args \u003d new String[]{\"id\", \"i\", \"a\", \"t\"};","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" required \u003d new boolean[]{false, false, false, false};","lastModifiedDate":"2023-11-04"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":" ui \u003d new UI();","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":" LOGGER.info(\"FindCommand instance created.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":" public void setTitle(String title){","lastModifiedDate":"2023-10-17"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" this.title \u003d title;","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":" public String getTitle(){","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":" return this.title;","lastModifiedDate":"2023-10-15"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" public void setAuthor(String author){","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" this.author \u003d author;","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" public String getAuthor(){","lastModifiedDate":"2023-10-17"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" return this.author;","lastModifiedDate":"2023-10-15"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" public void setISBN(String isbn){","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":" this.isbn \u003d isbn;","lastModifiedDate":"2023-10-15"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":" public String getISBN(){","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" return this.isbn;","lastModifiedDate":"2023-10-15"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":" public void setID(String id){","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":" this.id \u003d id;","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":" public String getID(){","lastModifiedDate":"2023-10-17"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" return this.id;","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws IllegalArgumentException, SysLibException {","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" assert parser !\u003d null : \"Parser cannot be null!\";","lastModifiedDate":"2023-10-17"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-11-03"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" validateStatement(statement, values);","lastModifiedDate":"2023-11-03"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":" // all null","lastModifiedDate":"2023-11-03"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":" if (values[FOURTH_INDEX]\u003d\u003dnull \u0026\u0026 values[THIRD_INDEX]\u003d\u003dnull \u0026\u0026 values[SECOND_INDEX]\u003d\u003dnull","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":" \u0026\u0026 values[FIRST_INDEX]\u003d\u003dnull) {","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" throw new IllegalArgumentException(INVALID_ARGUMENT_MESSAGE + System.lineSeparator());","lastModifiedDate":"2023-10-17"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":106,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":" ArrayList\u003cResource\u003e matchedResources \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":" for (Resource resource: parser.resourceList){","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" boolean isMatch \u003d true;","lastModifiedDate":"2023-11-03"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":" String resourceType \u003d resource.getTag();","lastModifiedDate":"2023-11-03"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":" if (values[FIRST_INDEX] !\u003d null \u0026\u0026 resource.getId() !\u003d Integer.parseInt(values[FIRST_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":114,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":115,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":116,"author":{"gitId":"000verflow"},"content":" if (values[SECOND_INDEX] !\u003d null \u0026\u0026 !resource.getISBN().equalsIgnoreCase(values[SECOND_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":117,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":118,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":119,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":120,"author":{"gitId":"000verflow"},"content":" switch (resourceType) {","lastModifiedDate":"2023-11-03"},{"lineNumber":121,"author":{"gitId":"000verflow"},"content":" case \"B\":","lastModifiedDate":"2023-11-03"},{"lineNumber":122,"author":{"gitId":"000verflow"},"content":" case \"EB\":","lastModifiedDate":"2023-11-03"},{"lineNumber":123,"author":{"gitId":"000verflow"},"content":" Book b \u003d (Book) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":124,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !b.getAuthor().trim().equalsIgnoreCase((values[THIRD_INDEX]))) {","lastModifiedDate":"2023-11-03"},{"lineNumber":125,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":126,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":127,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":128,"author":{"gitId":"000verflow"},"content":" case \"M\":","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"000verflow"},"content":" case \"EM\":","lastModifiedDate":"2023-11-03"},{"lineNumber":130,"author":{"gitId":"000verflow"},"content":" Magazine m \u003d (Magazine) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":131,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !m.getBrand().trim().equalsIgnoreCase(values[THIRD_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":132,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":134,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":135,"author":{"gitId":"000verflow"},"content":" case \"N\":","lastModifiedDate":"2023-11-03"},{"lineNumber":136,"author":{"gitId":"000verflow"},"content":" case \"EN\":","lastModifiedDate":"2023-11-03"},{"lineNumber":137,"author":{"gitId":"000verflow"},"content":" Newspaper n \u003d (Newspaper) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":138,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !n.getPublisher().trim().equalsIgnoreCase(values[THIRD_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":139,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":140,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":141,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":142,"author":{"gitId":"000verflow"},"content":" case \"CD\":","lastModifiedDate":"2023-11-03"},{"lineNumber":143,"author":{"gitId":"000verflow"},"content":" CD cd \u003d (CD) resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"000verflow"},"content":" if (values[THIRD_INDEX] !\u003d null \u0026\u0026 !cd.getCreator().trim().equalsIgnoreCase(values[THIRD_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":146,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":147,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":149,"author":{"gitId":"000verflow"},"content":" default:","lastModifiedDate":"2023-11-03"},{"lineNumber":150,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown resource type found.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":152,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":153,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"000verflow"},"content":" if (values[FOURTH_INDEX] !\u003d null \u0026\u0026 !resource.getTitle().equalsIgnoreCase(values[FOURTH_INDEX])) {","lastModifiedDate":"2023-11-03"},{"lineNumber":155,"author":{"gitId":"000verflow"},"content":" isMatch \u003d false;","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":157,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":158,"author":{"gitId":"000verflow"},"content":" // If all non-null criteria matched, add the book to the list","lastModifiedDate":"2023-11-03"},{"lineNumber":159,"author":{"gitId":"000verflow"},"content":" if (isMatch) {","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"000verflow"},"content":" LOGGER.info(String.format(\"Resource with name: %s matched given arguments.\", resource.getTitle()));","lastModifiedDate":"2023-11-03"},{"lineNumber":161,"author":{"gitId":"000verflow"},"content":" matchedResources.add(resource);","lastModifiedDate":"2023-11-03"},{"lineNumber":162,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":163,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":164,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":165,"author":{"gitId":"000verflow"},"content":" if (matchedResources.isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":166,"author":{"gitId":"000verflow"},"content":" LOGGER.info(\"No resources matched the given filters.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"000verflow"},"content":" System.out.println(NO_RESOURCE_FOUND_MESSAGE);","lastModifiedDate":"2023-10-17"},{"lineNumber":168,"author":{"gitId":"000verflow"},"content":" ui.showLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":169,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":170,"author":{"gitId":"000verflow"},"content":" LOGGER.info(\"Resources matched the given filters.\");","lastModifiedDate":"2023-10-17"},{"lineNumber":171,"author":{"gitId":"000verflow"},"content":" System.out.println(RESOURCE_FOUND_MESSAGE);","lastModifiedDate":"2023-10-17"},{"lineNumber":172,"author":{"gitId":"000verflow"},"content":" for (Resource r : matchedResources) {","lastModifiedDate":"2023-10-15"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":" System.out.println(r);","lastModifiedDate":"2023-10-15"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":175,"author":{"gitId":"000verflow"},"content":" ui.showLine();","lastModifiedDate":"2023-10-17"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":179,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":180,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":169,"yingx9":12}},{"path":"src/main/java/seedu/commands/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-17"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"/**","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":" * Command to print help message","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" private static final Logger logger \u003d Logger.getLogger(HelpCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(FindCommand.class.getName());","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" static {","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" // remove logs from showing in stdout","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" try {","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" for (java.util.logging.Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" if (handler instanceof java.util.logging.ConsoleHandler) {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" FileHandler fileHandler \u003d new FileHandler(\"logs/helpCommandLogs.log\", true);","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" fileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" LOGGER.addHandler(fileHandler);","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" LOGGER.setLevel(Level.INFO);","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":" LOGGER.log(Level.SEVERE, \"Failed to set up log file handler\", e);","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" assert statement !\u003d null : \"Statement to execute cannot be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" assert parser !\u003d null : \"Parser must not be null\";","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" UI ui \u003d new UI();","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" logger.log(Level.INFO, \"Executing HelpCommand\");","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" ui.showHelpMessage();","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":2,"bnjm2000":50,"yingx9":11}},{"path":"src/main/java/seedu/commands/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"import java.io.File;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-15"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLineSeparator;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLastLineDivider;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatFirstLine;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-26"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" public static final String FILTER_MESSAGE \u003d formatFirstLine(\"Listing resources matching given filters: \");","lastModifiedDate":"2023-10-26"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" public static final String GENERIC_MESSAGE \u003d formatFirstLine(\"Listing all resources in the Library:\");","lastModifiedDate":"2023-10-26"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" public static final String ZERO_RESOURCES_MESSAGE \u003d formatLastLineDivider(\"There are currently 0 resources.\");","lastModifiedDate":"2023-10-26"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" public static List\u003cResource\u003e matchedResources;","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" private static final Logger LIST_LOGGER \u003d Logger.getLogger(ListCommand.class.getName());","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":" private static String tagKeyword;","lastModifiedDate":"2023-10-19"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" private static String genreKeyword;","lastModifiedDate":"2023-10-19"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" private static String statusKeyword;","lastModifiedDate":"2023-11-04"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-10-26"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" static {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" FileHandler editFileHandler \u003d null;","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" String loggingDirectoryPath \u003d System.getProperty(\"user.dir\") + \"/logs\";","lastModifiedDate":"2023-11-04"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" String logFilePath \u003d loggingDirectoryPath + \"/editCommandLogs.log\";","lastModifiedDate":"2023-11-04"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" File directory \u003d new File(loggingDirectoryPath);","lastModifiedDate":"2023-11-04"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" if (!directory.exists()) {","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" directory.mkdir();","lastModifiedDate":"2023-11-04"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" editFileHandler \u003d new FileHandler(logFilePath, true);","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.log(Level.SEVERE, \"Failed to initialize list logging handler.\");","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" throw new RuntimeException(e);","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":" editFileHandler.setFormatter(new SimpleFormatter());","lastModifiedDate":"2023-11-04"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.addHandler(editFileHandler);","lastModifiedDate":"2023-11-04"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" public ListCommand(){","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" args \u003d new String[]{\"tag\", \"g\", \"s\"};","lastModifiedDate":"2023-11-04"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" required \u003d new boolean[]{false, false, false};","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-19"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws SysLibException, IllegalArgumentException {","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-10-26"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.info(\"List Command execute with \" + statement);","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-19"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":" validateStatement(statement, values);","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" filterResources(values, parser.resourceList);","lastModifiedDate":"2023-10-26"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":" LIST_LOGGER.info(\"List Command ends\");","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" public void filterResources(String[] values, List\u003cResource\u003e resourceList) throws SysLibException{","lastModifiedDate":"2023-10-26"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" boolean hasFilters \u003d hasFilters((values));","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":" matchedResources \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":85,"author":{"gitId":"yingx9"},"content":" if(hasFilters){","lastModifiedDate":"2023-10-26"},{"lineNumber":86,"author":{"gitId":"yingx9"},"content":" boolean isTagEqualToKeyword \u003d true;","lastModifiedDate":"2023-10-19"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" boolean isGenreEqualToKeyword \u003d true;","lastModifiedDate":"2023-10-19"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":" boolean isStatusEqualToKeyword \u003d true;","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"bnjm2000"},"content":" for (Resource resource : resourceList) {","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":92,"author":{"gitId":"yingx9"},"content":" if (tagKeyword !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":93,"author":{"gitId":"yingx9"},"content":" String resourceTag \u003d resource.getTag();","lastModifiedDate":"2023-10-19"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" isTagEqualToKeyword \u003d resourceTag.equals(tagKeyword);","lastModifiedDate":"2023-10-19"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" if (genreKeyword !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":" isGenreEqualToKeyword \u003d Resource.hasGenre(resource, genreKeyword);","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":" if (statusKeyword !\u003d null) {","lastModifiedDate":"2023-11-04"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":" Status resourceStatus \u003d resource.getStatus();","lastModifiedDate":"2023-11-04"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" isStatusEqualToKeyword \u003d statusKeyword.equals(resourceStatus.name());","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":107,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"yingx9"},"content":" if (isTagEqualToKeyword \u0026\u0026 isGenreEqualToKeyword \u0026\u0026 isStatusEqualToKeyword) {","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"yingx9"},"content":" matchedResources.add(resource);","lastModifiedDate":"2023-10-19"},{"lineNumber":110,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":111,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":112,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":113,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d FILTER_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":114,"author":{"gitId":"yingx9"},"content":" displayResourcesDetails(matchedResources);","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d GENERIC_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":118,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":119,"author":{"gitId":"yingx9"},"content":" displayResourcesDetails(resourceList);","lastModifiedDate":"2023-10-26"},{"lineNumber":120,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":121,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":122,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":123,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":124,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"yingx9"},"content":" public static String displayResourcesDetails(List\u003cResource\u003e resourcesList) {","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":127,"author":{"gitId":"yingx9"},"content":" String messageToDisplay \u003d \"\";","lastModifiedDate":"2023-10-26"},{"lineNumber":128,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":129,"author":{"gitId":"yingx9"},"content":" if (resourcesList.isEmpty()){","lastModifiedDate":"2023-10-19"},{"lineNumber":130,"author":{"gitId":"yingx9"},"content":" messageToDisplay +\u003d ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":131,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":132,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-19"},{"lineNumber":133,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":134,"author":{"gitId":"yingx9"},"content":" for (int i \u003d 0; i \u003c resourcesList.size(); i +\u003d 1) {","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"yingx9"},"content":" String resourceDetails \u003d resourcesList.get(i).toString();","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"yingx9"},"content":" messageToDisplay +\u003d formatLineSeparator(i+1 + \". \" + resourceDetails);","lastModifiedDate":"2023-10-26"},{"lineNumber":137,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":138,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":139,"author":{"gitId":"yingx9"},"content":" messageToDisplay +\u003d formatLastLineDivider(\"There are currently \" + resourcesList.size() +","lastModifiedDate":"2023-10-26"},{"lineNumber":140,"author":{"gitId":"yingx9"},"content":" \" resource(s).\");","lastModifiedDate":"2023-10-26"},{"lineNumber":141,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":142,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":143,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":144,"author":{"gitId":"yingx9"},"content":" feedbackToUser +\u003d messageToDisplay;","lastModifiedDate":"2023-10-26"},{"lineNumber":145,"author":{"gitId":"yingx9"},"content":" return messageToDisplay;","lastModifiedDate":"2023-10-26"},{"lineNumber":146,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":147,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":148,"author":{"gitId":"yingx9"},"content":" public static boolean hasFilters(String[] values) throws SysLibException {","lastModifiedDate":"2023-10-26"},{"lineNumber":149,"author":{"gitId":"yingx9"},"content":" tagKeyword \u003d null;","lastModifiedDate":"2023-10-26"},{"lineNumber":150,"author":{"gitId":"yingx9"},"content":" genreKeyword \u003d null;","lastModifiedDate":"2023-10-26"},{"lineNumber":151,"author":{"gitId":"yingx9"},"content":" statusKeyword \u003d null;","lastModifiedDate":"2023-11-04"},{"lineNumber":152,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":153,"author":{"gitId":"yingx9"},"content":" boolean hasFilters \u003d true;","lastModifiedDate":"2023-10-26"},{"lineNumber":154,"author":{"gitId":"yingx9"},"content":" if (values[0] \u003d\u003d null \u0026\u0026 values[1] \u003d\u003d null \u0026\u0026 values[2] \u003d\u003d null) {","lastModifiedDate":"2023-11-04"},{"lineNumber":155,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":156,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":" if (values[0] !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":159,"author":{"gitId":"yingx9"},"content":" tagKeyword \u003d values[0];","lastModifiedDate":"2023-10-26"},{"lineNumber":160,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":161,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":162,"author":{"gitId":"yingx9"},"content":" if (values[1] !\u003d null) {","lastModifiedDate":"2023-10-26"},{"lineNumber":163,"author":{"gitId":"yingx9"},"content":" genreKeyword \u003d values[1];","lastModifiedDate":"2023-10-26"},{"lineNumber":164,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-19"},{"lineNumber":165,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":" if (values[2] !\u003d null){","lastModifiedDate":"2023-11-04"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":" statusKeyword \u003d values[2].toUpperCase();","lastModifiedDate":"2023-11-04"},{"lineNumber":168,"author":{"gitId":"yingx9"},"content":" validateStatus();","lastModifiedDate":"2023-11-04"},{"lineNumber":169,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":170,"author":{"gitId":"yingx9"},"content":" return hasFilters;","lastModifiedDate":"2023-10-26"},{"lineNumber":171,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":172,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":173,"author":{"gitId":"yingx9"},"content":" public static void validateStatus() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":174,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":175,"author":{"gitId":"yingx9"},"content":" switch(statusKeyword){","lastModifiedDate":"2023-11-04"},{"lineNumber":176,"author":{"gitId":"yingx9"},"content":" case \"AVAILABLE\":","lastModifiedDate":"2023-11-04"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":" //fallthrough","lastModifiedDate":"2023-11-04"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":" case \"BORROWED\":","lastModifiedDate":"2023-11-04"},{"lineNumber":179,"author":{"gitId":"yingx9"},"content":" //fallthrough","lastModifiedDate":"2023-11-04"},{"lineNumber":180,"author":{"gitId":"yingx9"},"content":" case \"LOST\":","lastModifiedDate":"2023-11-04"},{"lineNumber":181,"author":{"gitId":"yingx9"},"content":" break;","lastModifiedDate":"2023-11-04"},{"lineNumber":182,"author":{"gitId":"yingx9"},"content":" default:","lastModifiedDate":"2023-11-04"},{"lineNumber":183,"author":{"gitId":"yingx9"},"content":" throw new SysLibException(\"Please enter a valid status: AVAILABLE / BORROWED / LOST\");","lastModifiedDate":"2023-11-04"},{"lineNumber":184,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":185,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":186,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":187,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":4,"bnjm2000":2,"DavinciDelta":1,"yingx9":180}},{"path":"src/main/java/seedu/commands/events/EventAddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.data.Event;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import java.time.format.DateTimeFormatterBuilder;","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"import java.time.format.ResolverStyle;","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":"import java.util.Locale;","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":"public class EventAddCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public EventAddCommand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" args \u003d new String[]{\"t\", \"date\", \"desc\"};","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" required \u003d new boolean[]{true, true, false};","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser)","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" throws IllegalArgumentException, IllegalStateException, SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" LocalDate currentDate \u003d parseDate(values[1]);","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" int index \u003d binarySearch(parser, currentDate);","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" parser.eventList.add(index, new Event(values[0], currentDate, values[2]));","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"Event inserted at: \" + index);","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" public static int binarySearch(Parser parser, LocalDate key) {","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" if(parser.eventList.isEmpty()){","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" return 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" int low \u003d 0;","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" int high \u003d parser.eventList.size() - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" while (low \u003c\u003d high) {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" int mid \u003d (low + high)/2;","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" LocalDate midVal \u003d parser.eventList.get(mid).getDate();","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" int cmp \u003d midVal.compareTo(key);","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" if (cmp \u003c 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" low \u003d mid + 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" } else if (cmp \u003e 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"DavinciDelta"},"content":" high \u003d mid - 1;","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"DavinciDelta"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"DavinciDelta"},"content":" return mid;","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"DavinciDelta"},"content":" return low;","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":" public static LocalDate parseDate(String dateStr) throws IllegalArgumentException {","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" DateTimeFormatter formatter \u003d new DateTimeFormatterBuilder()","lastModifiedDate":"2023-11-04"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" .parseCaseInsensitive()","lastModifiedDate":"2023-11-04"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" .appendPattern(\"dd MMM yyyy\")","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" .toFormatter(Locale.ENGLISH)","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"DavinciDelta"},"content":" .withResolverStyle(ResolverStyle.SMART);","lastModifiedDate":"2023-11-04"},{"lineNumber":67,"author":{"gitId":"DavinciDelta"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"DavinciDelta"},"content":" dateStr \u003d checkDate(dateStr);","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"DavinciDelta"},"content":" return LocalDate.parse(dateStr, formatter);","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"DavinciDelta"},"content":" } catch (DateTimeParseException e) {","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Please enter a valid date in the format \u0027dd MMM yyyy\u0027\"","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"DavinciDelta"},"content":" + System.lineSeparator()","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"DavinciDelta"},"content":" + \"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"DavinciDelta"},"content":" public static String checkDate(String dateStr) throws IllegalArgumentException {","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"DavinciDelta"},"content":" String[] temp \u003d dateStr.split(\" \");","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"DavinciDelta"},"content":" int first \u003d parseInt(temp[0]);","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"DavinciDelta"},"content":" if(first \u003c 10){","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"DavinciDelta"},"content":" return \"0\" + dateStr;","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"DavinciDelta"},"content":" return dateStr;","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":85,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":76,"yingx9":8}},{"path":"src/main/java/seedu/commands/events/EventDeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"public class EventDeleteCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":" public EventDeleteCommand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" args \u003d new String[]{\"i\"};","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" required \u003d new boolean[]{true};","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser)","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" throws IllegalArgumentException, IllegalStateException, SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" String[] values \u003d parseArgument(statement);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" int index \u003d parseCalendarInt(values[0], parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"This event is removed:\");","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(parser.eventList.get(index).toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" parser.eventList.remove(index);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" public int parseCalendarInt(String value, Parser parser) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" int index \u003d parseInt(value);","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" int size \u003d parser.eventList.size();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" if (index \u003e\u003d size || index \u003c 0) {","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"Index is out of range of the event list!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" return index;","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":30,"yingx9":6}},{"path":"src/main/java/seedu/commands/events/EventListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"public class EventListCommand extends Command {","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" private static String feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":" public CommandResult execute(String statement, Parser parser) throws","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" IllegalArgumentException, IllegalStateException, SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":" feedbackToUser \u003d \"\";","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" if (!statement.isEmpty()){","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" throw new IllegalArgumentException(\"\u0027eventlist\u0027 command does not require arguments!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" if(parser.eventList.isEmpty()){","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"The event list is empty!\");","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"This is the current event list:\");","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" for(int index \u003d 0; index \u003c parser.eventList.size(); index +\u003d 1){","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(index + \": \" + parser.eventList.get(index).toString());","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"____________________________________________________________\");","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" return new CommandResult(feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":4,"DavinciDelta":21,"yingx9":7}},{"path":"src/main/java/seedu/common/FormatMessages.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.common;","lastModifiedDate":"2023-10-26"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"import static seedu.ui.UI.LINESEPARATOR;","lastModifiedDate":"2023-10-26"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-26"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"public class FormatMessages {","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" public static String formatFirstLine(String message){","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" return LINESEPARATOR + message + LINESEPARATOR + LINESEPARATOR;","lastModifiedDate":"2023-10-26"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":" public static String formatLineSeparator(String message){","lastModifiedDate":"2023-10-26"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":" return message + LINESEPARATOR;","lastModifiedDate":"2023-10-26"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":" public static String formatLastLineDivider(String message){","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":" return LINESEPARATOR + message + SEPARATOR_LINEDIVIDER + LINESEPARATOR;","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-26"}],"authorContributionMap":{"yingx9":17}},{"path":"src/main/java/seedu/data/CreateResource.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"package seedu.data;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EBook;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EMagazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.ENewspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"import static seedu.parser.Parser.getStatusFromString;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"public class CreateResource {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public static Book createBook(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" String author \u003d args[2];","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" String genre;","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" String[] genres \u003d new String[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" if (args[5] !\u003d null) {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" genre \u003d args[5];","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" genres \u003d genre.split(\", \");","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" return new Book(title, isbn, author, genres, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" public static EBook createEBook(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" String author \u003d args[2];","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]); // Get the status from the provided string","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" String link \u003d args[7];","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" String genre;","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":" String[] genres \u003d new String[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" if (args[5] !\u003d null) {","lastModifiedDate":"2023-10-31"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":" genre \u003d args[5];","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"JoanneJo"},"content":" genres \u003d genre.split(\", \");","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":60,"author":{"gitId":"JoanneJo"},"content":" return new EBook(title, isbn, author, genres, id, status, link);","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"JoanneJo"},"content":" public static CD createCD(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":67,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":69,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":70,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"JoanneJo"},"content":" String creator \u003d args[8];","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"JoanneJo"},"content":" String type \u003d args[11];","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"JoanneJo"},"content":" return new CD(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"JoanneJo"},"content":" public static Magazine createMagazine(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":" String brand \u003d args[9];","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"JoanneJo"},"content":" String issue \u003d args[12];","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"JoanneJo"},"content":" return new Magazine(title, isbn, brand, issue, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"JoanneJo"},"content":" public static Magazine createEMagazine(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":104,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":105,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"JoanneJo"},"content":" String brand \u003d args[9];","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"JoanneJo"},"content":" String issue \u003d args[12];","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"JoanneJo"},"content":" String link \u003d args[7];","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":112,"author":{"gitId":"JoanneJo"},"content":" return new EMagazine(title, isbn, brand, issue, id, status, link);","lastModifiedDate":"2023-11-03"},{"lineNumber":113,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":115,"author":{"gitId":"JoanneJo"},"content":" public static Newspaper createNewspaper(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-10-31"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":120,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":122,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":" String publisher \u003d args[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":126,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"JoanneJo"},"content":" String edition \u003d args[13];","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"JoanneJo"},"content":" return new Newspaper(title, isbn, publisher, edition, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":" public static ENewspaper createENewspaper(String[] args) throws IllegalStateException, NumberFormatException {","lastModifiedDate":"2023-11-03"},{"lineNumber":133,"author":{"gitId":"JoanneJo"},"content":" int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-31"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":" id \u003d Integer.parseInt(args[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-31"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":" throw new NumberFormatException(\"Please enter a valid id.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":138,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"JoanneJo"},"content":" String title \u003d args[1];","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"JoanneJo"},"content":" String publisher \u003d args[10];","lastModifiedDate":"2023-10-31"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":" String isbn \u003d args[4];","lastModifiedDate":"2023-10-31"},{"lineNumber":143,"author":{"gitId":"JoanneJo"},"content":" Status status \u003d getStatusFromString(args[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":" String edition \u003d args[13];","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"JoanneJo"},"content":" String link \u003d args[7];","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":147,"author":{"gitId":"JoanneJo"},"content":" return new ENewspaper(title, isbn, publisher, edition, id, status, link);","lastModifiedDate":"2023-11-03"},{"lineNumber":148,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":8,"JoanneJo":141}},{"path":"src/main/java/seedu/data/Event.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.data;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"public class Event {","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":" private final String name;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":" private final LocalDate date;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":" private final String description;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":" public Event(String name, LocalDate date, String description) {","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":" this.date \u003d date;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" this.description \u003d description;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" public LocalDate getDate() {","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" return date;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" public String getName() {","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" return name;","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" public String getDescription() {","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" return description;","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd MMM yyyy\");","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" return name + \" | \" + date.format(formatter) + \" | \" + description;","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":10,"DavinciDelta":24}},{"path":"src/main/java/seedu/data/Status.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.data;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"public enum Status {","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":" AVAILABLE,","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":" BORROWED,","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":" LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"bnjm2000":7}},{"path":"src/main/java/seedu/data/resources/Book.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"public class Book extends Resource {","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String BOOK_TAG \u003d \"B\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":" private String author;","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" //private String synopsis;","lastModifiedDate":"2023-10-15"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" private String[] genres;","lastModifiedDate":"2023-10-15"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":" public Book(String title, String isbn, String author, String[] genres, int id, Status status) {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setTag(BOOK_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" setAuthor(author);","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" //setSynopsis(synopsis);","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" setGenre(genres);","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" public String getAuthor() {","lastModifiedDate":"2023-10-14"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" return author;","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" public void setAuthor(String author) {","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" this.author \u003d author;","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" /*public String getSynopsis() {","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" return synopsis;","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" public void setSynopsis(String synopsis) {","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" this.synopsis \u003d synopsis;","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" }*/","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String[] getGenre() {","lastModifiedDate":"2023-10-15"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return genres;","lastModifiedDate":"2023-10-15"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":" public void setGenre(String[] genres) {","lastModifiedDate":"2023-10-15"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" this.genres \u003d genres;","lastModifiedDate":"2023-10-15"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" public String getGenreString() {","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":" return String.join(\", \", genres);","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" @Override","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" public String toString() {","lastModifiedDate":"2023-10-14"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" StringBuilder genreString \u003d new StringBuilder();","lastModifiedDate":"2023-10-15"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":" if (getGenre()[0] \u003d\u003d null) {","lastModifiedDate":"2023-10-15"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" genreString.append(\"-\");","lastModifiedDate":"2023-10-15"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" genreString.append(java.util.Arrays.toString(getGenre()).replace(\"[\", \"\").replace(\"]\", \"\"));","lastModifiedDate":"2023-10-15"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Author: \"","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" + getAuthor() + \" Genre: \" + genreString + \" Status: \" + getStatus().name() + \" Received Date: \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" getDateReceived();","lastModifiedDate":"2023-10-31"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-14"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":3,"bnjm2000":1,"JoanneJo":29,"DavinciDelta":21,"yingx9":6}},{"path":"src/main/java/seedu/data/resources/CD.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class CD extends Resource {","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String CD_TAG \u003d \"CD\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String creator;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" private String type;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" public CD(String title, String isbn, String creator, String type, int id, Status status) {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setTag(CD_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setCreator(creator);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":" setType(type);","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" public String getCreator() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" return creator;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" public void setCreator(String creator) {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" this.creator \u003d creator;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" public String getType() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" return type;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" public void setType(String type) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" this.type \u003d type;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN()","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" + \" Creator: \" + getCreator() + \" Type: \" + getType() + \" Status: \" + getStatus().name();","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":35}},{"path":"src/main/java/seedu/data/resources/EBook.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class EBook extends Book{","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String EBOOK_TAG \u003d \"EB\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String link;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" public EBook(String title, String isbn, String author, String[] genres, int id, Status status, String link) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, author, genres, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" setTag(EBOOK_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setLink(link);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public String getLink() {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" return link;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public void setLink(String link) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" this.link \u003d link;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" StringBuilder genreString \u003d new StringBuilder();","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" if (getGenre()[0] \u003d\u003d null) {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" genreString.append(\"-\");","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" genreString.append(java.util.Arrays.toString(getGenre()).replace(\"[\", \"\").replace(\"]\", \"\"));","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Author: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" + getAuthor() + \" Genre: \" + genreString + \" Link: \" + getLink();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":32}},{"path":"src/main/java/seedu/data/resources/EMagazine.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class EMagazine extends Magazine {","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String EMAGAZINE_TAG \u003d \"EM\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String link;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" public EMagazine(String title, String isbn, String creator, String type, int id, Status status, String link) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" setTag(EMAGAZINE_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setLink(link);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public String getLink() {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" return link;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public void setLink(String link) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" this.link \u003d link;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Brand: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" + getBrand() + \" Issue: \" + getIssue() + \" Link: \" + getLink();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":25}},{"path":"src/main/java/seedu/data/resources/ENewspaper.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class ENewspaper extends Newspaper{","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String ENEWSPAPER_TAG \u003d \"EN\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String link;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":" public ENewspaper(String title, String isbn, String creator, String type, int id, Status status, String link) {","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" setTag(ENEWSPAPER_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setLink(link);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" public String getLink() {","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" return link;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public void setLink(String link) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" this.link \u003d link;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN()","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" + \" Publisher: \" + getPublisher() + \" Edition: \" + getEdition() + \" Link: \" + getLink();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":25}},{"path":"src/main/java/seedu/data/resources/Magazine.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class Magazine extends Resource {","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String MAGAZINE_TAG \u003d \"M\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String brand;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" private String issue;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" public Magazine(String title, String isbn, String brand, String issue, int id, Status status) {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setTag(MAGAZINE_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setBrand(brand);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":" setIssue(issue);","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" public String getBrand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" return brand;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" public void setBrand(String brand) {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" this.brand \u003d brand;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" public String getIssue() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" return issue;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" public void setIssue(String issue) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" this.issue \u003d issue;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN() + \" Brand: \"","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" + getBrand() + \" Issue: \" + getIssue() + \" Status: \" + getStatus().name();","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":35}},{"path":"src/main/java/seedu/data/resources/Newspaper.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"public class Newspaper extends Resource {","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" public static final String NEWSPAPER_TAG \u003d \"N\";","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":" private String publisher;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":" private String edition;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":" public Newspaper(String title, String isbn, String publisher, String edition, int id, Status status) {","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":" super(title, isbn, id, status);","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":" setTag(NEWSPAPER_TAG);","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" setPublisher(publisher);","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":" setEdition(edition);","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" public String getPublisher() {","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":" return publisher;","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" public void setPublisher(String publisher) {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"JoanneJo"},"content":" this.publisher \u003d publisher;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" public String getEdition() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" return edition;","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" public void setEdition(String edition) {","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" this.edition \u003d edition;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" @Override","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":" public String toString() {","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" return \"[\" + getTag() + \"] \" + \" ID: \" + getId() + \" Title: \" + getTitle() + \" ISBN: \" + getISBN()","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" + \" Publisher: \" + getPublisher() + \" Edition: \" + getEdition() + \" Status: \" + getStatus().name();","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":3,"JoanneJo":35}},{"path":"src/main/java/seedu/data/resources/Resource.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.data.resources;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"import java.time.LocalDateTime;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"public class Resource {","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":" private String title;","lastModifiedDate":"2023-10-14"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":" private boolean isBorrowed;","lastModifiedDate":"2023-10-14"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":" private Integer copies;","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":" private String tag;","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":" private String isbn;","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":" private int id;","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":" private Status status;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":" private LocalDateTime dateReceived; //To keep track of when the resource was entered into the system","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" public Resource(String title, String isbn, int id, Status status){","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" setTitle(title);","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" setBorrowed(false);","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" setISBN(isbn);","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" setCopies(1);","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":" setTag(\"\");","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":" setId(id);","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" setStatus(status);","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" setReceivedDate();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" public String getTitle() {","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" return title;","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" public void setTitle(String title) {","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" this.title \u003d title;","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" public boolean isBorrowed() {","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" return isBorrowed;","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" public void setBorrowed(boolean borrowed) {","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" isBorrowed \u003d borrowed;","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" public Integer getCopies() {","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" return copies;","lastModifiedDate":"2023-10-14"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" public void setCopies(Integer copies) {","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" this.copies \u003d copies;","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":53,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":54,"author":{"gitId":"DavinciDelta"},"content":" public String getTag() {","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"DavinciDelta"},"content":" return tag;","lastModifiedDate":"2023-10-14"},{"lineNumber":56,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"DavinciDelta"},"content":" public void setTag(String tag) {","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"DavinciDelta"},"content":" this.tag \u003d tag;","lastModifiedDate":"2023-10-14"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" public String getISBN() {","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" return isbn;","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"DavinciDelta"},"content":" public void setISBN(String isbn) {","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"DavinciDelta"},"content":" this.isbn \u003d isbn;","lastModifiedDate":"2023-10-14"},{"lineNumber":68,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":69,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"JoanneJo"},"content":" public int getId() {","lastModifiedDate":"2023-10-31"},{"lineNumber":71,"author":{"gitId":"JoanneJo"},"content":" return id;","lastModifiedDate":"2023-10-31"},{"lineNumber":72,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":73,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"JoanneJo"},"content":" public void setId(int id) {","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"JoanneJo"},"content":" this.id \u003d id;","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":77,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":" public String getDateReceived(){","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd MMM yyyy\");","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"bnjm2000"},"content":" return dateReceived.format(formatter);","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" public LocalDateTime getDateReceivedUnparsed(){","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" return dateReceived;","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" public void setReceivedDate(){","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":" dateReceived \u003d LocalDateTime.now();","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" public void setReceivedDateCustom(LocalDateTime ldt){","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" dateReceived \u003d ldt;","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":" public String toString() {","lastModifiedDate":"2023-10-14"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":" return \"[\" + tag + \"] \" + title;","lastModifiedDate":"2023-10-14"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" public static boolean hasGenre(Resource resource, String genre){","lastModifiedDate":"2023-10-26"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":" Book bookResource;","lastModifiedDate":"2023-10-26"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":" if (resource instanceof Book) {","lastModifiedDate":"2023-10-26"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" bookResource \u003d (Book) resource;","lastModifiedDate":"2023-10-26"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":" String[] genres \u003d bookResource.getGenre();","lastModifiedDate":"2023-10-26"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" if (genres[0] \u003d\u003d null ){","lastModifiedDate":"2023-10-26"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":107,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":108,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":109,"author":{"gitId":"bnjm2000"},"content":" for (String s : genres) {","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bnjm2000"},"content":" if (s.equals(genre)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"yingx9"},"content":" return true;","lastModifiedDate":"2023-10-26"},{"lineNumber":112,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":113,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":114,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":115,"author":{"gitId":"yingx9"},"content":" return false;","lastModifiedDate":"2023-10-26"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"bnjm2000"},"content":" public void setStatus(Status status){","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"bnjm2000"},"content":" this.status \u003d status;","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"bnjm2000"},"content":" public Status getStatus(){","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"bnjm2000"},"content":" return status;","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":11,"bnjm2000":16,"JoanneJo":13,"DavinciDelta":52,"yingx9":32}},{"path":"src/main/java/seedu/exception/SysLibException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.exception;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"public class SysLibException extends Exception {","lastModifiedDate":"2023-10-15"},{"lineNumber":4,"author":{"gitId":"JoanneJo"},"content":" public SysLibException(String message) {","lastModifiedDate":"2023-10-15"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":" super(message);","lastModifiedDate":"2023-10-15"},{"lineNumber":6,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-15"}],"authorContributionMap":{"000verflow":1,"JoanneJo":6}},{"path":"src/main/java/seedu/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.parser;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.events.EventAddCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.events.EventDeleteCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.commands.events.EventListCommand;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"import seedu.data.Event;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-15"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.AddCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.DeleteCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.FindCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.ListCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.HelpCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"import seedu.commands.ExitCommand;","lastModifiedDate":"2023-10-15"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import seedu.commands.EditCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static seedu.ui.UI.SEPARATOR_LINEDIVIDER;","lastModifiedDate":"2023-10-19"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-15"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-15"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":"public class Parser {","lastModifiedDate":"2023-10-14"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" public List\u003cResource\u003e resourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" public List\u003cEvent\u003e eventList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" public HashMap\u003cString, Command\u003e commandProcessor \u003d new HashMap\u003c\u003e() {","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" {","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" put(\"list\", new ListCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" put(\"delete\", new DeleteCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" put(\"find\", new FindCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" put(\"help\", new HelpCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" put(\"exit\", new ExitCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" put(\"add\", new AddCommand());","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" put(\"edit\", new EditCommand());","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" put(\"eventadd\", new EventAddCommand());","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" put(\"eventdelete\", new EventDeleteCommand());","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" put(\"eventlist\", new EventListCommand());","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" };","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" public void process(String response) {","lastModifiedDate":"2023-10-14"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" String command \u003d response.split(\" \")[0].toLowerCase();","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" if (commandProcessor.containsKey(command)) {","lastModifiedDate":"2023-10-14"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" String statement \u003d removeFirstWord(response);","lastModifiedDate":"2023-10-14"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" try {","lastModifiedDate":"2023-10-14"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" CommandResult commandResult \u003d commandProcessor.get(command).execute(statement, this);","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" System.out.print(commandResult.feedbackToUser);","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":" } catch (IllegalArgumentException | IllegalStateException | SysLibException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" System.out.println(e.getMessage());","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" } else {","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" System.out.println(\"no commands found. Enter \\\"help\\\" for a list of commands.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-19"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":" ","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" public static String removeFirstWord(String response) {","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" int index \u003d response.indexOf(\" \");","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" if (index \u003d\u003d -1) {","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" return \"\";","lastModifiedDate":"2023-10-14"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" return response.substring(index + 1);","lastModifiedDate":"2023-10-14"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":72,"author":{"gitId":"JoanneJo"},"content":" public List\u003cResource\u003e getResourceList() {","lastModifiedDate":"2023-10-23"},{"lineNumber":73,"author":{"gitId":"JoanneJo"},"content":" return resourceList;","lastModifiedDate":"2023-10-23"},{"lineNumber":74,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":75,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" public void setResourceList(List\u003cResource\u003e resourcelist) {","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":" this.resourceList \u003d resourcelist;","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":" public List\u003cEvent\u003e getEventList() {","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":" return eventList;","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"JoanneJo"},"content":" public static String[] parseAddCommand(String statement) throws SysLibException {","lastModifiedDate":"2023-10-15"},{"lineNumber":85,"author":{"gitId":"JoanneJo"},"content":" String inputPattern \u003d \"(.+?) /tag (.)(.+)\";","lastModifiedDate":"2023-10-15"},{"lineNumber":86,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":87,"author":{"gitId":"JoanneJo"},"content":" Pattern pattern \u003d Pattern.compile(inputPattern);","lastModifiedDate":"2023-10-15"},{"lineNumber":88,"author":{"gitId":"JoanneJo"},"content":" Matcher matcher \u003d pattern.matcher(statement);","lastModifiedDate":"2023-10-15"},{"lineNumber":89,"author":{"gitId":"JoanneJo"},"content":" boolean matchFound \u003d matcher.find();","lastModifiedDate":"2023-10-15"},{"lineNumber":90,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":91,"author":{"gitId":"JoanneJo"},"content":" if (matchFound) {","lastModifiedDate":"2023-10-15"},{"lineNumber":92,"author":{"gitId":"JoanneJo"},"content":" if (matcher.group(2).equalsIgnoreCase(\"b\")) {","lastModifiedDate":"2023-10-15"},{"lineNumber":93,"author":{"gitId":"JoanneJo"},"content":" return parseAddBook(statement);","lastModifiedDate":"2023-10-15"},{"lineNumber":94,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":95,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":96,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\"","lastModifiedDate":"2023-10-30"},{"lineNumber":97,"author":{"gitId":"bnjm2000"},"content":" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":98,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":99,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":100,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":101,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":102,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":103,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":104,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":105,"author":{"gitId":"bnjm2000"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":106,"author":{"gitId":"bnjm2000"},"content":" * @param statement input of the user","lastModifiedDate":"2023-10-31"},{"lineNumber":107,"author":{"gitId":"bnjm2000"},"content":" * @return string array with arguments of the user","lastModifiedDate":"2023-10-31"},{"lineNumber":108,"author":{"gitId":"bnjm2000"},"content":" * @throws SysLibException missing arguments","lastModifiedDate":"2023-10-31"},{"lineNumber":109,"author":{"gitId":"bnjm2000"},"content":" * @throws IllegalStateException","lastModifiedDate":"2023-10-31"},{"lineNumber":110,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":111,"author":{"gitId":"JoanneJo"},"content":" public static String[] parseAddBook(String statement) throws SysLibException, IllegalStateException {","lastModifiedDate":"2023-10-15"},{"lineNumber":112,"author":{"gitId":"JoanneJo"},"content":" try {","lastModifiedDate":"2023-10-15"},{"lineNumber":113,"author":{"gitId":"JoanneJo"},"content":" String inputPattern \u003d \"/id (.+?) /t (.+?) /a (.+?) /tag (.+?) /i (.+)\";","lastModifiedDate":"2023-10-15"},{"lineNumber":114,"author":{"gitId":"JoanneJo"},"content":" String genrePattern \u003d \"(.+) /g (.+)\";","lastModifiedDate":"2023-10-15"},{"lineNumber":115,"author":{"gitId":"bnjm2000"},"content":" String statusPattern \u003d \"(.+) /s (.+)\";","lastModifiedDate":"2023-10-30"},{"lineNumber":116,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":117,"author":{"gitId":"JoanneJo"},"content":" Pattern pattern \u003d Pattern.compile(inputPattern);","lastModifiedDate":"2023-10-15"},{"lineNumber":118,"author":{"gitId":"JoanneJo"},"content":" Matcher matcher \u003d pattern.matcher(statement);","lastModifiedDate":"2023-10-15"},{"lineNumber":119,"author":{"gitId":"JoanneJo"},"content":" boolean matchFound \u003d matcher.find();","lastModifiedDate":"2023-10-15"},{"lineNumber":120,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":121,"author":{"gitId":"JoanneJo"},"content":" Pattern gPattern \u003d Pattern.compile(genrePattern);","lastModifiedDate":"2023-10-15"},{"lineNumber":122,"author":{"gitId":"JoanneJo"},"content":" Matcher gMatcher \u003d gPattern.matcher(matcher.group(5));","lastModifiedDate":"2023-10-15"},{"lineNumber":123,"author":{"gitId":"JoanneJo"},"content":" boolean gMatchFound \u003d gMatcher.find();","lastModifiedDate":"2023-10-15"},{"lineNumber":124,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":125,"author":{"gitId":"bnjm2000"},"content":" Pattern sPattern \u003d Pattern.compile(statusPattern);","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"bnjm2000"},"content":" Matcher sMatcher \u003d sPattern.matcher(matcher.group(5));","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"bnjm2000"},"content":" boolean sMatchFound \u003d sMatcher.find();","lastModifiedDate":"2023-10-30"},{"lineNumber":128,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":129,"author":{"gitId":"bnjm2000"},"content":" String[] args \u003d new String[7]; // Increase the array size to accommodate status","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":131,"author":{"gitId":"JoanneJo"},"content":" if (matchFound) {","lastModifiedDate":"2023-10-15"},{"lineNumber":132,"author":{"gitId":"JoanneJo"},"content":" args[0] \u003d matcher.group(1).trim(); // id","lastModifiedDate":"2023-10-15"},{"lineNumber":133,"author":{"gitId":"JoanneJo"},"content":" args[1] \u003d matcher.group(2).trim(); // title","lastModifiedDate":"2023-10-15"},{"lineNumber":134,"author":{"gitId":"JoanneJo"},"content":" args[2] \u003d matcher.group(3).trim(); // author","lastModifiedDate":"2023-10-15"},{"lineNumber":135,"author":{"gitId":"JoanneJo"},"content":" args[3] \u003d matcher.group(4).trim(); // tag","lastModifiedDate":"2023-10-15"},{"lineNumber":136,"author":{"gitId":"JoanneJo"},"content":" if (gMatchFound) {","lastModifiedDate":"2023-10-15"},{"lineNumber":137,"author":{"gitId":"JoanneJo"},"content":" args[4] \u003d gMatcher.group(1).trim(); // isbn","lastModifiedDate":"2023-10-15"},{"lineNumber":138,"author":{"gitId":"bnjm2000"},"content":" if (sMatchFound){","lastModifiedDate":"2023-10-30"},{"lineNumber":139,"author":{"gitId":"bnjm2000"},"content":" args[5] \u003d gMatcher.group(2).split(\"/s\")[0].trim(); // genre","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"bnjm2000"},"content":" args[6] \u003d sMatcher.group(2).trim(); // status","lastModifiedDate":"2023-10-31"},{"lineNumber":141,"author":{"gitId":"bnjm2000"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"JoanneJo"},"content":" args[5] \u003d gMatcher.group(2).trim(); // genre","lastModifiedDate":"2023-10-15"},{"lineNumber":143,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":144,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":145,"author":{"gitId":"bnjm2000"},"content":" args[5] \u003d null; //genre","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"bnjm2000"},"content":" if (sMatchFound) {","lastModifiedDate":"2023-10-30"},{"lineNumber":147,"author":{"gitId":"bnjm2000"},"content":" args[4] \u003d sMatcher.group(1).trim(); // isbn","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"bnjm2000"},"content":" args[6] \u003d sMatcher.group(2).trim(); // status","lastModifiedDate":"2023-10-30"},{"lineNumber":149,"author":{"gitId":"bnjm2000"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":150,"author":{"gitId":"bnjm2000"},"content":" args[4] \u003d matcher.group(5).trim(); // isbn","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"bnjm2000"},"content":" args[6] \u003d \"Available\";","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":154,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"JoanneJo"},"content":" if (args[0].isEmpty() || args[1].isEmpty() || args[2].isEmpty() || args[3].isEmpty()","lastModifiedDate":"2023-10-15"},{"lineNumber":156,"author":{"gitId":"JoanneJo"},"content":" || args[4].isEmpty()) {","lastModifiedDate":"2023-10-15"},{"lineNumber":157,"author":{"gitId":"bnjm2000"},"content":" throw new SysLibException(\"Please state the id, title, author, tag, and ISBN.\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":158,"author":{"gitId":"yingx9"},"content":" SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-19"},{"lineNumber":159,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":160,"author":{"gitId":"JoanneJo"},"content":" } else {","lastModifiedDate":"2023-10-15"},{"lineNumber":161,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":162,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\"","lastModifiedDate":"2023-10-31"},{"lineNumber":163,"author":{"gitId":"bnjm2000"},"content":" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":165,"author":{"gitId":"JoanneJo"},"content":" return args;","lastModifiedDate":"2023-10-15"},{"lineNumber":166,"author":{"gitId":"JoanneJo"},"content":" } catch (IllegalStateException | SysLibException e) {","lastModifiedDate":"2023-10-15"},{"lineNumber":167,"author":{"gitId":"JoanneJo"},"content":" throw new SysLibException(\"Please use the format \" +","lastModifiedDate":"2023-10-15"},{"lineNumber":168,"author":{"gitId":"bnjm2000"},"content":" \"\u0027add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS]\u0027.\" + SEPARATOR_LINEDIVIDER);","lastModifiedDate":"2023-10-31"},{"lineNumber":169,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":170,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":171,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":172,"author":{"gitId":"000verflow"},"content":" public Matcher parseFindCommand(String command) throws SysLibException{","lastModifiedDate":"2023-10-15"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":" // Define a regular expression pattern to match optional flags and their values","lastModifiedDate":"2023-10-15"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":" Pattern pattern \u003d Pattern.compile(\"/(t|a|i|id)\\\\s+([^/]+)\");","lastModifiedDate":"2023-10-15"},{"lineNumber":175,"author":{"gitId":"000verflow"},"content":" return pattern.matcher(command);","lastModifiedDate":"2023-10-15"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":177,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"bnjm2000"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"bnjm2000"},"content":" * @param statusString input string status","lastModifiedDate":"2023-10-31"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":" * @return Status object","lastModifiedDate":"2023-10-31"},{"lineNumber":181,"author":{"gitId":"bnjm2000"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":" public static Status getStatusFromString(String statusString) {","lastModifiedDate":"2023-10-30"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":" if (statusString !\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":" statusString \u003d statusString.toLowerCase().trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":" if (statusString.equalsIgnoreCase(\"borrowed\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"bnjm2000"},"content":" return Status.BORROWED;","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":" } else if (statusString.equalsIgnoreCase(\"lost\")) {","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":" return Status.LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"bnjm2000"},"content":" // Default to Available if the status is not provided or unrecognized","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"bnjm2000"},"content":" return Status.AVAILABLE;","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":20,"bnjm2000":53,"JoanneJo":67,"DavinciDelta":11,"yingx9":43}},{"path":"src/main/java/seedu/storage/Storage.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.storage;","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import java.io.File;","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import java.time.LocalDateTime;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import java.util.List;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EBook;","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.EMagazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.ENewspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"import seedu.data.Event;","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"public class Storage {","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" public static final int FIRST_INDEX \u003d 0;","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" public static final int SECOND_INDEX \u003d 1;","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" public static final int THIRD_INDEX \u003d 2;","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" public static final int FOURTH_INDEX \u003d 3;","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" public static final int FIFTH_INDEX \u003d 4;","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":" public static final int SIXTH_INDEX \u003d 5;","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" public static final int SEVENTH_INDEX \u003d 6;","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" public static final int EIGHTH_INDEX \u003d 7;","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":" public static final int NINTH_INDEX \u003d 8;","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" public static final int TENTH_INDEX \u003d 9;","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" public static final int ELEVENTH_INDEX \u003d 10;","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":" public static final int TWELFTH_INDEX \u003d 11;","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" protected File dataFile;","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":" protected String filePath;","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":" protected Parser parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" public Storage(String filePath, Parser parser) {","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":" this.filePath \u003d filePath;","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" this.dataFile \u003d new File(filePath);","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" this.parser \u003d parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" public List\u003cResource\u003e load() throws SysLibException {","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" List\u003cResource\u003e resources \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" if (this.dataFile.createNewFile()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":" System.out.println(\"Data file not found @ \" + this.filePath +","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" \"\\nCreating new data file @ \" + this.filePath);","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" Scanner dataScanner \u003d new Scanner(dataFile);","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" while (dataScanner.hasNext()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" String dataLine \u003d dataScanner.nextLine();","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":" String[] splitLineArguments \u003d dataLine.split(\" \\\\| \");","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":" if (splitLineArguments[FIRST_INDEX].equals(\"R\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":" String title \u003d splitLineArguments[SECOND_INDEX].trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":" boolean isBorrowed \u003d Boolean.parseBoolean(splitLineArguments[THIRD_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" String isbn \u003d splitLineArguments[FOURTH_INDEX].trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" int copies \u003d Integer.parseInt(splitLineArguments[FIFTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":" String tag \u003d splitLineArguments[SIXTH_INDEX].trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":" int id \u003d Integer.parseInt(splitLineArguments[SEVENTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":" Status status \u003d Status.valueOf(splitLineArguments[EIGHTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" LocalDateTime ldt \u003d LocalDateTime.parse(splitLineArguments[NINTH_INDEX].trim());","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" switch(tag){","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" case \"B\":","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":" String author \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":" String[] genres \u003d splitLineArguments[ELEVENTH_INDEX].split(\",\");","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" Book bookToAdd \u003d new Book(title, isbn, author, genres, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" bookToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" bookToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":" bookToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" resources.add(bookToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":" case \"EB\":","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":" String eauthor \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" String[] egenres \u003d splitLineArguments[ELEVENTH_INDEX].split(\",\");","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" String blink \u003d splitLineArguments[11];","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"JoanneJo"},"content":" EBook ebookToAdd \u003d new EBook(title, isbn, eauthor, egenres, id, status, blink);","lastModifiedDate":"2023-11-03"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":" ebookToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":" ebookToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":" ebookToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":" resources.add(ebookToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" case \"N\":","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":" String publisher \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":" String edition \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"000verflow"},"content":" Newspaper newspaperToAdd \u003d new Newspaper(title, isbn, publisher, edition, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" newspaperToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"000verflow"},"content":" newspaperToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":" newspaperToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" resources.add(newspaperToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":" case \"EN\":","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":" String epublisher \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" String eedition \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":105,"author":{"gitId":"000verflow"},"content":" String nlink \u003d splitLineArguments[11];","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"JoanneJo"},"content":" ENewspaper enewspaperToAdd \u003d new ENewspaper(title, isbn, epublisher, eedition,","lastModifiedDate":"2023-11-03"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":" id, status, nlink);","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":" enewspaperToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" enewspaperToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":" enewspaperToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":" resources.add(enewspaperToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":114,"author":{"gitId":"000verflow"},"content":" case \"M\":","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"000verflow"},"content":" String brand \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"000verflow"},"content":" String issue \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"000verflow"},"content":" Magazine magazineToAdd \u003d new Magazine(title, isbn, brand, issue, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"000verflow"},"content":" magazineToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"000verflow"},"content":" magazineToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"000verflow"},"content":" magazineToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"000verflow"},"content":" resources.add(magazineToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":124,"author":{"gitId":"000verflow"},"content":" case \"EM\":","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"000verflow"},"content":" String ebrand \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"000verflow"},"content":" String eissue \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":127,"author":{"gitId":"000verflow"},"content":" String mlink \u003d splitLineArguments[TWELFTH_INDEX];","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"JoanneJo"},"content":" EMagazine emagazineToAdd \u003d new EMagazine(title, isbn, ebrand, eissue, id,","lastModifiedDate":"2023-11-03"},{"lineNumber":129,"author":{"gitId":"000verflow"},"content":" status, mlink);","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"000verflow"},"content":" emagazineToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"000verflow"},"content":" emagazineToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"000verflow"},"content":" emagazineToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"000verflow"},"content":" resources.add(emagazineToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"000verflow"},"content":" case \"CD\":","lastModifiedDate":"2023-11-02"},{"lineNumber":137,"author":{"gitId":"000verflow"},"content":" String creator \u003d splitLineArguments[TENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"000verflow"},"content":" String type \u003d splitLineArguments[ELEVENTH_INDEX];","lastModifiedDate":"2023-11-04"},{"lineNumber":139,"author":{"gitId":"000verflow"},"content":" CD cdToAdd \u003d new CD(title, isbn, creator, type, id, status);","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"000verflow"},"content":" cdToAdd.setCopies(copies);","lastModifiedDate":"2023-11-02"},{"lineNumber":141,"author":{"gitId":"000verflow"},"content":" cdToAdd.setBorrowed(isBorrowed);","lastModifiedDate":"2023-11-02"},{"lineNumber":142,"author":{"gitId":"000verflow"},"content":" cdToAdd.setReceivedDateCustom(ldt);","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"000verflow"},"content":" resources.add(cdToAdd);","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":145,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"000verflow"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown resource type found, data corrupted.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"000verflow"},"content":" }else if (splitLineArguments[FIRST_INDEX].equals(\"E\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":151,"author":{"gitId":"000verflow"},"content":" // String name \u003d splitLineArguments[SECOND_INDEX];","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"000verflow"},"content":" // String description \u003d splitLineArguments[THIRD_INDEX];","lastModifiedDate":"2023-11-02"},{"lineNumber":153,"author":{"gitId":"000verflow"},"content":" // Date eventldt \u003d parseDate(splitLineArguments[FOURTH_INDEX]);","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"000verflow"},"content":" // Event newEventToAdd \u003d new Event(name, eventldt, description);","lastModifiedDate":"2023-11-02"},{"lineNumber":155,"author":{"gitId":"000verflow"},"content":" System.out.println(\"Event loading not implemented yet.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":156,"author":{"gitId":"000verflow"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":157,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown data type found, data corrupted.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":158,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":159,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":160,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"000verflow"},"content":" } catch (IOException IOEx) {","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unable to create storage file. Please try to run with admin permissions.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"000verflow"},"content":" return resources;","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":167,"author":{"gitId":"000verflow"},"content":" public void save() throws SysLibException {","lastModifiedDate":"2023-11-02"},{"lineNumber":168,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":169,"author":{"gitId":"000verflow"},"content":" FileWriter fw \u003d new FileWriter(this.filePath);","lastModifiedDate":"2023-11-02"},{"lineNumber":170,"author":{"gitId":"000verflow"},"content":" List\u003cResource\u003e resourcelist \u003d parser.getResourceList();","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"000verflow"},"content":" List\u003cEvent\u003e eventlist \u003d parser.getEventList();","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"000verflow"},"content":" for (Resource resourceToSave : resourcelist){","lastModifiedDate":"2023-11-02"},{"lineNumber":173,"author":{"gitId":"000verflow"},"content":" String resourceSaveFormat \u003d \"\";","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"000verflow"},"content":" switch (resourceToSave.getTag()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"000verflow"},"content":" case \"B\": // Book","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"000verflow"},"content":" Book book \u003d (Book) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":178,"author":{"gitId":"000verflow"},"content":" book.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":179,"author":{"gitId":"000verflow"},"content":" book.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":180,"author":{"gitId":"000verflow"},"content":" book.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":181,"author":{"gitId":"000verflow"},"content":" book.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":182,"author":{"gitId":"000verflow"},"content":" book.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"000verflow"},"content":" book.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":184,"author":{"gitId":"000verflow"},"content":" book.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":185,"author":{"gitId":"000verflow"},"content":" book.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":186,"author":{"gitId":"000verflow"},"content":" book.getAuthor(),","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"000verflow"},"content":" String.join(\",\", book.getGenre()));","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":189,"author":{"gitId":"000verflow"},"content":" case \"EB\": // eBook","lastModifiedDate":"2023-11-02"},{"lineNumber":190,"author":{"gitId":"JoanneJo"},"content":" EBook ebook \u003d (EBook) resourceToSave;","lastModifiedDate":"2023-11-03"},{"lineNumber":191,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":192,"author":{"gitId":"000verflow"},"content":" ebook.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":193,"author":{"gitId":"000verflow"},"content":" ebook.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":194,"author":{"gitId":"000verflow"},"content":" ebook.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":195,"author":{"gitId":"000verflow"},"content":" ebook.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":196,"author":{"gitId":"000verflow"},"content":" ebook.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":197,"author":{"gitId":"000verflow"},"content":" ebook.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":198,"author":{"gitId":"000verflow"},"content":" ebook.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":199,"author":{"gitId":"000verflow"},"content":" ebook.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":200,"author":{"gitId":"000verflow"},"content":" ebook.getAuthor(),","lastModifiedDate":"2023-11-02"},{"lineNumber":201,"author":{"gitId":"000verflow"},"content":" String.join(\",\", ebook.getGenre()),","lastModifiedDate":"2023-11-02"},{"lineNumber":202,"author":{"gitId":"000verflow"},"content":" ebook.getLink());","lastModifiedDate":"2023-11-02"},{"lineNumber":203,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":204,"author":{"gitId":"000verflow"},"content":" case \"CD\": // CD","lastModifiedDate":"2023-11-02"},{"lineNumber":205,"author":{"gitId":"000verflow"},"content":" CD cd \u003d (CD) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":206,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":207,"author":{"gitId":"000verflow"},"content":" cd.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":208,"author":{"gitId":"000verflow"},"content":" cd.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":209,"author":{"gitId":"000verflow"},"content":" cd.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":210,"author":{"gitId":"000verflow"},"content":" cd.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":211,"author":{"gitId":"000verflow"},"content":" cd.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":212,"author":{"gitId":"000verflow"},"content":" cd.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":213,"author":{"gitId":"000verflow"},"content":" cd.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":214,"author":{"gitId":"000verflow"},"content":" cd.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":215,"author":{"gitId":"000verflow"},"content":" cd.getCreator(),","lastModifiedDate":"2023-11-02"},{"lineNumber":216,"author":{"gitId":"000verflow"},"content":" cd.getType());","lastModifiedDate":"2023-11-02"},{"lineNumber":217,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":218,"author":{"gitId":"000verflow"},"content":" case \"M\": // Magazine","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"000verflow"},"content":" Magazine magazine \u003d (Magazine) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":220,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":221,"author":{"gitId":"000verflow"},"content":" magazine.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":222,"author":{"gitId":"000verflow"},"content":" magazine.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":223,"author":{"gitId":"000verflow"},"content":" magazine.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":224,"author":{"gitId":"000verflow"},"content":" magazine.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":225,"author":{"gitId":"000verflow"},"content":" magazine.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":226,"author":{"gitId":"000verflow"},"content":" magazine.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":227,"author":{"gitId":"000verflow"},"content":" magazine.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":228,"author":{"gitId":"000verflow"},"content":" magazine.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":229,"author":{"gitId":"000verflow"},"content":" magazine.getBrand(),","lastModifiedDate":"2023-11-02"},{"lineNumber":230,"author":{"gitId":"000verflow"},"content":" magazine.getIssue());","lastModifiedDate":"2023-11-02"},{"lineNumber":231,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":232,"author":{"gitId":"000verflow"},"content":" case \"EM\": // eMagazine","lastModifiedDate":"2023-11-02"},{"lineNumber":233,"author":{"gitId":"JoanneJo"},"content":" EMagazine emagazine \u003d (EMagazine) resourceToSave;","lastModifiedDate":"2023-11-03"},{"lineNumber":234,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":235,"author":{"gitId":"000verflow"},"content":" emagazine.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":236,"author":{"gitId":"000verflow"},"content":" emagazine.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":237,"author":{"gitId":"000verflow"},"content":" emagazine.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":238,"author":{"gitId":"000verflow"},"content":" emagazine.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":239,"author":{"gitId":"000verflow"},"content":" emagazine.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":240,"author":{"gitId":"000verflow"},"content":" emagazine.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":241,"author":{"gitId":"000verflow"},"content":" emagazine.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":242,"author":{"gitId":"000verflow"},"content":" emagazine.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":243,"author":{"gitId":"000verflow"},"content":" emagazine.getLink());","lastModifiedDate":"2023-11-02"},{"lineNumber":244,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":245,"author":{"gitId":"000verflow"},"content":" case \"N\": // Newspaper","lastModifiedDate":"2023-11-02"},{"lineNumber":246,"author":{"gitId":"000verflow"},"content":" Newspaper newspaper \u003d (Newspaper) resourceToSave;","lastModifiedDate":"2023-11-02"},{"lineNumber":247,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":248,"author":{"gitId":"000verflow"},"content":" newspaper.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":249,"author":{"gitId":"000verflow"},"content":" newspaper.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":250,"author":{"gitId":"000verflow"},"content":" newspaper.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":251,"author":{"gitId":"000verflow"},"content":" newspaper.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":252,"author":{"gitId":"000verflow"},"content":" newspaper.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":253,"author":{"gitId":"000verflow"},"content":" newspaper.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":254,"author":{"gitId":"000verflow"},"content":" newspaper.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":255,"author":{"gitId":"000verflow"},"content":" newspaper.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":256,"author":{"gitId":"000verflow"},"content":" newspaper.getPublisher(),","lastModifiedDate":"2023-11-02"},{"lineNumber":257,"author":{"gitId":"000verflow"},"content":" newspaper.getEdition());","lastModifiedDate":"2023-11-02"},{"lineNumber":258,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":259,"author":{"gitId":"000verflow"},"content":" case \"EN\": // eNewspaper","lastModifiedDate":"2023-11-02"},{"lineNumber":260,"author":{"gitId":"JoanneJo"},"content":" ENewspaper enewspaper \u003d (ENewspaper) resourceToSave;","lastModifiedDate":"2023-11-03"},{"lineNumber":261,"author":{"gitId":"000verflow"},"content":" resourceSaveFormat \u003d String.format(\"R | %s | %b | %s | %d | %s | %s | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":262,"author":{"gitId":"000verflow"},"content":" enewspaper.getTitle(),","lastModifiedDate":"2023-11-02"},{"lineNumber":263,"author":{"gitId":"000verflow"},"content":" enewspaper.isBorrowed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":264,"author":{"gitId":"000verflow"},"content":" enewspaper.getISBN(),","lastModifiedDate":"2023-11-02"},{"lineNumber":265,"author":{"gitId":"000verflow"},"content":" enewspaper.getCopies(),","lastModifiedDate":"2023-11-02"},{"lineNumber":266,"author":{"gitId":"000verflow"},"content":" enewspaper.getTag(),","lastModifiedDate":"2023-11-02"},{"lineNumber":267,"author":{"gitId":"000verflow"},"content":" enewspaper.getId(),","lastModifiedDate":"2023-11-02"},{"lineNumber":268,"author":{"gitId":"000verflow"},"content":" enewspaper.getStatus(),","lastModifiedDate":"2023-11-02"},{"lineNumber":269,"author":{"gitId":"000verflow"},"content":" enewspaper.getDateReceivedUnparsed(),","lastModifiedDate":"2023-11-02"},{"lineNumber":270,"author":{"gitId":"000verflow"},"content":" enewspaper.getLink());","lastModifiedDate":"2023-11-02"},{"lineNumber":271,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":272,"author":{"gitId":"000verflow"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":273,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unknown data type in list. Can\u0027t store it in file.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":274,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":275,"author":{"gitId":"000verflow"},"content":" fw.write(resourceSaveFormat);","lastModifiedDate":"2023-11-02"},{"lineNumber":276,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":277,"author":{"gitId":"000verflow"},"content":" for (Event eventToSave : eventlist){","lastModifiedDate":"2023-11-02"},{"lineNumber":278,"author":{"gitId":"000verflow"},"content":" String eventSaveFormat \u003d String.format(\"E | %s | %s | %s%n\",","lastModifiedDate":"2023-11-02"},{"lineNumber":279,"author":{"gitId":"000verflow"},"content":" eventToSave.getName(),","lastModifiedDate":"2023-11-02"},{"lineNumber":280,"author":{"gitId":"000verflow"},"content":" eventToSave.getDescription(),","lastModifiedDate":"2023-11-02"},{"lineNumber":281,"author":{"gitId":"000verflow"},"content":" eventToSave.getDate());","lastModifiedDate":"2023-11-02"},{"lineNumber":282,"author":{"gitId":"000verflow"},"content":" fw.write(eventSaveFormat);","lastModifiedDate":"2023-11-02"},{"lineNumber":283,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":284,"author":{"gitId":"000verflow"},"content":" fw.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":285,"author":{"gitId":"000verflow"},"content":" } catch (IOException IOex){","lastModifiedDate":"2023-11-02"},{"lineNumber":286,"author":{"gitId":"000verflow"},"content":" throw new SysLibException(\"Unable to save to find @ ./storage.txt\");","lastModifiedDate":"2023-11-02"},{"lineNumber":287,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":288,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":289,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":290,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":291,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"000verflow":285,"JoanneJo":6}},{"path":"src/main/java/seedu/syslib/Syslib.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.syslib;","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.storage.Storage;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.ui.UI;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import java.util.List;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"public class Syslib {","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":" * Main entry-point for the java.duke.Duke application.","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":" public static final String FILEPATH \u003d \".\\\\storage.txt\";","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":" private static UI ui;","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":" private static Parser parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":" private static Storage storage;","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":" public Syslib(String filePath) {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" ui \u003d new UI();","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" parser \u003d new Parser();","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" storage \u003d new Storage(filePath, parser);","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" try{","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" List\u003cResource\u003e resourceListLoad \u003d storage.load();","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" if (!resourceListLoad.isEmpty()){","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" ui.showLoadMessage(filePath, resourceListLoad);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" parser.setResourceList(resourceListLoad);","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" } catch (SysLibException SysLibEx){","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" System.out.println(SysLibEx);","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":" public static void main(String[] args) {","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" new Syslib(FILEPATH).run();","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":" public void run() {","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" ui.showWelcomeMessage();","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":" while (true) {","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" String response \u003d ui.readCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" parser.process(response);","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":" storage.save();","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":" } catch (SysLibException SysLibEx){","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" System.out.println(SysLibEx);","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" if (response.equalsIgnoreCase(\"exit\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"000verflow":58}},{"path":"src/main/java/seedu/ui/UI.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.ui;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import java.util.List;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-14"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"public class UI {","lastModifiedDate":"2023-10-14"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":" public static final String LINESEPARATOR \u003d System.lineSeparator();","lastModifiedDate":"2023-10-26"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":" public static final String LINEDIVIDER \u003d \"____________________________________________________________\";","lastModifiedDate":"2023-10-19"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":" public static final String SEPARATOR_LINEDIVIDER \u003d LINESEPARATOR + LINEDIVIDER;","lastModifiedDate":"2023-10-26"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":" protected static String logo \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":" \" ____ _ _ _ ____ _ ___ \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":" \"/ ___| _ _ ___| | (_) |__ / ___| | |_ _|\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":" \"\\\\___ \\\\| | | / __| | | | \u0027_ \\\\ | | | | | | \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":" \" ___) | |_| \\\\__ \\\\ |___| | |_) | | |___| |___ | | \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":" \"|____/ \\\\__, |___/_____|_|_.__/ \\\\____|_____|___|\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":" \" |___/ \";","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-19"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":" protected Scanner myScanner;","lastModifiedDate":"2023-10-14"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":" public UI(){","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":" this.myScanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" public void showWelcomeMessage(){","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" System.out.println(logo);","lastModifiedDate":"2023-10-14"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"What would you like to do?\");","lastModifiedDate":"2023-10-28"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" public void showExitMessage(){","lastModifiedDate":"2023-10-14"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"Bye, hope to see you again soon!\");","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" public void showHelpMessage(){","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"Commands available:\");","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"add: adds a new resource to the library inventory.\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. add /id ID /t TITLE /a AUTHOR /tag TAG /i ISBN [/g GENRE /s STATUS])\");","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"delete: deletes the resource with the specified ID from the library inventory. \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. delete /id 123456789)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"list: list all resources OR filter by certain tags or genre.\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" \"(e.g. list /tag B /g Fiction\");","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"edit: Edit a listing by entering its isbn to update its details. \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"eventadd: Add an event to the event list \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])\");","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"eventlist: List out all the event list (e.g. eventlist)\");","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":" System.out.println(\"eventdelete: Delete an event in the event list based on the index \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventdelete /i INDEX)\");","lastModifiedDate":"2023-10-31"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"exit: displays a farewell message and exits the program (e.g. exit)\");","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" System.out.println(\"For more information, please refer to our user guide at:\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" \"https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html\");","lastModifiedDate":"2023-10-14"},{"lineNumber":56,"author":{"gitId":"bnjm2000"},"content":" showLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":" public void showError(Exception e){","lastModifiedDate":"2023-10-14"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":" System.out.println(e);","lastModifiedDate":"2023-10-14"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" public String readCommand(){","lastModifiedDate":"2023-10-14"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" System.out.print(\"\u003e \");","lastModifiedDate":"2023-10-14"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":" return myScanner.nextLine();","lastModifiedDate":"2023-10-14"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" public void showLoadMessage(String filepath, List\u003cResource\u003e resourcelist){","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":" showLine();","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" System.out.println(\"Storage file found @ \" + filepath);","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" System.out.printf(\"Loaded %d listings!%n\", resourcelist.size());","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" public void showLine(){","lastModifiedDate":"2023-10-14"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" System.out.println(LINEDIVIDER);","lastModifiedDate":"2023-10-14"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-14"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-10-14"}],"authorContributionMap":{"000verflow":49,"bnjm2000":18,"DavinciDelta":5,"yingx9":5}},{"path":"src/test/java/seedu/DukeTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu;","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"class DukeTest {","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":" public void sampleTest() {","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"000verflow":1,"-":11}},{"path":"src/test/java/seedu/commands/AddCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"JoanneJo"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-23"},{"lineNumber":2,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":3,"author":{"gitId":"JoanneJo"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-23"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"JoanneJo"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-23"},{"lineNumber":8,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":9,"author":{"gitId":"JoanneJo"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-23"},{"lineNumber":10,"author":{"gitId":"JoanneJo"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-23"},{"lineNumber":11,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":12,"author":{"gitId":"JoanneJo"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-23"},{"lineNumber":13,"author":{"gitId":"JoanneJo"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-23"},{"lineNumber":14,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":15,"author":{"gitId":"JoanneJo"},"content":"public class AddCommandTest {","lastModifiedDate":"2023-10-23"},{"lineNumber":16,"author":{"gitId":"JoanneJo"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-23"},{"lineNumber":17,"author":{"gitId":"JoanneJo"},"content":" private final AddCommand addCommand \u003d new AddCommand();","lastModifiedDate":"2023-10-23"},{"lineNumber":18,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":19,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":20,"author":{"gitId":"JoanneJo"},"content":" public void addCommandValidData() throws SysLibException {","lastModifiedDate":"2023-10-23"},{"lineNumber":21,"author":{"gitId":"JoanneJo"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" \"/g Non-Fiction, Biography /s lost\", parser);","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":24,"author":{"gitId":"JoanneJo"},"content":" Book newBook \u003d (Book) parser.getResourceList().get(0);","lastModifiedDate":"2023-10-23"},{"lineNumber":25,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":26,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getId(), 123456789);","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getTitle(), \"The Minds of Billy Milligan\");","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getAuthor(), \"Daniel Keyes\");","lastModifiedDate":"2023-10-23"},{"lineNumber":29,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getTag(), \"B\");","lastModifiedDate":"2023-10-23"},{"lineNumber":30,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getISBN(), \"987654321\");","lastModifiedDate":"2023-10-23"},{"lineNumber":31,"author":{"gitId":"JoanneJo"},"content":" assertEquals(newBook.getGenreString(), \"Non-Fiction, Biography\");","lastModifiedDate":"2023-10-23"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" assertEquals(newBook.getStatus(), Status.LOST);","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":34,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":35,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":36,"author":{"gitId":"JoanneJo"},"content":" public void addCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"JoanneJo"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-23"},{"lineNumber":38,"author":{"gitId":"JoanneJo"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-23"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":40,"author":{"gitId":"JoanneJo"},"content":" \"/g Non-Fiction, Biography\", parser);","lastModifiedDate":"2023-10-23"},{"lineNumber":41,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":42,"author":{"gitId":"JoanneJo"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-23"},{"lineNumber":43,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":44,"author":{"gitId":"JoanneJo"},"content":" String expectedOutput \u003d \"This book is added: The Minds of Billy Milligan\" + System.lineSeparator() +","lastModifiedDate":"2023-10-23"},{"lineNumber":45,"author":{"gitId":"JoanneJo"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-23"},{"lineNumber":46,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":47,"author":{"gitId":"JoanneJo"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-23"},{"lineNumber":48,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":50,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":51,"author":{"gitId":"JoanneJo"},"content":" public void addCommandInvalidId() {","lastModifiedDate":"2023-10-23"},{"lineNumber":52,"author":{"gitId":"JoanneJo"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eaddCommand.execute(\"/id abcd \" +","lastModifiedDate":"2023-10-23"},{"lineNumber":53,"author":{"gitId":"JoanneJo"},"content":" \"/t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321\", parser));","lastModifiedDate":"2023-10-23"},{"lineNumber":54,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":55,"author":{"gitId":"JoanneJo"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":56,"author":{"gitId":"JoanneJo"},"content":" @Test","lastModifiedDate":"2023-10-23"},{"lineNumber":57,"author":{"gitId":"JoanneJo"},"content":" public void addCommandInsufficientData() {","lastModifiedDate":"2023-10-23"},{"lineNumber":58,"author":{"gitId":"JoanneJo"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eaddCommand.execute(\"/id \", parser));","lastModifiedDate":"2023-10-23"},{"lineNumber":59,"author":{"gitId":"JoanneJo"},"content":" }","lastModifiedDate":"2023-10-23"},{"lineNumber":60,"author":{"gitId":"JoanneJo"},"content":"}","lastModifiedDate":"2023-10-23"}],"authorContributionMap":{"000verflow":2,"bnjm2000":3,"JoanneJo":55}},{"path":"src/test/java/seedu/commands/DeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"import static seedu.util.TestUtil.getCurrentDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":"public class DeleteCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" private final AddCommand addCommand \u003d new AddCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" private final DeleteCommand deleteCommand \u003d new DeleteCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public void deleteCommandValidData() throws SysLibException {","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" , parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" deleteCommand.execute(\"/id 123456789\", parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(parser.resourceList.size(), 0);","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" public void deleteCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" addCommand.execute(\"/id 123456789 /t The Minds of Billy Milligan /a Daniel Keyes /tag B /i 987654321 \"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" , parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" deleteCommand.execute(\"/id 123456789\", parser);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-17"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"Looking for ID: 123456789...\" + System.lineSeparator()+","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" \"This resource is removed: \" + System.lineSeparator() +","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" \"[B] ID: 123456789 Title: The Minds of Billy Milligan ISBN: 987654321 Author: Daniel Keyes Genre: - \" +","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" \"Status: AVAILABLE \" + \"Received Date: \" + getCurrentDate() + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-17"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" public void deleteCommandInvalidId() {","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e deleteCommand.execute(\"\", parser));","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":46,"yingx9":2}},{"path":"src/test/java/seedu/commands/EditCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.BeforeAll;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"yingx9"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import seedu.util.TestUtil;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.EditCommand.RESOURCE_NOT_FOUND;","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.EditCommand.EDIT_SUCCESS;","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import static seedu.common.FormatMessages.formatLastLineDivider;","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"public class EditCommandTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":" private static List\u003cResource\u003e testResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":" private Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" private List\u003cResource\u003e emptyResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" private TestUtil testUtil \u003d new TestUtil();","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" private Command editCommand \u003d new EditCommand();","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" @BeforeAll","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" public static void setup() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":" testResourceList \u003d TestUtil.fillTestList();","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" public void testEditResourceNotFound() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(editCommand, \"/i 123 /t NEWTITLE\", emptyResourceList);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d RESOURCE_NOT_FOUND;","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" public void testNoArgumentGiven() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" assertThrows(SysLibException.class, ()-\u003eeditCommand.execute(\"/i 123\", parser));","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" public void testNotBookBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" assertThrows(SysLibException.class, ()-\u003eeditCommand.execute(\"/i 1 /g Horror\", parser));","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" public void testEditTitleBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":" executeEditSuccessBehavior(\"/i 2 /t NEWTITLE\");","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" public void testEditAuthorBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" executeEditSuccessBehavior(\"/i 2 /a NEWAUTHOR\");","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" public void testEditGenreBehavior() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" executeEditSuccessBehavior(\"/i 2 /g Horror, Action, Fantasy\");","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":" private void executeEditSuccessBehavior(String argument) throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(editCommand, argument, testResourceList);","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d EDIT_SUCCESS + formatLastLineDivider((testResourceList.get(1)).toString());","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"000verflow":2,"yingx9":71}},{"path":"src/test/java/seedu/commands/ExitCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"class ExitCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":" void execute() {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" ExitCommand exitCommand \u003d new ExitCommand();","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":" exitCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Bye, hope to see you again soon!\" + System.lineSeparator()+","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bnjm2000":28}},{"path":"src/test/java/seedu/commands/FindCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"000verflow"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-17"},{"lineNumber":2,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":3,"author":{"gitId":"000verflow"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-17"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-17"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-17"},{"lineNumber":6,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Magazine;","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Newspaper;","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.CD;","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"000verflow"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":13,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":14,"author":{"gitId":"000verflow"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":15,"author":{"gitId":"000verflow"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-17"},{"lineNumber":16,"author":{"gitId":"000verflow"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-17"},{"lineNumber":17,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":18,"author":{"gitId":"000verflow"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-17"},{"lineNumber":19,"author":{"gitId":"000verflow"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-17"},{"lineNumber":20,"author":{"gitId":"000verflow"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-17"},{"lineNumber":21,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"000verflow"},"content":"public class FindCommandTest {","lastModifiedDate":"2023-10-17"},{"lineNumber":23,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":24,"author":{"gitId":"000verflow"},"content":" private FindCommand findCommand;","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"000verflow"},"content":" private Parser parser;","lastModifiedDate":"2023-10-17"},{"lineNumber":26,"author":{"gitId":"000verflow"},"content":" private final ByteArrayOutputStream outContent \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"000verflow"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"000verflow"},"content":" @BeforeEach","lastModifiedDate":"2023-10-17"},{"lineNumber":30,"author":{"gitId":"000verflow"},"content":" void setUp() {","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"000verflow"},"content":" findCommand \u003d new FindCommand();","lastModifiedDate":"2023-10-17"},{"lineNumber":32,"author":{"gitId":"000verflow"},"content":" parser \u003d new Parser();","lastModifiedDate":"2023-10-17"},{"lineNumber":33,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":34,"author":{"gitId":"000verflow"},"content":" parser.resourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-17"},{"lineNumber":35,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new Book(\"Title1\", \"ISBN1\", \"Author1\", new String[]{\"horror\"}, 1234, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":36,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new Magazine(\"Title2\", \"ISBN2\", \"VOGUE2\", \"1234\", 5678, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":37,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new Newspaper(\"Title3\", \"ISBN3\", \"Publisher3\", \"1234\", 9101, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":38,"author":{"gitId":"000verflow"},"content":" parser.resourceList.add(new CD(\"Title4\", \"Creator4\", \"Creator4\", \"1234\", 1121, Status.AVAILABLE));","lastModifiedDate":"2023-11-04"},{"lineNumber":39,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"000verflow"},"content":" outContent.reset();","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"000verflow"},"content":" System.setOut(new PrintStream(outContent));","lastModifiedDate":"2023-11-04"},{"lineNumber":42,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":43,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":44,"author":{"gitId":"000verflow"},"content":" @AfterEach","lastModifiedDate":"2023-10-17"},{"lineNumber":45,"author":{"gitId":"000verflow"},"content":" void tearDown() {","lastModifiedDate":"2023-10-17"},{"lineNumber":46,"author":{"gitId":"000verflow"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-11-04"},{"lineNumber":47,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":48,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":50,"author":{"gitId":"000verflow"},"content":" void testSetAndGetTitle() {","lastModifiedDate":"2023-10-17"},{"lineNumber":51,"author":{"gitId":"000verflow"},"content":" findCommand.setTitle(\"TitleTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"000verflow"},"content":" assertEquals(\"TitleTest\", findCommand.getTitle());","lastModifiedDate":"2023-10-17"},{"lineNumber":53,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"000verflow"},"content":" void testSetAndGetAuthor() {","lastModifiedDate":"2023-10-17"},{"lineNumber":57,"author":{"gitId":"000verflow"},"content":" findCommand.setAuthor(\"AuthorTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"000verflow"},"content":" assertEquals(\"AuthorTest\", findCommand.getAuthor());","lastModifiedDate":"2023-10-17"},{"lineNumber":59,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":60,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":61,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":62,"author":{"gitId":"000verflow"},"content":" void testSetAndGetISBN() {","lastModifiedDate":"2023-10-17"},{"lineNumber":63,"author":{"gitId":"000verflow"},"content":" findCommand.setISBN(\"ISBNTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":64,"author":{"gitId":"000verflow"},"content":" assertEquals(\"ISBNTest\", findCommand.getISBN());","lastModifiedDate":"2023-10-17"},{"lineNumber":65,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":66,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":67,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":68,"author":{"gitId":"000verflow"},"content":" void testSetAndGetID() {","lastModifiedDate":"2023-10-17"},{"lineNumber":69,"author":{"gitId":"000verflow"},"content":" findCommand.setID(\"IDTest\");","lastModifiedDate":"2023-10-17"},{"lineNumber":70,"author":{"gitId":"000verflow"},"content":" assertEquals(\"IDTest\", findCommand.getID());","lastModifiedDate":"2023-10-17"},{"lineNumber":71,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":72,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":73,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":74,"author":{"gitId":"000verflow"},"content":" void testExecuteWithInvalidFlag() {","lastModifiedDate":"2023-10-17"},{"lineNumber":75,"author":{"gitId":"000verflow"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e findCommand.execute(\"/x InvalidFlag\", parser));","lastModifiedDate":"2023-10-17"},{"lineNumber":76,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":77,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":78,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":79,"author":{"gitId":"000verflow"},"content":" void testExecuteWithNoFilter() {","lastModifiedDate":"2023-10-17"},{"lineNumber":80,"author":{"gitId":"000verflow"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e findCommand.execute(\"\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":82,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":83,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":84,"author":{"gitId":"000verflow"},"content":" void testExecuteFindTitleMatch() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":85,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/t Title1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":86,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Title1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":87,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":88,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":89,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":90,"author":{"gitId":"000verflow"},"content":" void testExecuteFindAuthorMatch() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":91,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a Author1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":92,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Author1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":93,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":94,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":95,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":96,"author":{"gitId":"000verflow"},"content":" void testExecuteFindISBNMatch() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":97,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/i ISBN1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":98,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"ISBN1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":99,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":100,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":101,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":102,"author":{"gitId":"000verflow"},"content":" void testExecuteNoMatchesFound() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":103,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/t NonexistentTitle\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":104,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"There are no resources found matching the given filters.\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":105,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":106,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":107,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":108,"author":{"gitId":"000verflow"},"content":" void testExecuteFindMagazineBrandMatch() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":109,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a VOGUE2\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":110,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"VOGUE2\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"000verflow"},"content":" void testExecuteFindNewspaperPublisherMatch() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":115,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a Publisher3\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":116,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Publisher3\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":117,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":118,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":119,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"000verflow"},"content":" void testExecuteFindCDMatch() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/a Creator4\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Creator4\"));","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":124,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":125,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":127,"author":{"gitId":"000verflow"},"content":" void testExecuteMultipleFilters() throws SysLibException {","lastModifiedDate":"2023-10-17"},{"lineNumber":128,"author":{"gitId":"000verflow"},"content":" findCommand.execute(\"/t Title1 /a Author1\", parser);","lastModifiedDate":"2023-10-17"},{"lineNumber":129,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Title1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":130,"author":{"gitId":"000verflow"},"content":" assertTrue(outContent.toString().contains(\"Author1\"));","lastModifiedDate":"2023-10-17"},{"lineNumber":131,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":132,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-10-17"},{"lineNumber":133,"author":{"gitId":"000verflow"},"content":" @Test","lastModifiedDate":"2023-10-17"},{"lineNumber":134,"author":{"gitId":"000verflow"},"content":" void testExecuteInvalidFormat() {","lastModifiedDate":"2023-10-17"},{"lineNumber":135,"author":{"gitId":"000verflow"},"content":" assertThrows(IllegalArgumentException.class, () -\u003e findCommand.execute(\"find /z Invalid\", parser));","lastModifiedDate":"2023-10-17"},{"lineNumber":136,"author":{"gitId":"000verflow"},"content":" }","lastModifiedDate":"2023-10-17"},{"lineNumber":137,"author":{"gitId":"000verflow"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":138,"author":{"gitId":"000verflow"},"content":"}","lastModifiedDate":"2023-10-17"}],"authorContributionMap":{"000verflow":137,"bnjm2000":1}},{"path":"src/test/java/seedu/commands/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"bnjm2000"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"class HelpCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":" void execute() {","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":" HelpCommand helpCommand \u003d new HelpCommand();","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" helpCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Commands available:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" \"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" \"/tag TAG /i ISBN [/g GENRE /s STATUS])\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" \"delete: deletes the resource with the specified ID from the library inventory. \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. delete /id 123456789)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-17"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":" \"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-19"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" \"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":" System.lineSeparator() + \"edit: Edit a listing by entering its isbn to update its details. \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" \"eventadd: Add an event to the event list (e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventlist: List out all the event list (e.g. eventlist)\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventdelete: Delete an event in the event list based on the index \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventdelete /i INDEX)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":" \"exit: displays a farewell message and exits the program (e.g. exit)\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" \"For more information, please refer to our user guide at:\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" \"https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"bnjm2000":40,"DavinciDelta":4,"yingx9":1}},{"path":"src/test/java/seedu/commands/ListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"yingx9"},"content":"package seedu.commands;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"yingx9"},"content":"import java.util.List;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.BeforeAll;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"yingx9"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import seedu.util.TestUtil;","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":14,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":15,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.GENERIC_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.FILTER_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":17,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":18,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.displayResourcesDetails;","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"yingx9"},"content":"import static seedu.commands.ListCommand.matchedResources;","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":21,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"yingx9"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":"public class ListCommandTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" private static List\u003cResource\u003e testResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" private Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" private List\u003cResource\u003e emptyResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" private TestUtil testUtil \u003d new TestUtil();","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" private Command listCommand \u003d new ListCommand();","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" @BeforeAll","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" public static void setup() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":" testResourceList \u003d TestUtil.fillTestList();","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"yingx9"},"content":" public void testEmptyListMessage() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(listCommand, \"\", emptyResourceList);","lastModifiedDate":"2023-10-19"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d GENERIC_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" expectedMessage +\u003d ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":52,"author":{"gitId":"yingx9"},"content":" public void testNoTagArgBehavior() {","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":54,"author":{"gitId":"yingx9"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003elistCommand.execute(\"/tag\", parser));","lastModifiedDate":"2023-10-19"},{"lineNumber":55,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":57,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":58,"author":{"gitId":"yingx9"},"content":" public void testNoGenreArgBehavior() {","lastModifiedDate":"2023-11-04"},{"lineNumber":59,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":60,"author":{"gitId":"yingx9"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003elistCommand.execute(\"/g\", parser));","lastModifiedDate":"2023-10-19"},{"lineNumber":61,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":62,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":63,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":64,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":65,"author":{"gitId":"yingx9"},"content":" public void testNoStatusArgBehavior() {","lastModifiedDate":"2023-11-04"},{"lineNumber":66,"author":{"gitId":"yingx9"},"content":" parser.resourceList \u003d testResourceList;","lastModifiedDate":"2023-11-04"},{"lineNumber":67,"author":{"gitId":"yingx9"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003elistCommand.execute(\"/s\", parser));","lastModifiedDate":"2023-11-04"},{"lineNumber":68,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":69,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":70,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":71,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":72,"author":{"gitId":"yingx9"},"content":" public void testListByTagFilterBehavior() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/tag B\");","lastModifiedDate":"2023-11-04"},{"lineNumber":74,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":75,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":76,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":77,"author":{"gitId":"yingx9"},"content":" public void testListByGenreFilterBehavior() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":78,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/g Horror\");","lastModifiedDate":"2023-11-04"},{"lineNumber":79,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/g Adventure\");","lastModifiedDate":"2023-11-04"},{"lineNumber":80,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/g Fiction\");","lastModifiedDate":"2023-11-04"},{"lineNumber":81,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":82,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":83,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-11-04"},{"lineNumber":84,"author":{"gitId":"yingx9"},"content":" public void testListByStatusFilterBehavior() throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":85,"author":{"gitId":"yingx9"},"content":" executeListFilterBehavior(\"/s AVAILABLE\");","lastModifiedDate":"2023-11-04"},{"lineNumber":86,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":87,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":88,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":89,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":90,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":91,"author":{"gitId":"yingx9"},"content":" public void executeListFilterBehavior(String argument) throws SysLibException {","lastModifiedDate":"2023-11-04"},{"lineNumber":92,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(listCommand, argument, testResourceList);","lastModifiedDate":"2023-11-04"},{"lineNumber":93,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d FILTER_MESSAGE + displayResourcesDetails(matchedResources);","lastModifiedDate":"2023-11-04"},{"lineNumber":94,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-11-04"},{"lineNumber":95,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":96,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":97,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":98,"author":{"gitId":"yingx9"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"yingx9"},"content":" public void testNoFilteredListDisplay() throws SysLibException {","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"yingx9"},"content":" String outputMessage \u003d testUtil.getOutputMessage(listCommand, \"/g Thriller\", testResourceList);","lastModifiedDate":"2023-10-19"},{"lineNumber":101,"author":{"gitId":"yingx9"},"content":" String expectedMessage \u003d FILTER_MESSAGE;","lastModifiedDate":"2023-10-26"},{"lineNumber":102,"author":{"gitId":"yingx9"},"content":" expectedMessage +\u003d ZERO_RESOURCES_MESSAGE;","lastModifiedDate":"2023-11-01"},{"lineNumber":103,"author":{"gitId":"yingx9"},"content":" assertEquals(expectedMessage, outputMessage);","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"yingx9"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"000verflow":2,"yingx9":104}},{"path":"src/test/java/seedu/commands/events/EventAddCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventAddCommandTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final EventAddCommand eventAddCommand \u003d new EventAddCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandValidData() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1 Dec 2001 /desc testing 123\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d parser.eventList.get(0).toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"testrun | 01 Dec 2001 | testing 123\";","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(output, expectedOutput);","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1 DEC 2001 /desc testing 123\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"Event inserted at: 0\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandInvalidId() {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventAddCommand.execute(","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" \"/t testrun /date tmr /desc testing 123\", parser));","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":" public void eventAddCommandInsufficientData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventAddCommand.execute(\"/t \", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":46}},{"path":"src/test/java/seedu/commands/events/EventDeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventDeleteCommandTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final EventAddCommand eventAddCommand \u003d new EventAddCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" private final EventDeleteCommand eventDeleteCommand \u003d new EventDeleteCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" public void eventDeleteCommandOutput() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1 dec 2001 /desc testing 123\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" eventDeleteCommand.execute(\"/i 0\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"This event is removed:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" \"testrun | 01 Dec 2001 | testing 123\" + System.lineSeparator() +","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" public void eventDeleteCommandInvalidIndex() {","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventDeleteCommand.execute(","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" \"/i aaaaa\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" public void eventDeleteCommandInsufficientData() {","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventDeleteCommand.execute(\"/i \", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":41}},{"path":"src/test/java/seedu/commands/events/EventListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"DavinciDelta"},"content":"package seedu.commands.events;","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"DavinciDelta"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"DavinciDelta"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"DavinciDelta"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"DavinciDelta"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"DavinciDelta"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"DavinciDelta"},"content":"public class EventListCommandTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"DavinciDelta"},"content":" private final Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"DavinciDelta"},"content":" private final EventAddCommand eventAddCommand \u003d new EventAddCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"DavinciDelta"},"content":" private final EventListCommand eventListCommand \u003d new EventListCommand();","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"DavinciDelta"},"content":" public void eventListCommandOutputEmpty() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"DavinciDelta"},"content":" eventListCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"The event list is empty!\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(output, expectedOutput);","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"DavinciDelta"},"content":" public void eventListCommandOutputMultiple() throws SysLibException {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun /date 1 dec 2001 /desc testing 123\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":33,"author":{"gitId":"DavinciDelta"},"content":" eventAddCommand.execute(\"/t testrun2 /date 1 DEC 2002 /desc testing 1234\", parser);","lastModifiedDate":"2023-11-04"},{"lineNumber":34,"author":{"gitId":"DavinciDelta"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"DavinciDelta"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"DavinciDelta"},"content":" eventListCommand.execute(\"\", parser);","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"DavinciDelta"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"DavinciDelta"},"content":" String expectedOutput \u003d \"This is the current event list:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"DavinciDelta"},"content":" \"0: testrun | 01 Dec 2001 | testing 123\" + System.lineSeparator() +","lastModifiedDate":"2023-11-04"},{"lineNumber":40,"author":{"gitId":"DavinciDelta"},"content":" \"1: testrun2 | 01 Dec 2002 | testing 1234\" + System.lineSeparator() +","lastModifiedDate":"2023-11-04"},{"lineNumber":41,"author":{"gitId":"DavinciDelta"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"DavinciDelta"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"DavinciDelta"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"DavinciDelta"},"content":" public void eventListCommandInvalidInput() {","lastModifiedDate":"2023-10-31"},{"lineNumber":47,"author":{"gitId":"DavinciDelta"},"content":" assertThrows(IllegalArgumentException.class, ()-\u003eeventListCommand.execute(","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"DavinciDelta"},"content":" \"random\", parser));","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"DavinciDelta"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"DavinciDelta"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"DavinciDelta"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"000verflow":1,"DavinciDelta":50}},{"path":"src/test/java/seedu/parser/ParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"JoanneJo"},"content":"import seedu.data.CreateResource;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"bnjm2000"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertArrayEquals;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":"import static org.junit.jupiter.api.Assertions.assertNull;","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"yingx9"},"content":"import static seedu.util.TestUtil.getCurrentDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":"class ParserTest {","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" public void testProcessExitCommand() {","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"exit\";","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":32,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Bye, hope to see you again soon!\";","lastModifiedDate":"2023-10-16"},{"lineNumber":33,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"bnjm2000"},"content":" public void testProcessHelpCommand() {","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"help\";","lastModifiedDate":"2023-10-16"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":45,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"Commands available:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bnjm2000"},"content":" \"add: adds a new resource to the library inventory.(e.g. add /id ID /t TITLE /a AUTHOR \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":52,"author":{"gitId":"bnjm2000"},"content":" \"/tag TAG /i ISBN [/g GENRE /s STATUS])\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"bnjm2000"},"content":" \"delete: deletes the resource with the specified ID from the library inventory. \" +","lastModifiedDate":"2023-10-17"},{"lineNumber":54,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. delete /id 123456789)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-17"},{"lineNumber":55,"author":{"gitId":"bnjm2000"},"content":" \"list: list all resources OR filter by certain tags or genre.(e.g. list /tag B /g Fiction\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":56,"author":{"gitId":"yingx9"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-19"},{"lineNumber":57,"author":{"gitId":"bnjm2000"},"content":" \"find: find a resource by title, author, ISBN or given id. (e.g. find /i 9780763630188)\" +","lastModifiedDate":"2023-10-17"},{"lineNumber":58,"author":{"gitId":"bnjm2000"},"content":" System.lineSeparator() + \"edit: Edit a listing by entering its isbn to update its details. \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"bnjm2000"},"content":" \"(e.g. edit /i 123 /t NEW_TITLE /a NEW_AUTHOR)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"DavinciDelta"},"content":" \"eventadd: Add an event to the event list (e.g. eventadd /t TITLE /date DATE [/desc DESCRIPTION])\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":61,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventlist: List out all the event list (e.g. eventlist)\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":62,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() + \"eventdelete: Delete an event in the event list based on the index \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":63,"author":{"gitId":"DavinciDelta"},"content":" \"(e.g. eventdelete /i INDEX)\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":64,"author":{"gitId":"DavinciDelta"},"content":" \"exit: displays a farewell message and exits the program (e.g. exit)\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":65,"author":{"gitId":"DavinciDelta"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":66,"author":{"gitId":"bnjm2000"},"content":" \"For more information, please refer to our user guide at:\" +","lastModifiedDate":"2023-10-16"},{"lineNumber":67,"author":{"gitId":"bnjm2000"},"content":" \"https://ay2324s1-cs2113t-w11-1.github.io/tp/UserGuide.html\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":68,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":69,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":70,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":71,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":72,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":73,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":74,"author":{"gitId":"bnjm2000"},"content":" public void testProcessUnknownCommand() {","lastModifiedDate":"2023-10-16"},{"lineNumber":75,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":76,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"bye\";","lastModifiedDate":"2023-10-16"},{"lineNumber":77,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":78,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":79,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":80,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":81,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":82,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":83,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":84,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":85,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":86,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"no commands found. Enter \\\"help\\\" for a list of commands.\";","lastModifiedDate":"2023-10-16"},{"lineNumber":87,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":88,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"____________________________________________________________\";","lastModifiedDate":"2023-10-16"},{"lineNumber":89,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":90,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":91,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":92,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":93,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":94,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":95,"author":{"gitId":"bnjm2000"},"content":" public void testProcessCommands() {","lastModifiedDate":"2023-10-16"},{"lineNumber":96,"author":{"gitId":"bnjm2000"},"content":" //Test add","lastModifiedDate":"2023-10-16"},{"lineNumber":97,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":98,"author":{"gitId":"bnjm2000"},"content":" String validResponse \u003d \"add /id 1 /t Surrounded by Idiots /a Thomas Erikson \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":99,"author":{"gitId":"bnjm2000"},"content":" \"/tag B /i 9781250255174 /g Self-help\";","lastModifiedDate":"2023-10-16"},{"lineNumber":100,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":101,"author":{"gitId":"bnjm2000"},"content":" ByteArrayOutputStream outputStream \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-16"},{"lineNumber":102,"author":{"gitId":"bnjm2000"},"content":" System.setOut(new PrintStream(outputStream));","lastModifiedDate":"2023-10-16"},{"lineNumber":103,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":104,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":105,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":106,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":107,"author":{"gitId":"bnjm2000"},"content":" String output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":108,"author":{"gitId":"bnjm2000"},"content":" String expectedOutput \u003d \"This book is added: Surrounded by Idiots\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":109,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();;","lastModifiedDate":"2023-10-16"},{"lineNumber":110,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":111,"author":{"gitId":"bnjm2000"},"content":" //Add second book","lastModifiedDate":"2023-10-16"},{"lineNumber":112,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"add /id 2 /t The Subtle Art of Not Giving a F*ck /a Mark Manson \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":113,"author":{"gitId":"bnjm2000"},"content":" \"/tag B /i 9780062457714 /g Self-help\";","lastModifiedDate":"2023-10-16"},{"lineNumber":114,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":115,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"This book is added: The Subtle Art of Not Giving a F*ck\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":116,"author":{"gitId":"yingx9"},"content":" \"____________________________________________________________\" + System.lineSeparator()","lastModifiedDate":"2023-10-26"},{"lineNumber":117,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator();;","lastModifiedDate":"2023-10-26"},{"lineNumber":118,"author":{"gitId":"bnjm2000"},"content":" //Test list","lastModifiedDate":"2023-10-16"},{"lineNumber":119,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"list\";","lastModifiedDate":"2023-10-16"},{"lineNumber":120,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":121,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Listing all resources in the Library:\" + System.lineSeparator() + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":122,"author":{"gitId":"bnjm2000"},"content":" \"1. [B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":123,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Erikson Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":124,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":125,"author":{"gitId":"bnjm2000"},"content":" \"2. [B] ID: 2 Title: The Subtle Art of Not Giving a F*ck ISBN: 9780062457714 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":126,"author":{"gitId":"yingx9"},"content":" \"Author: Mark Manson Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":127,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator() + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":128,"author":{"gitId":"yingx9"},"content":" \"There are currently 2 resource(s).\" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":129,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":130,"author":{"gitId":"bnjm2000"},"content":" System.setOut(System.out);","lastModifiedDate":"2023-10-16"},{"lineNumber":131,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":132,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":133,"author":{"gitId":"bnjm2000"},"content":" //Test find","lastModifiedDate":"2023-10-16"},{"lineNumber":134,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"find /t The Subtle Art of Not Giving a F*ck\";","lastModifiedDate":"2023-10-16"},{"lineNumber":135,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":136,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Here are resources that matched the given filters:\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":137,"author":{"gitId":"bnjm2000"},"content":" \"[B] ID: 2 Title: The Subtle Art of Not Giving a F*ck ISBN: 9780062457714 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":138,"author":{"gitId":"yingx9"},"content":" \"Author: Mark Manson Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate() +","lastModifiedDate":"2023-10-31"},{"lineNumber":139,"author":{"gitId":"yingx9"},"content":" System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":140,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();;","lastModifiedDate":"2023-10-16"},{"lineNumber":141,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":142,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":143,"author":{"gitId":"bnjm2000"},"content":" //Negative find test","lastModifiedDate":"2023-10-16"},{"lineNumber":144,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"find /t No Such Book\";","lastModifiedDate":"2023-10-16"},{"lineNumber":145,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":146,"author":{"gitId":"000verflow"},"content":" expectedOutput +\u003d \"There are no resources found matching the given filters.\" + System.lineSeparator() +","lastModifiedDate":"2023-10-17"},{"lineNumber":147,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();;","lastModifiedDate":"2023-10-16"},{"lineNumber":148,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":149,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":150,"author":{"gitId":"bnjm2000"},"content":" //Test edit","lastModifiedDate":"2023-10-30"},{"lineNumber":151,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"edit /i 9781250255174 /a Thomas\";","lastModifiedDate":"2023-10-30"},{"lineNumber":152,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-30"},{"lineNumber":153,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-30"},{"lineNumber":154,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Successfully updated! Your updated resource:\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":155,"author":{"gitId":"bnjm2000"},"content":" + System.lineSeparator() + \"[B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":156,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Genre: Self-help Status: AVAILABLE\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"yingx9"},"content":" +System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-30"},{"lineNumber":159,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-30"},{"lineNumber":160,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":161,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"edit /i 9781250255174 /s lost\";","lastModifiedDate":"2023-10-30"},{"lineNumber":162,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Successfully updated! Your updated resource:\" + System.lineSeparator()","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"bnjm2000"},"content":" + System.lineSeparator() + \"[B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Genre: Self-help Status: LOST\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":167,"author":{"gitId":"yingx9"},"content":" +System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":168,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-30"},{"lineNumber":169,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"bnjm2000"},"content":" //Test delete","lastModifiedDate":"2023-10-16"},{"lineNumber":171,"author":{"gitId":"bnjm2000"},"content":" validResponse \u003d \"delete /id 1\";","lastModifiedDate":"2023-10-16"},{"lineNumber":172,"author":{"gitId":"bnjm2000"},"content":" parser.process(validResponse);","lastModifiedDate":"2023-10-16"},{"lineNumber":173,"author":{"gitId":"bnjm2000"},"content":" output \u003d outputStream.toString();","lastModifiedDate":"2023-10-16"},{"lineNumber":174,"author":{"gitId":"bnjm2000"},"content":" expectedOutput +\u003d \"Looking for ID: 1...\" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":175,"author":{"gitId":"bnjm2000"},"content":" \"This resource is removed: \" + System.lineSeparator() +","lastModifiedDate":"2023-10-16"},{"lineNumber":176,"author":{"gitId":"bnjm2000"},"content":" \"[B] ID: 1 Title: Surrounded by Idiots ISBN: 9781250255174 \" +","lastModifiedDate":"2023-10-16"},{"lineNumber":177,"author":{"gitId":"yingx9"},"content":" \"Author: Thomas Genre: Self-help Status: LOST\" + \" Received Date: \" + getCurrentDate()","lastModifiedDate":"2023-10-31"},{"lineNumber":178,"author":{"gitId":"yingx9"},"content":" + System.lineSeparator() +","lastModifiedDate":"2023-10-31"},{"lineNumber":179,"author":{"gitId":"bnjm2000"},"content":" \"____________________________________________________________\" + System.lineSeparator();","lastModifiedDate":"2023-10-16"},{"lineNumber":180,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedOutput, output);","lastModifiedDate":"2023-10-16"},{"lineNumber":181,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":182,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":183,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":184,"author":{"gitId":"bnjm2000"},"content":" public void testParseAddCommand() throws SysLibException {","lastModifiedDate":"2023-10-16"},{"lineNumber":185,"author":{"gitId":"bnjm2000"},"content":" // Test case 1: Valid input with both genre and status","lastModifiedDate":"2023-10-31"},{"lineNumber":186,"author":{"gitId":"bnjm2000"},"content":" String statement1 \u003d \"add /id 123456789 /t Moby Dick /a Herman Melville /tag B /i 9780763630188 \" +","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"bnjm2000"},"content":" \"/g Adventure, Fiction /s lost\";","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"bnjm2000"},"content":" String[] result \u003d Parser.parseAddCommand(statement1);","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":190,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"123456789\", result[0]);","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Moby Dick\", result[1]);","lastModifiedDate":"2023-10-30"},{"lineNumber":192,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Herman Melville\", result[2]);","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"B\", result[3]);","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"9780763630188\", result[4]);","lastModifiedDate":"2023-10-30"},{"lineNumber":195,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Adventure, Fiction\", result[5]);","lastModifiedDate":"2023-10-30"},{"lineNumber":196,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"lost\", result[6]);","lastModifiedDate":"2023-10-30"},{"lineNumber":197,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":198,"author":{"gitId":"bnjm2000"},"content":" // Test case 2: Valid input without genre","lastModifiedDate":"2023-10-31"},{"lineNumber":199,"author":{"gitId":"bnjm2000"},"content":" String statement2 \u003d \"add /id 123 /t Moby Dick /a Herman Melville /tag B /i 9780763630188 /s lost\";","lastModifiedDate":"2023-10-31"},{"lineNumber":200,"author":{"gitId":"bnjm2000"},"content":" result \u003d Parser.parseAddCommand(statement2);","lastModifiedDate":"2023-10-31"},{"lineNumber":201,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":202,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"123\", result[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":203,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Moby Dick\", result[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":204,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Herman Melville\", result[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":205,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"B\", result[3]);","lastModifiedDate":"2023-10-31"},{"lineNumber":206,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"9780763630188\", result[4]);","lastModifiedDate":"2023-10-31"},{"lineNumber":207,"author":{"gitId":"bnjm2000"},"content":" assertNull(result[5]);","lastModifiedDate":"2023-10-31"},{"lineNumber":208,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"lost\", result[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":209,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":210,"author":{"gitId":"bnjm2000"},"content":" // Test case 3: Valid input without status and genre","lastModifiedDate":"2023-10-31"},{"lineNumber":211,"author":{"gitId":"bnjm2000"},"content":" String statement3 \u003d \"add /id 456 /t Moby Dick /a Herman Melville /tag B /i 9780763630188\";","lastModifiedDate":"2023-10-31"},{"lineNumber":212,"author":{"gitId":"bnjm2000"},"content":" result \u003d Parser.parseAddCommand(statement3);","lastModifiedDate":"2023-10-31"},{"lineNumber":213,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":214,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"456\", result[0]);","lastModifiedDate":"2023-10-31"},{"lineNumber":215,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Moby Dick\", result[1]);","lastModifiedDate":"2023-10-31"},{"lineNumber":216,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Herman Melville\", result[2]);","lastModifiedDate":"2023-10-31"},{"lineNumber":217,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"B\", result[3]);","lastModifiedDate":"2023-10-31"},{"lineNumber":218,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"9780763630188\", result[4]);","lastModifiedDate":"2023-10-31"},{"lineNumber":219,"author":{"gitId":"bnjm2000"},"content":" assertNull(result[5]);","lastModifiedDate":"2023-10-31"},{"lineNumber":220,"author":{"gitId":"bnjm2000"},"content":" assertEquals(\"Available\", result[6]);","lastModifiedDate":"2023-10-31"},{"lineNumber":221,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":222,"author":{"gitId":"bnjm2000"},"content":" // Test case 4: Invalid input (missing /tag b)","lastModifiedDate":"2023-10-31"},{"lineNumber":223,"author":{"gitId":"bnjm2000"},"content":" String statement4 \u003d \"add /id 123456789 /t Moby Dick /a Herman Melville /tag C /i 9780763630188 \" +","lastModifiedDate":"2023-10-31"},{"lineNumber":224,"author":{"gitId":"bnjm2000"},"content":" \"/g Adventure, Fiction /s Borrowed\";","lastModifiedDate":"2023-10-30"},{"lineNumber":225,"author":{"gitId":"bnjm2000"},"content":" assertThrows(SysLibException.class, () -\u003e Parser.parseAddCommand(statement4));","lastModifiedDate":"2023-10-31"},{"lineNumber":226,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":227,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":228,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":229,"author":{"gitId":"bnjm2000"},"content":" public void testParseAddBook() throws SysLibException {","lastModifiedDate":"2023-10-16"},{"lineNumber":230,"author":{"gitId":"bnjm2000"},"content":" // Test case 1: Valid input with /g GENRE and /s STATUS","lastModifiedDate":"2023-10-30"},{"lineNumber":231,"author":{"gitId":"bnjm2000"},"content":" String statement1 \u003d \"/id ID /t TITLE /a AUTHOR /tag b /i ISBN /g GENRE /s lost\";","lastModifiedDate":"2023-10-30"},{"lineNumber":232,"author":{"gitId":"bnjm2000"},"content":" String[] expectedArgs1 \u003d {\"ID\", \"TITLE\", \"AUTHOR\", \"b\", \"ISBN\", \"GENRE\", \"lost\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":233,"author":{"gitId":"bnjm2000"},"content":" assertArrayEquals(expectedArgs1, Parser.parseAddBook(statement1));","lastModifiedDate":"2023-10-16"},{"lineNumber":234,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":235,"author":{"gitId":"bnjm2000"},"content":" // Test case 2: Valid input without /g GENRE or /s STATUS","lastModifiedDate":"2023-10-30"},{"lineNumber":236,"author":{"gitId":"bnjm2000"},"content":" String statement2 \u003d \"/id ID /t TITLE /a AUTHOR /tag b /i ISBN\";","lastModifiedDate":"2023-10-16"},{"lineNumber":237,"author":{"gitId":"bnjm2000"},"content":" String[] expectedArgs2 \u003d {\"ID\", \"TITLE\", \"AUTHOR\", \"b\", \"ISBN\", null, \"Available\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":238,"author":{"gitId":"bnjm2000"},"content":" assertArrayEquals(expectedArgs2, Parser.parseAddBook(statement2));","lastModifiedDate":"2023-10-16"},{"lineNumber":239,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":240,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":241,"author":{"gitId":"JoanneJo"},"content":" // CreateResourceTest","lastModifiedDate":"2023-10-31"},{"lineNumber":242,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":243,"author":{"gitId":"bnjm2000"},"content":" public void testCreateBook() {","lastModifiedDate":"2023-10-16"},{"lineNumber":244,"author":{"gitId":"bnjm2000"},"content":" String[] args \u003d {\"123\", \"CS2113T\", \"W11\", \"B\", \"1234\", \"Horror\", \"lost\"};","lastModifiedDate":"2023-10-30"},{"lineNumber":245,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":246,"author":{"gitId":"bnjm2000"},"content":" Book book \u003d null;","lastModifiedDate":"2023-10-16"},{"lineNumber":247,"author":{"gitId":"JoanneJo"},"content":" book \u003d CreateResource.createBook(args);","lastModifiedDate":"2023-10-31"},{"lineNumber":248,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":249,"author":{"gitId":"bnjm2000"},"content":" int expectedId \u003d 123;","lastModifiedDate":"2023-10-16"},{"lineNumber":250,"author":{"gitId":"bnjm2000"},"content":" String expectedTitle \u003d \"CS2113T\";","lastModifiedDate":"2023-10-16"},{"lineNumber":251,"author":{"gitId":"bnjm2000"},"content":" String expectedAuthor \u003d \"W11\";","lastModifiedDate":"2023-10-16"},{"lineNumber":252,"author":{"gitId":"bnjm2000"},"content":" String expectedIsbn \u003d \"1234\";","lastModifiedDate":"2023-10-16"},{"lineNumber":253,"author":{"gitId":"bnjm2000"},"content":" String[] expectedGenres \u003d { \"Horror\" };","lastModifiedDate":"2023-10-16"},{"lineNumber":254,"author":{"gitId":"bnjm2000"},"content":" Status expectedStatus \u003d Status.LOST;","lastModifiedDate":"2023-10-30"},{"lineNumber":255,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":256,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedId, book.getId());","lastModifiedDate":"2023-10-16"},{"lineNumber":257,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedTitle, book.getTitle());","lastModifiedDate":"2023-10-16"},{"lineNumber":258,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedAuthor, book.getAuthor());","lastModifiedDate":"2023-10-16"},{"lineNumber":259,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedIsbn, book.getISBN());","lastModifiedDate":"2023-10-16"},{"lineNumber":260,"author":{"gitId":"bnjm2000"},"content":" assertArrayEquals(expectedGenres, book.getGenre());","lastModifiedDate":"2023-10-16"},{"lineNumber":261,"author":{"gitId":"bnjm2000"},"content":" assertEquals(expectedStatus, book.getStatus());","lastModifiedDate":"2023-10-30"},{"lineNumber":262,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":263,"author":{"gitId":"bnjm2000"},"content":" @Test","lastModifiedDate":"2023-10-16"},{"lineNumber":264,"author":{"gitId":"bnjm2000"},"content":" public void testCreateBookInvalidId() {","lastModifiedDate":"2023-10-16"},{"lineNumber":265,"author":{"gitId":"bnjm2000"},"content":" String[] args \u003d {\"not_a_number\", \"Sample Title\", \"Sample Author\", \"\", \"Sample ISBN\", \"Sample Genre\"};","lastModifiedDate":"2023-10-16"},{"lineNumber":266,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":267,"author":{"gitId":"JoanneJo"},"content":" assertThrows(NumberFormatException.class, () -\u003e CreateResource.createBook(args));","lastModifiedDate":"2023-10-31"},{"lineNumber":268,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":269,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"000verflow":3,"bnjm2000":239,"JoanneJo":4,"DavinciDelta":6,"yingx9":17}},{"path":"src/test/java/seedu/util/TestUtil.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"bnjm2000"},"content":"package seedu.util;","lastModifiedDate":"2023-10-16"},{"lineNumber":2,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"bnjm2000"},"content":"import seedu.commands.Command;","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Book;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"000verflow"},"content":"import seedu.data.resources.Resource;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"bnjm2000"},"content":"import seedu.data.Status;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"000verflow"},"content":"import seedu.exception.SysLibException;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"bnjm2000"},"content":"import seedu.parser.Parser;","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"yingx9"},"content":"import seedu.commands.CommandResult;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"yingx9"},"content":"import java.time.LocalDateTime;","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"yingx9"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"yingx9"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"bnjm2000"},"content":"import java.util.List;","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"bnjm2000"},"content":"public class TestUtil {","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"bnjm2000"},"content":" public String getOutputMessage(Command c, String m, List\u003cResource\u003e resourceList) throws SysLibException {","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"bnjm2000"},"content":" Parser parser \u003d new Parser();","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"bnjm2000"},"content":" parser.resourceList \u003d resourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"yingx9"},"content":" CommandResult commandResult \u003d c.execute(m, parser);","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"yingx9"},"content":" return commandResult.feedbackToUser;","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"bnjm2000"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"yingx9"},"content":" public static String getCurrentDate(){","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"yingx9"},"content":" LocalDateTime dateReceived \u003d LocalDateTime.now();","lastModifiedDate":"2023-10-31"},{"lineNumber":28,"author":{"gitId":"yingx9"},"content":" DateTimeFormatter formatter \u003d DateTimeFormatter.ofPattern(\"dd MMM yyyy\");","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"yingx9"},"content":" String formattedDate \u003d dateReceived.format(formatter);","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"yingx9"},"content":" return formattedDate;","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"yingx9"},"content":" public static List\u003cResource\u003e fillTestList() {","lastModifiedDate":"2023-10-16"},{"lineNumber":34,"author":{"gitId":"yingx9"},"content":" List\u003cResource\u003e testResourceList \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-16"},{"lineNumber":35,"author":{"gitId":"yingx9"},"content":" String[] genres \u003d {\"Horror\", \"Fiction\"};","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"yingx9"},"content":" String[] genresAdventure \u003d {\"Adventure\"};","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"yingx9"},"content":" String[] genresNull \u003d {null};","lastModifiedDate":"2023-10-17"},{"lineNumber":38,"author":{"gitId":"yingx9"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"JoanneJo"},"content":" Resource test1 \u003d new Resource(\"title1\", \"1\", 12345, Status.AVAILABLE);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"bnjm2000"},"content":" Book testBook \u003d new Book(\"title2\", \"2\", \"author\", genres, 123123, Status.AVAILABLE);","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"bnjm2000"},"content":" Book testBook2 \u003d new Book(\"title3\", \"3\", \"author\", genresAdventure, 123123,","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"bnjm2000"},"content":" Status.AVAILABLE);","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"bnjm2000"},"content":" Book testBook3 \u003d new Book(\"title3\", \"4\", \"author\", genresNull, 123123, Status.AVAILABLE);","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"bnjm2000"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"yingx9"},"content":" testResourceList.add(test1);","lastModifiedDate":"2023-10-16"},{"lineNumber":46,"author":{"gitId":"yingx9"},"content":" testResourceList.add(testBook);","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"yingx9"},"content":" testResourceList.add(testBook2);","lastModifiedDate":"2023-10-16"},{"lineNumber":48,"author":{"gitId":"yingx9"},"content":" testResourceList.add(testBook3);","lastModifiedDate":"2023-10-17"},{"lineNumber":49,"author":{"gitId":"yingx9"},"content":" return testResourceList;","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"yingx9"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":51,"author":{"gitId":"bnjm2000"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"000verflow":3,"bnjm2000":22,"JoanneJo":1,"yingx9":25}}] diff --git a/AY2324S1-CS2113T-W11-1_tp_master/commits.json b/AY2324S1-CS2113T-W11-1_tp_master/commits.json index ec314c4..47ec3fe 100644 --- a/AY2324S1-CS2113T-W11-1_tp_master/commits.json +++ b/AY2324S1-CS2113T-W11-1_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"000verflow":[{"date":"2023-10-06","commitResults":[{"hash":"40c098fcf74b1c2282447f9113b643a766c328d3","isMergeCommit":false,"messageTitle":"Add ashokbalaji-aboutus","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":1}}},{"hash":"ba10e507f38769c43a032bf8f9367a09dce03291","isMergeCommit":false,"messageTitle":"Add userguide draft","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":99,"deletions":23}}}]},{"date":"2023-10-11","commitResults":[{"hash":"d051634250466c7164160a7fddeb56f1762e79a3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into YingXia-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7b3caa8286c5e5afd39596c9d37aaa83da139f3e","isMergeCommit":true,"messageTitle":"Merge pull request #2 from yingx9/YingXia-AboutUs","messageBody":"Update AboutUs.md and add Portfolio Page","fileTypesAndContributionMap":{}},{"hash":"ce04bd2fd92aa288fc50505baa20550cef504563","isMergeCommit":true,"messageTitle":"Merge pull request #5 from AY2324S1-CS2113T-W11-1/branch-AshokBalaji-userguide","messageBody":"Add userguide draft","fileTypesAndContributionMap":{}},{"hash":"bd25c10208589cf71225db3fa2e85eb80cf14e72","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into WuXingyu-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2eb93ed11019095c9d83522d710cff1951ff90ee","isMergeCommit":true,"messageTitle":"Merge pull request #3 from DavinciDelta/WuXingyu-AboutUs","messageBody":"Add WuXingyu-AboutUs","fileTypesAndContributionMap":{}},{"hash":"da93b03bf043240cb13cd891d3f7d5ba034f221d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-AshokBalaji-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"751016df50864854566f9a6f330cc416719f3f8c","isMergeCommit":true,"messageTitle":"Merge pull request #4 from AY2324S1-CS2113T-W11-1/branch-AshokBalaji-AboutUs","messageBody":"Add ashokbalaji-aboutus","fileTypesAndContributionMap":{}},{"hash":"fbcd9e994f8f6d371570e0837d0b9df5d55e0a65","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"6e0c5086aa5ce4c4ef524b1109975395f85b10ec","isMergeCommit":true,"messageTitle":"Merge pull request #6 from bnjm2000/master","messageBody":"Add Benjamin-AboutUs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"7ac4de161937c8f68caedf661d33ac2743bce93f","isMergeCommit":false,"messageTitle":"Revert \"Add code from AddressBook\"","messageBody":"This reverts commit 24a54a13e9bff5754c97196f670acb1db3f9c3fe.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1937}}},{"hash":"15df575857850f9910d1277c039fd733830fde91","isMergeCommit":false,"messageTitle":"Add UI Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":61,"deletions":11}}},{"hash":"9598cd960fd0593f0decb94a2ad3150e18b70383","isMergeCommit":false,"messageTitle":"Update UI package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":12}}},{"hash":"cbd5935ccf882033ad0b08db364596550f560f60","isMergeCommit":false,"messageTitle":"Rename Ui.java to UI.java","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"dbd0e6f0e289653a11048a5d9c19c7a444448864","isMergeCommit":false,"messageTitle":"Update UI package bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":11}}},{"hash":"9a1adb0d5f9728d7fd6ddf0eb857fe41242adf24","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-AshokBalaji-UI-class\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into branch-AshokBalaji-UI-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"61cfb3cce6305613102703e161b14a648269c2a3","isMergeCommit":false,"messageTitle":"Update UI package bug","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"7e4f3fe7f71a7459f1bd36c678648852307f3437","isMergeCommit":false,"messageTitle":"Update tests and fix package structure","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":14},"other":{"insertions":22,"deletions":22}}},{"hash":"234d4f7e45be31af96739a72dbc38e756ac6e307","isMergeCommit":true,"messageTitle":"Merge pull request #22 from AY2324S1-CS2113T-W11-1/branch-AshokBalaji-UI-class","messageBody":"Add UI Class","fileTypesAndContributionMap":{}},{"hash":"11762124503a2c817f64b4270a43e8aacf3f413d","isMergeCommit":true,"messageTitle":"Merge pull request #23 from bnjm2000/add_portfolio","messageBody":"Add portfolio and updated README.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"53cf6f5c45786d68a96b75e355f9b23f4e85d942","isMergeCommit":false,"messageTitle":"Add FindCommand class","messageBody":"Refactored structure as well\n","fileTypesAndContributionMap":{"functional-code":{"insertions":107,"deletions":7},"other":{"insertions":3,"deletions":4}}},{"hash":"e47758599f53faae99cd80ef54ce1645c93bd29e","isMergeCommit":true,"messageTitle":"Merge pull request #33 from JoanneJo/JoanneAng-TagResource","messageBody":"Add Tag Function","fileTypesAndContributionMap":{}},{"hash":"8bfd4312374db9102e7007cac4eb3d716c3533b4","isMergeCommit":true,"messageTitle":"Merge pull request #34 from yingx9/YingXia-ListBySpecificArguments","messageBody":"Update Listing by specific filters for ListCommand.Java","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"c506bdc66a04030dcab18d1d8558dfe23fec32c2","isMergeCommit":false,"messageTitle":"Add Junit tests for FindCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":19},"test-code":{"insertions":126,"deletions":1}}},{"hash":"ecdbae3f3a74ddc3de8d01da6cc64fe1a557ff7b","isMergeCommit":false,"messageTitle":"Add logging and java assertions to FindCommand class, updated FindCommandTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":3},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-26","commitResults":[{"hash":"0643b459f813d1557ce46b3d1f313e42921a2afe","isMergeCommit":false,"messageTitle":"Update FindCommand with new parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":29},"test-code":{"insertions":0,"deletions":11}}},{"hash":"f2321f49afd6722491ed22ce65cf805c4856bf35","isMergeCommit":true,"messageTitle":"Merge pull request #72 from 000verflow/branch-AshokBalaji-UpdateFindCommand","messageBody":"Update FindCommand with new parser","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"3669b239dc0f2e56b1ac7d0fec9418ab1ef9e5bd","isMergeCommit":false,"messageTitle":"Add find command details on DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":69,"deletions":4}}}]},{"date":"2023-10-29","commitResults":[{"hash":"66de33dd0fc52c63e97efd45452feb410fad335e","isMergeCommit":true,"messageTitle":"Merge pull request #84 from bnjm2000/BenjaminNg-UpdateUG","messageBody":"Add updates to UG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"7a114bc50c352cde2e599ede33d45727add57cd2","isMergeCommit":true,"messageTitle":"Merge pull request #89 from yingx9/YingXia-AddDateTime","messageBody":"Add variable dateReceived to Resource","fileTypesAndContributionMap":{}},{"hash":"8b2bbe4e559c84ec13b552b7bb9e04c4ecaad8c7","isMergeCommit":false,"messageTitle":"Fix findCommand assertion issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"test-code":{"insertions":1,"deletions":1}}},{"hash":"4b83ab0ff7b907a7e472a3f18cd33577859f1a94","isMergeCommit":true,"messageTitle":"Merge pull request #100 from bnjm2000/BenjaminNg-FixLogsandConsistency","messageBody":"Fix logs and consistency","tags":["v2.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"1283a908bf1bc8db55e7eccbc9eae10eb2b036ad","isMergeCommit":true,"messageTitle":"Merge pull request #102 from yingx9/YingXia-ImplementCommandResult","messageBody":"Add CommandResult class and feedbackToUser variable to all commands","fileTypesAndContributionMap":{}},{"hash":"c41056bbea1c44119b19ef4f4eabef69279981e2","isMergeCommit":false,"messageTitle":"Add sequence diagram for Find Command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":96,"deletions":3}}}]},{"date":"2023-11-02","commitResults":[{"hash":"9e10a72f51cdceefc17f878cd4040334f5af4283","isMergeCommit":false,"messageTitle":"Add Storage capability, update some class to accommodate","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":350,"deletions":36},"other":{"insertions":1,"deletions":1}}},{"hash":"76241e51ca49b6eb0bf6a9de0a0ee708394de09f","isMergeCommit":false,"messageTitle":"Update for checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":216,"deletions":195}}},{"hash":"13130e7afc2f8be8bd7816dd7cbe3a4931eb442c","isMergeCommit":false,"messageTitle":"Update Storage.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4}}},{"hash":"79f666b5e1c970268d5510c54d4b43ab7a372298","isMergeCommit":false,"messageTitle":"Update text ui test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"9c1206087045f06a8f6d26741acab79f90358e14","isMergeCommit":false,"messageTitle":"Update find sequence diagram, add minor UI enhancement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":14},"docs":{"insertions":1,"deletions":7}}},{"hash":"669d6009a95825028574409c2ff368d688a41597","isMergeCommit":false,"messageTitle":"Revert UI Update","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"52be2a3a81a3c37cdf7e744386705701c269253f","isMergeCommit":true,"messageTitle":"Merge pull request #107 from yingx9/YingXia-AddEditListLogging","messageBody":"Add Logging and Assertions for EditCommand, ListCommand","fileTypesAndContributionMap":{}},{"hash":"0ffbebffb034f1c5f8dd8e5d1fa63158e63915f2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":15}}}]},{"date":"2023-11-03","commitResults":[{"hash":"0083b705af3556b21095da069b252b6b511a64f4","isMergeCommit":false,"messageTitle":"Update find command filter method, fix storage class bug.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":77,"deletions":41},"other":{"insertions":27,"deletions":9},"test-code":{"insertions":14,"deletions":14}}},{"hash":"5c3a463dc18f0041cc9ecb6f4ec3125b5f2387b1","isMergeCommit":false,"messageTitle":"Fix another bug with storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":14},"other":{"insertions":2,"deletions":2},"test-code":{"insertions":3,"deletions":3}}},{"hash":"e68bfd4e4b921982925629a69ecc47af8cbaac33","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":2}}},{"hash":"928c319931614b9047466c72a7045639765f8e58","isMergeCommit":false,"messageTitle":"Add logging for find","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"1f600f6a88597df6de8cfd654a8ef9514e6c8a26","isMergeCommit":false,"messageTitle":"Fix magic literals","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":8}}},{"hash":"13815aff3f064d96ffcc5c8869719ae39a7adc07","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"3cb2ee1912a6ba9928552d25ab858a7e542d88e3","isMergeCommit":false,"messageTitle":"Update FindCommand to account for different types of resources","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":12}}},{"hash":"9bfb7330638db31ff3822657e3337b7ba77d69e9","isMergeCommit":false,"messageTitle":"Update FindCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"4c61918964c6c1030efce3e7d10f2e0fc7ce9c69","isMergeCommit":false,"messageTitle":"Update UG and DG to reflect the changes to findCommand accordingly","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":2}}}]},{"date":"2023-11-04","commitResults":[{"hash":"b5832c6223a6020471902f436c74fa360236c0e2","isMergeCommit":false,"messageTitle":"Update Sequence diagram for Find","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":42}}},{"hash":"50d139af557e7dbd5cfe90db275b79a1944fd41e","isMergeCommit":false,"messageTitle":"Fix bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e71dfe7f219f8dcdc385475eb196134357b034d2","isMergeCommit":false,"messageTitle":"Update checkstyle and bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":32}}},{"hash":"8282651831ac89ea5bd21b6e3ae135657e23b58d","isMergeCommit":false,"messageTitle":"Fix Checkstule and add junit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":33,"deletions":10}}},{"hash":"0f6bef8cfb7199386649eb10fc90a92793488784","isMergeCommit":true,"messageTitle":"Merge pull request #133 from yingx9/YingXia-UpdateArchitectureDiagram","messageBody":"Update Overall Architecture Diagram for Storage and Data component","fileTypesAndContributionMap":{}},{"hash":"c03d25ace975ed9a6d9e202e32641d7736cf1703","isMergeCommit":true,"messageTitle":"Merge pull request #134 from yingx9/YingXia-UpdateListStatusFiltering","messageBody":"Add Filter by Status for List Command and fix logging for List, Edit","fileTypesAndContributionMap":{}},{"hash":"fea31f29a20b036e7ad232fdec4d66c616c55c7b","isMergeCommit":false,"messageTitle":"Fix whitespace visual bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":14}}}]}],"bnjm2000":[{"date":"2023-10-09","commitResults":[{"hash":"efad7d965c627a182d0c515fbcf8bd652d5f7b75","isMergeCommit":false,"messageTitle":"Add Benjamin-AboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":6}}}]},{"date":"2023-10-11","commitResults":[{"hash":"11fbaf7ff4a1c16bd6e857e1bfd19094d43fbfb9","isMergeCommit":false,"messageTitle":"Add portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":0}}},{"hash":"f98ad3ecdb9bf4a008479b664430633fe6aee154","isMergeCommit":false,"messageTitle":"Fix portfolio link","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-14","commitResults":[{"hash":"ff6ecc4e701b239a826fcd503989cca981a38809","isMergeCommit":false,"messageTitle":"Add portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":9}}},{"hash":"c5bb57406ed0171f9b20242b11d01e4955ec7839","isMergeCommit":true,"messageTitle":"Merge pull request #25 from AY2324S1-CS2113T-W11-1/WuXingyu-Resource","messageBody":"Add Resource class","fileTypesAndContributionMap":{}},{"hash":"fee0f659873ca0be326386c791db3e379df73714","isMergeCommit":false,"messageTitle":"Add HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":1}}},{"hash":"a01128ec5feae99924bb3c327d94bba7e5d9a31d","isMergeCommit":false,"messageTitle":"Fix ExitCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":3}}},{"hash":"243fa1457017b73e4edbd1929fadadd779e2de01","isMergeCommit":false,"messageTitle":"Changed unknown command message.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"3806b18ebb2a19a8bb7a2012027cda0f2f705459","isMergeCommit":false,"messageTitle":"Moved help message to UI class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":8}}},{"hash":"4f172b206ce42c544432438b8384906a12d5dc98","isMergeCommit":true,"messageTitle":"Merge pull request #29 from yingx9/YingXia-UpdateListCommand","messageBody":"Update ListCommand and edit Resource and Book","fileTypesAndContributionMap":{}},{"hash":"8d3ec47b216a8ecce72971e1286cd5c7816e3e0d","isMergeCommit":false,"messageTitle":"Changed syntax to \"exit\" and updated test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}}]},{"date":"2023-10-15","commitResults":[{"hash":"41e96d180eea8819810b89f4972503658bc58533","isMergeCommit":true,"messageTitle":"Merge pull request #31 from JoanneJo/JoanneAng-AddCommand","messageBody":"Update AddCommand.java and Add SysLibException.java","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"7ff86171a0fd13c77b3cf121db7fe6884d0b3d86","isMergeCommit":false,"messageTitle":"Add Junit testing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"test-code":{"insertions":183,"deletions":0}}},{"hash":"b567bf5aa32fe02c4fd1dfb89a7015f775c830c5","isMergeCommit":false,"messageTitle":"Add more Junit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":75,"deletions":2}}},{"hash":"307dadb3f1cadb6f4656b5a341d45ea46c7e249a","isMergeCommit":false,"messageTitle":"Fix checkstye","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":26,"deletions":17}}},{"hash":"86cf0bf0f325391532da1bcc682d06a7ad6362d6","isMergeCommit":false,"messageTitle":"Fix checks not working on Windows","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":35,"deletions":33}}},{"hash":"d6f62f5ccc65e022901ad84f3267897d80378000","isMergeCommit":true,"messageTitle":"Merge pull request #39 from yingx9/YingXia-UpdateUserGuide","messageBody":"Update UserGuide.md for List and minor change to ListCommand","fileTypesAndContributionMap":{}},{"hash":"bae7e026d74680fe4a0047fa954ce271f2bffaba","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into add_Junit","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Update UserGuide.md for List and minor change to ListCommand\n","fileTypesAndContributionMap":{}},{"hash":"3e910fc9d53b77f127940bc75640b25da44f6808","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":13,"deletions":13}}},{"hash":"db5883414825e7a5e441ce1878551dd7d555d7d2","isMergeCommit":false,"messageTitle":"Fix comment indentation","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":11,"deletions":11}}},{"hash":"83d05e7e51521c14924622be0f8d0597145b6eb5","isMergeCommit":false,"messageTitle":"Fix Try #1","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":11,"deletions":11}}},{"hash":"a81d766d11a375879c1f602842828531a8604d25","isMergeCommit":false,"messageTitle":"Add TestUtil and corrected Junit","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":40,"deletions":3}}},{"hash":"48875226e1bf55b48404da72ad34eab3eec785d4","isMergeCommit":true,"messageTitle":"Merge pull request #40 from yingx9/YingXia-UpdateListPrinting","messageBody":"Update ListCommand to use lineSeparator() and add more checks","fileTypesAndContributionMap":{}},{"hash":"affd9379953ddff889923ab527eedcb8736d6536","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":6}}},{"hash":"08a718177bfc3197280e2e6a5f1b74c34478186e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into add_Junit","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Fix lines to not exceed 120 characters for coding standard\n Update ListCommand to use lineSeparator() and add more checks\n","fileTypesAndContributionMap":{}},{"hash":"dda3ca33533312deceb333e38d5eb526948abdb1","isMergeCommit":false,"messageTitle":"Fix windows error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":2}}},{"hash":"e47ca19cf52aedb1ee571f7ae8ac7cae8fe4717d","isMergeCommit":false,"messageTitle":"Fix Windows error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"04906e63ebf2b3be29a4f8cd076683ee9d5777f6","isMergeCommit":false,"messageTitle":"Fix windows error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":1,"deletions":1}}},{"hash":"09ad6907d3798658b4b35994f88bd432abb995b9","isMergeCommit":false,"messageTitle":"Fix failed test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"a378b1122c47e5682c500f7615e125ef6e580665","isMergeCommit":false,"messageTitle":"Fix code to have better consistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":20},"test-code":{"insertions":30,"deletions":16}}},{"hash":"4586311a7acee699ecf66d65ab4402c569af92f3","isMergeCommit":true,"messageTitle":"Merge pull request #41 from yingx9/YingXia-AddListCommandTest","messageBody":"Add jUnit tests for ListCommand","fileTypesAndContributionMap":{}},{"hash":"0d98a06f824e5fa388728e538a12933f4cb95efb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg_consistency","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Update EXPECTED.TXT and input.txt for testing\n Fix windows error\n Fix check style error\n Add jUnit tests for ListCommand\n","fileTypesAndContributionMap":{}},{"hash":"816feeda7fb4686d2872e332338372a28eb35064","isMergeCommit":false,"messageTitle":"Fix checks after merge","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":3},"test-code":{"insertions":21,"deletions":5}}},{"hash":"2d31c5b83d50f5c0c1cca48f588661ac6a44e6d0","isMergeCommit":false,"messageTitle":"Fix failed test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"1171880f0dfcbe51c57f3c8c2ed253170606ea19","isMergeCommit":false,"messageTitle":"Fix failed checks","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-17","commitResults":[{"hash":"97bad5aea57f5f451ee8ca636e72807e15defeb3","isMergeCommit":false,"messageTitle":"Fix helpCommand to be consistent with UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":5},"docs":{"insertions":1,"deletions":1},"test-code":{"insertions":19,"deletions":13}}},{"hash":"969c6d2ed053ae8345ad0b5367f9ff113879b550","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg_FixHelpCommand","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Fix failed checks\n Fix failed test\n Fix checks after merge\n Fix code to have better consistency\n\n# Conflicts:\n#\tsrc/main/java/seedu/ui/UI.java\n#\tsrc/test/java/seedu/commands/HelpCommandTest.java\n#\tsrc/test/java/seedu/parser/ParserTest.java\n#\ttext-ui-test/EXPECTED.TXT\n","fileTypesAndContributionMap":{}},{"hash":"7f270f77a3b68d595ddb92c68f1aa96dc0e3c1f8","isMergeCommit":false,"messageTitle":"Fix merge conflicts","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":10},"test-code":{"insertions":0,"deletions":24}}},{"hash":"b44806541a1a31074bc32d9a7f54bc3b3daa2ff1","isMergeCommit":true,"messageTitle":"Merge pull request #45 from yingx9/YingXia-FixNullGenreBug","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"256dfd39999328567020cbfe6bbcff0b4730de0b","isMergeCommit":true,"messageTitle":"Merge pull request #46 from yingx9/YingXia-UpdateListGenre","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"effcd9da28de13988cba3b1caab69dd2f2e5b1bd","isMergeCommit":true,"messageTitle":"Merge pull request #51 from yingx9/YingXia-AddListCommandAssertion","messageBody":"Add assertion to ensure ListCommand works as intended","fileTypesAndContributionMap":{}},{"hash":"1e6825dff3c2f6d0aae77ec5048dac06227f015e","isMergeCommit":true,"messageTitle":"Merge pull request #53 from 000verflow/Add-Assertions-Logging-FindCommand","messageBody":"Add logging and java assertions to FindCommand class","fileTypesAndContributionMap":{}},{"hash":"3733b72dc6d2b395228ddd7a872b80f5686f534c","isMergeCommit":false,"messageTitle":"Add assert and logging","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":64,"deletions":4}}}]},{"date":"2023-10-26","commitResults":[{"hash":"5016c2e6074261fc5964ddfff0f7eb27d96cd571","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":56,"deletions":12}}},{"hash":"fe18b54784d8ad6cefddd54f43b9dfc4d95e44bd","isMergeCommit":false,"messageTitle":"Add help and bye manual testing","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":1}}},{"hash":"226408b08990865f86550c15a9c1128e24490679","isMergeCommit":true,"messageTitle":"Merge pull request #75 from yingx9/YingXia-UpdateListDG","messageBody":"Update ListCommand and List Implementation of DG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"14d7e50a5215ff6e3dfed92188ced624a631017c","isMergeCommit":false,"messageTitle":"Add updates to UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":96,"deletions":27}}},{"hash":"85830a26ef52ffe6b1b646cdad9d13b8fc6da1d5","isMergeCommit":false,"messageTitle":"Add update to UG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}}]},{"date":"2023-10-30","commitResults":[{"hash":"c2b327b5d0eb6132cb650ca8fb601da6319d286c","isMergeCommit":true,"messageTitle":"Merge pull request #85 from DavinciDelta/UpdateDelete","messageBody":"Fix and optimize testing for deleteCommand","fileTypesAndContributionMap":{}},{"hash":"bddbb6a6283e91042b12575f6b52a6f2b870d3bd","isMergeCommit":false,"messageTitle":"Add status to resources","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":12},"test-code":{"insertions":8,"deletions":6}}},{"hash":"9d5b57ba2e652d2b8a43eb19696db53a74721a78","isMergeCommit":true,"messageTitle":"Merge pull request #86 from yingx9/YingXia-AddEditCommand","messageBody":"Add EditCommand feature and update User Guide","fileTypesAndContributionMap":{}},{"hash":"278383095f4e21a739564c4e86cc0b65a2b9af1d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-Status","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Add EditCommand feature and update User Guide\n\n# Conflicts:\n#\tsrc/test/java/seedu/util/TestUtil.java\n","fileTypesAndContributionMap":{}},{"hash":"6c628cb61110d19475a8126447270e4837e6cd22","isMergeCommit":false,"messageTitle":"Update checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":10},"test-code":{"insertions":32,"deletions":20}}},{"hash":"4df06510418b576b5cd23c0388c3b19a999354d9","isMergeCommit":false,"messageTitle":"Add ability to update status of resource","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":5}}},{"hash":"15339b7431aa899a49c0ae4d376b5c32f0aa89a0","isMergeCommit":false,"messageTitle":"Add tests to include edit and status","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":19,"deletions":1}}},{"hash":"5378ba72254e090bc51a7073869e0682f251bd28","isMergeCommit":false,"messageTitle":"Fix test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":0,"deletions":3}}},{"hash":"6c54dd4aa2508dc4600f921ab17b2f8f18c148ed","isMergeCommit":false,"messageTitle":"Fix test pt. 2","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"13f1d9ee05d8f9a44438b0bdff0a131d77cfbb82","isMergeCommit":false,"messageTitle":"Update UG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":21,"deletions":13}}},{"hash":"e173c4f27ac84aba84f7aafb8f41290f23818aa6","isMergeCommit":false,"messageTitle":"Update UG, DG and Help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"docs":{"insertions":8,"deletions":6}}},{"hash":"160d8db2cca4d2559840c2cff09496e31834b8db","isMergeCommit":false,"messageTitle":"Update test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":5}}}]},{"date":"2023-10-31","commitResults":[{"hash":"233f4332d723c7b18f792e9ae26e441341dde5d7","isMergeCommit":false,"messageTitle":"Fix incorrect return in parser for Status","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":10},"test-code":{"insertions":29,"deletions":4}}},{"hash":"1a4a8fc56a3e3bdd587f0b7123c14dde90e8e3ff","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-FixParser-Status","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Add variable dateReceived to Resource\n Update Command\n\n# Conflicts:\n#\tsrc/test/java/seedu/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"32a9064cd67828909f1c2e6f5f7c4e7e6c1fa85c","isMergeCommit":true,"messageTitle":"Merge pull request #94 from DavinciDelta/EventCalendar","messageBody":"Add event commands","fileTypesAndContributionMap":{}},{"hash":"e2f72c400534d8afe11d3cf6b0c64efb77b8eed0","isMergeCommit":true,"messageTitle":"Merge pull request #97 from DavinciDelta/EventTesting","messageBody":"Add testing for event commands","fileTypesAndContributionMap":{}},{"hash":"b8f584c61da81bd0893d555f16bab5c300f15457","isMergeCommit":false,"messageTitle":"Fix logs for help and exit command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":2}}},{"hash":"361e044d77d6d1c923e5e31b795ce97dfa12e20c","isMergeCommit":false,"messageTitle":"Fix bugs and add consistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":77}}},{"hash":"779d13452030ccbb65b0016c0edda4e67518ba85","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-FixLogsandEnhancements","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Add testing for event commands\n\n# Conflicts:\n#\tsrc/main/java/seedu/commands/Command.java\n","fileTypesAndContributionMap":{}},{"hash":"084450cd5b80ad4b840e2b06c563ece7ec62c887","isMergeCommit":true,"messageTitle":"Merge pull request #99 from 000verflow/fix-FindCommandBug","messageBody":"Fix findCommand assertion issue","fileTypesAndContributionMap":{}},{"hash":"2f075fae15eed26fb85e3d0ce499461a594a5490","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-FixLogsandConsistency","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Fix findCommand assertion issue\n","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"2ab2554311e1141f32c6f3c769ee9db9cdf0c256","isMergeCommit":true,"messageTitle":"Merge pull request #98 from JoanneJo/JoanneAng-AddResources","messageBody":"Add Different Types of Resources","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"e103ca2c36321db6d7b34008649118f629f452d6","isMergeCommit":true,"messageTitle":"Merge pull request #104 from 000verflow/add-findsequencediagram","messageBody":"","fileTypesAndContributionMap":{}}]}],"JoanneJo":[{"date":"2023-10-04","commitResults":[{"hash":"d4b23856f14360e5e02b8b48f1fa8d867104aa99","isMergeCommit":false,"messageTitle":"Add personal details to AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-05","commitResults":[{"hash":"74ce9366bfeba2e78b22b08db06017a574898712","isMergeCommit":false,"messageTitle":"Update AboutUs.md and Add JoanneAng.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-15","commitResults":[{"hash":"6642630870c3a7e6899d35768f20336136f8ba75","isMergeCommit":false,"messageTitle":"Update AddCommand.java and Add SysLibException.java","messageBody":"Updated UserGuide.md so that all commands are\nusing the same tags for the same type of data.\nUI.java is therefore edited to standardize the\nhelp message.\n\nModified Book.java to remove synopsis from the\nobject and add genres. toString() is modified to\ndisplay genres.\n\nImplemented the add command to add books to the\nresource list. Validated user input for add command.\n\nChanged the naming of taskList to resourceList and\nadded SysLibException.java. Hence, edited\nCommand.java, DeleteCommand.java, ListCommand.java,\nand Parser.java.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":102,"deletions":39},"docs":{"insertions":33,"deletions":26}}},{"hash":"97f427ecac516acd184a6a24eb9aa5a62c8bd731","isMergeCommit":false,"messageTitle":"Update Book.java, AddCommand.java, and Parser.java","messageBody":"Updated to pass the checks.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"a6eb7919209e44ae45ed5fdab02d2447a377ddcd","isMergeCommit":false,"messageTitle":"Add Tag Function","messageBody":"Added tag function to identify and specify the\ntype of resources added.\n\nModified parseAddCommand method to be more generic.\nAdded parsing and validation methods for adding\nbooks.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":105,"deletions":59},"docs":{"insertions":2,"deletions":2}}},{"hash":"eb76d7512bd86add4df324bc90fb72ccb28a838c","isMergeCommit":false,"messageTitle":"Update AddCommand.java and Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":6}}},{"hash":"0d7af8aebc811a4ff9b851c0e322996edf43dc96","isMergeCommit":false,"messageTitle":"Update UserGuide.md and Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":2,"deletions":2}}}]},{"date":"2023-10-16","commitResults":[{"hash":"834fcdd733a92644b85cc8a507de7bbfd736d321","isMergeCommit":true,"messageTitle":"Merge pull request #35 from DavinciDelta/WuXingyu-DeleteCommand","messageBody":"Add Delete Command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"38a8d4706b95c1b71e8ed427ef64e64b0448d972","isMergeCommit":true,"messageTitle":"Merge pull request #49 from 000verflow/Add-FindCommandTest","messageBody":"Add Junit tests for FindCommand","fileTypesAndContributionMap":{}},{"hash":"3dc4400af9db7c3713fa071647fb9d32baf5181d","isMergeCommit":true,"messageTitle":"Merge pull request #50 from DavinciDelta/WuXingyu-DeleteTesting","messageBody":"Add DeleteCommand Testing","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"dd157775f08701fc6a2945c72d7ddd4eccb29665","isMergeCommit":true,"messageTitle":"Merge pull request #55 from yingx9/YingXia-UpdateListCommandParsing","messageBody":"Update logic and code quality of ListCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"ed7a3cc3a2b98b526a8b2901e6eac90a58555271","isMergeCommit":false,"messageTitle":"Add AddCommand JUnit Tests","messageBody":"Added addCommand JUnit tests to AddCommandTest.java.\nUpdated Book.java and Parser.java.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0},"test-code":{"insertions":58,"deletions":0}}},{"hash":"2c2e658a363c148a823aa30b74af030c1015aace","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":3}}}]},{"date":"2023-10-26","commitResults":[{"hash":"68271b08f8aa57213e668aef11dd07b64b33fb19","isMergeCommit":true,"messageTitle":"Merge pull request #71 from yingx9/YingXia-DGPlantUml","messageBody":"Repurpose style, architecture.puml from Addressbook","fileTypesAndContributionMap":{}},{"hash":"c83c8d24dbe24a1d92dfa2a5cc07c32ce8ea3e53","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"Added on to the developer guide and included parts\nfor the add feature.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5},"docs":{"insertions":172,"deletions":3}}}]},{"date":"2023-10-30","commitResults":[{"hash":"fa1e27bab9f27569ed12f4449a81d7fdf67cc106","isMergeCommit":true,"messageTitle":"Merge pull request #87 from bnjm2000/BenjaminNg-Status","messageBody":"Add Status to resources","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"c21709d7786a977da3bc595ff3fd93b0238eaf85","isMergeCommit":false,"messageTitle":"Add Different Types of Resources","messageBody":"Added eBook, CD, magazine, eMagazine, newspaper,\nand eNewspaper in addition to Book.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":384,"deletions":45},"docs":{"insertions":79,"deletions":2},"test-code":{"insertions":4,"deletions":2}}},{"hash":"513bba7872e7747d34ef2452b48ab5743853ae4e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JoanneAng-AddResources","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d45d1eaba41245eee2fc96316714f5bebc4dc67c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JoanneAng-AddResources","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"578246843230c6c009201b8b0fafd62fb3ef52d4","isMergeCommit":false,"messageTitle":"Update User Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a6298f27bd20473ad70e03620a26ca3868c44791","isMergeCommit":false,"messageTitle":"Update Resource.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"a567cf3f042985fd3a873291de03de783cb7376f","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}}]},{"date":"2023-11-01","commitResults":[{"hash":"3a5f5cfaedbc2b1262aefa66fb0a61be4c24925b","isMergeCommit":false,"messageTitle":"Update CD.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"765376c1d1ec2e81f67a88e406451ce4a8024f65","isMergeCommit":false,"messageTitle":"Update TestUtil.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":1,"deletions":1}}},{"hash":"e30e7898a6fbbbad0828439858d4bad44b0f99c6","isMergeCommit":false,"messageTitle":"Update TestUtil.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"5f77e875ed27edef3f60722b0d7b8d531531d807","isMergeCommit":true,"messageTitle":"Merge branch \u0027JoanneAng-AddResources\u0027 of https://github.com/JoanneJo/tp into JoanneAng-AddResources","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/data/CD.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"5f32227f04d464b9e0022a870672df9856395b73","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into JoanneAng-AddResources","messageBody":"# Conflicts:\n#\tdocs/UserGuide.md\n","fileTypesAndContributionMap":{}},{"hash":"00c03daa239bea155e1c253244c2846478317ac8","isMergeCommit":false,"messageTitle":"Update UserGuide.md and Refactor Classes","messageBody":"Refactored classes so they start with capital letters.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":17},"other":{"insertions":6,"deletions":6},"docs":{"insertions":4,"deletions":5}}},{"hash":"9d799d13c225b9d38bd1eed70390f093cf12d127","isMergeCommit":true,"messageTitle":"Merge pull request #110 from DavinciDelta/master","messageBody":"Update UG for events","fileTypesAndContributionMap":{}},{"hash":"0d3848c67d1dea9145549125e7ecb977b595f772","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JoanneAng-AddResources","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fa9f4d46962d793413ef03501cc58d3a3253f9d6","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":24},"docs":{"insertions":85,"deletions":8}}},{"hash":"1a86cb7137e89762bd751186a413657d43512b0b","isMergeCommit":false,"messageTitle":"Refactor Classes","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"42154a761604ff99485c8fdcc91ff90b811f1d37","isMergeCommit":true,"messageTitle":"Merge pull request #103 from DavinciDelta/UpdateGuides","messageBody":"Update guides","fileTypesAndContributionMap":{}}]}],"DavinciDelta":[{"date":"2023-10-05","commitResults":[{"hash":"20d84b8a2deaed74e86d4c49ff90766db2fd1d7d","isMergeCommit":false,"messageTitle":"Add AboutUs","messageBody":"Included my own about us\n","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":1}}}]},{"date":"2023-10-13","commitResults":[{"hash":"f816d329501fbc059fac7bc29b8449c0aa6d39ff","isMergeCommit":false,"messageTitle":"Basic abstract Command","messageBody":"Included the basic abstract command for reference, with delete code implemented\n","fileTypesAndContributionMap":{"functional-code":{"insertions":117,"deletions":0}}},{"hash":"c97d2cec899d51e82fa979133c029d496a59bb91","isMergeCommit":false,"messageTitle":"Revert \"Basic abstract Command\"","messageBody":"This reverts commit f816d329501fbc059fac7bc29b8449c0aa6d39ff.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":117}}}]},{"date":"2023-10-14","commitResults":[{"hash":"66cb8f164903cc7b8dd1c4e2f37449f49b783a53","isMergeCommit":true,"messageTitle":"Merge pull request #19 from yingx9/WuXingYu-BasicStructure","messageBody":"Add XingYu\u0027s Command and Parser from iP project","fileTypesAndContributionMap":{}},{"hash":"fae2e8bde57a2bcdca664f910751520047b3cb86","isMergeCommit":false,"messageTitle":"Add resource","messageBody":"Include resource class with book class.\n\nInclude basic add and list commands for testing\n","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":3}}},{"hash":"d168a5972836ae6563d2c2ff0f4dc4500e17bfb8","isMergeCommit":true,"messageTitle":"Merge from master","messageBody":"Include changes from master\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"18ae4568148b6a244a6954b2d645a6396383d92e","isMergeCommit":false,"messageTitle":"Add Delete Command","messageBody":"Added the delete command with it\u0027s parser\n","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":8}}}]},{"date":"2023-10-17","commitResults":[{"hash":"4b21bf920d2abd9b8d5ca763b6cb16a40a87e5ff","isMergeCommit":false,"messageTitle":"Add general validate and parse function","messageBody":"Include a validate and parse function that can be used for all command to decrease complexity of code\n","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":3}}},{"hash":"460604675bb122c09dd57d41481aad943423a7d2","isMergeCommit":false,"messageTitle":"Remove print statements","messageBody":"Remove debugging print statements\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"9c24aadd4353ff76d44e33afc61d3d758704f474","isMergeCommit":false,"messageTitle":"Update Command","messageBody":"Remove redundant code and improve style\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"4d4e242a5a8b83bfae05457a81c2ae027d999c3b","isMergeCommit":false,"messageTitle":"Add DeleteCommand Testing","messageBody":"Included J unit testing for DeleteComand\n","fileTypesAndContributionMap":{"test-code":{"insertions":46,"deletions":0}}},{"hash":"862395cfe14800213003b307dcf087084245681f","isMergeCommit":false,"messageTitle":"Update DeleteCommandTest.java","messageBody":"Updated DeleteCommandTest\n","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":17}}},{"hash":"92e2f73b5371af344b6816b12e4013c4800300e6","isMergeCommit":false,"messageTitle":"Remove redundant imports","messageBody":"Removed redundant imports to improve clarity\n","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":2}}},{"hash":"360606f9d100648710f69f6c9b8ed59e9da91041","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into WuXingyu-ParsingAbstraction","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"dae3e42c416444c4b6515a99bdb72c4b35e06356","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into WuXingyu-ParsingAbstraction","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"29d5789812c41805fbd1bab9a073d8baa2881793","isMergeCommit":false,"messageTitle":"Update validate and parsing","messageBody":"Update parsing into abstract Command class\n","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":27}}},{"hash":"7b07b79090bec34138f9cd269e9a17594cd4994c","isMergeCommit":false,"messageTitle":"Update style","messageBody":"Remove redundant imports\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"e2f835aeff05274f1bc1177563fd2ab439494762","isMergeCommit":false,"messageTitle":"Update AddCommand","messageBody":"Changed AddCommand isbn to i\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"bd37b380149d2f2f85f500c4d6da73dbe40e3fc3","isMergeCommit":false,"messageTitle":"Update genre","messageBody":"Change genre for add command\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"2240d9c6cdeaa91c620056f02f8f3af007701523","isMergeCommit":false,"messageTitle":"Improve validation","messageBody":"Included more validation checks for duplicate arguments\n\nAllow for aliasing for arguments\n","fileTypesAndContributionMap":{"functional-code":{"insertions":62,"deletions":15}}},{"hash":"da37d39f6e07a7a4d0171c5109158a737e7e91b0","isMergeCommit":false,"messageTitle":"Fix validator","messageBody":"Prevent clash of metacharacters in strings and capital letters with validator\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-23","commitResults":[{"hash":"9ca77c1f5398f3ee3e36892e95d939757a18b035","isMergeCommit":true,"messageTitle":"Merge pull request #65 from JoanneJo/JoanneAng-AddCommandJUnit","messageBody":"Add AddCommand JUnit Tests","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"f1c67d44a0c3306c28b454edfa5cc578ae3b17d9","isMergeCommit":true,"messageTitle":"Merge pull request #66 from yingx9/YingXia-EnableAssertion","messageBody":"Enable assertions in Gradle","fileTypesAndContributionMap":{}},{"hash":"fcbdbe6b9e56b76f011dd1383e5ebf1fd8d11eb6","isMergeCommit":false,"messageTitle":"Include assertion in DeleteCommand","messageBody":"Include a generic assertion for deleteCommand\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"c90927f278161ceb6bd90171ff4431ab5a81ddb7","isMergeCommit":true,"messageTitle":"Merge branch \u0027AddAssertion\u0027 into UpdateDeveloperGuide","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"85745dae00595ea292ea6bbc4b30c74c43f49ba0","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"Update the developer guide with the basic information\n","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":6}}}]},{"date":"2023-10-29","commitResults":[{"hash":"2a5c864c957d6ece547a674e1a9421c93155edc1","isMergeCommit":false,"messageTitle":"Fix and optimize testing for deleteCommand","messageBody":"Fix issue with delete where blank spaces causes an error\n\nImprove testing for DeleteCommand\n\nRemove unnecessary DeleteParser\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":27},"test-code":{"insertions":23,"deletions":32}}},{"hash":"6197ad013d13fa5b31d2a2d00e25493003ed5336","isMergeCommit":false,"messageTitle":"Remove unnecessary imports","messageBody":"remove data.book import from DeleteCommandTest\n","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"8eade84e05818203e4210c7f4a3b34f20b06e1a8","isMergeCommit":false,"messageTitle":"Fix issue with ParserTest","messageBody":"Introduce spacing for DeleteCommand and DeleteCommand test\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":1,"deletions":1}}},{"hash":"5676b7283ee33a09a617ee0530fd248ab053bc32","isMergeCommit":false,"messageTitle":"Update DeleteCommandTest.java","messageBody":"Update to improve style\n","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":4}}}]},{"date":"2023-10-31","commitResults":[{"hash":"99da8760a329363221b0d617f64b9541bd4c4803","isMergeCommit":false,"messageTitle":"Update Command","messageBody":"Remove aliasing and improved Variable names\n\nIncluded comments to improve readability\n","fileTypesAndContributionMap":{"functional-code":{"insertions":46,"deletions":42}}},{"hash":"88154068160914f8a7f20451d30d773b0afadab0","isMergeCommit":false,"messageTitle":"Add event commands","messageBody":"Add eventadd, eventlist and eventdelete commands to support keeping track of events\n\nEvent list is sorted by date\n","fileTypesAndContributionMap":{"functional-code":{"insertions":160,"deletions":2},"test-code":{"insertions":4,"deletions":0}}},{"hash":"33237ca1c19a03702b7ddcc5ad7d74dedbc7677d","isMergeCommit":false,"messageTitle":"Update event list variable name","messageBody":"Change variable name calendar into eventList to keep it consistent\n","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":11}}},{"hash":"699dfdd0a6cad228afbc568c9db6364f6b20c16e","isMergeCommit":false,"messageTitle":"Update ParserTest.java","messageBody":"Update ParserTest to include events in testProcessHelpCommand\n","fileTypesAndContributionMap":{"test-code":{"insertions":6,"deletions":1}}},{"hash":"135648c5a1b3eb4c149a07312cad94b2f064c45f","isMergeCommit":false,"messageTitle":"Add testing for event commands","messageBody":"Add testings for eventAdd, eventDelete, eventList\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":141,"deletions":0}}}]},{"date":"2023-11-01","commitResults":[{"hash":"0fad88e6ebdf13fbde509b55038c99279c59320c","isMergeCommit":false,"messageTitle":"Add event into DG and UG","messageBody":"Add information of events into DG and UG\n","fileTypesAndContributionMap":{"docs":{"insertions":165,"deletions":2}}},{"hash":"17697dbcbe1634948e82983a3984b1f8c14af707","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"Update DG for events\n","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":10}}}]},{"date":"2023-11-03","commitResults":[{"hash":"54b0afea991b33346395c519713d5072f8222727","isMergeCommit":false,"messageTitle":"Update UG for events","messageBody":"Update User Guide to include features for events, such as eventadd, eventlist nad eventdelete\n","fileTypesAndContributionMap":{"docs":{"insertions":80,"deletions":7}}},{"hash":"3d0862f6b459dcdd774310894c5e10f08b5e12a0","isMergeCommit":true,"messageTitle":"Merge pull request #111 from JoanneJo/JoanneAng-AddResources","messageBody":"Update UserGuide.md and Refactor Classes","fileTypesAndContributionMap":{}},{"hash":"5b2ec1f460d1665c04570194aa73e02f94eae002","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into UpdateGuides","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ec596924e9f1848fa261ff9200f7786faf63a73c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into UpdateGuides","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"13e735d0c0977dd744c19c167592cfc8dbaf548a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"Update userguide to remove overlap and redundant informations\n","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":15}}}]}],"yingx9":[{"date":"2023-10-04","commitResults":[{"hash":"d2a39c983b779d162587aa54cdcc043d19acb42b","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}}]},{"date":"2023-10-05","commitResults":[{"hash":"b1a23ae973590faec4fa49548e661798cddc354c","isMergeCommit":false,"messageTitle":"Update AboutUs.md and add Portfolio Page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}}]},{"date":"2023-10-11","commitResults":[{"hash":"34113bf6369cf3e72c81bad632b546565825c15e","isMergeCommit":true,"messageTitle":"Merge pull request #1 from JoanneJo/JoanneAng-AboutUs","messageBody":"Add personal details to AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"24a54a13e9bff5754c97196f670acb1db3f9c3fe","isMergeCommit":false,"messageTitle":"Add code from AddressBook","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1937,"deletions":0}}},{"hash":"4c73795256c18d337edb3cd0d8fd6e5e95854417","isMergeCommit":true,"messageTitle":"Merge pull request #16 from yingx9/YingXia-AddressBook","messageBody":"Add code from AddressBook","fileTypesAndContributionMap":{}},{"hash":"8fdb83fc66cf61cec1707849a12140f63547934c","isMergeCommit":false,"messageTitle":"Add XingYu\u0027s Command and Parser from iP project","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":125,"deletions":0}}},{"hash":"bffe4d35fbfddbd14885722e201bf230cd6a9453","isMergeCommit":false,"messageTitle":"Update ListCommand and edit Resource and Book","messageBody":"As Resource is a generic class, Book can inherit and override\ntoString to print its own specific details\n\nHence,\nResource.java: Add toString method to be overridden by Book\nBook.java: Override parent toString method\n","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":5},"docs":{"insertions":1,"deletions":1}}},{"hash":"6dcad7eeea645efabb2c7991d22053542764e697","isMergeCommit":true,"messageTitle":"Merge pull request #27 from bnjm2000/add_HelpCommand","messageBody":"Add HelpCommand","fileTypesAndContributionMap":{}},{"hash":"8ebfcaf95769d42cdf6ff8effed30582b2abbf09","isMergeCommit":true,"messageTitle":"Merge pull request #28 from bnjm2000/add_ExitCommand","messageBody":"Add ExitCommand","fileTypesAndContributionMap":{}},{"hash":"8336568d113cb4e16f4c7936c6d8254bc5d4ec2f","isMergeCommit":true,"messageTitle":"Merge pull request #30 from bnjm2000/add_ExitCommand","messageBody":"Change syntax to \"exit\" and updated test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"8365f041ce1578f5258123ae6f612456b752747f","isMergeCommit":true,"messageTitle":"Merge pull request #32 from 000verflow/Add-FindCommand","messageBody":"Add FindCommand class","fileTypesAndContributionMap":{}},{"hash":"e961ad179fefc5fe022232e8efaf73bbb1065a45","isMergeCommit":false,"messageTitle":"Update Listing by specific filters for ListCommand.Java","messageBody":"Librarians may want an overview of resources by categories such\nas tag and genre\n\nHence, add filter methods to ListCommand to filter by Tag, Genre,\nor Both\n","fileTypesAndContributionMap":{"functional-code":{"insertions":139,"deletions":8}}}]},{"date":"2023-10-16","commitResults":[{"hash":"ce80c867361f341512178783328995160bb24ca5","isMergeCommit":false,"messageTitle":"Update UserGuide.md for List and minor change to ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4},"docs":{"insertions":11,"deletions":8}}},{"hash":"8c30d1ef8dbba12f7d7807c9c6c3809726b2e1d4","isMergeCommit":false,"messageTitle":"Update ListCommand to use lineSeparator() and add more checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":11}}},{"hash":"ed23a422c3bc47ee6e56abb377be77f13c27e4bc","isMergeCommit":false,"messageTitle":"Fix lines to not exceed 120 characters for coding standard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"69362cc4634c29603bcee3690e6ac5cf11f530c8","isMergeCommit":true,"messageTitle":"Merge pull request #38 from bnjm2000/add_Junit","messageBody":"Add Junit","fileTypesAndContributionMap":{}},{"hash":"4e21bd1fc5c7dcf2ef84b90dd6e05e481e5b48f3","isMergeCommit":false,"messageTitle":"Add jUnit tests for ListCommand","messageBody":"To ensure ListCommand is works as intended, add tests such as:\n1. Ensure list does not crash SysLib if executed when there are no\nresources\n2. Ensure missing values for tag and genre filter throws exception\n3. Ensure listing with filters does not crash SysLib if there are\nno found resources matching filters\n","fileTypesAndContributionMap":{"test-code":{"insertions":101,"deletions":0}}},{"hash":"b62afec7114450326fdb9237456383a9845f62dd","isMergeCommit":false,"messageTitle":"Fix check style error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":13}}},{"hash":"871ae927c0777d5e302d720cf8a377459bac1304","isMergeCommit":false,"messageTitle":"Fix windows error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":2}}}]},{"date":"2023-10-17","commitResults":[{"hash":"446c9c1b9d6b76ce5b9b366d67eba021b3075894","isMergeCommit":true,"messageTitle":"Merge pull request #42 from bnjm2000/BenjaminNg_consistency","messageBody":"Fix consistency","fileTypesAndContributionMap":{}},{"hash":"61bca2d384d09bf9fce54fd2e5a13fa913fb028b","isMergeCommit":false,"messageTitle":"Fix bug where listing by genre crashes SysLib","messageBody":"When a book is added without a genre, SysLib crashes when listing\nby genre\n\nHence add a check to hasGenre method to return false when a book has\nno genre\n\nNote in future developments, if createBook changes its method of\ncreating genres array, this fix has to be updated\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0},"test-code":{"insertions":4,"deletions":1}}},{"hash":"8efd8319a62d5e716070bf29aadaa27690a176de","isMergeCommit":true,"messageTitle":"Merge pull request #44 from bnjm2000/BenjaminNg_FixHelpCommand","messageBody":"Fix HelpCommand","fileTypesAndContributionMap":{}},{"hash":"94f1c1b220672138c830e6ab79721ce84c1eb3da","isMergeCommit":false,"messageTitle":"Fix bug where multiple genres causes list filter to not work","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":7}}},{"hash":"7277e0d587c97e762d22c5a1e829b859b648b9b8","isMergeCommit":false,"messageTitle":"Update method of checking genre again for ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4}}},{"hash":"ea49ab338b61b8cf5cdb56c7e4b3679a1b1a91b7","isMergeCommit":false,"messageTitle":"Add assertion to ensure ListCommand works as intended","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"5eb00e5f0f4e350a35924a1cb0fe5faa6d6201e6","isMergeCommit":true,"messageTitle":"Merge pull request #54 from bnjm2000/BenjaminNg_addAssertandLogging","messageBody":"Add assert and logging for HelpCommand and ExitCommand","tags":["v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"d25c9b66e18042f05cf523e9875bdd7eba9be49d","isMergeCommit":true,"messageTitle":"Merge pull request #47 from DavinciDelta/WuXingyu-ParsingAbstraction","messageBody":"Add general validate and parse function","fileTypesAndContributionMap":{}},{"hash":"8e0d91820deea617c37ecaf1dfc69fefade72c9a","isMergeCommit":false,"messageTitle":"Update logic and code quality of ListCommand","messageBody":"There are also many repeats of System.lineSeparator + \"------\" etc\n\nHence update constant LINEDIVIDER in UI class to be public, and add\nSEPARATOR_LINEDIVIDER constant for use to tidy up code\n","fileTypesAndContributionMap":{"functional-code":{"insertions":107,"deletions":129},"test-code":{"insertions":14,"deletions":13}}}]},{"date":"2023-10-23","commitResults":[{"hash":"8507b3cd0107300ca6e7645b7ea6b0d311e5b9d2","isMergeCommit":false,"messageTitle":"Enable assertions in Gradle","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-24","commitResults":[{"hash":"41ef8d4d05c823217fd470fd2b0d5ce75cc9b755","isMergeCommit":true,"messageTitle":"Merge pull request #68 from DavinciDelta/AddAssertion","messageBody":"Include assertion in DeleteCommand","fileTypesAndContributionMap":{}},{"hash":"b36525d5ee13cdc1f2ef8fb4a9472930658ca9b1","isMergeCommit":true,"messageTitle":"Merge pull request #69 from DavinciDelta/UpdateDeveloperGuide","messageBody":"Update developer guide","fileTypesAndContributionMap":{}},{"hash":"7b8ffa67e21258e44d6123138f6526cf6ec70478","isMergeCommit":false,"messageTitle":"Repurpose style, architecture.puml from Addressbook","messageBody":"Add a draft architecture diagram\n","fileTypesAndContributionMap":{"docs":{"insertions":110,"deletions":0}}}]},{"date":"2023-10-25","commitResults":[{"hash":"0aea8979e3591fdba501ce8032615bd126a1555c","isMergeCommit":false,"messageTitle":"Add more structure to the Developer\u0027s Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":26,"deletions":0}}},{"hash":"b83bc4d4d00080b7f0ce0afc2896a051e7171889","isMergeCommit":false,"messageTitle":"Add Sequence Diagram for ListCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":84,"deletions":0}}}]},{"date":"2023-10-26","commitResults":[{"hash":"f09c1bf2895d25e06455027821024ce74864ead9","isMergeCommit":true,"messageTitle":"Merge pull request #74 from JoanneJo/JoanneAng-DeveloperGuide","messageBody":"Update DeveloperGuide.md","fileTypesAndContributionMap":{}},{"hash":"474936b9006df0c0a61054b29262af71487c4ffa","isMergeCommit":false,"messageTitle":"Update ListCommand and List Implementation of DG","messageBody":"Add a Messages class to format messages with frequently used\nline separators and dividers\n\nMove hasGenre to Resources class so it can be used for other purpose\n\nUpdate more details about ListCommand to DG\n","fileTypesAndContributionMap":{"functional-code":{"insertions":95,"deletions":75},"docs":{"insertions":16,"deletions":6},"test-code":{"insertions":10,"deletions":11}}},{"hash":"59cae2daeb0fb11a82e05710e3f9f504f5748974","isMergeCommit":false,"messageTitle":"Fix checkstyle error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"73265af04a474da052dbbe9cdda0066e4c0cf1a0","isMergeCommit":false,"messageTitle":"Fix ListCommandTest checkstyle error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":1}}},{"hash":"10159022ea4dc325910969bd62ba81407ec235cf","isMergeCommit":false,"messageTitle":"Update List DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":5}}},{"hash":"2d5ffa410ef7ee5a7a7dd822881d60585ac03a1e","isMergeCommit":true,"messageTitle":"Merge pull request #76 from bnjm2000/BenjaminNg-DG-Manual-Testing","messageBody":"Add more user stories as well as manual testing","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"e1ef61a3c639ad009ebfada3524d13be611ffb01","isMergeCommit":true,"messageTitle":"Merge pull request #77 from 000verflow/update-developer-guide","messageBody":"Add find command details on DG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"3e6a872f6c661d66560c016a3d14fd8d08cb0210","isMergeCommit":false,"messageTitle":"Add EditCommand feature and update User Guide","messageBody":"Librarians may want to update resources due to mistakes or outdated\ninformation\n\nHence, add a new Edit feature to update the title, author, tag, or\ngenre and update the Parser with new edit command\n\nUpdate User Guide with details of new Edit Command\n\nAdd tests for EditCommand\n\nIn future update:\n-Update help message with new Edit Command\n-Update genre editing to allow user to edit a specific genre rather\nthan all of them\n","fileTypesAndContributionMap":{"functional-code":{"insertions":154,"deletions":0},"docs":{"insertions":25,"deletions":2},"test-code":{"insertions":93,"deletions":16}}}]},{"date":"2023-10-31","commitResults":[{"hash":"853d35b9cf6126e242da4d2ec0c83c3d6ca44425","isMergeCommit":true,"messageTitle":"Merge pull request #88 from DavinciDelta/RemoveAliasing","messageBody":"Update Command","fileTypesAndContributionMap":{}},{"hash":"60e358edb08c0b688799b4bbc0d4ba6f902bd800","isMergeCommit":false,"messageTitle":"Add variable dateReceived to Resource","messageBody":"Librarians may want to track how long a resource has been in their\ncare\n\nHence, add a receivedDate attribute to resource which automatically\ntakes the current system time. Use current system time in order\nto reduce the amount of input a user has to type and it is also\nmore logical to take the current system time\n\nUpdate toString() and tests cases accordingly\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":1},"test-code":{"insertions":25,"deletions":16}}},{"hash":"9662c1ee2ffd733173ec4a18f87e93b7c860d9a0","isMergeCommit":true,"messageTitle":"Merge pull request #90 from bnjm2000/BenjaminNg-FixParser-Status","messageBody":"Fix incorrect return in parser for Status","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"b83d4e7dda0ede511ced81bbb5945bb1d65cade4","isMergeCommit":false,"messageTitle":"Add CommandResult class and feedbackToUser variable to all commands","messageBody":"All commands currently print every statement which may look messy\nand hard to get its output message\n\nHence, instead of printing every string, create a feedbackToUser\nstring in every Command class and add messages to that variable\n\nCommmandResult then stores feedbackToUser and Parser prints the\nfinal result at the end of command execution\n","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":19},"test-code":{"insertions":6,"deletions":12}}}]},{"date":"2023-11-02","commitResults":[{"hash":"aba3def8a30e7b7e109426275fb0c54ea674dfd9","isMergeCommit":true,"messageTitle":"Merge pull request #105 from 000verflow/Add-Storage","messageBody":"Add storage","fileTypesAndContributionMap":{}},{"hash":"ad173f6237166e90d3adc25b0efa8447327951b3","isMergeCommit":false,"messageTitle":"Add Logging and Assertions for EditCommand, ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":3}}},{"hash":"8700ccda9e7d0b98001f35e905284d6d250598b5","isMergeCommit":true,"messageTitle":"Merge pull request #108 from 000verflow/update-findsequencediagram","messageBody":"Update find sequence diagram, add minor UI enhancement","fileTypesAndContributionMap":{}},{"hash":"b076360856742c051a34fe006cb0c452576ae6f5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into YingXia-AddEditListLogging","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"baa86d2c9fe402d1671a3bf4f7de3bf2c66024b7","isMergeCommit":false,"messageTitle":"Fix logging","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":12}}},{"hash":"8f12bc97f303db6f67de9e80f0fbcbd8e37c2d1e","isMergeCommit":false,"messageTitle":"Update User Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":0}}},{"hash":"bf85077b8ffc0742d3e57802761516c0a7f71acc","isMergeCommit":true,"messageTitle":"Merge pull request #109 from 000verflow/update-ug","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"9f6ee8c9997c1e28b2502a43be0638ec587bb981","isMergeCommit":true,"messageTitle":"Merge pull request #112 from 000verflow/update-findcommand-filtering","messageBody":"Update findcommand filtering and fix storage class bug","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"94fe4b60581fe5b5952d12071c9ccab7c28ec8ca","isMergeCommit":true,"messageTitle":"Merge pull request #118 from 000verflow/add-findcommandfilters","messageBody":"Add findcommandfilters","fileTypesAndContributionMap":{}},{"hash":"7dcf3be8e15f5e04d190269e18375c3ba337d935","isMergeCommit":false,"messageTitle":"Update Overall Architecture Diagram for Storage and Data component","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":20,"deletions":6}}},{"hash":"2026ade377e8f292bdb80d5d50e4b44962b3af19","isMergeCommit":false,"messageTitle":"Add Filter by Status for List Command and fix logging for List, Edit","messageBody":"Librarians may want get an overview of the status of resources\n\nHence, add filter by status to list for AVAILABLE, BORROWED, LOST\nand add more test cases\n\nFix list and edit logging where ./runtest.bat fails due to missing\nlog directory\n\nRename Messages class to FormatMessages to reflect its purpose\nclearly\n","fileTypesAndContributionMap":{"functional-code":{"insertions":76,"deletions":22},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":41,"deletions":5}}},{"hash":"c0634943399388c21062ea98241665384f5ff8b3","isMergeCommit":false,"messageTitle":"Update user guide to reflect new status filtering","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":4}}},{"hash":"5f6341f653300af5a4b1edbcd9de9d5f5d0436bf","isMergeCommit":true,"messageTitle":"Merge pull request #135 from 000verflow/update-storageclass-whitespacebug","messageBody":"Update storageclass whitespacebug","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"000verflow":{"docs":212,"functional-code":664,"test-code":154,"other":1},"bnjm2000":{"docs":191,"functional-code":231,"test-code":333},"JoanneJo":{"docs":261,"functional-code":488,"test-code":60},"DavinciDelta":{"docs":203,"functional-code":336,"test-code":194},"yingx9":{"docs":290,"functional-code":542,"test-code":220,"other":1}},"authorContributionVariance":{"000verflow":117068.87,"bnjm2000":12993.465,"JoanneJo":10802.387,"DavinciDelta":6573.7637,"yingx9":99452.98},"authorDisplayNameMap":{"000verflow":"CS2113T-W11-1 VELU..LAJI","bnjm2000":"CS2113T-W11-1 BENJ..MING","JoanneJo":"CS2113T-W11-1 JOAN..LING","DavinciDelta":"CS2113T-W11-1 WU X..NGYU","yingx9":"CS2113T-W11-1 LOKE.. XIA"}} +{"authorDailyContributionsMap":{"000verflow":[{"date":"2023-10-06","commitResults":[{"hash":"40c098fcf74b1c2282447f9113b643a766c328d3","isMergeCommit":false,"messageTitle":"Add ashokbalaji-aboutus","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":1}}},{"hash":"ba10e507f38769c43a032bf8f9367a09dce03291","isMergeCommit":false,"messageTitle":"Add userguide draft","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":99,"deletions":23}}}]},{"date":"2023-10-11","commitResults":[{"hash":"d051634250466c7164160a7fddeb56f1762e79a3","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into YingXia-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"7b3caa8286c5e5afd39596c9d37aaa83da139f3e","isMergeCommit":true,"messageTitle":"Merge pull request #2 from yingx9/YingXia-AboutUs","messageBody":"Update AboutUs.md and add Portfolio Page","fileTypesAndContributionMap":{}},{"hash":"ce04bd2fd92aa288fc50505baa20550cef504563","isMergeCommit":true,"messageTitle":"Merge pull request #5 from AY2324S1-CS2113T-W11-1/branch-AshokBalaji-userguide","messageBody":"Add userguide draft","fileTypesAndContributionMap":{}},{"hash":"bd25c10208589cf71225db3fa2e85eb80cf14e72","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into WuXingyu-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2eb93ed11019095c9d83522d710cff1951ff90ee","isMergeCommit":true,"messageTitle":"Merge pull request #3 from DavinciDelta/WuXingyu-AboutUs","messageBody":"Add WuXingyu-AboutUs","fileTypesAndContributionMap":{}},{"hash":"da93b03bf043240cb13cd891d3f7d5ba034f221d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into branch-AshokBalaji-AboutUs","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"751016df50864854566f9a6f330cc416719f3f8c","isMergeCommit":true,"messageTitle":"Merge pull request #4 from AY2324S1-CS2113T-W11-1/branch-AshokBalaji-AboutUs","messageBody":"Add ashokbalaji-aboutus","fileTypesAndContributionMap":{}},{"hash":"fbcd9e994f8f6d371570e0837d0b9df5d55e0a65","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"6e0c5086aa5ce4c4ef524b1109975395f85b10ec","isMergeCommit":true,"messageTitle":"Merge pull request #6 from bnjm2000/master","messageBody":"Add Benjamin-AboutUs","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"7ac4de161937c8f68caedf661d33ac2743bce93f","isMergeCommit":false,"messageTitle":"Revert \"Add code from AddressBook\"","messageBody":"This reverts commit 24a54a13e9bff5754c97196f670acb1db3f9c3fe.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1937}}},{"hash":"15df575857850f9910d1277c039fd733830fde91","isMergeCommit":false,"messageTitle":"Add UI Class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":61,"deletions":11}}},{"hash":"9598cd960fd0593f0decb94a2ad3150e18b70383","isMergeCommit":false,"messageTitle":"Update UI package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":12}}},{"hash":"cbd5935ccf882033ad0b08db364596550f560f60","isMergeCommit":false,"messageTitle":"Rename Ui.java to UI.java","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"dbd0e6f0e289653a11048a5d9c19c7a444448864","isMergeCommit":false,"messageTitle":"Update UI package bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":11}}},{"hash":"9a1adb0d5f9728d7fd6ddf0eb857fe41242adf24","isMergeCommit":true,"messageTitle":"Merge branch \u0027branch-AshokBalaji-UI-class\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into branch-AshokBalaji-UI-class","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"61cfb3cce6305613102703e161b14a648269c2a3","isMergeCommit":false,"messageTitle":"Update UI package bug","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"7e4f3fe7f71a7459f1bd36c678648852307f3437","isMergeCommit":false,"messageTitle":"Update tests and fix package structure","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":14},"other":{"insertions":22,"deletions":22}}},{"hash":"234d4f7e45be31af96739a72dbc38e756ac6e307","isMergeCommit":true,"messageTitle":"Merge pull request #22 from AY2324S1-CS2113T-W11-1/branch-AshokBalaji-UI-class","messageBody":"Add UI Class","fileTypesAndContributionMap":{}},{"hash":"11762124503a2c817f64b4270a43e8aacf3f413d","isMergeCommit":true,"messageTitle":"Merge pull request #23 from bnjm2000/add_portfolio","messageBody":"Add portfolio and updated README.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"53cf6f5c45786d68a96b75e355f9b23f4e85d942","isMergeCommit":false,"messageTitle":"Add FindCommand class","messageBody":"Refactored structure as well\n","fileTypesAndContributionMap":{"functional-code":{"insertions":107,"deletions":7},"other":{"insertions":3,"deletions":4}}},{"hash":"e47758599f53faae99cd80ef54ce1645c93bd29e","isMergeCommit":true,"messageTitle":"Merge pull request #33 from JoanneJo/JoanneAng-TagResource","messageBody":"Add Tag Function","fileTypesAndContributionMap":{}},{"hash":"8bfd4312374db9102e7007cac4eb3d716c3533b4","isMergeCommit":true,"messageTitle":"Merge pull request #34 from yingx9/YingXia-ListBySpecificArguments","messageBody":"Update Listing by specific filters for ListCommand.Java","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"c506bdc66a04030dcab18d1d8558dfe23fec32c2","isMergeCommit":false,"messageTitle":"Add Junit tests for FindCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":19},"test-code":{"insertions":126,"deletions":1}}},{"hash":"ecdbae3f3a74ddc3de8d01da6cc64fe1a557ff7b","isMergeCommit":false,"messageTitle":"Add logging and java assertions to FindCommand class, updated FindCommandTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":3},"test-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-26","commitResults":[{"hash":"0643b459f813d1557ce46b3d1f313e42921a2afe","isMergeCommit":false,"messageTitle":"Update FindCommand with new parser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":29},"test-code":{"insertions":0,"deletions":11}}},{"hash":"f2321f49afd6722491ed22ce65cf805c4856bf35","isMergeCommit":true,"messageTitle":"Merge pull request #72 from 000verflow/branch-AshokBalaji-UpdateFindCommand","messageBody":"Update FindCommand with new parser","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"3669b239dc0f2e56b1ac7d0fec9418ab1ef9e5bd","isMergeCommit":false,"messageTitle":"Add find command details on DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":69,"deletions":4}}}]},{"date":"2023-10-29","commitResults":[{"hash":"66de33dd0fc52c63e97efd45452feb410fad335e","isMergeCommit":true,"messageTitle":"Merge pull request #84 from bnjm2000/BenjaminNg-UpdateUG","messageBody":"Add updates to UG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"7a114bc50c352cde2e599ede33d45727add57cd2","isMergeCommit":true,"messageTitle":"Merge pull request #89 from yingx9/YingXia-AddDateTime","messageBody":"Add variable dateReceived to Resource","fileTypesAndContributionMap":{}},{"hash":"8b2bbe4e559c84ec13b552b7bb9e04c4ecaad8c7","isMergeCommit":false,"messageTitle":"Fix findCommand assertion issue","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1},"test-code":{"insertions":1,"deletions":1}}},{"hash":"4b83ab0ff7b907a7e472a3f18cd33577859f1a94","isMergeCommit":true,"messageTitle":"Merge pull request #100 from bnjm2000/BenjaminNg-FixLogsandConsistency","messageBody":"Fix logs and consistency","tags":["v2.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"1283a908bf1bc8db55e7eccbc9eae10eb2b036ad","isMergeCommit":true,"messageTitle":"Merge pull request #102 from yingx9/YingXia-ImplementCommandResult","messageBody":"Add CommandResult class and feedbackToUser variable to all commands","fileTypesAndContributionMap":{}},{"hash":"c41056bbea1c44119b19ef4f4eabef69279981e2","isMergeCommit":false,"messageTitle":"Add sequence diagram for Find Command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":96,"deletions":3}}}]},{"date":"2023-11-02","commitResults":[{"hash":"9e10a72f51cdceefc17f878cd4040334f5af4283","isMergeCommit":false,"messageTitle":"Add Storage capability, update some class to accommodate","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":350,"deletions":36},"other":{"insertions":1,"deletions":1}}},{"hash":"76241e51ca49b6eb0bf6a9de0a0ee708394de09f","isMergeCommit":false,"messageTitle":"Update for checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":216,"deletions":195}}},{"hash":"13130e7afc2f8be8bd7816dd7cbe3a4931eb442c","isMergeCommit":false,"messageTitle":"Update Storage.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4}}},{"hash":"79f666b5e1c970268d5510c54d4b43ab7a372298","isMergeCommit":false,"messageTitle":"Update text ui test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"9c1206087045f06a8f6d26741acab79f90358e14","isMergeCommit":false,"messageTitle":"Update find sequence diagram, add minor UI enhancement","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":14},"docs":{"insertions":1,"deletions":7}}},{"hash":"669d6009a95825028574409c2ff368d688a41597","isMergeCommit":false,"messageTitle":"Revert UI Update","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"52be2a3a81a3c37cdf7e744386705701c269253f","isMergeCommit":true,"messageTitle":"Merge pull request #107 from yingx9/YingXia-AddEditListLogging","messageBody":"Add Logging and Assertions for EditCommand, ListCommand","fileTypesAndContributionMap":{}},{"hash":"0ffbebffb034f1c5f8dd8e5d1fa63158e63915f2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":15}}}]},{"date":"2023-11-03","commitResults":[{"hash":"0083b705af3556b21095da069b252b6b511a64f4","isMergeCommit":false,"messageTitle":"Update find command filter method, fix storage class bug.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":77,"deletions":41},"other":{"insertions":27,"deletions":9},"test-code":{"insertions":14,"deletions":14}}},{"hash":"5c3a463dc18f0041cc9ecb6f4ec3125b5f2387b1","isMergeCommit":false,"messageTitle":"Fix another bug with storage","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":14},"other":{"insertions":2,"deletions":2},"test-code":{"insertions":3,"deletions":3}}},{"hash":"e68bfd4e4b921982925629a69ecc47af8cbaac33","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":2}}},{"hash":"928c319931614b9047466c72a7045639765f8e58","isMergeCommit":false,"messageTitle":"Add logging for find","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"1f600f6a88597df6de8cfd654a8ef9514e6c8a26","isMergeCommit":false,"messageTitle":"Fix magic literals","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":8}}},{"hash":"13815aff3f064d96ffcc5c8869719ae39a7adc07","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"3cb2ee1912a6ba9928552d25ab858a7e542d88e3","isMergeCommit":false,"messageTitle":"Update FindCommand to account for different types of resources","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":12}}},{"hash":"9bfb7330638db31ff3822657e3337b7ba77d69e9","isMergeCommit":false,"messageTitle":"Update FindCommand.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"4c61918964c6c1030efce3e7d10f2e0fc7ce9c69","isMergeCommit":false,"messageTitle":"Update UG and DG to reflect the changes to findCommand accordingly","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":2}}}]},{"date":"2023-11-04","commitResults":[{"hash":"b5832c6223a6020471902f436c74fa360236c0e2","isMergeCommit":false,"messageTitle":"Update Sequence diagram for Find","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":42}}},{"hash":"50d139af557e7dbd5cfe90db275b79a1944fd41e","isMergeCommit":false,"messageTitle":"Fix bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"e71dfe7f219f8dcdc385475eb196134357b034d2","isMergeCommit":false,"messageTitle":"Update checkstyle and bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":32}}},{"hash":"8282651831ac89ea5bd21b6e3ae135657e23b58d","isMergeCommit":false,"messageTitle":"Fix Checkstule and add junit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":33,"deletions":10}}},{"hash":"0f6bef8cfb7199386649eb10fc90a92793488784","isMergeCommit":true,"messageTitle":"Merge pull request #133 from yingx9/YingXia-UpdateArchitectureDiagram","messageBody":"Update Overall Architecture Diagram for Storage and Data component","fileTypesAndContributionMap":{}},{"hash":"c03d25ace975ed9a6d9e202e32641d7736cf1703","isMergeCommit":true,"messageTitle":"Merge pull request #134 from yingx9/YingXia-UpdateListStatusFiltering","messageBody":"Add Filter by Status for List Command and fix logging for List, Edit","fileTypesAndContributionMap":{}},{"hash":"fea31f29a20b036e7ad232fdec4d66c616c55c7b","isMergeCommit":false,"messageTitle":"Fix whitespace visual bug","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":14}}}]}],"bnjm2000":[{"date":"2023-10-09","commitResults":[{"hash":"efad7d965c627a182d0c515fbcf8bd652d5f7b75","isMergeCommit":false,"messageTitle":"Add Benjamin-AboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":6}}}]},{"date":"2023-10-11","commitResults":[{"hash":"11fbaf7ff4a1c16bd6e857e1bfd19094d43fbfb9","isMergeCommit":false,"messageTitle":"Add portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":0}}},{"hash":"f98ad3ecdb9bf4a008479b664430633fe6aee154","isMergeCommit":false,"messageTitle":"Fix portfolio link","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-14","commitResults":[{"hash":"ff6ecc4e701b239a826fcd503989cca981a38809","isMergeCommit":false,"messageTitle":"Add portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":9}}},{"hash":"c5bb57406ed0171f9b20242b11d01e4955ec7839","isMergeCommit":true,"messageTitle":"Merge pull request #25 from AY2324S1-CS2113T-W11-1/WuXingyu-Resource","messageBody":"Add Resource class","fileTypesAndContributionMap":{}},{"hash":"fee0f659873ca0be326386c791db3e379df73714","isMergeCommit":false,"messageTitle":"Add HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":1}}},{"hash":"a01128ec5feae99924bb3c327d94bba7e5d9a31d","isMergeCommit":false,"messageTitle":"Fix ExitCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":3}}},{"hash":"243fa1457017b73e4edbd1929fadadd779e2de01","isMergeCommit":false,"messageTitle":"Changed unknown command message.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"3806b18ebb2a19a8bb7a2012027cda0f2f705459","isMergeCommit":false,"messageTitle":"Moved help message to UI class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":8}}},{"hash":"4f172b206ce42c544432438b8384906a12d5dc98","isMergeCommit":true,"messageTitle":"Merge pull request #29 from yingx9/YingXia-UpdateListCommand","messageBody":"Update ListCommand and edit Resource and Book","fileTypesAndContributionMap":{}},{"hash":"8d3ec47b216a8ecce72971e1286cd5c7816e3e0d","isMergeCommit":false,"messageTitle":"Changed syntax to \"exit\" and updated test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}}]},{"date":"2023-10-15","commitResults":[{"hash":"41e96d180eea8819810b89f4972503658bc58533","isMergeCommit":true,"messageTitle":"Merge pull request #31 from JoanneJo/JoanneAng-AddCommand","messageBody":"Update AddCommand.java and Add SysLibException.java","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"7ff86171a0fd13c77b3cf121db7fe6884d0b3d86","isMergeCommit":false,"messageTitle":"Add Junit testing","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1},"test-code":{"insertions":183,"deletions":0}}},{"hash":"b567bf5aa32fe02c4fd1dfb89a7015f775c830c5","isMergeCommit":false,"messageTitle":"Add more Junit tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":75,"deletions":2}}},{"hash":"307dadb3f1cadb6f4656b5a341d45ea46c7e249a","isMergeCommit":false,"messageTitle":"Fix checkstye","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":26,"deletions":17}}},{"hash":"86cf0bf0f325391532da1bcc682d06a7ad6362d6","isMergeCommit":false,"messageTitle":"Fix checks not working on Windows","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":35,"deletions":33}}},{"hash":"d6f62f5ccc65e022901ad84f3267897d80378000","isMergeCommit":true,"messageTitle":"Merge pull request #39 from yingx9/YingXia-UpdateUserGuide","messageBody":"Update UserGuide.md for List and minor change to ListCommand","fileTypesAndContributionMap":{}},{"hash":"bae7e026d74680fe4a0047fa954ce271f2bffaba","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into add_Junit","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Update UserGuide.md for List and minor change to ListCommand\n","fileTypesAndContributionMap":{}},{"hash":"3e910fc9d53b77f127940bc75640b25da44f6808","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":13,"deletions":13}}},{"hash":"db5883414825e7a5e441ce1878551dd7d555d7d2","isMergeCommit":false,"messageTitle":"Fix comment indentation","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":11,"deletions":11}}},{"hash":"83d05e7e51521c14924622be0f8d0597145b6eb5","isMergeCommit":false,"messageTitle":"Fix Try #1","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":11,"deletions":11}}},{"hash":"a81d766d11a375879c1f602842828531a8604d25","isMergeCommit":false,"messageTitle":"Add TestUtil and corrected Junit","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":40,"deletions":3}}},{"hash":"48875226e1bf55b48404da72ad34eab3eec785d4","isMergeCommit":true,"messageTitle":"Merge pull request #40 from yingx9/YingXia-UpdateListPrinting","messageBody":"Update ListCommand to use lineSeparator() and add more checks","fileTypesAndContributionMap":{}},{"hash":"affd9379953ddff889923ab527eedcb8736d6536","isMergeCommit":false,"messageTitle":"Fix Checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":6}}},{"hash":"08a718177bfc3197280e2e6a5f1b74c34478186e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into add_Junit","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Fix lines to not exceed 120 characters for coding standard\n Update ListCommand to use lineSeparator() and add more checks\n","fileTypesAndContributionMap":{}},{"hash":"dda3ca33533312deceb333e38d5eb526948abdb1","isMergeCommit":false,"messageTitle":"Fix windows error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":2}}},{"hash":"e47ca19cf52aedb1ee571f7ae8ac7cae8fe4717d","isMergeCommit":false,"messageTitle":"Fix Windows error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"04906e63ebf2b3be29a4f8cd076683ee9d5777f6","isMergeCommit":false,"messageTitle":"Fix windows error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":1,"deletions":1}}},{"hash":"09ad6907d3798658b4b35994f88bd432abb995b9","isMergeCommit":false,"messageTitle":"Fix failed test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"a378b1122c47e5682c500f7615e125ef6e580665","isMergeCommit":false,"messageTitle":"Fix code to have better consistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":20},"test-code":{"insertions":30,"deletions":16}}},{"hash":"4586311a7acee699ecf66d65ab4402c569af92f3","isMergeCommit":true,"messageTitle":"Merge pull request #41 from yingx9/YingXia-AddListCommandTest","messageBody":"Add jUnit tests for ListCommand","fileTypesAndContributionMap":{}},{"hash":"0d98a06f824e5fa388728e538a12933f4cb95efb","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg_consistency","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Update EXPECTED.TXT and input.txt for testing\n Fix windows error\n Fix check style error\n Add jUnit tests for ListCommand\n","fileTypesAndContributionMap":{}},{"hash":"816feeda7fb4686d2872e332338372a28eb35064","isMergeCommit":false,"messageTitle":"Fix checks after merge","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":3},"test-code":{"insertions":21,"deletions":5}}},{"hash":"2d31c5b83d50f5c0c1cca48f588661ac6a44e6d0","isMergeCommit":false,"messageTitle":"Fix failed test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"1171880f0dfcbe51c57f3c8c2ed253170606ea19","isMergeCommit":false,"messageTitle":"Fix failed checks","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-17","commitResults":[{"hash":"97bad5aea57f5f451ee8ca636e72807e15defeb3","isMergeCommit":false,"messageTitle":"Fix helpCommand to be consistent with UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":5},"docs":{"insertions":1,"deletions":1},"test-code":{"insertions":19,"deletions":13}}},{"hash":"969c6d2ed053ae8345ad0b5367f9ff113879b550","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg_FixHelpCommand","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Fix failed checks\n Fix failed test\n Fix checks after merge\n Fix code to have better consistency\n\n# Conflicts:\n#\tsrc/main/java/seedu/ui/UI.java\n#\tsrc/test/java/seedu/commands/HelpCommandTest.java\n#\tsrc/test/java/seedu/parser/ParserTest.java\n#\ttext-ui-test/EXPECTED.TXT\n","fileTypesAndContributionMap":{}},{"hash":"7f270f77a3b68d595ddb92c68f1aa96dc0e3c1f8","isMergeCommit":false,"messageTitle":"Fix merge conflicts","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":10},"test-code":{"insertions":0,"deletions":24}}},{"hash":"b44806541a1a31074bc32d9a7f54bc3b3daa2ff1","isMergeCommit":true,"messageTitle":"Merge pull request #45 from yingx9/YingXia-FixNullGenreBug","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"256dfd39999328567020cbfe6bbcff0b4730de0b","isMergeCommit":true,"messageTitle":"Merge pull request #46 from yingx9/YingXia-UpdateListGenre","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"effcd9da28de13988cba3b1caab69dd2f2e5b1bd","isMergeCommit":true,"messageTitle":"Merge pull request #51 from yingx9/YingXia-AddListCommandAssertion","messageBody":"Add assertion to ensure ListCommand works as intended","fileTypesAndContributionMap":{}},{"hash":"1e6825dff3c2f6d0aae77ec5048dac06227f015e","isMergeCommit":true,"messageTitle":"Merge pull request #53 from 000verflow/Add-Assertions-Logging-FindCommand","messageBody":"Add logging and java assertions to FindCommand class","fileTypesAndContributionMap":{}},{"hash":"3733b72dc6d2b395228ddd7a872b80f5686f534c","isMergeCommit":false,"messageTitle":"Add assert and logging","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":64,"deletions":4}}}]},{"date":"2023-10-26","commitResults":[{"hash":"5016c2e6074261fc5964ddfff0f7eb27d96cd571","isMergeCommit":false,"messageTitle":"no message","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":56,"deletions":12}}},{"hash":"fe18b54784d8ad6cefddd54f43b9dfc4d95e44bd","isMergeCommit":false,"messageTitle":"Add help and bye manual testing","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":1}}},{"hash":"226408b08990865f86550c15a9c1128e24490679","isMergeCommit":true,"messageTitle":"Merge pull request #75 from yingx9/YingXia-UpdateListDG","messageBody":"Update ListCommand and List Implementation of DG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"14d7e50a5215ff6e3dfed92188ced624a631017c","isMergeCommit":false,"messageTitle":"Add updates to UG","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":96,"deletions":27}}},{"hash":"85830a26ef52ffe6b1b646cdad9d13b8fc6da1d5","isMergeCommit":false,"messageTitle":"Add update to UG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}}]},{"date":"2023-10-30","commitResults":[{"hash":"c2b327b5d0eb6132cb650ca8fb601da6319d286c","isMergeCommit":true,"messageTitle":"Merge pull request #85 from DavinciDelta/UpdateDelete","messageBody":"Fix and optimize testing for deleteCommand","fileTypesAndContributionMap":{}},{"hash":"bddbb6a6283e91042b12575f6b52a6f2b870d3bd","isMergeCommit":false,"messageTitle":"Add status to resources","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":54,"deletions":12},"test-code":{"insertions":8,"deletions":6}}},{"hash":"9d5b57ba2e652d2b8a43eb19696db53a74721a78","isMergeCommit":true,"messageTitle":"Merge pull request #86 from yingx9/YingXia-AddEditCommand","messageBody":"Add EditCommand feature and update User Guide","fileTypesAndContributionMap":{}},{"hash":"278383095f4e21a739564c4e86cc0b65a2b9af1d","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-Status","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Add EditCommand feature and update User Guide\n\n# Conflicts:\n#\tsrc/test/java/seedu/util/TestUtil.java\n","fileTypesAndContributionMap":{}},{"hash":"6c628cb61110d19475a8126447270e4837e6cd22","isMergeCommit":false,"messageTitle":"Update checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":10},"test-code":{"insertions":32,"deletions":20}}},{"hash":"4df06510418b576b5cd23c0388c3b19a999354d9","isMergeCommit":false,"messageTitle":"Add ability to update status of resource","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":21,"deletions":5}}},{"hash":"15339b7431aa899a49c0ae4d376b5c32f0aa89a0","isMergeCommit":false,"messageTitle":"Add tests to include edit and status","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":19,"deletions":1}}},{"hash":"5378ba72254e090bc51a7073869e0682f251bd28","isMergeCommit":false,"messageTitle":"Fix test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":0,"deletions":3}}},{"hash":"6c54dd4aa2508dc4600f921ab17b2f8f18c148ed","isMergeCommit":false,"messageTitle":"Fix test pt. 2","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"13f1d9ee05d8f9a44438b0bdff0a131d77cfbb82","isMergeCommit":false,"messageTitle":"Update UG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":21,"deletions":13}}},{"hash":"e173c4f27ac84aba84f7aafb8f41290f23818aa6","isMergeCommit":false,"messageTitle":"Update UG, DG and Help command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1},"docs":{"insertions":8,"deletions":6}}},{"hash":"160d8db2cca4d2559840c2cff09496e31834b8db","isMergeCommit":false,"messageTitle":"Update test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":5}}}]},{"date":"2023-10-31","commitResults":[{"hash":"233f4332d723c7b18f792e9ae26e441341dde5d7","isMergeCommit":false,"messageTitle":"Fix incorrect return in parser for Status","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":10},"test-code":{"insertions":29,"deletions":4}}},{"hash":"1a4a8fc56a3e3bdd587f0b7123c14dde90e8e3ff","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-FixParser-Status","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Add variable dateReceived to Resource\n Update Command\n\n# Conflicts:\n#\tsrc/test/java/seedu/parser/ParserTest.java\n","fileTypesAndContributionMap":{}},{"hash":"32a9064cd67828909f1c2e6f5f7c4e7e6c1fa85c","isMergeCommit":true,"messageTitle":"Merge pull request #94 from DavinciDelta/EventCalendar","messageBody":"Add event commands","fileTypesAndContributionMap":{}},{"hash":"e2f72c400534d8afe11d3cf6b0c64efb77b8eed0","isMergeCommit":true,"messageTitle":"Merge pull request #97 from DavinciDelta/EventTesting","messageBody":"Add testing for event commands","fileTypesAndContributionMap":{}},{"hash":"b8f584c61da81bd0893d555f16bab5c300f15457","isMergeCommit":false,"messageTitle":"Fix logs for help and exit command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":2}}},{"hash":"361e044d77d6d1c923e5e31b795ce97dfa12e20c","isMergeCommit":false,"messageTitle":"Fix bugs and add consistency","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":77}}},{"hash":"779d13452030ccbb65b0016c0edda4e67518ba85","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-FixLogsandEnhancements","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Add testing for event commands\n\n# Conflicts:\n#\tsrc/main/java/seedu/commands/Command.java\n","fileTypesAndContributionMap":{}},{"hash":"084450cd5b80ad4b840e2b06c563ece7ec62c887","isMergeCommit":true,"messageTitle":"Merge pull request #99 from 000verflow/fix-FindCommandBug","messageBody":"Fix findCommand assertion issue","fileTypesAndContributionMap":{}},{"hash":"2f075fae15eed26fb85e3d0ce499461a594a5490","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into BenjaminNg-FixLogsandConsistency","messageBody":"* \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp:\n Fix findCommand assertion issue\n","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"2ab2554311e1141f32c6f3c769ee9db9cdf0c256","isMergeCommit":true,"messageTitle":"Merge pull request #98 from JoanneJo/JoanneAng-AddResources","messageBody":"Add Different Types of Resources","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"e103ca2c36321db6d7b34008649118f629f452d6","isMergeCommit":true,"messageTitle":"Merge pull request #104 from 000verflow/add-findsequencediagram","messageBody":"","fileTypesAndContributionMap":{}}]}],"JoanneJo":[{"date":"2023-10-04","commitResults":[{"hash":"d4b23856f14360e5e02b8b48f1fa8d867104aa99","isMergeCommit":false,"messageTitle":"Add personal details to AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":7}}}]},{"date":"2023-10-05","commitResults":[{"hash":"74ce9366bfeba2e78b22b08db06017a574898712","isMergeCommit":false,"messageTitle":"Update AboutUs.md and Add JoanneAng.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-15","commitResults":[{"hash":"6642630870c3a7e6899d35768f20336136f8ba75","isMergeCommit":false,"messageTitle":"Update AddCommand.java and Add SysLibException.java","messageBody":"Updated UserGuide.md so that all commands are\nusing the same tags for the same type of data.\nUI.java is therefore edited to standardize the\nhelp message.\n\nModified Book.java to remove synopsis from the\nobject and add genres. toString() is modified to\ndisplay genres.\n\nImplemented the add command to add books to the\nresource list. Validated user input for add command.\n\nChanged the naming of taskList to resourceList and\nadded SysLibException.java. Hence, edited\nCommand.java, DeleteCommand.java, ListCommand.java,\nand Parser.java.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":102,"deletions":39},"docs":{"insertions":33,"deletions":26}}},{"hash":"97f427ecac516acd184a6a24eb9aa5a62c8bd731","isMergeCommit":false,"messageTitle":"Update Book.java, AddCommand.java, and Parser.java","messageBody":"Updated to pass the checks.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"a6eb7919209e44ae45ed5fdab02d2447a377ddcd","isMergeCommit":false,"messageTitle":"Add Tag Function","messageBody":"Added tag function to identify and specify the\ntype of resources added.\n\nModified parseAddCommand method to be more generic.\nAdded parsing and validation methods for adding\nbooks.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":105,"deletions":59},"docs":{"insertions":2,"deletions":2}}},{"hash":"eb76d7512bd86add4df324bc90fb72ccb28a838c","isMergeCommit":false,"messageTitle":"Update AddCommand.java and Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":6}}},{"hash":"0d7af8aebc811a4ff9b851c0e322996edf43dc96","isMergeCommit":false,"messageTitle":"Update UserGuide.md and Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":2,"deletions":2}}}]},{"date":"2023-10-16","commitResults":[{"hash":"834fcdd733a92644b85cc8a507de7bbfd736d321","isMergeCommit":true,"messageTitle":"Merge pull request #35 from DavinciDelta/WuXingyu-DeleteCommand","messageBody":"Add Delete Command","fileTypesAndContributionMap":{}}]},{"date":"2023-10-17","commitResults":[{"hash":"38a8d4706b95c1b71e8ed427ef64e64b0448d972","isMergeCommit":true,"messageTitle":"Merge pull request #49 from 000verflow/Add-FindCommandTest","messageBody":"Add Junit tests for FindCommand","fileTypesAndContributionMap":{}},{"hash":"3dc4400af9db7c3713fa071647fb9d32baf5181d","isMergeCommit":true,"messageTitle":"Merge pull request #50 from DavinciDelta/WuXingyu-DeleteTesting","messageBody":"Add DeleteCommand Testing","fileTypesAndContributionMap":{}}]},{"date":"2023-10-20","commitResults":[{"hash":"dd157775f08701fc6a2945c72d7ddd4eccb29665","isMergeCommit":true,"messageTitle":"Merge pull request #55 from yingx9/YingXia-UpdateListCommandParsing","messageBody":"Update logic and code quality of ListCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"ed7a3cc3a2b98b526a8b2901e6eac90a58555271","isMergeCommit":false,"messageTitle":"Add AddCommand JUnit Tests","messageBody":"Added addCommand JUnit tests to AddCommandTest.java.\nUpdated Book.java and Parser.java.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":0},"test-code":{"insertions":58,"deletions":0}}},{"hash":"2c2e658a363c148a823aa30b74af030c1015aace","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":3}}}]},{"date":"2023-10-26","commitResults":[{"hash":"68271b08f8aa57213e668aef11dd07b64b33fb19","isMergeCommit":true,"messageTitle":"Merge pull request #71 from yingx9/YingXia-DGPlantUml","messageBody":"Repurpose style, architecture.puml from Addressbook","fileTypesAndContributionMap":{}},{"hash":"c83c8d24dbe24a1d92dfa2a5cc07c32ce8ea3e53","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"Added on to the developer guide and included parts\nfor the add feature.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5},"docs":{"insertions":172,"deletions":3}}}]},{"date":"2023-10-30","commitResults":[{"hash":"fa1e27bab9f27569ed12f4449a81d7fdf67cc106","isMergeCommit":true,"messageTitle":"Merge pull request #87 from bnjm2000/BenjaminNg-Status","messageBody":"Add Status to resources","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"c21709d7786a977da3bc595ff3fd93b0238eaf85","isMergeCommit":false,"messageTitle":"Add Different Types of Resources","messageBody":"Added eBook, CD, magazine, eMagazine, newspaper,\nand eNewspaper in addition to Book.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":384,"deletions":45},"docs":{"insertions":79,"deletions":2},"test-code":{"insertions":4,"deletions":2}}},{"hash":"513bba7872e7747d34ef2452b48ab5743853ae4e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JoanneAng-AddResources","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d45d1eaba41245eee2fc96316714f5bebc4dc67c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JoanneAng-AddResources","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"578246843230c6c009201b8b0fafd62fb3ef52d4","isMergeCommit":false,"messageTitle":"Update User Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a6298f27bd20473ad70e03620a26ca3868c44791","isMergeCommit":false,"messageTitle":"Update Resource.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"a567cf3f042985fd3a873291de03de783cb7376f","isMergeCommit":false,"messageTitle":"Update Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}}]},{"date":"2023-11-01","commitResults":[{"hash":"3a5f5cfaedbc2b1262aefa66fb0a61be4c24925b","isMergeCommit":false,"messageTitle":"Update CD.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"765376c1d1ec2e81f67a88e406451ce4a8024f65","isMergeCommit":false,"messageTitle":"Update TestUtil.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":1,"deletions":1}}},{"hash":"e30e7898a6fbbbad0828439858d4bad44b0f99c6","isMergeCommit":false,"messageTitle":"Update TestUtil.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"5f77e875ed27edef3f60722b0d7b8d531531d807","isMergeCommit":true,"messageTitle":"Merge branch \u0027JoanneAng-AddResources\u0027 of https://github.com/JoanneJo/tp into JoanneAng-AddResources","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/data/CD.java\n","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"5f32227f04d464b9e0022a870672df9856395b73","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of https://github.com/AY2324S1-CS2113T-W11-1/tp into JoanneAng-AddResources","messageBody":"# Conflicts:\n#\tdocs/UserGuide.md\n","fileTypesAndContributionMap":{}},{"hash":"00c03daa239bea155e1c253244c2846478317ac8","isMergeCommit":false,"messageTitle":"Update UserGuide.md and Refactor Classes","messageBody":"Refactored classes so they start with capital letters.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":17},"other":{"insertions":6,"deletions":6},"docs":{"insertions":4,"deletions":5}}},{"hash":"9d799d13c225b9d38bd1eed70390f093cf12d127","isMergeCommit":true,"messageTitle":"Merge pull request #110 from DavinciDelta/master","messageBody":"Update UG for events","fileTypesAndContributionMap":{}},{"hash":"0d3848c67d1dea9145549125e7ecb977b595f772","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JoanneAng-AddResources","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fa9f4d46962d793413ef03501cc58d3a3253f9d6","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":24},"docs":{"insertions":85,"deletions":8}}},{"hash":"1a86cb7137e89762bd751186a413657d43512b0b","isMergeCommit":false,"messageTitle":"Refactor Classes","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":0,"deletions":0}}},{"hash":"42154a761604ff99485c8fdcc91ff90b811f1d37","isMergeCommit":true,"messageTitle":"Merge pull request #103 from DavinciDelta/UpdateGuides","messageBody":"Update guides","fileTypesAndContributionMap":{}}]},{"date":"2023-11-05","commitResults":[{"hash":"8602a84aa4e4b196b490ab9673b36a9fa48632fd","isMergeCommit":true,"messageTitle":"Merge pull request #136 from DavinciDelta/eventDateChange","messageBody":"Update events","fileTypesAndContributionMap":{}}]}],"DavinciDelta":[{"date":"2023-10-05","commitResults":[{"hash":"20d84b8a2deaed74e86d4c49ff90766db2fd1d7d","isMergeCommit":false,"messageTitle":"Add AboutUs","messageBody":"Included my own about us\n","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":1}}}]},{"date":"2023-10-13","commitResults":[{"hash":"f816d329501fbc059fac7bc29b8449c0aa6d39ff","isMergeCommit":false,"messageTitle":"Basic abstract Command","messageBody":"Included the basic abstract command for reference, with delete code implemented\n","fileTypesAndContributionMap":{"functional-code":{"insertions":117,"deletions":0}}},{"hash":"c97d2cec899d51e82fa979133c029d496a59bb91","isMergeCommit":false,"messageTitle":"Revert \"Basic abstract Command\"","messageBody":"This reverts commit f816d329501fbc059fac7bc29b8449c0aa6d39ff.\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":117}}}]},{"date":"2023-10-14","commitResults":[{"hash":"66cb8f164903cc7b8dd1c4e2f37449f49b783a53","isMergeCommit":true,"messageTitle":"Merge pull request #19 from yingx9/WuXingYu-BasicStructure","messageBody":"Add XingYu\u0027s Command and Parser from iP project","fileTypesAndContributionMap":{}},{"hash":"fae2e8bde57a2bcdca664f910751520047b3cb86","isMergeCommit":false,"messageTitle":"Add resource","messageBody":"Include resource class with book class.\n\nInclude basic add and list commands for testing\n","fileTypesAndContributionMap":{"functional-code":{"insertions":115,"deletions":3}}},{"hash":"d168a5972836ae6563d2c2ff0f4dc4500e17bfb8","isMergeCommit":true,"messageTitle":"Merge from master","messageBody":"Include changes from master\n","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"18ae4568148b6a244a6954b2d645a6396383d92e","isMergeCommit":false,"messageTitle":"Add Delete Command","messageBody":"Added the delete command with it\u0027s parser\n","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":8}}}]},{"date":"2023-10-17","commitResults":[{"hash":"4b21bf920d2abd9b8d5ca763b6cb16a40a87e5ff","isMergeCommit":false,"messageTitle":"Add general validate and parse function","messageBody":"Include a validate and parse function that can be used for all command to decrease complexity of code\n","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":3}}},{"hash":"460604675bb122c09dd57d41481aad943423a7d2","isMergeCommit":false,"messageTitle":"Remove print statements","messageBody":"Remove debugging print statements\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}},{"hash":"9c24aadd4353ff76d44e33afc61d3d758704f474","isMergeCommit":false,"messageTitle":"Update Command","messageBody":"Remove redundant code and improve style\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":3}}},{"hash":"4d4e242a5a8b83bfae05457a81c2ae027d999c3b","isMergeCommit":false,"messageTitle":"Add DeleteCommand Testing","messageBody":"Included J unit testing for DeleteComand\n","fileTypesAndContributionMap":{"test-code":{"insertions":46,"deletions":0}}},{"hash":"862395cfe14800213003b307dcf087084245681f","isMergeCommit":false,"messageTitle":"Update DeleteCommandTest.java","messageBody":"Updated DeleteCommandTest\n","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":17}}},{"hash":"92e2f73b5371af344b6816b12e4013c4800300e6","isMergeCommit":false,"messageTitle":"Remove redundant imports","messageBody":"Removed redundant imports to improve clarity\n","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":2}}},{"hash":"360606f9d100648710f69f6c9b8ed59e9da91041","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into WuXingyu-ParsingAbstraction","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-18","commitResults":[{"hash":"dae3e42c416444c4b6515a99bdb72c4b35e06356","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into WuXingyu-ParsingAbstraction","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"29d5789812c41805fbd1bab9a073d8baa2881793","isMergeCommit":false,"messageTitle":"Update validate and parsing","messageBody":"Update parsing into abstract Command class\n","fileTypesAndContributionMap":{"functional-code":{"insertions":29,"deletions":27}}},{"hash":"7b07b79090bec34138f9cd269e9a17594cd4994c","isMergeCommit":false,"messageTitle":"Update style","messageBody":"Remove redundant imports\n","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":1}}},{"hash":"e2f835aeff05274f1bc1177563fd2ab439494762","isMergeCommit":false,"messageTitle":"Update AddCommand","messageBody":"Changed AddCommand isbn to i\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"bd37b380149d2f2f85f500c4d6da73dbe40e3fc3","isMergeCommit":false,"messageTitle":"Update genre","messageBody":"Change genre for add command\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"2240d9c6cdeaa91c620056f02f8f3af007701523","isMergeCommit":false,"messageTitle":"Improve validation","messageBody":"Included more validation checks for duplicate arguments\n\nAllow for aliasing for arguments\n","fileTypesAndContributionMap":{"functional-code":{"insertions":62,"deletions":15}}},{"hash":"da37d39f6e07a7a4d0171c5109158a737e7e91b0","isMergeCommit":false,"messageTitle":"Fix validator","messageBody":"Prevent clash of metacharacters in strings and capital letters with validator\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-23","commitResults":[{"hash":"9ca77c1f5398f3ee3e36892e95d939757a18b035","isMergeCommit":true,"messageTitle":"Merge pull request #65 from JoanneJo/JoanneAng-AddCommandJUnit","messageBody":"Add AddCommand JUnit Tests","fileTypesAndContributionMap":{}}]},{"date":"2023-10-24","commitResults":[{"hash":"f1c67d44a0c3306c28b454edfa5cc578ae3b17d9","isMergeCommit":true,"messageTitle":"Merge pull request #66 from yingx9/YingXia-EnableAssertion","messageBody":"Enable assertions in Gradle","fileTypesAndContributionMap":{}},{"hash":"fcbdbe6b9e56b76f011dd1383e5ebf1fd8d11eb6","isMergeCommit":false,"messageTitle":"Include assertion in DeleteCommand","messageBody":"Include a generic assertion for deleteCommand\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"c90927f278161ceb6bd90171ff4431ab5a81ddb7","isMergeCommit":true,"messageTitle":"Merge branch \u0027AddAssertion\u0027 into UpdateDeveloperGuide","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"85745dae00595ea292ea6bbc4b30c74c43f49ba0","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"Update the developer guide with the basic information\n","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":6}}}]},{"date":"2023-10-29","commitResults":[{"hash":"2a5c864c957d6ece547a674e1a9421c93155edc1","isMergeCommit":false,"messageTitle":"Fix and optimize testing for deleteCommand","messageBody":"Fix issue with delete where blank spaces causes an error\n\nImprove testing for DeleteCommand\n\nRemove unnecessary DeleteParser\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":27},"test-code":{"insertions":23,"deletions":32}}},{"hash":"6197ad013d13fa5b31d2a2d00e25493003ed5336","isMergeCommit":false,"messageTitle":"Remove unnecessary imports","messageBody":"remove data.book import from DeleteCommandTest\n","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"8eade84e05818203e4210c7f4a3b34f20b06e1a8","isMergeCommit":false,"messageTitle":"Fix issue with ParserTest","messageBody":"Introduce spacing for DeleteCommand and DeleteCommand test\n","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":1,"deletions":1}}},{"hash":"5676b7283ee33a09a617ee0530fd248ab053bc32","isMergeCommit":false,"messageTitle":"Update DeleteCommandTest.java","messageBody":"Update to improve style\n","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":4}}}]},{"date":"2023-10-31","commitResults":[{"hash":"99da8760a329363221b0d617f64b9541bd4c4803","isMergeCommit":false,"messageTitle":"Update Command","messageBody":"Remove aliasing and improved Variable names\n\nIncluded comments to improve readability\n","fileTypesAndContributionMap":{"functional-code":{"insertions":46,"deletions":42}}},{"hash":"88154068160914f8a7f20451d30d773b0afadab0","isMergeCommit":false,"messageTitle":"Add event commands","messageBody":"Add eventadd, eventlist and eventdelete commands to support keeping track of events\n\nEvent list is sorted by date\n","fileTypesAndContributionMap":{"functional-code":{"insertions":160,"deletions":2},"test-code":{"insertions":4,"deletions":0}}},{"hash":"33237ca1c19a03702b7ddcc5ad7d74dedbc7677d","isMergeCommit":false,"messageTitle":"Update event list variable name","messageBody":"Change variable name calendar into eventList to keep it consistent\n","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":11}}},{"hash":"699dfdd0a6cad228afbc568c9db6364f6b20c16e","isMergeCommit":false,"messageTitle":"Update ParserTest.java","messageBody":"Update ParserTest to include events in testProcessHelpCommand\n","fileTypesAndContributionMap":{"test-code":{"insertions":6,"deletions":1}}},{"hash":"135648c5a1b3eb4c149a07312cad94b2f064c45f","isMergeCommit":false,"messageTitle":"Add testing for event commands","messageBody":"Add testings for eventAdd, eventDelete, eventList\n","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":141,"deletions":0}}}]},{"date":"2023-11-01","commitResults":[{"hash":"0fad88e6ebdf13fbde509b55038c99279c59320c","isMergeCommit":false,"messageTitle":"Add event into DG and UG","messageBody":"Add information of events into DG and UG\n","fileTypesAndContributionMap":{"docs":{"insertions":165,"deletions":2}}},{"hash":"17697dbcbe1634948e82983a3984b1f8c14af707","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"Update DG for events\n","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":10}}}]},{"date":"2023-11-03","commitResults":[{"hash":"54b0afea991b33346395c519713d5072f8222727","isMergeCommit":false,"messageTitle":"Update UG for events","messageBody":"Update User Guide to include features for events, such as eventadd, eventlist nad eventdelete\n","fileTypesAndContributionMap":{"docs":{"insertions":80,"deletions":7}}},{"hash":"3d0862f6b459dcdd774310894c5e10f08b5e12a0","isMergeCommit":true,"messageTitle":"Merge pull request #111 from JoanneJo/JoanneAng-AddResources","messageBody":"Update UserGuide.md and Refactor Classes","fileTypesAndContributionMap":{}},{"hash":"5b2ec1f460d1665c04570194aa73e02f94eae002","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into UpdateGuides","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ec596924e9f1848fa261ff9200f7786faf63a73c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into UpdateGuides","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"13e735d0c0977dd744c19c167592cfc8dbaf548a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"Update userguide to remove overlap and redundant informations\n","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":15}}}]},{"date":"2023-11-04","commitResults":[{"hash":"c4b41f61e1e0f352952953b9f56a7f710ef729bd","isMergeCommit":false,"messageTitle":"Update events","messageBody":"Update event from Date to LocalDate to standardize\n","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":17},"test-code":{"insertions":10,"deletions":11}}},{"hash":"58ffbd1dea1b888633df6038147629e1061be767","isMergeCommit":false,"messageTitle":"Remove redundant imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":2}}}]}],"yingx9":[{"date":"2023-10-04","commitResults":[{"hash":"d2a39c983b779d162587aa54cdcc043d19acb42b","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}}]},{"date":"2023-10-05","commitResults":[{"hash":"b1a23ae973590faec4fa49548e661798cddc354c","isMergeCommit":false,"messageTitle":"Update AboutUs.md and add Portfolio Page","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":7}}}]},{"date":"2023-10-11","commitResults":[{"hash":"34113bf6369cf3e72c81bad632b546565825c15e","isMergeCommit":true,"messageTitle":"Merge pull request #1 from JoanneJo/JoanneAng-AboutUs","messageBody":"Add personal details to AboutUs.md","fileTypesAndContributionMap":{}}]},{"date":"2023-10-14","commitResults":[{"hash":"24a54a13e9bff5754c97196f670acb1db3f9c3fe","isMergeCommit":false,"messageTitle":"Add code from AddressBook","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1937,"deletions":0}}},{"hash":"4c73795256c18d337edb3cd0d8fd6e5e95854417","isMergeCommit":true,"messageTitle":"Merge pull request #16 from yingx9/YingXia-AddressBook","messageBody":"Add code from AddressBook","fileTypesAndContributionMap":{}},{"hash":"8fdb83fc66cf61cec1707849a12140f63547934c","isMergeCommit":false,"messageTitle":"Add XingYu\u0027s Command and Parser from iP project","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":125,"deletions":0}}},{"hash":"bffe4d35fbfddbd14885722e201bf230cd6a9453","isMergeCommit":false,"messageTitle":"Update ListCommand and edit Resource and Book","messageBody":"As Resource is a generic class, Book can inherit and override\ntoString to print its own specific details\n\nHence,\nResource.java: Add toString method to be overridden by Book\nBook.java: Override parent toString method\n","fileTypesAndContributionMap":{"functional-code":{"insertions":24,"deletions":5},"docs":{"insertions":1,"deletions":1}}},{"hash":"6dcad7eeea645efabb2c7991d22053542764e697","isMergeCommit":true,"messageTitle":"Merge pull request #27 from bnjm2000/add_HelpCommand","messageBody":"Add HelpCommand","fileTypesAndContributionMap":{}},{"hash":"8ebfcaf95769d42cdf6ff8effed30582b2abbf09","isMergeCommit":true,"messageTitle":"Merge pull request #28 from bnjm2000/add_ExitCommand","messageBody":"Add ExitCommand","fileTypesAndContributionMap":{}},{"hash":"8336568d113cb4e16f4c7936c6d8254bc5d4ec2f","isMergeCommit":true,"messageTitle":"Merge pull request #30 from bnjm2000/add_ExitCommand","messageBody":"Change syntax to \"exit\" and updated test","fileTypesAndContributionMap":{}}]},{"date":"2023-10-15","commitResults":[{"hash":"8365f041ce1578f5258123ae6f612456b752747f","isMergeCommit":true,"messageTitle":"Merge pull request #32 from 000verflow/Add-FindCommand","messageBody":"Add FindCommand class","fileTypesAndContributionMap":{}},{"hash":"e961ad179fefc5fe022232e8efaf73bbb1065a45","isMergeCommit":false,"messageTitle":"Update Listing by specific filters for ListCommand.Java","messageBody":"Librarians may want an overview of resources by categories such\nas tag and genre\n\nHence, add filter methods to ListCommand to filter by Tag, Genre,\nor Both\n","fileTypesAndContributionMap":{"functional-code":{"insertions":139,"deletions":8}}}]},{"date":"2023-10-16","commitResults":[{"hash":"ce80c867361f341512178783328995160bb24ca5","isMergeCommit":false,"messageTitle":"Update UserGuide.md for List and minor change to ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":4},"docs":{"insertions":11,"deletions":8}}},{"hash":"8c30d1ef8dbba12f7d7807c9c6c3809726b2e1d4","isMergeCommit":false,"messageTitle":"Update ListCommand to use lineSeparator() and add more checks","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":11}}},{"hash":"ed23a422c3bc47ee6e56abb377be77f13c27e4bc","isMergeCommit":false,"messageTitle":"Fix lines to not exceed 120 characters for coding standard","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":5}}},{"hash":"69362cc4634c29603bcee3690e6ac5cf11f530c8","isMergeCommit":true,"messageTitle":"Merge pull request #38 from bnjm2000/add_Junit","messageBody":"Add Junit","fileTypesAndContributionMap":{}},{"hash":"4e21bd1fc5c7dcf2ef84b90dd6e05e481e5b48f3","isMergeCommit":false,"messageTitle":"Add jUnit tests for ListCommand","messageBody":"To ensure ListCommand is works as intended, add tests such as:\n1. Ensure list does not crash SysLib if executed when there are no\nresources\n2. Ensure missing values for tag and genre filter throws exception\n3. Ensure listing with filters does not crash SysLib if there are\nno found resources matching filters\n","fileTypesAndContributionMap":{"test-code":{"insertions":101,"deletions":0}}},{"hash":"b62afec7114450326fdb9237456383a9845f62dd","isMergeCommit":false,"messageTitle":"Fix check style error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":13}}},{"hash":"871ae927c0777d5e302d720cf8a377459bac1304","isMergeCommit":false,"messageTitle":"Fix windows error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":2}}}]},{"date":"2023-10-17","commitResults":[{"hash":"446c9c1b9d6b76ce5b9b366d67eba021b3075894","isMergeCommit":true,"messageTitle":"Merge pull request #42 from bnjm2000/BenjaminNg_consistency","messageBody":"Fix consistency","fileTypesAndContributionMap":{}},{"hash":"61bca2d384d09bf9fce54fd2e5a13fa913fb028b","isMergeCommit":false,"messageTitle":"Fix bug where listing by genre crashes SysLib","messageBody":"When a book is added without a genre, SysLib crashes when listing\nby genre\n\nHence add a check to hasGenre method to return false when a book has\nno genre\n\nNote in future developments, if createBook changes its method of\ncreating genres array, this fix has to be updated\n","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0},"test-code":{"insertions":4,"deletions":1}}},{"hash":"8efd8319a62d5e716070bf29aadaa27690a176de","isMergeCommit":true,"messageTitle":"Merge pull request #44 from bnjm2000/BenjaminNg_FixHelpCommand","messageBody":"Fix HelpCommand","fileTypesAndContributionMap":{}},{"hash":"94f1c1b220672138c830e6ab79721ce84c1eb3da","isMergeCommit":false,"messageTitle":"Fix bug where multiple genres causes list filter to not work","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":7}}},{"hash":"7277e0d587c97e762d22c5a1e829b859b648b9b8","isMergeCommit":false,"messageTitle":"Update method of checking genre again for ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":4}}},{"hash":"ea49ab338b61b8cf5cdb56c7e4b3679a1b1a91b7","isMergeCommit":false,"messageTitle":"Add assertion to ensure ListCommand works as intended","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2}}},{"hash":"5eb00e5f0f4e350a35924a1cb0fe5faa6d6201e6","isMergeCommit":true,"messageTitle":"Merge pull request #54 from bnjm2000/BenjaminNg_addAssertandLogging","messageBody":"Add assert and logging for HelpCommand and ExitCommand","tags":["v1.0"],"fileTypesAndContributionMap":{}}]},{"date":"2023-10-19","commitResults":[{"hash":"d25c9b66e18042f05cf523e9875bdd7eba9be49d","isMergeCommit":true,"messageTitle":"Merge pull request #47 from DavinciDelta/WuXingyu-ParsingAbstraction","messageBody":"Add general validate and parse function","fileTypesAndContributionMap":{}},{"hash":"8e0d91820deea617c37ecaf1dfc69fefade72c9a","isMergeCommit":false,"messageTitle":"Update logic and code quality of ListCommand","messageBody":"There are also many repeats of System.lineSeparator + \"------\" etc\n\nHence update constant LINEDIVIDER in UI class to be public, and add\nSEPARATOR_LINEDIVIDER constant for use to tidy up code\n","fileTypesAndContributionMap":{"functional-code":{"insertions":107,"deletions":129},"test-code":{"insertions":14,"deletions":13}}}]},{"date":"2023-10-23","commitResults":[{"hash":"8507b3cd0107300ca6e7645b7ea6b0d311e5b9d2","isMergeCommit":false,"messageTitle":"Enable assertions in Gradle","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-24","commitResults":[{"hash":"41ef8d4d05c823217fd470fd2b0d5ce75cc9b755","isMergeCommit":true,"messageTitle":"Merge pull request #68 from DavinciDelta/AddAssertion","messageBody":"Include assertion in DeleteCommand","fileTypesAndContributionMap":{}},{"hash":"b36525d5ee13cdc1f2ef8fb4a9472930658ca9b1","isMergeCommit":true,"messageTitle":"Merge pull request #69 from DavinciDelta/UpdateDeveloperGuide","messageBody":"Update developer guide","fileTypesAndContributionMap":{}},{"hash":"7b8ffa67e21258e44d6123138f6526cf6ec70478","isMergeCommit":false,"messageTitle":"Repurpose style, architecture.puml from Addressbook","messageBody":"Add a draft architecture diagram\n","fileTypesAndContributionMap":{"docs":{"insertions":110,"deletions":0}}}]},{"date":"2023-10-25","commitResults":[{"hash":"0aea8979e3591fdba501ce8032615bd126a1555c","isMergeCommit":false,"messageTitle":"Add more structure to the Developer\u0027s Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":26,"deletions":0}}},{"hash":"b83bc4d4d00080b7f0ce0afc2896a051e7171889","isMergeCommit":false,"messageTitle":"Add Sequence Diagram for ListCommand","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":84,"deletions":0}}}]},{"date":"2023-10-26","commitResults":[{"hash":"f09c1bf2895d25e06455027821024ce74864ead9","isMergeCommit":true,"messageTitle":"Merge pull request #74 from JoanneJo/JoanneAng-DeveloperGuide","messageBody":"Update DeveloperGuide.md","fileTypesAndContributionMap":{}},{"hash":"474936b9006df0c0a61054b29262af71487c4ffa","isMergeCommit":false,"messageTitle":"Update ListCommand and List Implementation of DG","messageBody":"Add a Messages class to format messages with frequently used\nline separators and dividers\n\nMove hasGenre to Resources class so it can be used for other purpose\n\nUpdate more details about ListCommand to DG\n","fileTypesAndContributionMap":{"functional-code":{"insertions":95,"deletions":75},"docs":{"insertions":16,"deletions":6},"test-code":{"insertions":10,"deletions":11}}},{"hash":"59cae2daeb0fb11a82e05710e3f9f504f5748974","isMergeCommit":false,"messageTitle":"Fix checkstyle error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"73265af04a474da052dbbe9cdda0066e4c0cf1a0","isMergeCommit":false,"messageTitle":"Fix ListCommandTest checkstyle error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":1}}},{"hash":"10159022ea4dc325910969bd62ba81407ec235cf","isMergeCommit":false,"messageTitle":"Update List DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":13,"deletions":5}}},{"hash":"2d5ffa410ef7ee5a7a7dd822881d60585ac03a1e","isMergeCommit":true,"messageTitle":"Merge pull request #76 from bnjm2000/BenjaminNg-DG-Manual-Testing","messageBody":"Add more user stories as well as manual testing","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"e1ef61a3c639ad009ebfada3524d13be611ffb01","isMergeCommit":true,"messageTitle":"Merge pull request #77 from 000verflow/update-developer-guide","messageBody":"Add find command details on DG","fileTypesAndContributionMap":{}}]},{"date":"2023-10-30","commitResults":[{"hash":"3e6a872f6c661d66560c016a3d14fd8d08cb0210","isMergeCommit":false,"messageTitle":"Add EditCommand feature and update User Guide","messageBody":"Librarians may want to update resources due to mistakes or outdated\ninformation\n\nHence, add a new Edit feature to update the title, author, tag, or\ngenre and update the Parser with new edit command\n\nUpdate User Guide with details of new Edit Command\n\nAdd tests for EditCommand\n\nIn future update:\n-Update help message with new Edit Command\n-Update genre editing to allow user to edit a specific genre rather\nthan all of them\n","fileTypesAndContributionMap":{"functional-code":{"insertions":154,"deletions":0},"docs":{"insertions":25,"deletions":2},"test-code":{"insertions":93,"deletions":16}}}]},{"date":"2023-10-31","commitResults":[{"hash":"853d35b9cf6126e242da4d2ec0c83c3d6ca44425","isMergeCommit":true,"messageTitle":"Merge pull request #88 from DavinciDelta/RemoveAliasing","messageBody":"Update Command","fileTypesAndContributionMap":{}},{"hash":"60e358edb08c0b688799b4bbc0d4ba6f902bd800","isMergeCommit":false,"messageTitle":"Add variable dateReceived to Resource","messageBody":"Librarians may want to track how long a resource has been in their\ncare\n\nHence, add a receivedDate attribute to resource which automatically\ntakes the current system time. Use current system time in order\nto reduce the amount of input a user has to type and it is also\nmore logical to take the current system time\n\nUpdate toString() and tests cases accordingly\n","fileTypesAndContributionMap":{"functional-code":{"insertions":17,"deletions":1},"test-code":{"insertions":25,"deletions":16}}},{"hash":"9662c1ee2ffd733173ec4a18f87e93b7c860d9a0","isMergeCommit":true,"messageTitle":"Merge pull request #90 from bnjm2000/BenjaminNg-FixParser-Status","messageBody":"Fix incorrect return in parser for Status","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"b83d4e7dda0ede511ced81bbb5945bb1d65cade4","isMergeCommit":false,"messageTitle":"Add CommandResult class and feedbackToUser variable to all commands","messageBody":"All commands currently print every statement which may look messy\nand hard to get its output message\n\nHence, instead of printing every string, create a feedbackToUser\nstring in every Command class and add messages to that variable\n\nCommmandResult then stores feedbackToUser and Parser prints the\nfinal result at the end of command execution\n","fileTypesAndContributionMap":{"functional-code":{"insertions":68,"deletions":19},"test-code":{"insertions":6,"deletions":12}}}]},{"date":"2023-11-02","commitResults":[{"hash":"aba3def8a30e7b7e109426275fb0c54ea674dfd9","isMergeCommit":true,"messageTitle":"Merge pull request #105 from 000verflow/Add-Storage","messageBody":"Add storage","fileTypesAndContributionMap":{}},{"hash":"ad173f6237166e90d3adc25b0efa8447327951b3","isMergeCommit":false,"messageTitle":"Add Logging and Assertions for EditCommand, ListCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":50,"deletions":3}}},{"hash":"8700ccda9e7d0b98001f35e905284d6d250598b5","isMergeCommit":true,"messageTitle":"Merge pull request #108 from 000verflow/update-findsequencediagram","messageBody":"Update find sequence diagram, add minor UI enhancement","fileTypesAndContributionMap":{}},{"hash":"b076360856742c051a34fe006cb0c452576ae6f5","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into YingXia-AddEditListLogging","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"baa86d2c9fe402d1671a3bf4f7de3bf2c66024b7","isMergeCommit":false,"messageTitle":"Fix logging","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":12}}},{"hash":"8f12bc97f303db6f67de9e80f0fbcbd8e37c2d1e","isMergeCommit":false,"messageTitle":"Update User Guide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":0}}},{"hash":"bf85077b8ffc0742d3e57802761516c0a7f71acc","isMergeCommit":true,"messageTitle":"Merge pull request #109 from 000verflow/update-ug","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}}]},{"date":"2023-11-03","commitResults":[{"hash":"9f6ee8c9997c1e28b2502a43be0638ec587bb981","isMergeCommit":true,"messageTitle":"Merge pull request #112 from 000verflow/update-findcommand-filtering","messageBody":"Update findcommand filtering and fix storage class bug","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"94fe4b60581fe5b5952d12071c9ccab7c28ec8ca","isMergeCommit":true,"messageTitle":"Merge pull request #118 from 000verflow/add-findcommandfilters","messageBody":"Add findcommandfilters","fileTypesAndContributionMap":{}},{"hash":"7dcf3be8e15f5e04d190269e18375c3ba337d935","isMergeCommit":false,"messageTitle":"Update Overall Architecture Diagram for Storage and Data component","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":20,"deletions":6}}},{"hash":"2026ade377e8f292bdb80d5d50e4b44962b3af19","isMergeCommit":false,"messageTitle":"Add Filter by Status for List Command and fix logging for List, Edit","messageBody":"Librarians may want get an overview of the status of resources\n\nHence, add filter by status to list for AVAILABLE, BORROWED, LOST\nand add more test cases\n\nFix list and edit logging where ./runtest.bat fails due to missing\nlog directory\n\nRename Messages class to FormatMessages to reflect its purpose\nclearly\n","fileTypesAndContributionMap":{"functional-code":{"insertions":76,"deletions":22},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":41,"deletions":5}}},{"hash":"c0634943399388c21062ea98241665384f5ff8b3","isMergeCommit":false,"messageTitle":"Update user guide to reflect new status filtering","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":4}}},{"hash":"5f6341f653300af5a4b1edbcd9de9d5f5d0436bf","isMergeCommit":true,"messageTitle":"Merge pull request #135 from 000verflow/update-storageclass-whitespacebug","messageBody":"Update storageclass whitespacebug","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"000verflow":{"docs":212,"functional-code":663,"test-code":154,"other":1},"bnjm2000":{"docs":191,"functional-code":231,"test-code":333},"JoanneJo":{"docs":261,"functional-code":488,"test-code":60},"DavinciDelta":{"docs":203,"functional-code":354,"test-code":193},"yingx9":{"docs":290,"functional-code":542,"test-code":220,"other":1}},"authorContributionVariance":{"000verflow":114668.82,"bnjm2000":12735.908,"JoanneJo":10584.871,"DavinciDelta":6465.844,"yingx9":97416.03},"authorDisplayNameMap":{"000verflow":"CS2113T-W11-1 VELU..LAJI","bnjm2000":"CS2113T-W11-1 BENJ..MING","JoanneJo":"CS2113T-W11-1 JOAN..LING","DavinciDelta":"CS2113T-W11-1 WU X..NGYU","yingx9":"CS2113T-W11-1 LOKE.. XIA"}} diff --git a/AY2324S1-CS2113T-W11-2_tp_master/authorship.json b/AY2324S1-CS2113T-W11-2_tp_master/authorship.json index 904e3cc..a297544 100644 --- a/AY2324S1-CS2113T-W11-2_tp_master/authorship.json +++ b/AY2324S1-CS2113T-W11-2_tp_master/authorship.json @@ -1 +1 @@ -[{"path":"README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/6c982946-3165-41ec-917a-54c46c30b012)","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the Command Line Interface (CLI). ","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient! ","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"Useful links:","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"* [About Us](https://ay2324s1-cs2113t-w11-2.github.io/tp/AboutUs.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"* [User Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"* [Developer Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html)","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":12,"-":1}},{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" mainClass.set(\"seedu.wildwatch.WildWatch\")","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" archiveBaseName.set(\"wildwatch\")","lastModifiedDate":"2023-10-09"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"woodenclock":3,"-":44}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"|-------------------------------------------------------------------------------------------------------|:-----------:|:----------------------------------------:|:---------------------------------------------------------------------------------------------------------:|","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"| ![](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/252865bb-811e-48b1-9777-6c01b98500b1) | Lee Sungmin | [Github](https://github.com/woodenclock) | [Portfolio](https://github.com/AY2324S1-CS2113T-W11-2/tp/blob/master/docs/team/leesungmin.md#lee-sungmin) |","lastModifiedDate":"2023-10-13"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"| ![](https://via.placeholder.com/100.png?text\u003dPhoto) |Tang Zhen En | [Github](https://github.com/tangzhenen) | [Portfolio](docs/team/johndoe.md) |","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"| ![](images/person.png) | Lien Cai Ting | [Github](https://github.com/lctxct) | [Portfolio](https://github.com/AY2324S1-CS2113T-W11-2/tp/blob/master/docs/team/caiting.md) |","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"| ![](https://via.placeholder.com/100.png?text\u003dPhoto) | John Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md) |","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"woodenclock":3,"tangzhenen":1,"lctxct":2,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch Developer Guide 🦣","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"## Table of Contents ","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"- [Introduction](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#introduction-)","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" - [Purpose](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#purpose)","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" - [Audience](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#audience)","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" - [How to use the Developer Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#how-to-use-the-developer-guide)","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" - [Legend](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#legend)","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"- [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#quick-start-)","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"- [Design \u0026 Implementation](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#design--implementation-)","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"- [Product Scope](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#product-scope-)","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" - [Target User Profile](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#target-user-profile)","lastModifiedDate":"2023-10-21"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" - [Value Proposition](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#value-proposition)","lastModifiedDate":"2023-10-21"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"- [User Stories](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#user-stories-)","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"- [Non-Funtional Requirements](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#non-functional-requirements-)","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"- [Manual Testing](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#manual-testing-)","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"- [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#command-summary-)","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"- [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary-)","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"- [Acknowledgements](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#acknowledgements-)","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"## Introduction 🐻","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the [Command Line Interface (CLI)](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary). ","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data required in everyday operations of the wildlife reserve. ","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"### Purpose","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"This document specifies the architectural and software design decisions in the implementation of the WildWatch. ","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"For a detailed guide on how to use the program and explanations on the individual commands, we have our very own [**WildWatch User Guide**](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html) for your perusal.","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"### Audience","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"The intended audience for this document are developers who would like to look under the hood and understand how WildWatch works, and are looking to introduce new functionalities into WildWatch.","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":"### How to use the Developer Guide ","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":"- Are you new here? ","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"No worries, head to the [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#quick-start-) page.","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"- Lost among the pages? ","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"Head to the [Table of Contents](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents) to look for the right pages. ","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"- Need help with the functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"Head to the [Features](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#features-) page for detailed guidance. ","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"- Do you have a question for us? ","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":"Head to the [FAQ](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#faq-) page. ","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"- Do you want a concise summary of all functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"Head to the [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#command-summary-) page for a summary of all commands.","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":"- Not sure what that word meant? ","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":"Head to the [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary-) page for its meaning. ","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"### Legend","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":"| Symbol | Meaning |","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":"| -------------- |------------------------------------------------------------ |","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"| ❗ IMPORTANT | These are important instructions that you should follow. |","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"| ✏ Note | These are important details that you should take note of. |","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":"| ⬆ Back to top | Click to scroll back up to the `Table of Contents`. |","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"| 🐵 🦊 🦁 | Animals indicate you have reached a new section. |","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":"## Quick Start 🐵","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":"1. Ensure you have Java 11 or above installed in your Computer. (What is my [Java version](https://www.java.com/en/download/help/version_manual.html)?)","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":"2. Download the latest `WildWatch.jar` from [here](https://github.com/AY2324S1-CS2113T-W11-2/tp/releases).","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"woodenclock"},"content":"3. Copy the file to the folder you want to use as the home folder for your WildWatch.","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":"4. Open a command terminal, `cd` into the folder you put the jar file in, and run the following command: `java -jar WildWatch.jar`.","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":"You should see the welcome screen as the diagram below.","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":"5. Type commands beside `\u003e\u003e\u003e` below the horizontal line and press `Enter` to execute it. Some example commands you can try:","lastModifiedDate":"2023-10-31"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":"- `help` : Shows the help page. ","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":"- `bye` : Exits the program. ","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"woodenclock"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":78,"author":{"gitId":"woodenclock"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"woodenclock"},"content":"____ __ ____ __ __ _______","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"woodenclock"},"content":"\\ \\ / \\ / / | | | | | \\","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"woodenclock"},"content":" \\ \\/ \\/ / | | | | | .--. |","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"woodenclock"},"content":" \\ / | | | | | | | |","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"woodenclock"},"content":" \\ /\\ / | | | `----.| \u0027--\u0027 |","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"woodenclock"},"content":" \\__/ \\__/ |__| |_______||_______/","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"woodenclock"},"content":"____ __ ____ ___ .___________. ______ __ __","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"woodenclock"},"content":"\\ \\ / \\ / / / \\ | | / || | | |","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"woodenclock"},"content":" \\ \\/ \\/ / / ^ \\ `---| |----`| ,----\u0027| |__| |","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"woodenclock"},"content":" \\ / / /_\\ \\ | | | | | __ |","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"woodenclock"},"content":" \\ /\\ / / _____ \\ | | | `----.| | | |","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"woodenclock"},"content":" \\__/ \\__/ /__/ \\__\\ |__| \\______||__| |__|","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"woodenclock"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"woodenclock"},"content":"Hello there! Welcome to WildWatch!","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"woodenclock"},"content":"Checking if \"WildWatch.txt\" already exists...","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"woodenclock"},"content":"File does not exist.","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"woodenclock"},"content":"Creating new file...","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"woodenclock"},"content":"File created successfully.","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"woodenclock"},"content":"What would you like to do?","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"woodenclock"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"woodenclock"},"content":"\u003e\u003e\u003e ","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"woodenclock"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":103,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":104,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":105,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"woodenclock"},"content":"## Design \u0026 Implementation 🐹","lastModifiedDate":"2023-11-03"},{"lineNumber":108,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":109,"author":{"gitId":"woodenclock"},"content":"### System Architecture","lastModifiedDate":"2023-10-30"},{"lineNumber":110,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"woodenclock"},"content":"![System Architecture](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/90309a3c-f784-4ffb-8eef-65735c05ec52)","lastModifiedDate":"2023-11-01"},{"lineNumber":112,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"woodenclock"},"content":"The **_Architecture Diagram_** above shows a high-level overview of the architectural design of WildWatch. ","lastModifiedDate":"2023-11-01"},{"lineNumber":114,"author":{"gitId":"woodenclock"},"content":"Actual detailed implementation may differ from the architectural diagram. ","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"woodenclock"},"content":"(e.g., `Parser` in the diagram encompasses the `Input`, `Error`, and `Parser` packages). ","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"woodenclock"},"content":"WildWatch is comprised of 7 major components. ","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"woodenclock"},"content":"- `Main`: Entry point of the program.","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"woodenclock"},"content":"- `UI`: A class that receives input from, and prints output to the user.","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"woodenclock"},"content":"- `Parser`: A class that processes and interpretes the input command of the user.","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"woodenclock"},"content":"- `Command`: A set of classes that does specific task according to the command of the user.","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"woodenclock"},"content":"- `EntryList`: A class that stores all the wildlife data, while the program is running.","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"woodenclock"},"content":"- `Entry`: A class that stores individual wildlife data, while the program is running.","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"woodenclock"},"content":"- `Storage`: A class that saves and retrieves all the wildlife data from the local storage","lastModifiedDate":"2023-11-04"},{"lineNumber":125,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":126,"author":{"gitId":"woodenclock"},"content":"![Architecture Sequence Diagram](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/6bea5165-aa78-4b3e-baf0-2e9ced109161) ","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"woodenclock"},"content":"The **_Generic Sequence Diagram_** above shows a shows how the components in the architecture interact with each other for a generic command input in WildWatch. ","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"woodenclock"},"content":"\u003e ✏ Note: `Command` here is a placeholder, and will be replaced by actual commands. e.g., `ListCommand`.","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"lctxct"},"content":"### Parser component ","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"lctxct"},"content":"The `Parser` component is responsible for for parsing an input from the user, and returns an `XYZCommand` class. ","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"lctxct"},"content":"### Command component","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"lctxct"},"content":"![](images/AddSequenceDiagram.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":138,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":140,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":141,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":143,"author":{"gitId":"woodenclock"},"content":"## Product scope 🦁","lastModifiedDate":"2023-11-03"},{"lineNumber":144,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":145,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":146,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":147,"author":{"gitId":"woodenclock"},"content":"Target user profile for WildWatch is the clerks working in wildlife reserves, who manages the wildlife data.","lastModifiedDate":"2023-10-31"},{"lineNumber":148,"author":{"gitId":"woodenclock"},"content":"Since our program is interacted through the [Command Line Interface (CLI)](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary), someone who can type fast will definitely benefit from WildWatch.","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"woodenclock"},"content":"This would significantly boost one\u0027s productivity.","lastModifiedDate":"2023-10-31"},{"lineNumber":150,"author":{"gitId":"woodenclock"},"content":"Since clerks are already accustomed to typing and working with a computer, this program would be ideal for this user profile.","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":152,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":153,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":154,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":155,"author":{"gitId":"woodenclock"},"content":"- **Effortless User Experience**: Designed with simplicity in mind, our product ensures that even users with minimal technical experience can easily navigate and interact with the software.","lastModifiedDate":"2023-10-31"},{"lineNumber":156,"author":{"gitId":"woodenclock"},"content":"- **Rapid CLI Interaction**: Unlike traditional GUIs that require multiple clicks and drags, our Command Line Interface (CLI) offers direct command inputs, allowing for faster and more efficient operations.","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"woodenclock"},"content":"- **Light \u0026 Versatile**: Built to be lean and light, our program ensures seamless performance across a variety of devices, as long as Java is installed, from high-end workstations to older laptops. Regardless of your computer\u0027s specifications, our product guarantees a smooth and efficient functioning.","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"woodenclock"},"content":"- **Robust Data Protection**: Say goodbye to the vulnerabilities of paper records! Our digital solution offers enhanced data protection, ensuring your records remain safe from damage, loss, or unauthorized access. With advanced encryption and backup mechanisms in place, your data\u0027s safety is our priority.","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"woodenclock"},"content":"- **Eco-Friendly**: Transition from paper to digital and contribute to a greener planet. Not only does this transition reduce clutter and the risk of loss, but it also significantly diminishes your carbon footprint.","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"woodenclock"},"content":"- **Cost-Effective**: Eliminate the recurring costs of paper, printing, and storage. With our solution, you\u0027ll experience a noticeable reduction in operational expenses while benefiting from advanced data management capabilities.","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":162,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"woodenclock"},"content":"## User Stories 🦊","lastModifiedDate":"2023-11-03"},{"lineNumber":167,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":168,"author":{"gitId":"-"},"content":"|Version| As a ... | I want to ... | So that I can ...|","lastModifiedDate":"2020-05-24"},{"lineNumber":169,"author":{"gitId":"-"},"content":"|--------|----------|---------------|------------------|","lastModifiedDate":"2020-05-24"},{"lineNumber":170,"author":{"gitId":"woodenclock"},"content":"|v1.0|new user|see help instructions|refer to them when I forget how to use the application|","lastModifiedDate":"2023-10-21"},{"lineNumber":171,"author":{"gitId":"woodenclock"},"content":"|v1.0|zoo clerk|add an animal entry|record the animals in the zoo, and refer to them afterwards|","lastModifiedDate":"2023-10-21"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":"|v1.0|zoo clerk|delete an animal entry|remove redundant or invalid animal entry|","lastModifiedDate":"2023-10-21"},{"lineNumber":173,"author":{"gitId":"woodenclock"},"content":"|v1.0|zoo clerk|list all the entries|see what entries I have entered previously, and refer to them|","lastModifiedDate":"2023-10-21"},{"lineNumber":174,"author":{"gitId":"-"},"content":"|v2.0|user|find a to-do item by name|locate a to-do without having to go through the entire list|","lastModifiedDate":"2020-05-24"},{"lineNumber":175,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":176,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":177,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":178,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":179,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":180,"author":{"gitId":"woodenclock"},"content":"## Non-Functional Requirements 🐯","lastModifiedDate":"2023-11-03"},{"lineNumber":181,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":182,"author":{"gitId":"-"},"content":"{Give non-functional requirements}","lastModifiedDate":"2020-05-24"},{"lineNumber":183,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":184,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":185,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":188,"author":{"gitId":"woodenclock"},"content":"## Manual Testing 🐼","lastModifiedDate":"2023-11-03"},{"lineNumber":189,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":190,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"},{"lineNumber":191,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":192,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":194,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":195,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":196,"author":{"gitId":"woodenclock"},"content":"## Command Summary 🐱","lastModifiedDate":"2023-11-03"},{"lineNumber":197,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":198,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":199,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":200,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":201,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":202,"author":{"gitId":"woodenclock"},"content":"## Glossary 🐨","lastModifiedDate":"2023-11-03"},{"lineNumber":203,"author":{"gitId":"woodenclock"},"content":"We are here to help you with terminologies used in the user guide, that may not be familiar to you.","lastModifiedDate":"2023-11-03"},{"lineNumber":204,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"woodenclock"},"content":"| Terminology | Meaning |","lastModifiedDate":"2023-11-03"},{"lineNumber":206,"author":{"gitId":"woodenclock"},"content":"| -------------- |------------------------------------------------------------|","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"woodenclock"},"content":"| Command Line Interface | A way to communicate with your computer using texts. |","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":209,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":210,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":213,"author":{"gitId":"woodenclock"},"content":"## Acknowledgements 🐶","lastModifiedDate":"2023-11-03"},{"lineNumber":214,"author":{"gitId":"woodenclock"},"content":"[woodenclock](https://github.com/woodenclock/ip.git) - Reference ","lastModifiedDate":"2023-11-01"},{"lineNumber":215,"author":{"gitId":"woodenclock"},"content":"[AB3 Developer Guide](https://se-education.org/addressbook-level3/DeveloperGuide.html) - Reference ","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"woodenclock"},"content":"Meet the [people](https://ay2324s1-cs2113t-w11-2.github.io/tp/AboutUs.html) behind WildWatch! ","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":185,"lctxct":6,"-":29}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/a44a2292-9ca1-4ab8-b585-782b0406d61c)","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the Command Line Interface (CLI). ","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient! ","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2019-07-29"},{"lineNumber":10,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"* [About Us](https://ay2324s1-cs2113t-w11-2.github.io/tp/AboutUs.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"* [User Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"* [Developer Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":10,"-":4}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch User Guide 🐘","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"## Table of Contents ","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"- [Introduction](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#introduction-)","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" - [How to use the User Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#how-to-use-the-user-guide)","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" - [Legend](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#legend)","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"- [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#quick-start-)","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"- [Features](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#features-)","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" - [Adding Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#1-adding-entries-add): `add`","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" - [Standard Mode](#11-standard-mode)","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":" - [Interactive Mode](#12-interactive-mode-add-i)","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" - [Deleting Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#2-deleting-entries-delete): `delete`","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" - [Listing Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#3-listing-entries-list): `list`","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" - [Editing Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#4-editing-entries-edit): `edit`","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" - [Summarizing Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#5-summarizing-entries-summary): `summary`","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" - [Exporting Entries](#6-exporting-your-entries-export): `export`","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" - [Getting Help](#7-getting-help--help): `help` ","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"- [FAQ](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#faq-)","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"- [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#command-summary-)","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"- [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#glossary-)","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"## Introduction 🐻","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the [Command Line Interface (CLI)](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#glossary-). ","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient!","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"### How to use the User Guide ","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"- Are you new here? ","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"No worries, head to the [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#quick-start-) page, and you will be up and running in no time! ","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"- Lost among the pages? ","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"Head to the [Table of Contents](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents) to look for the right pages. ","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":"- Need help with the functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":"Head to the [Features](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#features-) page for detailed guidance. ","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"- Do you have a question for us? ","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"Head to the [FAQ](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#faq-) page. ","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"- Do you want a concise summary of all functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"Head to the [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#command-summary-) page for a summary of all commands.","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"- Not sure what that word meant? ","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"Head to the [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#glossary-) page for its meaning. ","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"### Legend","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" Symbol | Meaning","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" -------------- |------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" ❗ IMPORTANT | These are important instructions that you should follow. ","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" ⬆ Back to top | Click to scroll back up to the `Table of Contents`.","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" 🐵 🦊 🦁 | Your cute animal friends pop up to let you know that you have reached a new section.","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"## Quick Start 🐵","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"1. Ensure you have Java 11 or above installed in your Computer. (What is my [Java version](https://www.java.com/en/download/help/version_manual.html)?)","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":"2. Download the latest `WildWatch.jar` from [here](https://github.com/AY2324S1-CS2113T-W11-2/tp/releases).","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":"3. Copy the file to the folder you want to use as the home folder for your WildWatch.","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":"4. Open a command terminal, `cd` into the folder you put the jar file in, and run the following command: `java -jar WildWatch.jar`.","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":"You should see the welcome screen as the diagram below.","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":"5. Type commands beside `\u003e\u003e\u003e` and press `Enter` to execute it. (e.g. typing `help` and pressing `Enter` will show the help page).","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"woodenclock"},"content":"Some example commands you can try:","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":"- `list` : Lists all entries. ","lastModifiedDate":"2023-10-28"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":"- `bye` : Exits the program. ","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/c110856f-dd16-4c5c-8205-446d86425ddb)","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":78,"author":{"gitId":"woodenclock"},"content":"## Features 🦊","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"woodenclock"},"content":"\u003e ❗ IMPORTANT","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"woodenclock"},"content":"\u003e * Capitalized words between angle brackets `\u003c \u003e` are information to be written appropriately by the user.","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"woodenclock"},"content":"\u003e * E.g., `delete \u003cINDEX\u003e` should be `delete 2`","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":84,"author":{"gitId":"imaginarys96"},"content":"### 1. Adding Entries: `add`","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"woodenclock"},"content":"Adds a new entry to the system.","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":"#### 1.1 Standard Mode ","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"woodenclock"},"content":"Format: `add D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e`","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"woodenclock"},"content":"`\u003cdate\u003e` should be in the format **DD-MM-YY**","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"woodenclock"},"content":"Example: ","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/db83c0d5-5ba6-4db7-9f57-bb86b4f4cc07)","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":95,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":96,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":"#### 1.2 Interactive Mode: `add i/`","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":"If you\u0027re prone to forgetting fields to include in the `add` command, have no fear, we\u0027ve got your back! You may choose to use the `add i/` command instead, which triggers the interactive add mode. ","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":"It helpfully prompts you for data each step of the way, and notifies you when you\u0027ve left a mandatory field blank, so you don\u0027t have to worry about getting it wrong!","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":"Format: `add i/`","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":"![image](https://github.com/lctxct/tp/assets/70379887/21db0b5d-1f76-40b0-a73d-92fbc5204b04)","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":"[⬆ Back to top](#table-of-contents)","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":107,"author":{"gitId":"imaginarys96"},"content":"### 2. Deleting Entries: `delete`","lastModifiedDate":"2023-10-28"},{"lineNumber":108,"author":{"gitId":"woodenclock"},"content":"Deletes an entry. ","lastModifiedDate":"2023-10-25"},{"lineNumber":109,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":110,"author":{"gitId":"woodenclock"},"content":"Format: `delete INDEX`","lastModifiedDate":"2023-10-25"},{"lineNumber":111,"author":{"gitId":"woodenclock"},"content":"Deletes the entry at the specified INDEX. ","lastModifiedDate":"2023-10-25"},{"lineNumber":112,"author":{"gitId":"woodenclock"},"content":"The index refers to the index number shown in the displayed entry list.","lastModifiedDate":"2023-10-25"},{"lineNumber":113,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":114,"author":{"gitId":"woodenclock"},"content":"\u003e❗ IMPORTANT","lastModifiedDate":"2023-10-29"},{"lineNumber":115,"author":{"gitId":"woodenclock"},"content":"\u003e * Index must be a positive integer 1, 2, 3, ...","lastModifiedDate":"2023-10-25"},{"lineNumber":116,"author":{"gitId":"woodenclock"},"content":"\u003e * Deleted items may not be recoverable","lastModifiedDate":"2023-10-25"},{"lineNumber":117,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":118,"author":{"gitId":"woodenclock"},"content":"Example: ","lastModifiedDate":"2023-10-25"},{"lineNumber":119,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/6c43700c-909b-490e-b497-ef370664ff9e)","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":121,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":122,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":123,"author":{"gitId":"imaginarys96"},"content":"### 3. Listing Entries: `list`","lastModifiedDate":"2023-10-28"},{"lineNumber":124,"author":{"gitId":"woodenclock"},"content":"Shows a list of all entries of wildlife in the WildWatch so far.","lastModifiedDate":"2023-10-25"},{"lineNumber":125,"author":{"gitId":"woodenclock"},"content":"Shows useful information about each entry.","lastModifiedDate":"2023-10-25"},{"lineNumber":126,"author":{"gitId":"woodenclock"},"content":"Information such as the species, name, age, gender, size, remarks are shown together.","lastModifiedDate":"2023-10-25"},{"lineNumber":127,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":128,"author":{"gitId":"woodenclock"},"content":"Format: `list` ","lastModifiedDate":"2023-10-25"},{"lineNumber":129,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":130,"author":{"gitId":"woodenclock"},"content":"Example: ","lastModifiedDate":"2023-10-25"},{"lineNumber":131,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/ef21314f-fb23-4bd6-bcfd-fddfa8fb0330)","lastModifiedDate":"2023-10-30"},{"lineNumber":132,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":133,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":134,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":135,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":136,"author":{"gitId":"woodenclock"},"content":"### 4. Editing Entries: `edit`","lastModifiedDate":"2023-10-29"},{"lineNumber":137,"author":{"gitId":"imaginarys96"},"content":"Edits an entry in the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":138,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":139,"author":{"gitId":"imaginarys96"},"content":"Format: `edit I/\u003cINDEX\u003e D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e`","lastModifiedDate":"2023-10-29"},{"lineNumber":140,"author":{"gitId":"imaginarys96"},"content":"`\u003cdate\u003e` should be in the format **DD-MM-YY**","lastModifiedDate":"2023-10-29"},{"lineNumber":141,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"imaginarys96"},"content":"`I/\u003cINDEX\u003e` argument is required.","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"imaginarys96"},"content":"Example:","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":146,"author":{"gitId":"imaginarys96"},"content":"edit I/1 D/02-03-24 S/Annam Leaf Turtle N/Ariel R/Injured left flipper","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":148,"author":{"gitId":"imaginarys96"},"content":"The following entry has been edited:","lastModifiedDate":"2023-10-29"},{"lineNumber":149,"author":{"gitId":"imaginarys96"},"content":"Date: [02-04-2024] | Species: [Annam Leaf Turtle] | Name: [Javier] | Remark: [Injured right flipper]","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":151,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":152,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"imaginarys96"},"content":"edit I/1 S/Green Leaf Turtle","lastModifiedDate":"2023-10-29"},{"lineNumber":154,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"imaginarys96"},"content":"The following entry has been edited:","lastModifiedDate":"2023-10-29"},{"lineNumber":156,"author":{"gitId":"imaginarys96"},"content":"Date: [02-03-2023] | Species: [Green Leaf Turtle] | Name: [Ariel] | Remark: [Injured left flipper]","lastModifiedDate":"2023-10-29"},{"lineNumber":157,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":160,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":161,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":163,"author":{"gitId":"woodenclock"},"content":"### 5. Summarizing Entries: `summary`","lastModifiedDate":"2023-10-29"},{"lineNumber":164,"author":{"gitId":"woodenclock"},"content":"Shows a summary of all wildlife in the WildWatch system by the species type.","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":166,"author":{"gitId":"imaginarys96"},"content":"Format: `summary \u003cSPECIES\u003e`","lastModifiedDate":"2023-10-29"},{"lineNumber":167,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":168,"author":{"gitId":"imaginarys96"},"content":"`\u003cSPECIES\u003e` argument is optional. When specified, it will show a summary of the wildlife recorded for the specified species.","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":170,"author":{"gitId":"imaginarys96"},"content":"Example: ","lastModifiedDate":"2023-10-29"},{"lineNumber":171,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/4a089c9f-ef0a-4c57-96a1-48479614ac9c)","lastModifiedDate":"2023-10-30"},{"lineNumber":172,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents) ","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":175,"author":{"gitId":"lctxct"},"content":"### 6. Exporting your entries: `export` ","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"lctxct"},"content":"Maybe you need to share the entries you\u0027ve collected with someone else. In that case, we also provide the option for you to export your data as a Comma Separated Values (CSV) file. CSV files can be recognized and imported into universally-used tools such as Microsoft Excel, allowing you to share your data and insights with others. ","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":178,"author":{"gitId":"lctxct"},"content":"Format: `export \u003cFILENAME\u003e`","lastModifiedDate":"2023-11-02"},{"lineNumber":179,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":180,"author":{"gitId":"lctxct"},"content":"`\u003cFILENAME\u003e` is optional. However, if you choose to include it, note that it should end with the file extension `.csv` so that it can be recognized as a CSV. If unspecified, your data will be written to the default file `WildWatch.csv`. ","lastModifiedDate":"2023-11-02"},{"lineNumber":181,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":182,"author":{"gitId":"lctxct"},"content":"We also guide you through the process of selecting the columns that you want to include in your CSV, if you only want to share some parts of the data. ","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":184,"author":{"gitId":"lctxct"},"content":"![image](https://github.com/lctxct/tp/assets/70379887/bf1d866f-3003-4deb-818a-e1023fb9813c)","lastModifiedDate":"2023-11-02"},{"lineNumber":185,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":186,"author":{"gitId":"lctxct"},"content":"[⬆ Back to top](#table-of-contents)","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"lctxct"},"content":" ","lastModifiedDate":"2023-11-02"},{"lineNumber":188,"author":{"gitId":"lctxct"},"content":"### 7. Getting Help : `help`","lastModifiedDate":"2023-11-02"},{"lineNumber":189,"author":{"gitId":"imaginarys96"},"content":"Shows the user how to use all the commands.","lastModifiedDate":"2023-10-28"},{"lineNumber":190,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":191,"author":{"gitId":"imaginarys96"},"content":"Format: `help`","lastModifiedDate":"2023-10-28"},{"lineNumber":192,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":193,"author":{"gitId":"imaginarys96"},"content":"Example: ","lastModifiedDate":"2023-10-28"},{"lineNumber":194,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/2e76abd5-64bc-4739-ab6e-cc57b243900b)","lastModifiedDate":"2023-10-30"},{"lineNumber":195,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":196,"author":{"gitId":"imaginarys96"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":197,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":198,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":200,"author":{"gitId":"woodenclock"},"content":"## FAQ 🦁","lastModifiedDate":"2023-10-29"},{"lineNumber":201,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":202,"author":{"gitId":"woodenclock"},"content":"\u003e **Q**: Why do I get the `OOPS!!! Invalid Date input :-(` error? ","lastModifiedDate":"2023-10-26"},{"lineNumber":203,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":204,"author":{"gitId":"imaginarys96"},"content":"Ensure the day, month, year is separated by `-` e.g., `23-05-23` in **DD-MM-YY** format. ","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":206,"author":{"gitId":"woodenclock"},"content":"\u003e **Q**: I found a bug! What do I do? ","lastModifiedDate":"2023-10-26"},{"lineNumber":207,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":208,"author":{"gitId":"imaginarys96"},"content":"Great! Please contact [Min](https://github.com/woodenclock), your help is greatly appreciated!","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":210,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-27"},{"lineNumber":211,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":212,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-26"},{"lineNumber":213,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":214,"author":{"gitId":"woodenclock"},"content":"## Command Summary 🐱","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":216,"author":{"gitId":"woodenclock"},"content":"| Action | Format |","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"lctxct"},"content":"| ------------------------- | ---------------------------------------------------------- |","lastModifiedDate":"2023-11-02"},{"lineNumber":218,"author":{"gitId":"woodenclock"},"content":"| Getting Help | `help` |","lastModifiedDate":"2023-10-29"},{"lineNumber":219,"author":{"gitId":"woodenclock"},"content":"| Add Entries | `add D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"lctxct"},"content":"| Add Entries (interactive) | `add i/` |","lastModifiedDate":"2023-11-02"},{"lineNumber":221,"author":{"gitId":"woodenclock"},"content":"| Delete Entries | `delete \u003cINDEX\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"woodenclock"},"content":"| Edit Entries | `edit I/\u003cINDEX\u003e D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"woodenclock"},"content":"| Summarizing Entries | `summary \u003cSPECIES\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":224,"author":{"gitId":"woodenclock"},"content":"| List Entries | `list` |","lastModifiedDate":"2023-10-29"},{"lineNumber":225,"author":{"gitId":"lctxct"},"content":"| Export Entries | `export \u003cFILENAME\u003e` |","lastModifiedDate":"2023-11-02"},{"lineNumber":226,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":228,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":229,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"woodenclock"},"content":"## Glossary 🐨","lastModifiedDate":"2023-10-29"},{"lineNumber":232,"author":{"gitId":"woodenclock"},"content":"We are here to help you with terminologies used in the user guide, that may not be familiar to you.","lastModifiedDate":"2023-10-29"},{"lineNumber":233,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":234,"author":{"gitId":"woodenclock"},"content":"| Terminology | Meaning |","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"imaginarys96"},"content":"| -------------- |------------------------------------------------------------|","lastModifiedDate":"2023-10-29"},{"lineNumber":236,"author":{"gitId":"woodenclock"},"content":"| Command Line Interface | A way to communicate with your computer using texts. |","lastModifiedDate":"2023-10-29"},{"lineNumber":237,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":238,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"imaginarys96":39,"woodenclock":141,"lctxct":28,"-":30}},{"path":"docs/diagrams/AddSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"!include Style.puml","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"box","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"participant \"CommandHandler\" \u003c\u003cclass\u003e\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"participant \":EntryHandler\" as EntryHandler","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"participant \":AddCommandParser\" as AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"participant \":AddCommand\" as AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"end box","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"-\u003e CommandHandler : processCommand(inputBuffer)","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"activate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"CommandHandler -\u003e EntryHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"activate EntryHandler","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"create AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"EntryHandler -\u003e AddCommandParser : AddCommandParser()","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"activate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"AddCommandParser --\u003e EntryHandler","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":"deactivate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":"EntryHandler -\u003e AddCommandParser : parse(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"activate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":"AddCommandParser -\u003e AddCommandParser : performChecks(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"activate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"deactivate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":"create AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"AddCommandParser -\u003e AddCommand : AddCommand(entry)","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":"activate AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":"AddCommand --\u003e AddCommandParser : a","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":"deactivate AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":"AddCommandParser --\u003e EntryHandler : a","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"deactivate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":"EntryHandler --\u003e CommandHandler : a","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"deactivate EntryHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":"CommandHandler -\u003e CommandHandler : executeCommand(command)","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":"activate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":"CommandHandler -\u003e AddCommand : execute()","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":"activate AddCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":"deactivate AddCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":"deactivate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"\u003c-- CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":"deactivate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"lctxct":57}},{"path":"docs/diagrams/HelpCommand.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"autonumber","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"imaginarys96"},"content":"title Help Command","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":"participant a as \"WildWatch\"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"participant b as \"InputHandler\"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"participant c as \"Ui\"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":"participant d as \"LOGGER\"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"participant e as \"CommandHandler\"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"participant f as \"EntryHandler\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":"participant g as \"HelpCommand\"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"a-\u003eb: handleInput()","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":"b-\u003ec: inputPromptPrinter()","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":"c--\u003eb: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"imaginarys96"},"content":"b-\u003ec: inputRetriever()","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"c--\u003eb: return input","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":"b-\u003ed: log(..)","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":"d--\u003eb: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"b-\u003ee: processCommand(input)","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"imaginarys96"},"content":"deactivate b","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":"deactivate c","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"e-\u003ef: handleEntry(input)","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"imaginarys96"},"content":"f-\u003eg: constructor HelpCommand(..)","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":"activate g","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":"deactivate g","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":"f--\u003ee: return command","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":"e-\u003ee: executeCommand(command)","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"imaginarys96"},"content":"e-\u003ec: printHorizontalLines()","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":"c--\u003ee: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":"e-\u003eg: execute()","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":"g--\u003ee: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":"e-\u003ec: printHorizontalLines()","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":"c--\u003ee: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"imaginarys96":35,"woodenclock":3}},{"path":"docs/diagrams/Style.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"@startuml","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"!define WILDWATCH_COLOR #006368","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"!define MAIN_COLOR #FF0000","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"!define PARSER_COLOR #ED7D31","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"!define STORAGE_COLOR #FFC000","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"!define COMMAND_COLOR #00B050","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"!define ENTRY_COLOR #00B0F0","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"!define ENTRYLIST_COLOR #4472C4","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"!define UI_COLOR #7030A0","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"!define LOCALSTORAGE_COLOR #000000","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"@enduml","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"lctxct":11}},{"path":"docs/team/lctxct.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# Cai Ting\u0027s Project Portfolio Page 🐋","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"## Summary of contributions ","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":":) ","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"woodenclock":1,"lctxct":3}},{"path":"docs/team/leesungmin.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# Lee Sungmin\u0027s Project Portfolio Page 🦈","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"## Table of Contents ","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"- [Overview](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/leesungmin.html#overview)","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"## Overview ","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the Command Line Interface (CLI). ","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient! ","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/leesungmin.html#table-of-contents) ","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"## Summary of Contributions ","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"### Code Contributed","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"To view the codes that I have contributed to the team project WildWatch, click [here](https://nus-cs2113-ay2324s1.github.io/tp-dashboard/?search\u003dwoodenclock\u0026breakdown\u003dtrue). ","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"### Enhancements implemented ","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"1. Organizing all classes into their repective packages (e.g., `ui`, `execute`, etc).","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"2. ","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"woodenclock":25}},{"path":"src/main/java/seedu/wildwatch/WildWatch.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.LogHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.BootUp;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.storage.FileHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.execute.InputHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public class WildWatch {","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" * Main entry-point for the java.wildwatch.WildWatch application.","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" public static void main(String[] args) {","lastModifiedDate":"2019-07-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" LogHandler.configure(); //Configure Log","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" BootUp.bootUpOne();","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" FileHandler.handleFile(); //FileHandler takes on","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" InputHandler.handleInput();","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":19,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"woodenclock":12,"lctxct":1,"-":6}},{"path":"src/main/java/seedu/wildwatch/command/AddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.AddCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Command class for adding entry to EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"public class AddCommand extends Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"add\";","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" public static final Pattern ADD_DEFAULT_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"add\"","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" + \"\\\\s* D/\\\\s*(?\u003cdate\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" + \"\\\\s* S/\\\\s*(?\u003cspecies\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" + \"\\\\s* N/\\\\s*(?\u003cname\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?: R/\\\\s*(?\u003cremark\u003e[^/]+)\\\\s*)?\");","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" public static final Pattern ADD_INTERACTIVE_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"add\\\\s+i/\\\\s*\");","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" private final Entry newEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" public AddCommand(Entry entry) {","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" newEntry \u003d entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" EntryList.addEntry(newEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" AddCommandPrinter.entryAddedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(EntryList.getArraySize() - 1);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.entryCountPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" public boolean equals(Object other) {","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" if (other \u003d\u003d this) {","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" // instanceof handles nulls","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" if (!(other instanceof AddCommand)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" AddCommand otherAddCommand \u003d (AddCommand) other;","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" return newEntry.equals(otherAddCommand.newEntry);","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":15,"lctxct":44}},{"path":"src/main/java/seedu/wildwatch/command/AddFileStringCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"public class AddFileStringCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" public static final Pattern FILE_STRING_FORMAT \u003d","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"\\\\s*(?\u003cdate\u003e[^/]+)\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cspecies\u003e[^/]+)\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cname\u003e[^/]+)\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cremark\u003e[^/]+)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" private final Entry newEntry;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public AddFileStringCommand(Entry entry) {","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" newEntry \u003d entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" EntryList.addEntry(newEntry);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"lctxct":26}},{"path":"src/main/java/seedu/wildwatch/command/ByeCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.ShutDown;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"public class ByeCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"bye\";","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(ByeCommand.class.getName());","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static void exitProgram() {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Initiating shutdown procedures.\");","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDown();","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" //TODO: figure out a way to get rid of this","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"woodenclock":14,"lctxct":8}},{"path":"src/main/java/seedu/wildwatch/command/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" * Command class for manipulating EntryList","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public Command() {}","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" public abstract void execute() throws InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":10,"lctxct":2}},{"path":"src/main/java/seedu/wildwatch/command/DeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-13"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.DeleteCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" * Command class for deleting entry in EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"public class DeleteCommand extends Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"delete\";","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" private final int numberInput;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public DeleteCommand(int numberInput) {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" this.numberInput \u003d numberInput;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" /**","lastModifiedDate":"2023-10-13"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" * Deletes entry in the EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" */","lastModifiedDate":"2023-10-13"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" if (numberInput \u003c\u003d 0 || numberInput \u003e EntryList.getArraySize()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryNotFoundMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"tangzhenen"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(numberInput-1);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryDeletionConfirmationPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" String confirmation \u003d scanner.nextLine().trim().toLowerCase();","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":" if (confirmation.equals(\"yes\")) {","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryRemovedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" EntryList.deleteEntry(numberInput);","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.entryCountPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryNotDeletedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":47,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":21,"tangzhenen":16,"lctxct":10}},{"path":"src/main/java/seedu/wildwatch/command/EditCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EditCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"public class EditCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" public static final String COMMAND_WORD \u003d \"edit\";","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":" public static final Pattern EDIT_ENTRY_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":" Pattern.compile(\"edit\"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":" + \" I/(?\u003cindex\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"imaginarys96"},"content":" + \"( D/(?\u003cdate\u003e[^/]+))?\"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" + \"( S/(?\u003cspecies\u003e[^/]+))?\"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":" + \"( N/(?\u003cname\u003e[^/]+))?\"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" + \"(?: R/(?\u003cremark\u003e[^/]+))?\");","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" private String input;","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" public EditCommand(String input) {","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" this.input \u003d input;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":" public Entry checkAndUpdateEntry(Entry entry, String date, String species, String name, String remark) {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":" if( date !\u003d null \u0026\u0026 !date.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" date \u003d date.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"imaginarys96"},"content":" entry.setDate(date);","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" if( species !\u003d null \u0026\u0026 !species.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" species \u003d species.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" entry.setSpecies(species);","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" if( name !\u003d null \u0026\u0026 !name.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" name \u003d name.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" entry.setName(name);","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" if( remark !\u003d null \u0026\u0026 !remark.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" remark \u003d remark.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" entry.setRemark(remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":" return entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" final Matcher matcher \u003d EDIT_ENTRY_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"imaginarys96"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"imaginarys96"},"content":" final String indexStr \u003d matcher.group(\"index\").trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"imaginarys96"},"content":" final String date \u003d matcher.group(\"date\");","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"imaginarys96"},"content":" final String species \u003d matcher.group(\"species\");","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"imaginarys96"},"content":" final String name \u003d matcher.group(\"name\");","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"imaginarys96"},"content":" final String remark \u003d matcher.group(\"remark\");","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"imaginarys96"},"content":" int index \u003d Integer.parseInt(indexStr);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" if( index \u003c\u003d 0 ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.ENTRY_NOT_FOUND);","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"imaginarys96"},"content":" index -\u003d 1; // EntryList is 0 based.","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"imaginarys96"},"content":" //System.out.println(indexStr + \" \" + date + \" \" + species + \" \" + name + \" \" + remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"imaginarys96"},"content":" Entry currentEntry \u003d EntryList.getEntry(index);","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"imaginarys96"},"content":" Entry updatedEntry \u003d checkAndUpdateEntry(currentEntry, date, species, name, remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"imaginarys96"},"content":" EntryList.editEntry(index, updatedEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":" EditCommandPrinter.entryEditedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(index);","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"imaginarys96"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"imaginarys96":58,"woodenclock":15}},{"path":"src/main/java/seedu/wildwatch/command/ExportCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.storage.EntryToStringConverter;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.storage.FileCreater;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.io.File;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"import java.util.Collections;","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"/**","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" * Command class for exporting all current entries as a CSV file.","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"public class ExportCommand extends Command {","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"export\";","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" public static final Pattern EXPORT_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"export(?:\\\\s+(?\u003cfilename\u003e\\\\S+))?\\\\s*\");","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" public static final String DEFAULT_FILENAME \u003d \"WildWatch.csv\";","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" private static final String[] ALL_COLUMNS \u003d new String[] { \"date\", \"species\", \"name\", \"remark\" };","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" private final String filename;","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" * Constructs a new {@code ExportCommand}.","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" * @param file Name of file to set on {@code filename}.","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" public ExportCommand(String file) {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":" filename \u003d file;","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" * Constructs a new {@code ExportCommand}, with filename set","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" * to {@code DEFAULT_FILENAME}.","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" public ExportCommand() {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" this(DEFAULT_FILENAME);","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" if (EntryList.isArrayEmpty()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"No entries to write to csv.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" File file \u003d new File(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" if (file.exists()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" boolean canReplaceFile \u003d canReplaceFile(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" if (!canReplaceFile) {","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Exiting export command...\");","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" return;","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":" createFile();","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":" ArrayList\u003cEntry\u003e entries \u003d EntryList.getArray();","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" ArrayList\u003cString\u003e columnsToInclude \u003d getColumnsToInclude();","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"lctxct"},"content":" if (columnsToInclude.isEmpty()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"You need to select at least one column to include in the csv.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"lctxct"},"content":" String header \u003d \"id\";","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"lctxct"},"content":" for (String column : columnsToInclude) {","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"lctxct"},"content":" header \u003d String.join(\",\", header, column);","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"lctxct"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"lctxct"},"content":" FileWriter writer \u003d new FileWriter(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"lctxct"},"content":" writer.write(header + \"\\n\");","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"lctxct"},"content":" for (int i \u003d 0; i \u003c EntryList.getArraySize(); i++) {","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"lctxct"},"content":" writer.write(EntryToStringConverter.toCSVString(entries.get(i), i+1, columnsToInclude));","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"lctxct"},"content":" writer.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"Error writing to file.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"lctxct"},"content":" System.out.printf(\"%s has been written to!%n\", filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":" * Confirms with user if file can be replaced. Returns true if user","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":" * accepts, and false otherwise.","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"lctxct"},"content":" * @return True if user allows file to be replaced, else false.","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"lctxct"},"content":" private boolean canReplaceFile(String filename) {","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":" final String confirmationMessage \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"lctxct"},"content":" String.format(\"%s already exists. Would you like to replace it? (Y/N)\", filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"lctxct"},"content":" return doesUserApprove(scanner, confirmationMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"lctxct"},"content":" * Reads user input in a loop until \"Y\" or \"N\" received.","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":114,"author":{"gitId":"lctxct"},"content":" * @param scanner Scanner used to read user input","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"lctxct"},"content":" * @param confirmationMessage Message to prompt user for input","lastModifiedDate":"2023-11-02"},{"lineNumber":116,"author":{"gitId":"lctxct"},"content":" * @return true if user inputs \"Y\", false if user inputs \"N\"","lastModifiedDate":"2023-11-02"},{"lineNumber":117,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"lctxct"},"content":" private boolean doesUserApprove(Scanner scanner, String confirmationMessage) {","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"lctxct"},"content":" do {","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"lctxct"},"content":" System.out.print(confirmationMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"lctxct"},"content":" System.out.print(\": \");","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"lctxct"},"content":" String confirmation \u003d scanner.nextLine().trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":124,"author":{"gitId":"lctxct"},"content":" switch (confirmation) {","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"lctxct"},"content":" case \"Y\":","lastModifiedDate":"2023-11-02"},{"lineNumber":126,"author":{"gitId":"lctxct"},"content":" return true;","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"lctxct"},"content":" case \"N\":","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"lctxct"},"content":" return false;","lastModifiedDate":"2023-11-02"},{"lineNumber":129,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Unrecognized input!\"","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"lctxct"},"content":" + \" Please ensure that you only respond with Y or N.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"lctxct"},"content":" } while (true);","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"lctxct"},"content":" private void createFile() throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":137,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":138,"author":{"gitId":"lctxct"},"content":" System.out.println(\"File does not exist.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":139,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"lctxct"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":141,"author":{"gitId":"lctxct"},"content":" FileCreater.createFile(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":142,"author":{"gitId":"lctxct"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"Unable to create file.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":145,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"lctxct"},"content":" private ArrayList\u003cString\u003e getColumnsToInclude() {","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"lctxct"},"content":" ArrayList\u003cString\u003e columnsToInclude \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"lctxct"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-02"},{"lineNumber":151,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"lctxct"},"content":" String includeAllColumnsMessage \u003d \"Would you like to include all columns? (Y/N)\";","lastModifiedDate":"2023-11-02"},{"lineNumber":153,"author":{"gitId":"lctxct"},"content":" if (doesUserApprove(scanner, includeAllColumnsMessage)) {","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"lctxct"},"content":" Collections.addAll(columnsToInclude, ALL_COLUMNS);","lastModifiedDate":"2023-11-02"},{"lineNumber":155,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":156,"author":{"gitId":"lctxct"},"content":" return columnsToInclude;","lastModifiedDate":"2023-11-02"},{"lineNumber":157,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":158,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":159,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Please select the columns you would like to include in your csv:\");","lastModifiedDate":"2023-11-02"},{"lineNumber":160,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"lctxct"},"content":" for (String column : ALL_COLUMNS) {","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"lctxct"},"content":" String confirmationMessage \u003d String.format(\"Would you like to include %s in your csv? (Y/N)\", column);","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"lctxct"},"content":" boolean shouldIncludeColumn \u003d doesUserApprove(scanner, confirmationMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"lctxct"},"content":" if (shouldIncludeColumn) {","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"lctxct"},"content":" columnsToInclude.add(column);","lastModifiedDate":"2023-11-02"},{"lineNumber":167,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":168,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":169,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":170,"author":{"gitId":"lctxct"},"content":" return columnsToInclude;","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"lctxct":172}},{"path":"src/main/java/seedu/wildwatch/command/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.SearchResultPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * Handles the \"find\" command to search for tasks that contain a specific keyword.","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"find\";","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" private String input;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public FindCommand(String input) {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" this.input \u003d input;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" * Searches for tasks that contain the specified keyword and prints them.","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" boolean hasMatch \u003d false;","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" ArrayList\u003cEntry\u003e entries \u003d EntryList.getArray();","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" ArrayList\u003cInteger\u003e matchingEntries \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" LocalDate inputDate \u003d null;","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" inputDate \u003d LocalDate.parse(input, DateTimeFormatter.ofPattern(\"dd-MM-yy\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" } catch (DateTimeParseException exception) {","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" // matchingWord is not a date","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" for (Entry entry: entries) {","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" boolean isInputADate \u003d (inputDate !\u003d null \u0026\u0026 entry.getDate().equals(inputDate));","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" if (entry.getSpecies().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" || entry.getSpecies().toLowerCase().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" || entry.getName().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" || entry.getName().toLowerCase().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" || entry.getRemark().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" || entry.getRemark().toLowerCase().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" || isInputADate) {","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" hasMatch \u003d true;","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" matchingEntries.add(entries.indexOf(entry));","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" SearchResultPrinter.findEntryMessagePrinter(hasMatch, matchingEntries);","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"woodenclock":51,"lctxct":5}},{"path":"src/main/java/seedu/wildwatch/command/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"help\";","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" * Requires UPDATE","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":" private static final String helpCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":" \"1. Get help - show the list of commands available for this app\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" \" Format: help\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" \" help\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":" private static final String addCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" \"2. To add a new wildlife\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":" \" Format: add D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" \" DATE should be in the format DD-MM-YY\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" \" add D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"imaginarys96"},"content":" private static final String listCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":" \"3. To list all wildlife,\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":" \" Format: list\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" \" list\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" private static final String deleteCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" \"4. To delete a wildlife\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" \" Format: delete INDEX\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" \" The index refers to the index number shown in the displayed observation list.\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" \" Note:\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" \" - The index must be a positive integer:\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" \" - Deleted items may not be recoverable:\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" \" delete 1\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":" private static final String editCommandMessage \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"imaginarys96"},"content":" \"5. To edit a wildlife\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"imaginarys96"},"content":" \" Format: edit I/INDEX D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"imaginarys96"},"content":" \" The index refers to the index number shown in the displayed observation list.\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"imaginarys96"},"content":" \" Note:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"imaginarys96"},"content":" \" - The index must be a positive integer:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"imaginarys96"},"content":" \" - DATE, SPECIES, NAME, REMARKS arguments are optional.\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"imaginarys96"},"content":" \" edit I/1 D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" private static final String summaryCommandMessage \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"imaginarys96"},"content":" \"6. To show a summary\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"imaginarys96"},"content":" \" Format: summary SPECIES\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"imaginarys96"},"content":" \" Note:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"imaginarys96"},"content":" \" - SPECIES argument is optional:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"imaginarys96"},"content":" \" summary \\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"imaginarys96"},"content":" \" summary Annam Leaf Turtle\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"imaginarys96"},"content":" private static final String helpPage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":" \"---------------------------HELP PAGE-----------------------------\\n\"+","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"imaginarys96"},"content":" helpCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":77,"author":{"gitId":"imaginarys96"},"content":" addCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":78,"author":{"gitId":"imaginarys96"},"content":" listCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":79,"author":{"gitId":"imaginarys96"},"content":" deleteCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":80,"author":{"gitId":"imaginarys96"},"content":" editCommandMessage +","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"imaginarys96"},"content":" summaryCommandMessage +","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-11"},{"lineNumber":83,"author":{"gitId":"woodenclock"},"content":" \"-------------------------HELP PAGE END---------------------------\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":85,"author":{"gitId":"imaginarys96"},"content":" private static final String helpPageShort \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"imaginarys96"},"content":" \"---------------------------HELP PAGE (short)-----------------------------\\n\"+","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"imaginarys96"},"content":" \"add: add D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"imaginarys96"},"content":" \"list: list\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"imaginarys96"},"content":" \"delete: delete INDEX\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"imaginarys96"},"content":" \"edit: edit I/INDEX D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"imaginarys96"},"content":" \"summary: summary SPECIES\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"imaginarys96"},"content":" \"-------------------------HELP PAGE (short) END---------------------------\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"woodenclock"},"content":" private static final String needHelpPage \u003d","lastModifiedDate":"2023-10-22"},{"lineNumber":98,"author":{"gitId":"woodenclock"},"content":" \"Please type \\\"help\\\" if you need help.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":100,"author":{"gitId":"woodenclock"},"content":" private String input;","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"woodenclock"},"content":" public HelpCommand(String input) {","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"woodenclock"},"content":" this.input \u003d input;","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"woodenclock"},"content":" public static void printNeedHelpMessage() {","lastModifiedDate":"2023-10-22"},{"lineNumber":107,"author":{"gitId":"woodenclock"},"content":" System.out.println(needHelpPage);","lastModifiedDate":"2023-10-22"},{"lineNumber":108,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":109,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":110,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"imaginarys96"},"content":" * Print specific help message based on the command specified","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"imaginarys96"},"content":" * @return String helpPage","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":115,"author":{"gitId":"imaginarys96"},"content":" public static String getHelpPage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"imaginarys96"},"content":" return helpPage;","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"imaginarys96"},"content":" * Print specific help message based on the command specified","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"imaginarys96"},"content":" * @param command command","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":124,"author":{"gitId":"imaginarys96"},"content":" public void printMessageForCommand(String command) {","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"imaginarys96"},"content":" switch(command) {","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"imaginarys96"},"content":" case \"add\":","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"imaginarys96"},"content":" System.out.println(addCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"imaginarys96"},"content":" case \"list\":","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"imaginarys96"},"content":" System.out.println(listCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"imaginarys96"},"content":" case \"delete\":","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"imaginarys96"},"content":" System.out.println(deleteCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"imaginarys96"},"content":" case \"edit\":","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"imaginarys96"},"content":" System.out.println(editCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"imaginarys96"},"content":" case \"summary\":","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"imaginarys96"},"content":" System.out.println(summaryCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"imaginarys96"},"content":" case \"full\":","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"imaginarys96"},"content":" System.out.println(helpPage);","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"imaginarys96"},"content":" default:","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":149,"author":{"gitId":"woodenclock"},"content":" * Prints out help page","lastModifiedDate":"2023-10-11"},{"lineNumber":150,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":151,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":152,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"woodenclock"},"content":" if( input.isEmpty() ) {","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"lctxct"},"content":" System.out.println(\"No worries, I\u0027m here to help!\");","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"woodenclock"},"content":" System.out.println(helpPage);","lastModifiedDate":"2023-10-11"},{"lineNumber":156,"author":{"gitId":"imaginarys96"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"woodenclock"},"content":" String argument \u003d input.replace(\"help\", \"\").trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"imaginarys96"},"content":" if( argument.isEmpty() ) {","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"imaginarys96"},"content":" // print short version","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"imaginarys96"},"content":" System.out.println(\"No worries, I\u0027m here to help!\");","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"imaginarys96"},"content":" System.out.println(helpPageShort);","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"imaginarys96"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"imaginarys96"},"content":" // e.g `help add`","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"imaginarys96"},"content":" System.out.println(\"No worries, I\u0027m here to help!\");","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"imaginarys96"},"content":" printMessageForCommand(argument);","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":171,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":173,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"imaginarys96":125,"woodenclock":43,"lctxct":5}},{"path":"src/main/java/seedu/wildwatch/command/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * Command class for listing all entries in EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"list\";","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" * Lists out all entry in EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public static void listEntry() {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" int arraySize \u003d EntryList.getArraySize();","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" for (int i \u003d 0; i \u003c arraySize; i++) {","lastModifiedDate":"2023-10-11"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" System.out.print(i + 1 + \".\");","lastModifiedDate":"2023-10-11"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(i);","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.entryCountPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" if (EntryList.isArrayEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_LIST);","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.listMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":28,"lctxct":10}},{"path":"src/main/java/seedu/wildwatch/command/SummaryCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"imaginarys96"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"imaginarys96"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.SummaryCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" * Command class for `summary`","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"public class SummaryCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"summary\";","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" private String speciesName;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" public SummaryCommand(String speciesName) {","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":" this.speciesName \u003d speciesName;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"imaginarys96"},"content":" * Group the wildlife entries by their species","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":" * @param entries","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":" * @return A map of the wildlife entries grouped by their species","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" private static Map\u003cString, List\u003cEntry\u003e\u003e groupEntriesBySpecies(List\u003cEntry\u003e entries) {","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e map \u003d new HashMap\u003cString, List\u003cEntry\u003e\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" for (Entry entry : entries) {","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" String key \u003d entry.getSpecies();","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" if(map.containsKey(key)){","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d map.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" }else{","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d new ArrayList\u003cEntry\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" map.put(key, list);","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":" return map;","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"imaginarys96"},"content":" * Group a set of wildlife entries by their name","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"imaginarys96"},"content":" * @param filteredEntries","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"imaginarys96"},"content":" * @return A map of filteredEntries grouped by their name","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" private static Map\u003cString, List\u003cEntry\u003e\u003e groupSpecieByName(List\u003cEntry\u003e filteredEntries) {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e filteredMap \u003d new HashMap\u003cString, List\u003cEntry\u003e\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"imaginarys96"},"content":" for (Entry entry : filteredEntries) {","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"imaginarys96"},"content":" String key \u003d entry.getName();","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"imaginarys96"},"content":" if(filteredMap.containsKey(key)){","lastModifiedDate":"2023-10-28"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d filteredMap.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":62,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":63,"author":{"gitId":"imaginarys96"},"content":" }else{","lastModifiedDate":"2023-10-28"},{"lineNumber":64,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d new ArrayList\u003cEntry\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":65,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":66,"author":{"gitId":"imaginarys96"},"content":" filteredMap.put(key, list);","lastModifiedDate":"2023-10-28"},{"lineNumber":67,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":68,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"imaginarys96"},"content":" return filteredMap;","lastModifiedDate":"2023-10-28"},{"lineNumber":70,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"imaginarys96"},"content":" boolean hasArgument \u003d !this.speciesName.isEmpty();","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":74,"author":{"gitId":"imaginarys96"},"content":" ArrayList\u003cEntry\u003e entries \u003d EntryList.getArray();","lastModifiedDate":"2023-10-28"},{"lineNumber":75,"author":{"gitId":"imaginarys96"},"content":" // Group entries by .species attribute","lastModifiedDate":"2023-10-28"},{"lineNumber":76,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e map \u003d groupEntriesBySpecies(entries);","lastModifiedDate":"2023-10-28"},{"lineNumber":77,"author":{"gitId":"imaginarys96"},"content":" // change message based on whether `summary` or `summary \u003cspecies\u003e`","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"imaginarys96"},"content":" if( hasArgument ) {","lastModifiedDate":"2023-10-28"},{"lineNumber":79,"author":{"gitId":"woodenclock"},"content":" SummaryCommandPrinter.printSummaryNameMessage(speciesName);","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e filteredEntries \u003d map.get(speciesName);","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e filteredMap \u003d groupSpecieByName(filteredEntries);","lastModifiedDate":"2023-10-28"},{"lineNumber":82,"author":{"gitId":"imaginarys96"},"content":" filteredMap.forEach((key, value) -\u003e System.out.println(key + \" - (\" + value.size() + \")\"));","lastModifiedDate":"2023-10-28"},{"lineNumber":83,"author":{"gitId":"imaginarys96"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"woodenclock"},"content":" SummaryCommandPrinter.printSummarySpecieMessage();","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"imaginarys96"},"content":" map.forEach((key, value) -\u003e System.out.println(key + \" - (\" + value.size() + \")\"));","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"imaginarys96"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"imaginarys96":75,"woodenclock":5,"lctxct":8}},{"path":"src/main/java/seedu/wildwatch/entry/Entry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.entry;","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class Entry {","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" private LocalDate date;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" private String species;","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" private String name;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" private String remark;","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public Entry(String date, String species, String name, String remark) {","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" DateTimeFormatter inputFormat \u003d DateTimeFormatter.ofPattern(\"dd-MM-yy\");","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" this.date \u003d LocalDate.parse(date, inputFormat);","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" this.species \u003d species;","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" this.remark \u003d remark;","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public LocalDate getDate() {","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" return date;","lastModifiedDate":"2023-10-11"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" public String getSpecies() {","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" return species;","lastModifiedDate":"2023-10-11"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" public String getName() {","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" return name;","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" public String getRemark() {","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" return remark;","lastModifiedDate":"2023-10-11"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" public void setDate(String date) {","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" DateTimeFormatter inputFormat \u003d DateTimeFormatter.ofPattern(\"dd-MM-yy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" this.date \u003d LocalDate.parse(date, inputFormat);","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" public void setSpecies(String species) {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" this.species \u003d species;","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":" public void setRemark(String remark) {","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":" this.remark \u003d remark;","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" * Returns true if both entries have the same value for each field.","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" public boolean equals(Object other) {","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" if (other \u003d\u003d this) {","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" // instanceof handles nulls","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" if (!(other instanceof Entry)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" Entry otherEntry \u003d (Entry) other;","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" return date.equals(otherEntry.date)","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":" \u0026\u0026 species.equals(otherEntry.species)","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" \u0026\u0026 name.equals(otherEntry.name)","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" \u0026\u0026 remark.equals(otherEntry.remark);","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"imaginarys96":13,"woodenclock":36,"lctxct":21}},{"path":"src/main/java/seedu/wildwatch/entry/EntryList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.entry;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.storage.Saver;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class EntryList {","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" private static ArrayList\u003cEntry\u003e entries \u003d new ArrayList\u003c\u003e(); //Keeps track of all Entry instances made","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static ArrayList\u003cEntry\u003e getArray() {","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" return entries;","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static int getArraySize() {","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" return entries.size();","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public static void addEntry(Entry newEntry) {","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" entries.add(newEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" public static void deleteEntry(int numberInput){","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" entries.remove(numberInput - 1);","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" public static void clearEntry(){","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" entries.clear();","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" public static Entry getEntry(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" return entries.get(nthEntry);","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" public static void editEntry(int nthEntry, Entry updatedEntry) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" entries.set(nthEntry, updatedEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" public static LocalDate getEntryDate(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getDate();","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" public static String getEntrySpecies(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getSpecies();","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" public static String getEntryName(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getName();","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" public static String getEntryRemark(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getRemark();","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" public static boolean isArrayEmpty() {","lastModifiedDate":"2023-10-11"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" return entries.isEmpty();","lastModifiedDate":"2023-10-11"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":" public static void saveEntry() {","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":" Saver.saver(entries);","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"imaginarys96":4,"woodenclock":52,"tangzhenen":3,"lctxct":2}},{"path":"src/main/java/seedu/wildwatch/error/DateChecker.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class DateChecker {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" private static final Pattern DATE_PATTERN \u003d Pattern.compile(","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" \"(0[1-9]|[1-2][0-9]|3[0-1])-(0[1-9]|1[0-2])-\\\\d{2}\" // dd-mm-yy","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" );","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" public static boolean isDateValid(String date) {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" date \u003d date.trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" if (DATE_PATTERN.matcher(date).matches()) {","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" return true;","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" return false;","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":16,"lctxct":1}},{"path":"src/main/java/seedu/wildwatch/error/ErrorHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.HelpCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ErrorPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.DeleteCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EmptyDescriptionPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"public class ErrorHandler {","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(ErrorHandler.class.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void handleInputError(InvalidInputException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" boolean validInput \u003d false;","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" switch (exception.getError()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" case CUSTOM:","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Command is invalid.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.customInvalidInputMessagePrinter(exception.getCustomMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" case EMPTY_INPUT:","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Received an empty input.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" EmptyDescriptionPrinter.emptyDescriptionMessagePrinter(null);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" case EMPTY_EDIT_INPUT:","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Received an empty edit input.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" EmptyDescriptionPrinter.emptyDescriptionMessagePrinter(EditCommand.COMMAND_WORD);","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" case EMPTY_FIND_INPUT:","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Received an empty find input.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" EmptyDescriptionPrinter.emptyDescriptionMessagePrinter(FindCommand.COMMAND_WORD);","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" case EMPTY_LIST:","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" LOGGER.info(\"List is empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.emptyListMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":" validInput \u003d true;","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" case ENTRY_NOT_FOUND:","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Queried entry not found.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryNotFoundMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" validInput \u003d true;","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" case INVALID_DATE:","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Date is invalid.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidDateMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" case INVALID_INDEX:","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Index is invalid.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidIndexMessagePrinter();","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" case INVALID_INPUT:","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Command is invalid.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidInputMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidInputMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" if (!validInput) {","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" HelpCommand.printNeedHelpMessage();","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":32,"lctxct":34}},{"path":"src/main/java/seedu/wildwatch/error/InvalidInputErrorType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public enum InvalidInputErrorType {","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" CUSTOM,","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":" EMPTY_INPUT,","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" EMPTY_EDIT_INPUT,","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":" EMPTY_FIND_INPUT,","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":" EMPTY_LIST,","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":" ENTRY_NOT_FOUND,","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" INVALID_DATE,","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" INVALID_INDEX,","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" INVALID_INPUT","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":6,"lctxct":7}},{"path":"src/main/java/seedu/wildwatch/error/Router.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.SummaryCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.ListCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.ByeCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.DeleteCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.ExportCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.HelpCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.SummaryCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.AddCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.DeleteCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.EditCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.ExportCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.FindCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" * Identifies the input command and sends it to the corresponding parser.","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"public class Router {","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(Router.class.getName());","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" public static Command route (String input) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Managing entry for input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" Scanner bufferScanner \u003d new Scanner(input); //Scanner for the buffer","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" if (!bufferScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_INPUT);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" String firstWord \u003d bufferScanner.next(); //Stores first word in the input","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" //Functionalities","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" switch (firstWord) {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" case AddCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Add command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" return new AddCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" case DeleteCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Delete command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" return new DeleteCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" case EditCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Edit command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" return new EditCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" case FindCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Find command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" return new FindCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" case ListCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"List command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" return new ListCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" case SummaryCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Summary command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" return new SummaryCommandParser().parse(input);","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" case ExportCommand.COMMAND_WORD:","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Export command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":" return new ExportCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" case HelpCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Help command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":" return new HelpCommand(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" case ByeCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Exit command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":" return new ByeCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.WARNING, \"Invalid input received: {0}. Throwing exception.\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":76,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"imaginarys96":17,"woodenclock":44,"lctxct":15}},{"path":"src/main/java/seedu/wildwatch/exception/InvalidInputException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.exception;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class InvalidInputException extends Exception {","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" private InvalidInputErrorType errorType;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" private String customMessage;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":" public InvalidInputException(InvalidInputErrorType error, String message) {","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" errorType \u003d error;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":" customMessage \u003d message;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public InvalidInputException(InvalidInputErrorType error) {","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" this(error, \"Command is invalid.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public InvalidInputException(String message) {","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" this(InvalidInputErrorType.INVALID_INPUT, message);","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" public InvalidInputErrorType getError() {","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" return errorType;","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" public String getCustomMessage() {","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" return customMessage;","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":21,"lctxct":8}},{"path":"src/main/java/seedu/wildwatch/exception/UnknownDateFormatException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.exception;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class UnknownDateFormatException extends Exception {","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":4}},{"path":"src/main/java/seedu/wildwatch/execute/CommandHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.ByeCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.Router;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.ErrorHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"public class CommandHandler {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static boolean processCommand(String input) {","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" Command command \u003d Router.route(input); //Checks if the input command is valid","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" if (command instanceof ByeCommand) {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" executeCommand(command);","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" } catch (InvalidInputException exception) {","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" ErrorHandler.handleInputError(exception);","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" return true;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" public static void executeCommand(Command command) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":26}},{"path":"src/main/java/seedu/wildwatch/execute/InputHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.ByeCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.InputConsole;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"public class InputHandler {","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(InputHandler.class.getName());","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" * Runs the WildWatch by looping through the I/O process.","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" * If \"bye\" is received,","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" public static void handleInput() {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" boolean loopFlag \u003d true;","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" while (loopFlag) {","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" Ui.inputPromptPrinter();","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" String input \u003d InputConsole.inputRetriever(); //Retrieves input of user","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" if (!input.equals(\"bye\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Input received: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" loopFlag \u003d CommandHandler.processCommand(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" EntryList.saveEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" ByeCommand.exitProgram();","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"woodenclock":31,"lctxct":3}},{"path":"src/main/java/seedu/wildwatch/miscellaneous/BootUp.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.miscellaneous;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"public class BootUp {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" public static final String WELCOME_MESSAGE_1 \u003d","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" \"Hello there! Welcome to WildWatch!\\n\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static final String WELCOME_MESSAGE_2 \u003d","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" \"What would you like to do?\\n\";","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static final String LOGO \u003d","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" \"____ __ ____ __ __ _______\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" \"\\\\ \\\\ / \\\\ / / | | | | | \\\\\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" \" \\\\ \\\\/ \\\\/ / | | | | | .--. |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" \" \\\\ / | | | | | | | |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" \" \\\\ /\\\\ / | | | `----.| \u0027--\u0027 |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" \" \\\\__/ \\\\__/ |__| |_______||_______/\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" \"____ __ ____ ___ .___________. ______ __ __\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" \"\\\\ \\\\ / \\\\ / / / \\\\ | | / || | | |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" \" \\\\ \\\\/ \\\\/ / / ^ \\\\ `---| |----`| ,----\u0027| |__| |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" \" \\\\ / / /_\\\\ \\\\ | | | | | __ |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" \" \\\\ /\\\\ / / _____ \\\\ | | | `----.| | | |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" \" \\\\__/ \\\\__/ /__/ \\\\__\\\\ |__| \\\\______||__| |__|\\n\";","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" public static void bootUpOne() {","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" System.out.print(BootUp.LOGO);","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" System.out.print(BootUp.WELCOME_MESSAGE_1);","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" public static void bootUpTwo() {","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" System.out.print(BootUp.WELCOME_MESSAGE_2);","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"woodenclock":38}},{"path":"src/main/java/seedu/wildwatch/miscellaneous/LogHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.miscellaneous;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ErrorPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Handler;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"public class LogHandler {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(LogHandler.class.getName());","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" static {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" // Configure a FileHandler","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" FileHandler file \u003d new FileHandler(\"WildWatch.log\", true);","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" file.setFormatter(formatter);","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" // Obtain the root logger. An empty string gets the root logger","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" // Remove the default handlers (like ConsoleHandler)","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" for (Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" // Add the FileHandler to the root logger","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" rootLogger.addHandler(file);","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" } catch (Exception exception) {","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Queried entry not found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.corruptLoggerMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDownWithError();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" System.exit(0);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" public static void configure() { // Call this empty method to ensure the static block runs","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"woodenclock":40}},{"path":"src/main/java/seedu/wildwatch/miscellaneous/ShutDown.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.miscellaneous;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"public class ShutDown {","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" public static void shutDown() {","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" //Program Ending","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Bye. Hope to see you again soon!\");","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void shutDownWithError() {","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" //Program Ending","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Ending program due to error...\");","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":18}},{"path":"src/main/java/seedu/wildwatch/parser/AddCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"public class AddCommandParser implements Parser\u003cAddCommand\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" private static final String[] ENTRY_ITEMS \u003d new String[] { \"date\", \"species\", \"name\", \"remark\" };","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" private static final Pattern ADD_DEFAULT_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"add\"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?\u003cdprefix\u003e D/)?\\\\s*(?\u003cdate\u003e[^/]+)?\"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?\u003csprefix\u003e S/)?\\\\s*(?\u003cspecies\u003e[^/]+)?\"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?\u003cnprefix\u003e N/)?\\\\s*(?\u003cname\u003e[^/]+)?\"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?: R/(?\u003cremark\u003e[^/]+))?\");","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" private String date;","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" private String species;","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" private String name;","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" private String remark \u003d null;","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" public AddCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" final Matcher matcherInteractive \u003d AddCommand.ADD_INTERACTIVE_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" if (matcherInteractive.matches()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" handleInteractive();","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" // Default case","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" performChecks(input);","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" final Matcher matcherDefault \u003d AddCommand.ADD_DEFAULT_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" boolean isMatch \u003d matcherDefault.matches();","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" assert isMatch : \"Command should match format.\";","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" date \u003d matcherDefault.group(\"date\").trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" species \u003d matcherDefault.group(\"species\").trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" name \u003d matcherDefault.group(\"name\").trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" remark \u003d matcherDefault.group(\"remark\");","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" if (remark \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" remark \u003d \"\";","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" remark \u003d remark.trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" Entry newEntry \u003d new Entry(date, species, name, remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" return new AddCommand(newEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" * Handle interactive add command, which prompts user for each item required","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" * in an entry.","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" private void handleInteractive() throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":" String input;","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" for (String item : ENTRY_ITEMS) {","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"lctxct"},"content":" String promptMessage \u003d String.format(\"Please input the %s you would like to set, or q/ to quit.\", item);","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"lctxct"},"content":" if (item.equals(\"remark\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"lctxct"},"content":" promptMessage +\u003d \"\\n(Hit Enter to leave this field blank)\";","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"lctxct"},"content":" input \u003d getItem(scanner, promptMessage, item);","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"lctxct"},"content":" switch (item) {","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"lctxct"},"content":" case \"date\":","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"lctxct"},"content":" date \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"lctxct"},"content":" case \"species\":","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"lctxct"},"content":" species \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"lctxct"},"content":" case \"name\":","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":" name \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":" case \"remark\":","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"lctxct"},"content":" remark \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":" private String getItem(Scanner scanner, String promptMessage, String item) throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":" String inputBuffer;","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":" boolean isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":" do {","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"lctxct"},"content":" System.out.print(promptMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":" System.out.println(\": \");","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"lctxct"},"content":" inputBuffer \u003d scanner.nextLine().trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"lctxct"},"content":" isValid \u003d true;","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"lctxct"},"content":" // check if user q/uits early","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"lctxct"},"content":" if (inputBuffer.equals(\"q/\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"Exited add command\");","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":114,"author":{"gitId":"lctxct"},"content":" // check that fields are not empty","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"lctxct"},"content":" if (!item.equals(\"remark\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":116,"author":{"gitId":"lctxct"},"content":" if (inputBuffer.isEmpty()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":117,"author":{"gitId":"lctxct"},"content":" isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Field cannot be left blank.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"lctxct"},"content":" // if date, check validity of date","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"lctxct"},"content":" if (item.equals(\"date\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":124,"author":{"gitId":"lctxct"},"content":" if (!DateChecker.isDateValid(inputBuffer)) {","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"lctxct"},"content":" isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":126,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Please key in a valid date.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":129,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"lctxct"},"content":" // check that no /","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"lctxct"},"content":" if (inputBuffer.contains(\"/\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"lctxct"},"content":" isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Your input should not contain /.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"lctxct"},"content":" } while (!isValid);","lastModifiedDate":"2023-11-02"},{"lineNumber":137,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":138,"author":{"gitId":"lctxct"},"content":" return inputBuffer;","lastModifiedDate":"2023-11-02"},{"lineNumber":139,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":141,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"lctxct"},"content":" * Ensures that {@code input} adheres to the command format.","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"lctxct"},"content":" * @param input","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown if the input does not adhere to command format.","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"woodenclock"},"content":" private void performChecks(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d ADD_DEFAULT_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":152,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"lctxct"},"content":" checkDate(matcher);","lastModifiedDate":"2023-10-29"},{"lineNumber":154,"author":{"gitId":"lctxct"},"content":" checkSpecies(matcher);","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"lctxct"},"content":" checkName(matcher);","lastModifiedDate":"2023-10-29"},{"lineNumber":156,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":157,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"lctxct"},"content":" * Checks that date is correctly defined in input. Checks the following:","lastModifiedDate":"2023-10-29"},{"lineNumber":160,"author":{"gitId":"lctxct"},"content":" * 1. D/ is present in user input","lastModifiedDate":"2023-10-29"},{"lineNumber":161,"author":{"gitId":"lctxct"},"content":" * 2. A date value is defined","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"lctxct"},"content":" * 3. Date provided is correctly formatted","lastModifiedDate":"2023-10-29"},{"lineNumber":163,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":164,"author":{"gitId":"lctxct"},"content":" * @param matcher Input matched against command pattern","lastModifiedDate":"2023-10-29"},{"lineNumber":165,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when date is not correctly defined","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":167,"author":{"gitId":"woodenclock"},"content":" private void checkDate(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":168,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"dprefix\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"D/ is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":171,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"date\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"Date value cannot be empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"lctxct"},"content":" String date \u003d matcher.group(\"date\").trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":175,"author":{"gitId":"woodenclock"},"content":" if (!DateChecker.isDateValid(date)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_DATE);","lastModifiedDate":"2023-10-30"},{"lineNumber":177,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":178,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":179,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":180,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":181,"author":{"gitId":"lctxct"},"content":" * Checks that species is correctly defined in input. Checks the following:","lastModifiedDate":"2023-10-29"},{"lineNumber":182,"author":{"gitId":"lctxct"},"content":" * 1. S/ is present in user input","lastModifiedDate":"2023-10-29"},{"lineNumber":183,"author":{"gitId":"lctxct"},"content":" * 2. Species is defined","lastModifiedDate":"2023-10-29"},{"lineNumber":184,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":185,"author":{"gitId":"lctxct"},"content":" * @param matcher Input matched against command pattern","lastModifiedDate":"2023-10-29"},{"lineNumber":186,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when species is not correctly defined","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":188,"author":{"gitId":"woodenclock"},"content":" private void checkSpecies(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"sprefix\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"S/ is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"species\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":193,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"Species is not defined.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"lctxct"},"content":" * Checks that name is correctly defined in input. Checks the following:","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"lctxct"},"content":" * 1. N/ is present in user input","lastModifiedDate":"2023-10-29"},{"lineNumber":200,"author":{"gitId":"lctxct"},"content":" * 2. Name is defined","lastModifiedDate":"2023-10-29"},{"lineNumber":201,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":202,"author":{"gitId":"lctxct"},"content":" * @param matcher Input matched against command pattern","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when species is not correctly defined","lastModifiedDate":"2023-10-30"},{"lineNumber":204,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"woodenclock"},"content":" private void checkName(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":206,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"nprefix\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"N/ is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":208,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"name\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"Name is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":21,"lctxct":192}},{"path":"src/main/java/seedu/wildwatch/parser/DeleteCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.DeleteCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"public class DeleteCommandParser implements Parser\u003cDeleteCommand\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" private static final Pattern DELETE_ENTRY_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"delete\\\\s+(?\u003cindex\u003e\\\\S+)\\\\s*\");","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" public DeleteCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" int getIdx \u003d getIndexFromInput(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" return new DeleteCommand(getIdx);","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" * Gets index of entry to delete from input.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" * Checks that input adheres to required delete command format.","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" * 1. Checks that it is in the form {@code delete\u003cwhitespace(s)\u003eINDEX}","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" * 2. Checks that INDEX \u003e 1 and INDEX \u003c\u003d length of entry list","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" * @param input","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" * @return index of entry to delete","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when command format is incorrect.","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" private int getIndexFromInput(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d DELETE_ENTRY_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" // Check that index is a valid number","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" int deleteIdx \u003d -1;","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" try {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" deleteIdx \u003d Integer.parseInt(matcher.group(\"index\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INDEX);","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" // Check that index is within bounds","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" if (deleteIdx \u003c 1 || deleteIdx \u003e EntryList.getArraySize()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.ENTRY_NOT_FOUND);","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" return deleteIdx;","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":8,"lctxct":48}},{"path":"src/main/java/seedu/wildwatch/parser/EditCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"public class EditCommandParser {","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" private static final Pattern EDIT_ENTRY_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" Pattern.compile(\"edit\"","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003ciprefix\u003e I/)?\\\\s*(?\u003cindex\u003e[^/]+)\"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003cdprefix\u003e D/)?\\\\s*(?\u003cdate\u003e[^/]+)?\"","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003csprefix\u003e S/)?\\\\s*(?\u003cspecies\u003e[^/]+)?\"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003cnprefix\u003e N/)?\\\\s*(?\u003cname\u003e[^/]+)?\"","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?: R/(?\u003cremark\u003e[^/]+))?\");","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public Command parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" performChecks(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" final Matcher matcher \u003d EditCommand.EDIT_ENTRY_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" boolean isMatch \u003d matcher.matches();","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" assert isMatch : \"Command should match format.\";","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" return new EditCommand(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" * Ensures that {@code input} adheres to the command format.","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" * @param input","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown if the input does not adhere to command format.","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" private void performChecks(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" final Matcher matcher \u003d EDIT_ENTRY_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" //Checks if the input adheres to the command format","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" checkIndex(matcher);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" if (!(matcher.group(\"date\") \u003d\u003d null)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" checkDate(matcher);","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" //Checks if there is any change to edit","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" if ((matcher.group(\"date\") \u003d\u003d null) \u0026\u0026 (matcher.group(\"species\") \u003d\u003d null) \u0026\u0026","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" (matcher.group(\"name\") \u003d\u003d null) \u0026\u0026 (matcher.group(\"remark\") \u003d\u003d null)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_EDIT_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" private void checkIndex(Matcher matcher) throws InvalidInputException{","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":" int editIdx \u003d -1;","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" editIdx \u003d Integer.parseInt(matcher.group(\"index\"));","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":" } catch (NumberFormatException exception) {","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INDEX);","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":" if ((matcher.group(\"index\") \u003d\u003d null) || editIdx \u003c 1 || editIdx \u003e EntryList.getArraySize()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.ENTRY_NOT_FOUND);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":" private void checkDate(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":" String dateValue \u003d matcher.group(\"date\");","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":" if (!DateChecker.isDateValid(dateValue)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_DATE);","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"woodenclock":75}},{"path":"src/main/java/seedu/wildwatch/parser/ExportCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.ExportCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"/**","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":" * Parses export command. Accepts optional {@code filename} argument","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":" * proceeding {@code export} keyword.","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"public class ExportCommandParser implements Parser\u003cExportCommand\u003e {","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" private static final Pattern FILENAME_FORMAT \u003d Pattern.compile(\"\\\\w+.csv\");","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public ExportCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d ExportCommand.EXPORT_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" String filename \u003d matcher.group(\"filename\");","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" if (filename \u003d\u003d null) {","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" return new ExportCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" if (checkFilenameValid(filename)) {","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" return new ExportCommand(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Filename is invalid. Using default filename...\");","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" return new ExportCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" * Checks if filename is in the format {@code [a-zA-Z0-9_].csv}.","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" * @param filename Input to test","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" * @return true if filename is valid, else false","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" private boolean checkFilenameValid(String filename) {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d FILENAME_FORMAT.matcher(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" return matcher.matches();","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"lctxct":52}},{"path":"src/main/java/seedu/wildwatch/parser/FileStringParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.AddFileStringCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"public class FileStringParser implements Parser\u003cAddFileStringCommand\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" private static final Pattern ADD_FILE_ENTRY_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" Pattern.compile(","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" \"\\\\s*(?\u003cdate\u003e[^/]+)?\\\\s*/\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cspecies\u003e[^/]+)?\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cname\u003e[^/]+)?\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cremark\u003e[^/]+)?\");","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" public AddFileStringCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" performChecks(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d AddFileStringCommand.FILE_STRING_FORMAT.matcher(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" boolean isMatch \u003d matcher.matches();","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" assert isMatch : \"Input line should match format.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" final String date \u003d matcher.group(\"date\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" final String species \u003d matcher.group(\"species\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" final String name \u003d matcher.group(\"name\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" final String remark \u003d matcher.group(\"remark\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" Entry newEntry \u003d new Entry(date, species, name, remark);","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" return new AddFileStringCommand(newEntry);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" private void performChecks(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d ADD_FILE_ENTRY_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" // Check that all groups present","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"date\") \u003d\u003d null ||","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" matcher.group(\"species\") \u003d\u003d null ||","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" matcher.group(\"name\") \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" // Check that date is valid","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":" if (!DateChecker.isDateValid(matcher.group(\"date\"))) {","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":15,"lctxct":45}},{"path":"src/main/java/seedu/wildwatch/parser/FindCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class FindCommandParser implements Parser\u003cFindCommand\u003e{","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" public static final String COMMAND_WORD \u003d \"find\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" private static final int NUMBER_OF_ALPHABETS_IN_FIND \u003d 4;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" public FindCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" String matchingWord \u003d input.substring(input.indexOf(COMMAND_WORD)","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" + NUMBER_OF_ALPHABETS_IN_FIND).trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" if (matchingWord \u003d\u003d null || matchingWord.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_FIND_INPUT);","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" return new FindCommand(matchingWord); //Note the \"find\" is removed here","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":20}},{"path":"src/main/java/seedu/wildwatch/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Returns a specific command object as defined in the command package.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * @param \u003cT\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"public interface Parser\u003cT extends Command\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" T parse(String input) throws InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":7,"lctxct":6}},{"path":"src/main/java/seedu/wildwatch/parser/SummaryCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.SummaryCommand;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"imaginarys96"},"content":"public class SummaryCommandParser implements Parser\u003cSummaryCommand\u003e {","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":" private static final String COMMAND_WORD \u003d \"summary\";","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":" @Override","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":" public SummaryCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":" String speciesName \u003d getArgumentFromInput(input);","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" return new SummaryCommand(speciesName);","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":" * Gets the argument (species name) if specified.","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" * @param input","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":" * @return species name if specified, otherwise an empty string.","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":" protected String getArgumentFromInput(String input) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"imaginarys96"},"content":" return input.replace(\"summary\", \"\").trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"imaginarys96"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"imaginarys96":26}},{"path":"src/main/java/seedu/wildwatch/storage/EntryToStringConverter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"public class EntryToStringConverter {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" private static final DateTimeFormatter STD_FORMAT \u003d DateTimeFormatter.ofPattern(\"dd-MM-yy\");","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Returns String that is in the format to be written to file.","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * @param entry Entry of interest.","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" * @return String.","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" * @throws IOException when there is problem with formatting the task.","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" public static String toFileString(Entry entry) throws IOException {","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" assert entry !\u003d null : \"Trying to convert a null entry to file string.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" String date \u003d entry.getDate().format(STD_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" String species \u003d entry.getSpecies();","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" String name \u003d entry.getName();","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" String remark \u003d entry.getRemark();","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" return String.format(\"%s / %s / %s / %s\", date, species, name, remark);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" public static String toCSVString(Entry entry, int id, ArrayList\u003cString\u003e columns) {","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" assert entry !\u003d null : \"Trying to convert a null entry to file string.\";","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" String items \u003d String.format(\"%d\", id);","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"date\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" String date \u003d entry.getDate().format(STD_FORMAT);","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, date);","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"species\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":" String species \u003d entry.getSpecies();","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, species);","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"name\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" String name \u003d entry.getName();","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, name);","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"remark\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" String remark \u003d entry.getRemark();","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, remark);","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" return items + \"\\n\";","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":27,"lctxct":29}},{"path":"src/main/java/seedu/wildwatch/storage/ExistenceChecker.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.FilePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class ExistenceChecker {","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * Checks if file exists. Opens file if the file exists.","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @return true if file exists; false if not.","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static boolean checkFileExistence(String filePath) {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.print(System.lineSeparator());","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" FilePrinter.checkingIfFileExistsMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" assert filePath !\u003d null : \"File path should not be null.\";","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" if (!file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" return true;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":25}},{"path":"src/main/java/seedu/wildwatch/storage/FileCreater.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.FilePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public class FileCreater {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" * Creates new file with filename specified by {@code FILE_PATH}.","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" public static File createFile(String filePath) throws IOException {","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" if (file.createNewFile()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" FilePrinter.createNewFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" return file;","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" throw new IOException();","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":21}},{"path":"src/main/java/seedu/wildwatch/storage/FileHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.ListCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.BootUp;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.ShutDown;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.FilePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"public class FileHandler {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" private static final String FILE_PATH \u003d \"./WildWatch.txt\";","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" private static File openedFile; //File to save the entries","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" public static void handleFile() {","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" if (ExistenceChecker.checkFileExistence(FILE_PATH)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" FilePrinter.fileExistMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" openedFile \u003d new File(FILE_PATH);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" FileLoader.loadFile(openedFile); // Loads entries from file","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" assert openedFile !\u003d null : \"Trying to read from a non-initialized file.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" FilePrinter.taskLoadedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" // Lists entries loaded from file","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" ListCommand.listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" } catch (FileNotFoundException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" FilePrinter.noFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" } catch (InvalidInputException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" FilePrinter.corruptFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDownWithError();","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" System.exit(0);","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" } else { // File does not exist","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" FilePrinter.noFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" openedFile \u003d FileCreater.createFile(FILE_PATH);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" } catch (IOException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" FilePrinter.fileCreationFailMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDownWithError();","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" System.exit(0);","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" assert openedFile.exists() : \"File was supposed to be created but it doesn\u0027t exist.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" BootUp.bootUpTwo(); //Welcome prompt message","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"woodenclock":43,"lctxct":7}},{"path":"src/main/java/seedu/wildwatch/storage/FileLoader.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.parser.FileStringParser;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"public class FileLoader {","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Loads tasks from file into the TaskList.","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" public static void loadFile(File openedFile) throws FileNotFoundException, InvalidInputException {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" Scanner fileReader \u003d new Scanner(openedFile); // create a Scanner using the File as the source","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" while (fileReader.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" String lineOfFile \u003d fileReader.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" new FileStringParser().parse(lineOfFile).execute(); // Creates new entry from line in file","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":23}},{"path":"src/main/java/seedu/wildwatch/storage/Saver.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ErrorPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"public class Saver {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" private static final String FILE_PATH \u003d \"./WildWatch.txt\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" * Manages the storage of tasks in a file.","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * Write each task in the desired format to the file.","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void saver(ArrayList\u003cEntry\u003e entries) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" assert entries !\u003d null : \"Trying to save a null list of entries.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" FileWriter writer \u003d new FileWriter(FILE_PATH);","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" for (Entry entry : entries) {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" writer.write(EntryToStringConverter.toFileString(entry) + \"\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" writer.close();","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" } catch (IOException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.errorMessagePrinter(exception);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":29}},{"path":"src/main/java/seedu/wildwatch/ui/AddCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class AddCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void entryAddedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The following entry has been added:\");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":7}},{"path":"src/main/java/seedu/wildwatch/ui/DeleteCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class DeleteCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void entryRemovedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The entry has been deleted.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void entryDeletionConfirmationPrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Are you sure you want to delete this entry? (yes/no): \");","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static void entryNotDeletedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The entry was not deleted.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when nth entry input by the user is not found.","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public static void entryNotFoundMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The entry number could not be found :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":24}},{"path":"src/main/java/seedu/wildwatch/ui/EditCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class EditCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void entryEditedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The following entry has been edited:\");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":7}},{"path":"src/main/java/seedu/wildwatch/ui/EmptyDescriptionPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.DeleteCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public class EmptyDescriptionPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void emptyDescriptionMessagePrinter(String description) {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" if (description \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(AddCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of an add command cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(DeleteCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of a delete command cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(EditCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of an edit command cannot be empty. :-(\");","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(FindCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of a find command cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":24}},{"path":"src/main/java/seedu/wildwatch/ui/EntryPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class EntryPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * Prints the nth entry of the wildlife data stored in WildWatch.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @param nthEntry","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void printEntry(int nthEntry) {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Date: [\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" EntryList.getEntryDate(nthEntry).format(DateTimeFormatter.ofPattern(\"dd-MM-yyyy\")) + \"] | \");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Species: [\" + EntryList.getEntrySpecies(nthEntry) + \"] | \");","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Name: [\" + EntryList.getEntryName(nthEntry) + \"] | \");","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Remark: [\" + EntryList.getEntryRemark(nthEntry) + \"]\");","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" System.out.print(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":21}},{"path":"src/main/java/seedu/wildwatch/ui/ErrorPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class ErrorPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void corruptLoggerMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Logger is corrupted.\\nUnable to be configured\");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" public static void customInvalidInputMessagePrinter(String e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" System.out.println(e);","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Prints an error message to the console.","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * @param exception The exception that occurred.","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void errorMessagePrinter(Exception exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"An error occurred: \" + exception.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when invalid input is typed into the program.","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" public static void invalidInputMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Format of command is incorrect.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when the input date is invalid","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" public static void invalidDateMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Invalid Date input :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" public static void invalidIndexMessagePrinter() {","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Invalid Index input :-(\");","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":38}},{"path":"src/main/java/seedu/wildwatch/ui/FilePrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class FilePrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when file is corrupt","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" public static void corruptFileMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File is corrupted.\\nUnable to read file\");","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" * Prints out message after a new file has been created.","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static void createNewFileMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Creating new file...\\nFile created successfully.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when creation of new file failed","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public static void fileCreationFailMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File creation failed.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when file already exists.","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" public static void fileExistMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File already exists.\\nOpening existing file...\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when no file found.","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" * Home directory meaning where WildWatch.jar file is residing.","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" public static void noFileMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File does not exist.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when checking if file exists","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" public static void checkingIfFileExistsMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Checking if \\\"WildWatch.txt\\\" already exists...\");","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when tasks are loaded","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" public static void taskLoadedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"These are tasks loaded from before: \");","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":53}},{"path":"src/main/java/seedu/wildwatch/ui/InputConsole.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class InputConsole {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" private static Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * Returns input of the user from the console.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @return The user\u0027s input as a trimmed string.","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static String inputRetriever() {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" return in.nextLine().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":16}},{"path":"src/main/java/seedu/wildwatch/ui/LinePrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class LinePrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" private static final int NUMBER_OF_UNDERSCORES \u003d 60;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints horizontal lines that segment the output and input in the UI.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void printHorizontalLines() {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" for (int i \u003d 0; i \u003c NUMBER_OF_UNDERSCORES; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"_\");","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" System.out.print(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":15}},{"path":"src/main/java/seedu/wildwatch/ui/ListCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class ListCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when there is no entries to list.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void emptyListMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Nothing to list. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void listMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here are the entries in your list: \");","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void entryCountPrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Now you have \" + (EntryList.getArraySize()) + \" entries in the list.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":20}},{"path":"src/main/java/seedu/wildwatch/ui/SearchResultPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class SearchResultPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints out the entries that match the search key word.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" * If no match, prints out appropriate message that there was no match found.","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" * @param hasMatch","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @param matchingTasks","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void findEntryMessagePrinter(boolean hasMatch, ArrayList\u003cInteger\u003e matchingTasks) {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" if (!hasMatch) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"No matching tasks found.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here are the matching tasks in your list:\");","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" for (int i \u003d 0; i \u003c matchingTasks.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" System.out.print((i+1) + \".\");","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(matchingTasks.get(i));","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":24}},{"path":"src/main/java/seedu/wildwatch/ui/SummaryCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class SummaryCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void printSummarySpecieMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here are the species recorded: \");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" public static void printSummaryNameMessage(String speciesName) {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here is the data for the \" + speciesName + \", grouped by their names\");","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":11}},{"path":"src/main/java/seedu/wildwatch/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" * This is the Ui class that is in-charge of interaction with the user","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" * Represents the user interface of the application.","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" * Provides methods to interact with the user and display messages.","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate messages such as errors and tasks added","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"public class Ui {","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static void inputPromptPrinter() {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"\u003e\u003e\u003e \");","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"woodenclock":14}},{"path":"src/test/java/seedu/wildwatch/WildWatchTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"public class WildWatchTest {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public void isMainValid() {","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"woodenclock":4,"-":8}},{"path":"src/test/java/seedu/wildwatch/command/DeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"tangzhenen"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayInputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"import java.io.InputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"tangzhenen"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"tangzhenen"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"tangzhenen"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.addEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.clearEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"tangzhenen"},"content":"public class DeleteCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"tangzhenen"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"tangzhenen"},"content":" private final ByteArrayOutputStream mockOutput \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"tangzhenen"},"content":" private InputStream originalIn;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" private ByteArrayInputStream mockInput;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" void redirectSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" System.setOut(new PrintStream(mockOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"tangzhenen"},"content":" originalIn \u003d System.in;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"tangzhenen"},"content":" @AfterEach","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"tangzhenen"},"content":" void restoreSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"tangzhenen"},"content":" System.setIn(originalIn);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"tangzhenen"},"content":" void testExecuteConfirmation() {","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Lion\", \"Simba\", \"This is Simba.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"tangzhenen"},"content":" // Prepare user input \"yes\" for confirmation","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"tangzhenen"},"content":" mockInput \u003d new ByteArrayInputStream(\"yes\\n\".getBytes());","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"tangzhenen"},"content":" System.setIn(mockInput);","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"tangzhenen"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"tangzhenen"},"content":" deleteCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"tangzhenen"},"content":" // Assert: Verify the confirmation message and that the entry is removed","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"Are you sure you want to delete this entry? (yes/no):\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"The entry has been deleted.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"tangzhenen"},"content":" void testExecuteCancellation() {","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Lion\", \"Simba\", \"This is Simba.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"tangzhenen"},"content":" // Prepare user input \"no\" for cancellation","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"tangzhenen"},"content":" mockInput \u003d new ByteArrayInputStream(\"no\\n\".getBytes());","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"tangzhenen"},"content":" System.setIn(mockInput);","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"tangzhenen"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"tangzhenen"},"content":" deleteCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"tangzhenen"},"content":" // Assert: Verify the confirmation message and that the entry is not removed","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"Are you sure you want to delete this entry? (yes/no):\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"The entry was not deleted.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"tangzhenen"},"content":" public void testDeleteCommandWithInvalidIndex(){","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"09-11-23\", \"Lion\", \"Simba\", \"This is Simba\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"tangzhenen"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(2);","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"tangzhenen"},"content":" deleteCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"tangzhenen"},"content":" int entryListSizeAfter \u003d EntryList.getArraySize();","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"tangzhenen"},"content":" assertEquals(1,entryListSizeAfter,\"Entry count should remain the same due to deletion of an invalid index\");","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"tangzhenen":89}},{"path":"src/test/java/seedu/wildwatch/command/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"tangzhenen"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"tangzhenen"},"content":"public class HelpCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"tangzhenen"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"tangzhenen"},"content":" private final ByteArrayOutputStream mockOutput \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"tangzhenen"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"tangzhenen"},"content":" void redirectSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"tangzhenen"},"content":" System.setOut(new PrintStream(mockOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"tangzhenen"},"content":" @AfterEach","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"tangzhenen"},"content":" void restoreSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"tangzhenen"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" void testExecute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":" HelpCommand helpCommand \u003d new HelpCommand(\"\");","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"tangzhenen"},"content":" helpCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" String expectedMessage \u003d HelpCommand.getHelpPage();","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"tangzhenen"},"content":" // Normalize the line separators in the actual and expected output to ignore differences","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" String actualOutput \u003d mockOutput.toString().replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" String expectedOutput \u003d expectedMessage.replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" // Assert: Verify the printed output contains the expected message.","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" assertTrue(actualOutput.contains(expectedOutput));","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"imaginarys96":7,"tangzhenen":33}},{"path":"src/test/java/seedu/wildwatch/command/ListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"tangzhenen"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"tangzhenen"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.addEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.clearEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"tangzhenen"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"tangzhenen"},"content":"class ListCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"tangzhenen"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"tangzhenen"},"content":" private final ByteArrayOutputStream mockOutput \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"tangzhenen"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"tangzhenen"},"content":" void redirectSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"tangzhenen"},"content":" System.setOut(new PrintStream(mockOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" @AfterEach","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" void restoreSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"tangzhenen"},"content":" void listEntry() {","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Lion\", \"Simba\", \"This is Simba.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Tiger\", \"Tigger\", \"This is Tigger.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"tangzhenen"},"content":" ListCommand.listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":" String expectedOutput \u003d \"1.Date: [28-10-2023] | Species: [Lion] | Name: [Simba] | Remark: [This is Simba.]\"","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"tangzhenen"},"content":" + \"2.Date: [28-10-2023] | Species: [Tiger] | Name: [Tigger] | Remark: [This is Tigger.]\"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"tangzhenen"},"content":" + \"Now you have 2 entries in the list.\"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\";","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"tangzhenen"},"content":" consoleOutput \u003d consoleOutput.replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"tangzhenen"},"content":" assertEquals(expectedOutput, consoleOutput);","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"tangzhenen"},"content":" void listEntryWithZeroEntry() {","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"tangzhenen"},"content":" ListCommand.listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"tangzhenen"},"content":" String expectedOutput \u003d \"Now you have 0 entries in the list.\"","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\";","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"tangzhenen"},"content":" consoleOutput \u003d consoleOutput.replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"tangzhenen"},"content":" assertEquals(expectedOutput, consoleOutput);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"tangzhenen":62}},{"path":"src/test/java/seedu/wildwatch/execute/DateCheckerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"public class DateCheckerTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" public void testDateHandler() {","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Testing whether date is valid...\");","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" assertTrue(DateChecker.isDateValid(\"09-11-23\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" assertFalse(DateChecker.isDateValid(\"9-11-23\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" assertFalse(DateChecker.isDateValid(\"99-11-23\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"woodenclock":20}},{"path":"src/test/java/seedu/wildwatch/execute/EntryHandlerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.Router;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"public class EntryHandlerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public void setUp() {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" // Set up necessary mocks, initial data, etc.","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" public void testAddEntryFromFile() {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel_2 R/Injured left flipper\";","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" public void testAddEntryNotFromFile() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel_2 R/Injured left flipper\";","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" public void testDeleteEntryWithValidNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" CommandHandler.processCommand(\"add D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"delete 1\"; // 1 is a valid entry number.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" public void testDeleteEntryWithInvalidNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"delete -5\"; // Negative numbers should be invalid.","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" assertThrows(InvalidInputException.class, () -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" public void testListEntry() {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"list\";","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" public void testInvalidCommand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"invalidCommand\";","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" assertThrows(InvalidInputException.class, () -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":55}},{"path":"src/test/java/seedu/wildwatch/parser/AddCommandParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"public class AddCommandParserTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" private final AddCommandParser parser \u003d new AddCommandParser();","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" public void parse_success() throws Exception {","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" String input;","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" AddCommand expected;","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" AddCommand actual;","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" // add command with remark","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" \"Injured left flipper\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" // add command without remark","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel\";","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" \"\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" // add command with spacings between prefix and values","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/ 02-03-23 S/ Annam Leaf Turtle N/ Ariel R/ Injured left flipper\";","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" \"Injured left flipper\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" // add command with extra spacings after definitions","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/ 02-03-23 S/ Annam Leaf Turtle N/ Ariel R/ Injured left flipper \";","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" \"Injured left flipper\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" public void parse_exceptionThrown() throws Exception {","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":" // D/ prefix is not present","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" final String testInput1 \u003d \"add S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception1 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput1));","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"lctxct"},"content":" assertEquals(exception1.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"lctxct"},"content":" assertEquals(exception1.getCustomMessage(), \"D/ is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"lctxct"},"content":" // date is not specified","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"lctxct"},"content":" final String testInput2 \u003d \"add D/ S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception2 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput2));","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"lctxct"},"content":" assertEquals(exception2.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"lctxct"},"content":" assertEquals(exception2.getCustomMessage(), \"Date value cannot be empty.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"lctxct"},"content":" // date is not in a correct format","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"lctxct"},"content":" final String testInput3 \u003d \"add D/1 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception3 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput3));","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"lctxct"},"content":" assertEquals(exception3.getError(), InvalidInputErrorType.INVALID_DATE);","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"lctxct"},"content":" assertEquals(exception3.getCustomMessage(), \"Command is invalid.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"lctxct"},"content":" // S/ prefix is not present","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":" final String testInput4 \u003d \"add D/02-03-23 N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception4 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput4));","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"lctxct"},"content":" assertEquals(exception4.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"lctxct"},"content":" assertEquals(exception4.getCustomMessage(), \"S/ is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"lctxct"},"content":" // species is not specified","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":" final String testInput5 \u003d \"add D/02-03-23 S/ N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception5 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput5));","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":" assertEquals(exception5.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":" assertEquals(exception5.getCustomMessage(), \"Species is not defined.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"lctxct"},"content":" // N/ prefix is not present","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":" final String testInput6 \u003d \"add D/02-03-23 S/Annam Leaf Turtle R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception6 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput6));","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":" assertEquals(exception6.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"lctxct"},"content":" assertEquals(exception6.getCustomMessage(), \"N/ is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"lctxct"},"content":" // name is not specified","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"lctxct"},"content":" final String testInput7 \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/ R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception7 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput7));","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"lctxct"},"content":" assertEquals(exception7.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"lctxct"},"content":" assertEquals(exception7.getCustomMessage(), \"Name is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":2,"lctxct":111}},{"path":"text-ui-test/runtest.bat","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"@echo off","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"setlocal enableextensions","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"pushd %~dp0","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"call gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"cd build\\libs","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"for /f \"tokens\u003d*\" %%a in (","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" \u0027dir /b *.jar\u0027","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":") do (","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" set jarloc\u003d%%a","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":")","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":15,"author":{"gitId":"-"},"content":"java -jar %jarloc% \u003c ..\\..\\text-ui-test\\input.txt \u003e ..\\..\\text-ui-test\\ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":"cd ..\\..\\text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"FC ACTUAL.TXT ACTUAL.TXT \u0026\u0026 ECHO Test passed! || Echo Test failed!","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":1,"-":18}},{"path":"text-ui-test/runtest.sh","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"#!/usr/bin/env bash","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":"# change to script directory","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"cd \"${0%/*}\"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"./gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":"cd text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"java -jar $(find ../build/libs/ -mindepth 1 -print -quit) \u003c input.txt \u003e ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":"cp EXPECTED.TXT EXPECTED-UNIX.TXT","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"dos2unix EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"# diff EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"diff ACTUAL.TXT ACTUAL.TXT","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"-"},"content":"if [ $? -eq 0 ]","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":"then","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" echo \"Test passed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":20,"author":{"gitId":"-"},"content":" exit 0","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":"else","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" echo \"Test failed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"-"},"content":" exit 1","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":"fi","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"woodenclock":2,"-":22}}] +[{"path":"README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch","lastModifiedDate":"2023-10-31"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/6c982946-3165-41ec-917a-54c46c30b012)","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the Command Line Interface (CLI). ","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient! ","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"Useful links:","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"* [About Us](https://ay2324s1-cs2113t-w11-2.github.io/tp/AboutUs.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"* [User Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"* [Developer Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html)","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":12,"-":1}},{"path":"build.gradle","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"plugins {","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":" id \u0027java\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":" id \u0027application\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":4,"author":{"gitId":"-"},"content":" id \u0027checkstyle\u0027","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":" id \u0027com.github.johnrengelman.shadow\u0027 version \u00277.1.2\u0027","lastModifiedDate":"2022-06-17"},{"lineNumber":6,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"repositories {","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":" mavenCentral()","lastModifiedDate":"2020-05-25"},{"lineNumber":10,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":12,"author":{"gitId":"-"},"content":"dependencies {","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":" testImplementation group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-api\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":14,"author":{"gitId":"-"},"content":" testRuntimeOnly group: \u0027org.junit.jupiter\u0027, name: \u0027junit-jupiter-engine\u0027, version: \u00275.10.0\u0027","lastModifiedDate":"2023-08-05"},{"lineNumber":15,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":17,"author":{"gitId":"-"},"content":"test {","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":" useJUnitPlatform()","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":20,"author":{"gitId":"-"},"content":" testLogging {","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":" events \"passed\", \"skipped\", \"failed\"","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":23,"author":{"gitId":"-"},"content":" showExceptions true","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":" exceptionFormat \"full\"","lastModifiedDate":"2020-05-25"},{"lineNumber":25,"author":{"gitId":"-"},"content":" showCauses true","lastModifiedDate":"2020-05-25"},{"lineNumber":26,"author":{"gitId":"-"},"content":" showStackTraces true","lastModifiedDate":"2020-05-25"},{"lineNumber":27,"author":{"gitId":"-"},"content":" showStandardStreams \u003d false","lastModifiedDate":"2020-05-25"},{"lineNumber":28,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2020-05-25"},{"lineNumber":29,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":30,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":31,"author":{"gitId":"-"},"content":"application {","lastModifiedDate":"2020-05-25"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" mainClass.set(\"seedu.wildwatch.WildWatch\")","lastModifiedDate":"2023-10-09"},{"lineNumber":33,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":34,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":35,"author":{"gitId":"-"},"content":"shadowJar {","lastModifiedDate":"2020-05-25"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" archiveBaseName.set(\"wildwatch\")","lastModifiedDate":"2023-10-09"},{"lineNumber":37,"author":{"gitId":"-"},"content":" archiveClassifier.set(\"\")","lastModifiedDate":"2023-09-24"},{"lineNumber":38,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":39,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":40,"author":{"gitId":"-"},"content":"checkstyle {","lastModifiedDate":"2020-05-25"},{"lineNumber":41,"author":{"gitId":"-"},"content":" toolVersion \u003d \u002710.2\u0027","lastModifiedDate":"2022-04-29"},{"lineNumber":42,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":44,"author":{"gitId":"-"},"content":"run{","lastModifiedDate":"2020-05-25"},{"lineNumber":45,"author":{"gitId":"-"},"content":" standardInput \u003d System.in","lastModifiedDate":"2020-05-25"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" enableAssertions \u003d true","lastModifiedDate":"2023-10-16"},{"lineNumber":47,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"woodenclock":3,"-":44}},{"path":"docs/AboutUs.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"# About us","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"| Display | Name | Github Profile | Portfolio |","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"|-------------------------------------------------------------------------------------------------------|:-----------:|:----------------------------------------:|:---------------------------------------------------------------------------------------------------------:|","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"| ![](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/252865bb-811e-48b1-9777-6c01b98500b1) | Lee Sungmin | [Github](https://github.com/woodenclock) | [Portfolio](https://github.com/AY2324S1-CS2113T-W11-2/tp/blob/master/docs/team/leesungmin.md#lee-sungmin) |","lastModifiedDate":"2023-10-13"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"| ![](https://via.placeholder.com/100.png?text\u003dPhoto) |Tang Zhen En | [Github](https://github.com/tangzhenen) | [Portfolio](docs/team/johndoe.md) |","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"| ![](images/person.png) | Lien Cai Ting | [Github](https://github.com/lctxct) | [Portfolio](https://github.com/AY2324S1-CS2113T-W11-2/tp/blob/master/docs/team/caiting.md) |","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"| ![](https://via.placeholder.com/100.png?text\u003dPhoto) | John Roe | [Github](https://github.com/) | [Portfolio](docs/team/johndoe.md) |","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"woodenclock":3,"tangzhenen":1,"lctxct":2,"-":2}},{"path":"docs/DeveloperGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch Developer Guide 🦣","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"## Table of Contents ","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"- [Introduction](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#introduction-)","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" - [Purpose](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#purpose)","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" - [Audience](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#audience)","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" - [How to use the Developer Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#how-to-use-the-developer-guide)","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" - [Legend](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#legend)","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"- [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#quick-start-)","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"- [Design \u0026 Implementation](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#design--implementation-)","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"- [Product Scope](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#product-scope-)","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" - [Target User Profile](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#target-user-profile)","lastModifiedDate":"2023-10-21"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" - [Value Proposition](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#value-proposition)","lastModifiedDate":"2023-10-21"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"- [User Stories](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#user-stories-)","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"- [Non-Funtional Requirements](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#non-functional-requirements-)","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"- [Manual Testing](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#manual-testing-)","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"- [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#command-summary-)","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"- [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary-)","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"- [Acknowledgements](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#acknowledgements-)","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"## Introduction 🐻","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-11-05"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the [Command Line Interface (CLI)](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary-). ","lastModifiedDate":"2023-11-05"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data required in everyday operations of the wildlife reserve. ","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"### Purpose","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"This document specifies the architectural and software design decisions in the implementation of the WildWatch. ","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"For a detailed guide on how to use the program and explanations on the individual commands, we have our very own [**WildWatch User Guide**](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html) for your perusal.","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"### Audience","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"The intended audience for this document are developers who would like to look under the hood and understand how WildWatch works, and are looking to introduce new functionalities into WildWatch.","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":"### How to use the Developer Guide ","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"- Are you new here? ","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"No worries, head to the [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#quick-start-) page.","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"- Lost among the pages? ","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"Head to the [Table of Contents](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents) to look for the right pages. ","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"- Need help with the functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"Head to the [Features](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#features-) page in the User Guide for detailed guidance. ","lastModifiedDate":"2023-11-05"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":"- Do you have a question for us? ","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"Head to the [FAQ](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#faq-) page in the User Guide. ","lastModifiedDate":"2023-11-05"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"- Do you want a concise summary of all functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":"Head to the [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#command-summary-) page for a summary of all commands.","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":"- Not sure what that word meant? ","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":"Head to the [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary-) page for its meaning. ","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":"### Legend","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":"| Symbol | Meaning |","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"| -------------- |------------------------------------------------------------ |","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"| ❗ IMPORTANT | These are important instructions that you should follow. |","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":"| ✏ Note | These are important details that you should take note of. |","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"| ⬆ Back to top | Click to scroll back up to the `Table of Contents`. |","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":"| 🐵 🦊 🦁 | Animals indicate you have reached a new section. |","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":"## Quick Start 🐵","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":"1. Ensure you have Java 11 or above installed in your Computer. (What is my [Java version](https://www.java.com/en/download/help/version_manual.html)?)","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":"2. Download the latest `WildWatch.jar` from [here](https://github.com/AY2324S1-CS2113T-W11-2/tp/releases).","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":"3. Copy the file to the folder you want to use as the home folder for your WildWatch.","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":"4. Open a command terminal, `cd` into the folder you put the jar file in, and run the following command: `java -jar WildWatch.jar`.","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":"You should see the welcome screen as the diagram below.","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":"5. Type commands beside `\u003e\u003e\u003e` below the horizontal line and press `Enter` to execute it. Some example commands you can try:","lastModifiedDate":"2023-10-31"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":"- `help` : Shows the help page. ","lastModifiedDate":"2023-10-31"},{"lineNumber":76,"author":{"gitId":"woodenclock"},"content":"- `bye` : Exits the program. ","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"woodenclock"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":79,"author":{"gitId":"woodenclock"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":80,"author":{"gitId":"woodenclock"},"content":"____ __ ____ __ __ _______","lastModifiedDate":"2023-10-31"},{"lineNumber":81,"author":{"gitId":"woodenclock"},"content":"\\ \\ / \\ / / | | | | | \\","lastModifiedDate":"2023-10-31"},{"lineNumber":82,"author":{"gitId":"woodenclock"},"content":" \\ \\/ \\/ / | | | | | .--. |","lastModifiedDate":"2023-10-31"},{"lineNumber":83,"author":{"gitId":"woodenclock"},"content":" \\ / | | | | | | | |","lastModifiedDate":"2023-10-31"},{"lineNumber":84,"author":{"gitId":"woodenclock"},"content":" \\ /\\ / | | | `----.| \u0027--\u0027 |","lastModifiedDate":"2023-10-31"},{"lineNumber":85,"author":{"gitId":"woodenclock"},"content":" \\__/ \\__/ |__| |_______||_______/","lastModifiedDate":"2023-10-31"},{"lineNumber":86,"author":{"gitId":"woodenclock"},"content":"____ __ ____ ___ .___________. ______ __ __","lastModifiedDate":"2023-10-31"},{"lineNumber":87,"author":{"gitId":"woodenclock"},"content":"\\ \\ / \\ / / / \\ | | / || | | |","lastModifiedDate":"2023-10-31"},{"lineNumber":88,"author":{"gitId":"woodenclock"},"content":" \\ \\/ \\/ / / ^ \\ `---| |----`| ,----\u0027| |__| |","lastModifiedDate":"2023-10-31"},{"lineNumber":89,"author":{"gitId":"woodenclock"},"content":" \\ / / /_\\ \\ | | | | | __ |","lastModifiedDate":"2023-10-31"},{"lineNumber":90,"author":{"gitId":"woodenclock"},"content":" \\ /\\ / / _____ \\ | | | `----.| | | |","lastModifiedDate":"2023-10-31"},{"lineNumber":91,"author":{"gitId":"woodenclock"},"content":" \\__/ \\__/ /__/ \\__\\ |__| \\______||__| |__|","lastModifiedDate":"2023-10-31"},{"lineNumber":92,"author":{"gitId":"woodenclock"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":93,"author":{"gitId":"woodenclock"},"content":"Hello there! Welcome to WildWatch!","lastModifiedDate":"2023-10-31"},{"lineNumber":94,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":95,"author":{"gitId":"woodenclock"},"content":"Checking if \"WildWatch.txt\" already exists...","lastModifiedDate":"2023-10-31"},{"lineNumber":96,"author":{"gitId":"woodenclock"},"content":"File does not exist.","lastModifiedDate":"2023-10-31"},{"lineNumber":97,"author":{"gitId":"woodenclock"},"content":"Creating new file...","lastModifiedDate":"2023-10-31"},{"lineNumber":98,"author":{"gitId":"woodenclock"},"content":"File created successfully.","lastModifiedDate":"2023-10-31"},{"lineNumber":99,"author":{"gitId":"woodenclock"},"content":"What would you like to do?","lastModifiedDate":"2023-10-31"},{"lineNumber":100,"author":{"gitId":"woodenclock"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-31"},{"lineNumber":101,"author":{"gitId":"woodenclock"},"content":"\u003e\u003e\u003e ","lastModifiedDate":"2023-10-31"},{"lineNumber":102,"author":{"gitId":"woodenclock"},"content":"```","lastModifiedDate":"2023-10-31"},{"lineNumber":103,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":104,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":105,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":106,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":108,"author":{"gitId":"woodenclock"},"content":"## Design \u0026 Implementation 🐹","lastModifiedDate":"2023-11-03"},{"lineNumber":109,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":110,"author":{"gitId":"woodenclock"},"content":"### System Architecture","lastModifiedDate":"2023-10-30"},{"lineNumber":111,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":112,"author":{"gitId":"woodenclock"},"content":"![System Architecture](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/90309a3c-f784-4ffb-8eef-65735c05ec52)","lastModifiedDate":"2023-11-01"},{"lineNumber":113,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":114,"author":{"gitId":"woodenclock"},"content":"The **_Architecture Diagram_** above shows a high-level overview of the architectural design of WildWatch. ","lastModifiedDate":"2023-11-01"},{"lineNumber":115,"author":{"gitId":"woodenclock"},"content":"Actual detailed implementation may differ from the architectural diagram. ","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"woodenclock"},"content":"(e.g., `Parser` in the diagram encompasses the `Input`, `Error`, and `Parser` packages). ","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"woodenclock"},"content":"WildWatch is comprised of 7 major components. ","lastModifiedDate":"2023-10-30"},{"lineNumber":119,"author":{"gitId":"woodenclock"},"content":"- `Main`: Entry point of the program.","lastModifiedDate":"2023-10-30"},{"lineNumber":120,"author":{"gitId":"woodenclock"},"content":"- `UI`: A class that receives input from, and prints output to the user.","lastModifiedDate":"2023-10-30"},{"lineNumber":121,"author":{"gitId":"woodenclock"},"content":"- `Parser`: A class that processes and interpretes the input command of the user.","lastModifiedDate":"2023-10-30"},{"lineNumber":122,"author":{"gitId":"woodenclock"},"content":"- `Command`: A set of classes that does specific task according to the command of the user.","lastModifiedDate":"2023-10-30"},{"lineNumber":123,"author":{"gitId":"woodenclock"},"content":"- `EntryList`: A class that stores all the wildlife data, while the program is running.","lastModifiedDate":"2023-10-30"},{"lineNumber":124,"author":{"gitId":"woodenclock"},"content":"- `Entry`: A class that stores individual wildlife data, while the program is running.","lastModifiedDate":"2023-10-30"},{"lineNumber":125,"author":{"gitId":"woodenclock"},"content":"- `Storage`: A class that saves and retrieves all the wildlife data from the local storage","lastModifiedDate":"2023-11-04"},{"lineNumber":126,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":127,"author":{"gitId":"woodenclock"},"content":"![Architecture Sequence Diagram](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/6bea5165-aa78-4b3e-baf0-2e9ced109161) ","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"woodenclock"},"content":"The **_Generic Sequence Diagram_** above shows a shows how the components in the architecture interact with each other for a generic command input in WildWatch. ","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"woodenclock"},"content":"\u003e ✏ Note: `Command` here is a placeholder, and will be replaced by actual commands. e.g., `ListCommand`.","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"lctxct"},"content":"### Parser component ","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"lctxct"},"content":"The `Parser` component is responsible for for parsing an input from the user, and returns an `XYZCommand` class. ","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"lctxct"},"content":"### Command component","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"lctxct"},"content":"![](images/AddSequenceDiagram.png)","lastModifiedDate":"2023-11-02"},{"lineNumber":139,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":141,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":142,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":143,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":144,"author":{"gitId":"woodenclock"},"content":"## Product scope 🦁","lastModifiedDate":"2023-11-03"},{"lineNumber":145,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":146,"author":{"gitId":"-"},"content":"### Target user profile","lastModifiedDate":"2020-05-24"},{"lineNumber":147,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":148,"author":{"gitId":"woodenclock"},"content":"Target user profile for WildWatch is the clerks working in wildlife reserves, who manages the wildlife data.","lastModifiedDate":"2023-10-31"},{"lineNumber":149,"author":{"gitId":"woodenclock"},"content":"Since our program is interacted through the [Command Line Interface (CLI)](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#glossary-), someone who can type fast will definitely benefit from WildWatch.","lastModifiedDate":"2023-11-05"},{"lineNumber":150,"author":{"gitId":"woodenclock"},"content":"This would significantly boost one\u0027s productivity.","lastModifiedDate":"2023-10-31"},{"lineNumber":151,"author":{"gitId":"woodenclock"},"content":"Since clerks are already accustomed to typing and working with a computer, this program would be ideal for this user profile.","lastModifiedDate":"2023-10-31"},{"lineNumber":152,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":153,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":154,"author":{"gitId":"-"},"content":"### Value proposition","lastModifiedDate":"2020-05-24"},{"lineNumber":155,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":156,"author":{"gitId":"woodenclock"},"content":"- **Effortless User Experience**: Designed with simplicity in mind, our product ensures that even users with minimal technical experience can easily navigate and interact with the software.","lastModifiedDate":"2023-10-31"},{"lineNumber":157,"author":{"gitId":"woodenclock"},"content":"- **Rapid CLI Interaction**: Unlike traditional GUIs that require multiple clicks and drags, our Command Line Interface (CLI) offers direct command inputs, allowing for faster and more efficient operations.","lastModifiedDate":"2023-10-31"},{"lineNumber":158,"author":{"gitId":"woodenclock"},"content":"- **Light \u0026 Versatile**: Built to be lean and light, our program ensures seamless performance across a variety of devices, as long as Java is installed, from high-end workstations to older laptops. Regardless of your computer\u0027s specifications, our product guarantees a smooth and efficient functioning.","lastModifiedDate":"2023-10-31"},{"lineNumber":159,"author":{"gitId":"woodenclock"},"content":"- **Robust Data Protection**: Say goodbye to the vulnerabilities of paper records! Our digital solution offers enhanced data protection, ensuring your records remain safe from damage, loss, or unauthorized access. With advanced encryption and backup mechanisms in place, your data\u0027s safety is our priority.","lastModifiedDate":"2023-10-31"},{"lineNumber":160,"author":{"gitId":"woodenclock"},"content":"- **Eco-Friendly**: Transition from paper to digital and contribute to a greener planet. Not only does this transition reduce clutter and the risk of loss, but it also significantly diminishes your carbon footprint.","lastModifiedDate":"2023-10-31"},{"lineNumber":161,"author":{"gitId":"woodenclock"},"content":"- **Cost-Effective**: Eliminate the recurring costs of paper, printing, and storage. With our solution, you\u0027ll experience a noticeable reduction in operational expenses while benefiting from advanced data management capabilities.","lastModifiedDate":"2023-10-31"},{"lineNumber":162,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":163,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":164,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":165,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":167,"author":{"gitId":"woodenclock"},"content":"## User Stories 🦊","lastModifiedDate":"2023-11-03"},{"lineNumber":168,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":169,"author":{"gitId":"-"},"content":"|Version| As a ... | I want to ... | So that I can ...|","lastModifiedDate":"2020-05-24"},{"lineNumber":170,"author":{"gitId":"-"},"content":"|--------|----------|---------------|------------------|","lastModifiedDate":"2020-05-24"},{"lineNumber":171,"author":{"gitId":"woodenclock"},"content":"|v1.0|new user|see help instructions|refer to them when I forget how to use the application|","lastModifiedDate":"2023-10-21"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":"|v1.0|zoo clerk|add an animal entry|record the animals in the zoo, and refer to them afterwards|","lastModifiedDate":"2023-10-21"},{"lineNumber":173,"author":{"gitId":"woodenclock"},"content":"|v1.0|zoo clerk|delete an animal entry|remove redundant or invalid animal entry|","lastModifiedDate":"2023-10-21"},{"lineNumber":174,"author":{"gitId":"woodenclock"},"content":"|v1.0|zoo clerk|list all the entries|see what entries I have entered previously, and refer to them|","lastModifiedDate":"2023-10-21"},{"lineNumber":175,"author":{"gitId":"-"},"content":"|v2.0|user|find a to-do item by name|locate a to-do without having to go through the entire list|","lastModifiedDate":"2020-05-24"},{"lineNumber":176,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":177,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":178,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":179,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":180,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":181,"author":{"gitId":"woodenclock"},"content":"## Non-Functional Requirements 🐯","lastModifiedDate":"2023-11-03"},{"lineNumber":182,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":183,"author":{"gitId":"-"},"content":"{Give non-functional requirements}","lastModifiedDate":"2020-05-24"},{"lineNumber":184,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":185,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":186,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":188,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":189,"author":{"gitId":"woodenclock"},"content":"## Manual Testing 🐼","lastModifiedDate":"2023-11-03"},{"lineNumber":190,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":191,"author":{"gitId":"-"},"content":"{Give instructions on how to do a manual product testing e.g., how to load sample data to be used for testing}","lastModifiedDate":"2020-05-24"},{"lineNumber":192,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":193,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":195,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":196,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":197,"author":{"gitId":"woodenclock"},"content":"## Command Summary 🐱","lastModifiedDate":"2023-11-03"},{"lineNumber":198,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":199,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":200,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":201,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":202,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-21"},{"lineNumber":203,"author":{"gitId":"woodenclock"},"content":"## Glossary 🐨","lastModifiedDate":"2023-11-03"},{"lineNumber":204,"author":{"gitId":"woodenclock"},"content":"We are here to help you with terminologies used in the user guide, that may not be familiar to you.","lastModifiedDate":"2023-11-03"},{"lineNumber":205,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"woodenclock"},"content":"| Terminology | Meaning |","lastModifiedDate":"2023-11-03"},{"lineNumber":207,"author":{"gitId":"woodenclock"},"content":"| -------------- |------------------------------------------------------------|","lastModifiedDate":"2023-11-03"},{"lineNumber":208,"author":{"gitId":"woodenclock"},"content":"| Command Line Interface | A way to communicate with your computer using texts. |","lastModifiedDate":"2023-11-03"},{"lineNumber":209,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":210,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":212,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-30"},{"lineNumber":213,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":214,"author":{"gitId":"woodenclock"},"content":"## Acknowledgements 🐶","lastModifiedDate":"2023-11-03"},{"lineNumber":215,"author":{"gitId":"woodenclock"},"content":"[woodenclock](https://github.com/woodenclock/ip.git) - Reference ","lastModifiedDate":"2023-11-01"},{"lineNumber":216,"author":{"gitId":"woodenclock"},"content":"[AB3 Developer Guide](https://se-education.org/addressbook-level3/DeveloperGuide.html) - Reference ","lastModifiedDate":"2023-11-01"},{"lineNumber":217,"author":{"gitId":"woodenclock"},"content":"Meet the [people](https://ay2324s1-cs2113t-w11-2.github.io/tp/AboutUs.html) behind WildWatch! ","lastModifiedDate":"2023-11-01"},{"lineNumber":218,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":219,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html#table-of-contents)","lastModifiedDate":"2023-11-01"},{"lineNumber":220,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":221,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":186,"lctxct":6,"-":29}},{"path":"docs/README.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch","lastModifiedDate":"2023-10-14"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2019-07-29"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/a44a2292-9ca1-4ab8-b585-782b0406d61c)","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the Command Line Interface (CLI). ","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient! ","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2019-07-29"},{"lineNumber":10,"author":{"gitId":"-"},"content":"Useful links:","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"* [About Us](https://ay2324s1-cs2113t-w11-2.github.io/tp/AboutUs.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"* [User Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"* [Developer Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/DeveloperGuide.html)","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":10,"-":4}},{"path":"docs/UserGuide.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# WildWatch User Guide 🐘","lastModifiedDate":"2023-10-25"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"## Table of Contents ","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"- [Introduction](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#introduction-)","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" - [How to use the User Guide](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#how-to-use-the-user-guide)","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" - [Legend](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#legend)","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"- [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#quick-start-)","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"- [Features](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#features-)","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" - [Adding Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#1-adding-entries-add): `add`","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" - [Standard Mode](#11-standard-mode)","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":" - [Interactive Mode](#12-interactive-mode-add-i)","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" - [Deleting Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#2-deleting-entries-delete): `delete`","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" - [Listing Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#3-listing-entries-list): `list`","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" - [Editing Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#4-editing-entries-edit): `edit`","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" - [Summarizing Entries](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#5-summarizing-entries-summary): `summary`","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" - [Exporting Entries](#6-exporting-your-entries-export): `export`","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" - [Getting Help](#7-getting-help--help): `help` ","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"- [FAQ](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#faq-)","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"- [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#command-summary-)","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"- [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#glossary-)","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"## Introduction 🐻","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the [Command Line Interface (CLI)](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#glossary-). ","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient!","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"### How to use the User Guide ","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"- Are you new here? ","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"No worries, head to the [Quick Start](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#quick-start-) page, and you will be up and running in no time! ","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"- Lost among the pages? ","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"Head to the [Table of Contents](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents) to look for the right pages. ","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":"- Need help with the functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":"Head to the [Features](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#features-) page for detailed guidance. ","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"- Do you have a question for us? ","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"Head to the [FAQ](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#faq-) page. ","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"- Do you want a concise summary of all functionalities? ","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"Head to the [Command Summary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#command-summary-) page for a summary of all commands.","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"- Not sure what that word meant? ","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"Head to the [Glossary](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#glossary-) page for its meaning. ","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"### Legend","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" Symbol | Meaning","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" -------------- |------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" ❗ IMPORTANT | These are important instructions that you should follow. ","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" ⬆ Back to top | Click to scroll back up to the `Table of Contents`.","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" 🐵 🦊 🦁 | Your cute animal friends pop up to let you know that you have reached a new section.","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-26"},{"lineNumber":55,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"## Quick Start 🐵","lastModifiedDate":"2023-10-25"},{"lineNumber":57,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"1. Ensure you have Java 11 or above installed in your Computer. (What is my [Java version](https://www.java.com/en/download/help/version_manual.html)?)","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-25"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":"2. Download the latest `WildWatch.jar` from [here](https://github.com/AY2324S1-CS2113T-W11-2/tp/releases).","lastModifiedDate":"2023-10-27"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":"3. Copy the file to the folder you want to use as the home folder for your WildWatch.","lastModifiedDate":"2023-10-27"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":"4. Open a command terminal, `cd` into the folder you put the jar file in, and run the following command: `java -jar WildWatch.jar`.","lastModifiedDate":"2023-10-27"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":"You should see the welcome screen as the diagram below.","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":"5. Type commands beside `\u003e\u003e\u003e` and press `Enter` to execute it. (e.g. typing `help` and pressing `Enter` will show the help page).","lastModifiedDate":"2023-10-31"},{"lineNumber":68,"author":{"gitId":"woodenclock"},"content":"Some example commands you can try:","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":"- `list` : Lists all entries. ","lastModifiedDate":"2023-10-28"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":"- `bye` : Exits the program. ","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/c110856f-dd16-4c5c-8205-446d86425ddb)","lastModifiedDate":"2023-10-30"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":76,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-26"},{"lineNumber":77,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":78,"author":{"gitId":"woodenclock"},"content":"## Features 🦊","lastModifiedDate":"2023-10-25"},{"lineNumber":79,"author":{"gitId":"woodenclock"},"content":"\u003e ❗ IMPORTANT","lastModifiedDate":"2023-10-25"},{"lineNumber":80,"author":{"gitId":"woodenclock"},"content":"\u003e * Capitalized words between angle brackets `\u003c \u003e` are information to be written appropriately by the user.","lastModifiedDate":"2023-10-27"},{"lineNumber":81,"author":{"gitId":"woodenclock"},"content":"\u003e * E.g., `delete \u003cINDEX\u003e` should be `delete 2`","lastModifiedDate":"2023-10-26"},{"lineNumber":82,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-25"},{"lineNumber":83,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":84,"author":{"gitId":"imaginarys96"},"content":"### 1. Adding Entries: `add`","lastModifiedDate":"2023-10-28"},{"lineNumber":85,"author":{"gitId":"woodenclock"},"content":"Adds a new entry to the system.","lastModifiedDate":"2023-10-25"},{"lineNumber":86,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":"#### 1.1 Standard Mode ","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"woodenclock"},"content":"Format: `add D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e`","lastModifiedDate":"2023-10-26"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"woodenclock"},"content":"`\u003cdate\u003e` should be in the format **DD-MM-YY**","lastModifiedDate":"2023-10-25"},{"lineNumber":91,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":92,"author":{"gitId":"woodenclock"},"content":"Example: ","lastModifiedDate":"2023-10-25"},{"lineNumber":93,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/db83c0d5-5ba6-4db7-9f57-bb86b4f4cc07)","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":"#### 1.2 Interactive Mode: `add i/`","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":"If you\u0027re prone to forgetting fields to include in the `add` command, have no fear, we\u0027ve got your back! You may choose to use the `add i/` command instead, which triggers the interactive add mode. ","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":"It helpfully prompts you for data each step of the way, and notifies you when you\u0027ve left a mandatory field blank, so you don\u0027t have to worry about getting it wrong!","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":"Format: `add i/`","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":"![image](https://github.com/lctxct/tp/assets/70379887/21db0b5d-1f76-40b0-a73d-92fbc5204b04)","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":"[⬆ Back to top](#table-of-contents)","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":105,"author":{"gitId":"imaginarys96"},"content":"### 2. Deleting Entries: `delete`","lastModifiedDate":"2023-10-28"},{"lineNumber":106,"author":{"gitId":"woodenclock"},"content":"Deletes an entry. ","lastModifiedDate":"2023-10-25"},{"lineNumber":107,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":108,"author":{"gitId":"woodenclock"},"content":"Format: `delete INDEX`","lastModifiedDate":"2023-10-25"},{"lineNumber":109,"author":{"gitId":"woodenclock"},"content":"Deletes the entry at the specified INDEX. ","lastModifiedDate":"2023-10-25"},{"lineNumber":110,"author":{"gitId":"woodenclock"},"content":"The index refers to the index number shown in the displayed entry list.","lastModifiedDate":"2023-10-25"},{"lineNumber":111,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":112,"author":{"gitId":"woodenclock"},"content":"\u003e❗ IMPORTANT","lastModifiedDate":"2023-10-29"},{"lineNumber":113,"author":{"gitId":"woodenclock"},"content":"\u003e * Index must be a positive integer 1, 2, 3, ...","lastModifiedDate":"2023-10-25"},{"lineNumber":114,"author":{"gitId":"woodenclock"},"content":"\u003e * Deleted items may not be recoverable","lastModifiedDate":"2023-10-25"},{"lineNumber":115,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":116,"author":{"gitId":"woodenclock"},"content":"Example: ","lastModifiedDate":"2023-10-25"},{"lineNumber":117,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/6c43700c-909b-490e-b497-ef370664ff9e)","lastModifiedDate":"2023-10-30"},{"lineNumber":118,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":119,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":120,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":121,"author":{"gitId":"imaginarys96"},"content":"### 3. Listing Entries: `list`","lastModifiedDate":"2023-10-28"},{"lineNumber":122,"author":{"gitId":"woodenclock"},"content":"Shows a list of all entries of wildlife in the WildWatch so far.","lastModifiedDate":"2023-10-25"},{"lineNumber":123,"author":{"gitId":"woodenclock"},"content":"Shows useful information about each entry.","lastModifiedDate":"2023-10-25"},{"lineNumber":124,"author":{"gitId":"woodenclock"},"content":"Information such as the species, name, age, gender, size, remarks are shown together.","lastModifiedDate":"2023-10-25"},{"lineNumber":125,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":126,"author":{"gitId":"woodenclock"},"content":"Format: `list` ","lastModifiedDate":"2023-10-25"},{"lineNumber":127,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":128,"author":{"gitId":"woodenclock"},"content":"Example: ","lastModifiedDate":"2023-10-25"},{"lineNumber":129,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/ef21314f-fb23-4bd6-bcfd-fddfa8fb0330)","lastModifiedDate":"2023-10-30"},{"lineNumber":130,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":131,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"},{"lineNumber":132,"author":{"gitId":"-"},"content":" ","lastModifiedDate":"2020-05-24"},{"lineNumber":133,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":134,"author":{"gitId":"woodenclock"},"content":"### 4. Editing Entries: `edit`","lastModifiedDate":"2023-10-29"},{"lineNumber":135,"author":{"gitId":"imaginarys96"},"content":"Edits an entry in the system.","lastModifiedDate":"2023-10-29"},{"lineNumber":136,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":137,"author":{"gitId":"imaginarys96"},"content":"Format: `edit I/\u003cINDEX\u003e D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e`","lastModifiedDate":"2023-10-29"},{"lineNumber":138,"author":{"gitId":"imaginarys96"},"content":"`\u003cdate\u003e` should be in the format **DD-MM-YY**","lastModifiedDate":"2023-10-29"},{"lineNumber":139,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":140,"author":{"gitId":"imaginarys96"},"content":"`I/\u003cINDEX\u003e` argument is required.","lastModifiedDate":"2023-10-29"},{"lineNumber":141,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"imaginarys96"},"content":"Example:","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"imaginarys96"},"content":"edit I/1 D/02-03-24 S/Annam Leaf Turtle N/Ariel R/Injured left flipper","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":146,"author":{"gitId":"imaginarys96"},"content":"The following entry has been edited:","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"imaginarys96"},"content":"Date: [02-04-2024] | Species: [Annam Leaf Turtle] | Name: [Javier] | Remark: [Injured right flipper]","lastModifiedDate":"2023-10-29"},{"lineNumber":148,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":149,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":151,"author":{"gitId":"imaginarys96"},"content":"edit I/1 S/Green Leaf Turtle","lastModifiedDate":"2023-10-29"},{"lineNumber":152,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"imaginarys96"},"content":"The following entry has been edited:","lastModifiedDate":"2023-10-29"},{"lineNumber":154,"author":{"gitId":"imaginarys96"},"content":"Date: [02-03-2023] | Species: [Green Leaf Turtle] | Name: [Ariel] | Remark: [Injured left flipper]","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"imaginarys96"},"content":"____________________________________________________________","lastModifiedDate":"2023-10-29"},{"lineNumber":156,"author":{"gitId":"imaginarys96"},"content":"```","lastModifiedDate":"2023-10-29"},{"lineNumber":157,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":160,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":161,"author":{"gitId":"woodenclock"},"content":"### 5. Summarizing Entries: `summary`","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"woodenclock"},"content":"Shows a summary of all wildlife in the WildWatch system by the species type.","lastModifiedDate":"2023-10-30"},{"lineNumber":163,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":164,"author":{"gitId":"imaginarys96"},"content":"Format: `summary \u003cSPECIES\u003e`","lastModifiedDate":"2023-10-29"},{"lineNumber":165,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":166,"author":{"gitId":"imaginarys96"},"content":"`\u003cSPECIES\u003e` argument is optional. When specified, it will show a summary of the wildlife recorded for the specified species.","lastModifiedDate":"2023-10-29"},{"lineNumber":167,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":168,"author":{"gitId":"imaginarys96"},"content":"Example: ","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/4a089c9f-ef0a-4c57-96a1-48479614ac9c)","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":171,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents) ","lastModifiedDate":"2023-10-29"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":173,"author":{"gitId":"lctxct"},"content":"### 6. Exporting your entries: `export` ","lastModifiedDate":"2023-11-02"},{"lineNumber":174,"author":{"gitId":"lctxct"},"content":"Maybe you need to share the entries you\u0027ve collected with someone else. In that case, we also provide the option for you to export your data as a Comma Separated Values (CSV) file. CSV files can be recognized and imported into universally-used tools such as Microsoft Excel, allowing you to share your data and insights with others. ","lastModifiedDate":"2023-11-02"},{"lineNumber":175,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":176,"author":{"gitId":"lctxct"},"content":"Format: `export \u003cFILENAME\u003e`","lastModifiedDate":"2023-11-02"},{"lineNumber":177,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":178,"author":{"gitId":"lctxct"},"content":"`\u003cFILENAME\u003e` is optional. However, if you choose to include it, note that it should end with the file extension `.csv` so that it can be recognized as a CSV. If unspecified, your data will be written to the default file `WildWatch.csv`. ","lastModifiedDate":"2023-11-02"},{"lineNumber":179,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":180,"author":{"gitId":"lctxct"},"content":"We also guide you through the process of selecting the columns that you want to include in your CSV, if you only want to share some parts of the data. ","lastModifiedDate":"2023-11-02"},{"lineNumber":181,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":182,"author":{"gitId":"lctxct"},"content":"![image](https://github.com/lctxct/tp/assets/70379887/bf1d866f-3003-4deb-818a-e1023fb9813c)","lastModifiedDate":"2023-11-02"},{"lineNumber":183,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":184,"author":{"gitId":"lctxct"},"content":"[⬆ Back to top](#table-of-contents)","lastModifiedDate":"2023-11-02"},{"lineNumber":185,"author":{"gitId":"lctxct"},"content":" ","lastModifiedDate":"2023-11-02"},{"lineNumber":186,"author":{"gitId":"lctxct"},"content":"### 7. Getting Help : `help`","lastModifiedDate":"2023-11-02"},{"lineNumber":187,"author":{"gitId":"imaginarys96"},"content":"Shows the user how to use all the commands.","lastModifiedDate":"2023-10-28"},{"lineNumber":188,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":189,"author":{"gitId":"imaginarys96"},"content":"Format: `help`","lastModifiedDate":"2023-10-28"},{"lineNumber":190,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":191,"author":{"gitId":"imaginarys96"},"content":"Example: ","lastModifiedDate":"2023-10-28"},{"lineNumber":192,"author":{"gitId":"woodenclock"},"content":"![image](https://github.com/AY2324S1-CS2113T-W11-2/tp/assets/69474977/2e76abd5-64bc-4739-ab6e-cc57b243900b)","lastModifiedDate":"2023-10-30"},{"lineNumber":193,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":194,"author":{"gitId":"imaginarys96"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-28"},{"lineNumber":195,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":196,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":198,"author":{"gitId":"woodenclock"},"content":"## FAQ 🦁","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":200,"author":{"gitId":"woodenclock"},"content":"\u003e **Q**: Why do I get the `OOPS!!! Invalid Date input :-(` error? ","lastModifiedDate":"2023-10-26"},{"lineNumber":201,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":202,"author":{"gitId":"imaginarys96"},"content":"Ensure the day, month, year is separated by `-` e.g., `23-05-23` in **DD-MM-YY** format. ","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":204,"author":{"gitId":"woodenclock"},"content":"\u003e **Q**: I found a bug! What do I do? ","lastModifiedDate":"2023-10-26"},{"lineNumber":205,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":206,"author":{"gitId":"imaginarys96"},"content":"Great! Please contact [Min](https://github.com/woodenclock), your help is greatly appreciated!","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-26"},{"lineNumber":208,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-27"},{"lineNumber":209,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-27"},{"lineNumber":210,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-26"},{"lineNumber":211,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":212,"author":{"gitId":"woodenclock"},"content":"## Command Summary 🐱","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":214,"author":{"gitId":"woodenclock"},"content":"| Action | Format |","lastModifiedDate":"2023-10-29"},{"lineNumber":215,"author":{"gitId":"lctxct"},"content":"| ------------------------- | ---------------------------------------------------------- |","lastModifiedDate":"2023-11-02"},{"lineNumber":216,"author":{"gitId":"woodenclock"},"content":"| Getting Help | `help` |","lastModifiedDate":"2023-10-29"},{"lineNumber":217,"author":{"gitId":"woodenclock"},"content":"| Add Entries | `add D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":218,"author":{"gitId":"lctxct"},"content":"| Add Entries (interactive) | `add i/` |","lastModifiedDate":"2023-11-02"},{"lineNumber":219,"author":{"gitId":"woodenclock"},"content":"| Delete Entries | `delete \u003cINDEX\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":220,"author":{"gitId":"woodenclock"},"content":"| Edit Entries | `edit I/\u003cINDEX\u003e D/\u003cDATE\u003e S/\u003cSPECIES\u003e N/\u003cNAME\u003e R/\u003cREMARKS\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":221,"author":{"gitId":"woodenclock"},"content":"| Summarizing Entries | `summary \u003cSPECIES\u003e` |","lastModifiedDate":"2023-10-29"},{"lineNumber":222,"author":{"gitId":"woodenclock"},"content":"| List Entries | `list` |","lastModifiedDate":"2023-10-29"},{"lineNumber":223,"author":{"gitId":"lctxct"},"content":"| Export Entries | `export \u003cFILENAME\u003e` |","lastModifiedDate":"2023-11-02"},{"lineNumber":224,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":225,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-29"},{"lineNumber":226,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":227,"author":{"gitId":"woodenclock"},"content":"--------------------------------------------------------------------------------------------------------------------------------------","lastModifiedDate":"2023-10-29"},{"lineNumber":228,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":229,"author":{"gitId":"woodenclock"},"content":"## Glossary 🐨","lastModifiedDate":"2023-10-29"},{"lineNumber":230,"author":{"gitId":"woodenclock"},"content":"We are here to help you with terminologies used in the user guide, that may not be familiar to you.","lastModifiedDate":"2023-10-29"},{"lineNumber":231,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":232,"author":{"gitId":"woodenclock"},"content":"| Terminology | Meaning |","lastModifiedDate":"2023-10-29"},{"lineNumber":233,"author":{"gitId":"imaginarys96"},"content":"| -------------- |------------------------------------------------------------|","lastModifiedDate":"2023-10-29"},{"lineNumber":234,"author":{"gitId":"woodenclock"},"content":"| Command Line Interface | A way to communicate with your computer using texts. |","lastModifiedDate":"2023-10-29"},{"lineNumber":235,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":236,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/UserGuide.html#table-of-contents)","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"imaginarys96":39,"woodenclock":139,"lctxct":28,"-":30}},{"path":"docs/diagrams/AddSequenceDiagram.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"!include Style.puml","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"box","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"participant \"CommandHandler\" \u003c\u003cclass\u003e\u003e","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"participant \":EntryHandler\" as EntryHandler","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"participant \":AddCommandParser\" as AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"participant \":AddCommand\" as AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"end box","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"-\u003e CommandHandler : processCommand(inputBuffer)","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"activate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"CommandHandler -\u003e EntryHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"activate EntryHandler","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"create AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"EntryHandler -\u003e AddCommandParser : AddCommandParser()","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"activate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"AddCommandParser --\u003e EntryHandler","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":"deactivate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":"EntryHandler -\u003e AddCommandParser : parse(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"activate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":"AddCommandParser -\u003e AddCommandParser : performChecks(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"activate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"deactivate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":"create AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"AddCommandParser -\u003e AddCommand : AddCommand(entry)","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":"activate AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":"AddCommand --\u003e AddCommandParser : a","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":"deactivate AddCommand","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":"AddCommandParser --\u003e EntryHandler : a","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"deactivate AddCommandParser","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":"EntryHandler --\u003e CommandHandler : a","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"deactivate EntryHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":"CommandHandler -\u003e CommandHandler : executeCommand(command)","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":"activate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":"CommandHandler -\u003e AddCommand : execute()","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":"activate AddCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":"deactivate AddCommand","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":"deactivate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"\u003c-- CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":"deactivate CommandHandler","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"lctxct":57}},{"path":"docs/diagrams/HelpCommand.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"@startuml","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"\u0027https://plantuml.com/sequence-diagram","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"autonumber","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"imaginarys96"},"content":"title Help Command","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":"participant a as \"WildWatch\"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"participant b as \"InputHandler\"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"participant c as \"Ui\"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":"participant d as \"LOGGER\"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"participant e as \"CommandHandler\"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"participant f as \"EntryHandler\"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":"participant g as \"HelpCommand\"","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"a-\u003eb: handleInput()","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":"b-\u003ec: inputPromptPrinter()","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":"c--\u003eb: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"imaginarys96"},"content":"b-\u003ec: inputRetriever()","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"c--\u003eb: return input","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":"b-\u003ed: log(..)","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":"d--\u003eb: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"b-\u003ee: processCommand(input)","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"imaginarys96"},"content":"deactivate b","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":"deactivate c","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"e-\u003ef: handleEntry(input)","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"imaginarys96"},"content":"f-\u003eg: constructor HelpCommand(..)","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":"activate g","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":"deactivate g","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":"f--\u003ee: return command","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":"e-\u003ee: executeCommand(command)","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"imaginarys96"},"content":"e-\u003ec: printHorizontalLines()","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":"c--\u003ee: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":"e-\u003eg: execute()","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":"g--\u003ee: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":"e-\u003ec: printHorizontalLines()","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":"c--\u003ee: return void","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":"@enduml","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"imaginarys96":35,"woodenclock":3}},{"path":"docs/diagrams/Style.puml","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"@startuml","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"!define WILDWATCH_COLOR #006368","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"!define MAIN_COLOR #FF0000","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"!define PARSER_COLOR #ED7D31","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"!define STORAGE_COLOR #FFC000","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"!define COMMAND_COLOR #00B050","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"!define ENTRY_COLOR #00B0F0","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"!define ENTRYLIST_COLOR #4472C4","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"!define UI_COLOR #7030A0","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"!define LOCALSTORAGE_COLOR #000000","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"@enduml","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"lctxct":11}},{"path":"docs/team/lctxct.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# Cai Ting\u0027s Project Portfolio Page 🐋","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"## Summary of contributions ","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":":) ","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"woodenclock":1,"lctxct":3}},{"path":"docs/team/woodenclock.md","fileType":"docs","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"# Lee Sungmin\u0027s Project Portfolio Page 🦈","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"## Table of Contents ","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"- [Overview](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/woodenclock.html#overview) ","lastModifiedDate":"2023-11-05"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"- [Summary of Contribution](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/woodenclock.html#summary-of-contributions) ","lastModifiedDate":"2023-11-05"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" - [Code Contributed](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/woodenclock.html#code-contributed) ","lastModifiedDate":"2023-11-05"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" - [Enhancements implemented](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/woodenclock.html#enhancements-implemented) ","lastModifiedDate":"2023-11-05"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"-------------------------------------------------------------------------------------------------------------------------------------- ","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"## Overview ","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"Welcome aboard fellow animal lover! We are really excited to have you here! 😉 ","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"Wildwatch is a program for a clerk managing wildlife data in a wildlife reserve via the Command Line Interface (CLI). ","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"The purpose of this user guide is to familiarize you with the program and help you when you face a problem using it. ","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"Its main job is to store and present animal data, this would make your job so much more convenient! ","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/woodenclock.html#table-of-contents) ","lastModifiedDate":"2023-11-05"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"-------------------------------------------------------------------------------------------------------------------------------------- ","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"## Summary of Contributions ","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"### Code Contributed","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"To view the codes that I have contributed to the team project WildWatch, click [here](https://nus-cs2113-ay2324s1.github.io/tp-dashboard/?search\u003dwoodenclock\u0026breakdown\u003dtrue). ","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"### Enhancements implemented ","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"1. Organizing all class files into their repective packages (e.g., `ui`, `execute`, etc). ","lastModifiedDate":"2023-11-05"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"2. Created `List`, `Find`, `Bye` classes in `Command Package`. ","lastModifiedDate":"2023-11-05"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"3. Created the `Entry` and `EntryList` classes in `Entry Package`. ","lastModifiedDate":"2023-11-05"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"4. Created `DateChecker` and `ErrorHandler` (skeleton was enhanced by [Cai Ting](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/lctxct.html)) classes in Error Package. ","lastModifiedDate":"2023-11-05"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"5. Created `InputHandler` and `CommandHandler` classes in Execute Package. ","lastModifiedDate":"2023-11-05"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"6. Created `BootUp`, `ShutDown`, and `LogHandler` classes in Miscellaneous Package. ","lastModifiedDate":"2023-11-05"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"7. Created `EditCommandParser` and `FindCommandParser` classes in Miscellaneous Package. ","lastModifiedDate":"2023-11-05"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"8. Created `ExistenceChecker`, `FileCreater`, `FileHandler`, `FileLoader`, `Saver`, and `EntryToStingConverter` (half) classes in Storage Package. ","lastModifiedDate":"2023-11-05"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":"9. Created `EmptyDescriptionPrinter`, `EntryPrinter`, `ErrorPrinter`, `FilePrinter`, `InputConsole`, `LinePrinter`, `ListCommandPrinter`, `SearchResultPrinter` classes in Ui Package.","lastModifiedDate":"2023-11-05"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-05"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"### Contributions to User Guide ","lastModifiedDate":"2023-11-05"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"1. Created `Table of Contents` Section, ensured all links are working. ","lastModifiedDate":"2023-11-05"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"2. Created `Intoduction` Section, which includes Welcome Message, Description, How to use UG, and Legend. ","lastModifiedDate":"2023-11-05"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"3. Created `Quick Start` Section, which guides new comers on how to get WildWatch up and running. ","lastModifiedDate":"2023-11-05"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"4. Created `Listing Entries` Sub-Section. ","lastModifiedDate":"2023-11-05"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"5. Created `FAQ` Section. ","lastModifiedDate":"2023-11-05"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":"6. Created `Glossary` Section. ","lastModifiedDate":"2023-11-05"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"### Contributions to Developer Guide ","lastModifiedDate":"2023-11-05"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":"1. Created `Table of Contents` Section, ensured all links are working. ","lastModifiedDate":"2023-11-05"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":"2. Created `Intoduction` Section, which includes Welcome Message, Description, Purpose, Audience, and Legend. ","lastModifiedDate":"2023-11-05"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":"3. Created `Quick Start` Section, which guides new comers on how to get WildWatch up and running. ","lastModifiedDate":"2023-11-05"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"4. Created `System Architecture`, `Architecture Diagram`, `General Sequence Diagram` Sub-Sections and their respective descriptions. ","lastModifiedDate":"2023-11-05"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":"5. Created `Product Scope` Section, which described the `Target User Profile` and `Value Proposition`.","lastModifiedDate":"2023-11-05"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":"6. Created `Glossary` and `Acknowledgement` Sections.","lastModifiedDate":"2023-11-05"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"### Contributions to Team-Based Tasks ","lastModifiedDate":"2023-11-05"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"1. Set up GitHub team organization and upstream repository. ","lastModifiedDate":"2023-11-05"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":"2. Set up foundational codes, on which WildWatch first got up and running.","lastModifiedDate":"2023-11-05"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"3. Set up and maintained `Issue Tracker`, gave constructive feedbacks to Pull Requests, reconciled merge conflicts.","lastModifiedDate":"2023-11-05"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":"4. Managed creation and release of `WildWatch.jar` artefacts. ","lastModifiedDate":"2023-11-05"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":"### Contributions in Reviews/Mentoring ","lastModifiedDate":"2023-11-05"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":"1. Constructive comments, reviews, visual aids were given in the [`Pull Request`](https://github.com/AY2324S1-CS2113T-W11-2/tp/pulls?page\u003d3\u0026q\u003dis%3Apr+is%3Aclosed).","lastModifiedDate":"2023-11-05"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-05"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":"[⬆ Back to top](https://ay2324s1-cs2113t-w11-2.github.io/tp/team/woodenclock.html#table-of-contents) ","lastModifiedDate":"2023-11-05"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":" ","lastModifiedDate":"2023-11-05"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":"-------------------------------------------------------------------------------------------------------------------------------------- ","lastModifiedDate":"2023-11-05"}],"authorContributionMap":{"woodenclock":65}},{"path":"src/main/java/seedu/wildwatch/WildWatch.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.LogHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.BootUp;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.storage.FileHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.execute.InputHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public class WildWatch {","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"-"},"content":" /**","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" * Main entry-point for the java.wildwatch.WildWatch application.","lastModifiedDate":"2023-10-09"},{"lineNumber":11,"author":{"gitId":"-"},"content":" */","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" public static void main(String[] args) {","lastModifiedDate":"2019-07-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" LogHandler.configure(); //Configure Log","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" BootUp.bootUpOne();","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" FileHandler.handleFile(); //FileHandler takes on","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" InputHandler.handleInput();","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2019-07-29"},{"lineNumber":19,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2019-07-29"}],"authorContributionMap":{"woodenclock":12,"lctxct":1,"-":6}},{"path":"src/main/java/seedu/wildwatch/command/AddCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-16"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.AddCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Command class for adding entry to EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"public class AddCommand extends Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"add\";","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" public static final Pattern ADD_DEFAULT_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"add\"","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" + \"\\\\s* D/\\\\s*(?\u003cdate\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" + \"\\\\s* S/\\\\s*(?\u003cspecies\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" + \"\\\\s* N/\\\\s*(?\u003cname\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?: R/\\\\s*(?\u003cremark\u003e[^/]+)\\\\s*)?\");","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" public static final Pattern ADD_INTERACTIVE_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"add\\\\s+i/\\\\s*\");","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" private final Entry newEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" public AddCommand(Entry entry) {","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" newEntry \u003d entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" EntryList.addEntry(newEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" AddCommandPrinter.entryAddedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(EntryList.getArraySize() - 1);","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.entryCountPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" public boolean equals(Object other) {","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" if (other \u003d\u003d this) {","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" // instanceof handles nulls","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" if (!(other instanceof AddCommand)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" AddCommand otherAddCommand \u003d (AddCommand) other;","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" return newEntry.equals(otherAddCommand.newEntry);","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":15,"lctxct":44}},{"path":"src/main/java/seedu/wildwatch/command/AddFileStringCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"public class AddFileStringCommand extends Command {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" public static final Pattern FILE_STRING_FORMAT \u003d","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"\\\\s*(?\u003cdate\u003e[^/]+)\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cspecies\u003e[^/]+)\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cname\u003e[^/]+)\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cremark\u003e[^/]+)\");","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" private final Entry newEntry;","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public AddFileStringCommand(Entry entry) {","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" newEntry \u003d entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" EntryList.addEntry(newEntry);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"lctxct":26}},{"path":"src/main/java/seedu/wildwatch/command/ByeCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-22"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.ShutDown;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-22"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-22"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"public class ByeCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"bye\";","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(ByeCommand.class.getName());","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static void exitProgram() {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Initiating shutdown procedures.\");","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDown();","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" //TODO: figure out a way to get rid of this","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"woodenclock":14,"lctxct":8}},{"path":"src/main/java/seedu/wildwatch/command/Command.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" * Command class for manipulating EntryList","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public abstract class Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public Command() {}","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" public abstract void execute() throws InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":10,"lctxct":2}},{"path":"src/main/java/seedu/wildwatch/command/DeleteCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-13"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.DeleteCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-13"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" * Command class for deleting entry in EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"public class DeleteCommand extends Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"delete\";","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" private final int numberInput;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public DeleteCommand(int numberInput) {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" this.numberInput \u003d numberInput;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" /**","lastModifiedDate":"2023-10-13"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" * Deletes entry in the EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" */","lastModifiedDate":"2023-10-13"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" if (numberInput \u003c\u003d 0 || numberInput \u003e EntryList.getArraySize()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryNotFoundMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"tangzhenen"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(numberInput-1);","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryDeletionConfirmationPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" String confirmation \u003d scanner.nextLine().trim().toLowerCase();","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":" if (confirmation.equals(\"yes\")) {","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryRemovedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" EntryList.deleteEntry(numberInput);","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.entryCountPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":" } else {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryNotDeletedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":47,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":21,"tangzhenen":16,"lctxct":10}},{"path":"src/main/java/seedu/wildwatch/command/EditCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EditCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"public class EditCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" public static final String COMMAND_WORD \u003d \"edit\";","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":" public static final Pattern EDIT_ENTRY_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":" Pattern.compile(\"edit\"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":" + \" I/(?\u003cindex\u003e[^/]+)\"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"imaginarys96"},"content":" + \"( D/(?\u003cdate\u003e[^/]+))?\"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" + \"( S/(?\u003cspecies\u003e[^/]+))?\"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":" + \"( N/(?\u003cname\u003e[^/]+))?\"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" + \"(?: R/(?\u003cremark\u003e[^/]+))?\");","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" private String input;","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" public EditCommand(String input) {","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" this.input \u003d input;","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":" public Entry checkAndUpdateEntry(Entry entry, String date, String species, String name, String remark) {","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":" if( date !\u003d null \u0026\u0026 !date.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" date \u003d date.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"imaginarys96"},"content":" entry.setDate(date);","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" if( species !\u003d null \u0026\u0026 !species.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" species \u003d species.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" entry.setSpecies(species);","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" if( name !\u003d null \u0026\u0026 !name.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" name \u003d name.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" entry.setName(name);","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" if( remark !\u003d null \u0026\u0026 !remark.isEmpty() ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" remark \u003d remark.trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" entry.setRemark(remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":" return entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" final Matcher matcher \u003d EDIT_ENTRY_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"imaginarys96"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"imaginarys96"},"content":" final String indexStr \u003d matcher.group(\"index\").trim();","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"imaginarys96"},"content":" final String date \u003d matcher.group(\"date\");","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"imaginarys96"},"content":" final String species \u003d matcher.group(\"species\");","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"imaginarys96"},"content":" final String name \u003d matcher.group(\"name\");","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"imaginarys96"},"content":" final String remark \u003d matcher.group(\"remark\");","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"imaginarys96"},"content":" int index \u003d Integer.parseInt(indexStr);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" if( index \u003c\u003d 0 ) {","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.ENTRY_NOT_FOUND);","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"imaginarys96"},"content":" index -\u003d 1; // EntryList is 0 based.","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"imaginarys96"},"content":" //System.out.println(indexStr + \" \" + date + \" \" + species + \" \" + name + \" \" + remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"imaginarys96"},"content":" Entry currentEntry \u003d EntryList.getEntry(index);","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"imaginarys96"},"content":" Entry updatedEntry \u003d checkAndUpdateEntry(currentEntry, date, species, name, remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"imaginarys96"},"content":" EntryList.editEntry(index, updatedEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":" EditCommandPrinter.entryEditedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(index);","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"imaginarys96"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"imaginarys96":58,"woodenclock":15}},{"path":"src/main/java/seedu/wildwatch/command/ExportCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.storage.EntryToStringConverter;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.storage.FileCreater;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.io.File;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"import java.util.Collections;","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"/**","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" * Command class for exporting all current entries as a CSV file.","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"public class ExportCommand extends Command {","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"export\";","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" public static final Pattern EXPORT_COMMAND_FORMAT \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"export(?:\\\\s+(?\u003cfilename\u003e\\\\S+))?\\\\s*\");","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" public static final String DEFAULT_FILENAME \u003d \"WildWatch.csv\";","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" private static final String[] ALL_COLUMNS \u003d new String[] { \"date\", \"species\", \"name\", \"remark\" };","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" private final String filename;","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" * Constructs a new {@code ExportCommand}.","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" * @param file Name of file to set on {@code filename}.","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" public ExportCommand(String file) {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":" filename \u003d file;","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" * Constructs a new {@code ExportCommand}, with filename set","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" * to {@code DEFAULT_FILENAME}.","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" public ExportCommand() {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" this(DEFAULT_FILENAME);","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" if (EntryList.isArrayEmpty()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"No entries to write to csv.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" File file \u003d new File(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" if (file.exists()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" boolean canReplaceFile \u003d canReplaceFile(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" if (!canReplaceFile) {","lastModifiedDate":"2023-11-02"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Exiting export command...\");","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" return;","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":" createFile();","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":" ArrayList\u003cEntry\u003e entries \u003d EntryList.getArray();","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" ArrayList\u003cString\u003e columnsToInclude \u003d getColumnsToInclude();","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"lctxct"},"content":" if (columnsToInclude.isEmpty()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"You need to select at least one column to include in the csv.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"lctxct"},"content":" String header \u003d \"id\";","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"lctxct"},"content":" for (String column : columnsToInclude) {","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"lctxct"},"content":" header \u003d String.join(\",\", header, column);","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"lctxct"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"lctxct"},"content":" FileWriter writer \u003d new FileWriter(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"lctxct"},"content":" writer.write(header + \"\\n\");","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"lctxct"},"content":" for (int i \u003d 0; i \u003c EntryList.getArraySize(); i++) {","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"lctxct"},"content":" writer.write(EntryToStringConverter.toCSVString(entries.get(i), i+1, columnsToInclude));","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"lctxct"},"content":" writer.close();","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"Error writing to file.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"lctxct"},"content":" System.out.printf(\"%s has been written to!%n\", filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":" * Confirms with user if file can be replaced. Returns true if user","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":" * accepts, and false otherwise.","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"lctxct"},"content":" * @return True if user allows file to be replaced, else false.","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"lctxct"},"content":" private boolean canReplaceFile(String filename) {","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":" final String confirmationMessage \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"lctxct"},"content":" String.format(\"%s already exists. Would you like to replace it? (Y/N)\", filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"lctxct"},"content":" return doesUserApprove(scanner, confirmationMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"lctxct"},"content":" * Reads user input in a loop until \"Y\" or \"N\" received.","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":114,"author":{"gitId":"lctxct"},"content":" * @param scanner Scanner used to read user input","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"lctxct"},"content":" * @param confirmationMessage Message to prompt user for input","lastModifiedDate":"2023-11-02"},{"lineNumber":116,"author":{"gitId":"lctxct"},"content":" * @return true if user inputs \"Y\", false if user inputs \"N\"","lastModifiedDate":"2023-11-02"},{"lineNumber":117,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"lctxct"},"content":" private boolean doesUserApprove(Scanner scanner, String confirmationMessage) {","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"lctxct"},"content":" do {","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"lctxct"},"content":" System.out.print(confirmationMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"lctxct"},"content":" System.out.print(\": \");","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"lctxct"},"content":" String confirmation \u003d scanner.nextLine().trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":124,"author":{"gitId":"lctxct"},"content":" switch (confirmation) {","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"lctxct"},"content":" case \"Y\":","lastModifiedDate":"2023-11-02"},{"lineNumber":126,"author":{"gitId":"lctxct"},"content":" return true;","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"lctxct"},"content":" case \"N\":","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"lctxct"},"content":" return false;","lastModifiedDate":"2023-11-02"},{"lineNumber":129,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Unrecognized input!\"","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"lctxct"},"content":" + \" Please ensure that you only respond with Y or N.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"lctxct"},"content":" } while (true);","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"lctxct"},"content":" private void createFile() throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":137,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":138,"author":{"gitId":"lctxct"},"content":" System.out.println(\"File does not exist.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":139,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"lctxct"},"content":" try {","lastModifiedDate":"2023-11-02"},{"lineNumber":141,"author":{"gitId":"lctxct"},"content":" FileCreater.createFile(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":142,"author":{"gitId":"lctxct"},"content":" } catch (IOException e) {","lastModifiedDate":"2023-11-02"},{"lineNumber":143,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"Unable to create file.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":144,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":145,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":146,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":147,"author":{"gitId":"lctxct"},"content":" private ArrayList\u003cString\u003e getColumnsToInclude() {","lastModifiedDate":"2023-11-02"},{"lineNumber":148,"author":{"gitId":"lctxct"},"content":" ArrayList\u003cString\u003e columnsToInclude \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":150,"author":{"gitId":"lctxct"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-02"},{"lineNumber":151,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":152,"author":{"gitId":"lctxct"},"content":" String includeAllColumnsMessage \u003d \"Would you like to include all columns? (Y/N)\";","lastModifiedDate":"2023-11-02"},{"lineNumber":153,"author":{"gitId":"lctxct"},"content":" if (doesUserApprove(scanner, includeAllColumnsMessage)) {","lastModifiedDate":"2023-11-02"},{"lineNumber":154,"author":{"gitId":"lctxct"},"content":" Collections.addAll(columnsToInclude, ALL_COLUMNS);","lastModifiedDate":"2023-11-02"},{"lineNumber":155,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":156,"author":{"gitId":"lctxct"},"content":" return columnsToInclude;","lastModifiedDate":"2023-11-02"},{"lineNumber":157,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":158,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":159,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Please select the columns you would like to include in your csv:\");","lastModifiedDate":"2023-11-02"},{"lineNumber":160,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":161,"author":{"gitId":"lctxct"},"content":" for (String column : ALL_COLUMNS) {","lastModifiedDate":"2023-11-02"},{"lineNumber":162,"author":{"gitId":"lctxct"},"content":" String confirmationMessage \u003d String.format(\"Would you like to include %s in your csv? (Y/N)\", column);","lastModifiedDate":"2023-11-02"},{"lineNumber":163,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":164,"author":{"gitId":"lctxct"},"content":" boolean shouldIncludeColumn \u003d doesUserApprove(scanner, confirmationMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":165,"author":{"gitId":"lctxct"},"content":" if (shouldIncludeColumn) {","lastModifiedDate":"2023-11-02"},{"lineNumber":166,"author":{"gitId":"lctxct"},"content":" columnsToInclude.add(column);","lastModifiedDate":"2023-11-02"},{"lineNumber":167,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":168,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":169,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":170,"author":{"gitId":"lctxct"},"content":" return columnsToInclude;","lastModifiedDate":"2023-11-02"},{"lineNumber":171,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":172,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"lctxct":172}},{"path":"src/main/java/seedu/wildwatch/command/FindCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-25"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.SearchResultPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-25"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-25"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeParseException;","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * Handles the \"find\" command to search for tasks that contain a specific keyword.","lastModifiedDate":"2023-10-25"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"public class FindCommand extends Command {","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"find\";","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" private String input;","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public FindCommand(String input) {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" this.input \u003d input;","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-25"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" * Searches for tasks that contain the specified keyword and prints them.","lastModifiedDate":"2023-10-25"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-25"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" boolean hasMatch \u003d false;","lastModifiedDate":"2023-10-25"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" ArrayList\u003cEntry\u003e entries \u003d EntryList.getArray();","lastModifiedDate":"2023-10-25"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" ArrayList\u003cInteger\u003e matchingEntries \u003d new ArrayList\u003c\u003e();","lastModifiedDate":"2023-10-25"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" LocalDate inputDate \u003d null;","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-10-25"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" inputDate \u003d LocalDate.parse(input, DateTimeFormatter.ofPattern(\"dd-MM-yy\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" } catch (DateTimeParseException exception) {","lastModifiedDate":"2023-10-25"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" // matchingWord is not a date","lastModifiedDate":"2023-10-25"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" for (Entry entry: entries) {","lastModifiedDate":"2023-10-25"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" boolean isInputADate \u003d (inputDate !\u003d null \u0026\u0026 entry.getDate().equals(inputDate));","lastModifiedDate":"2023-10-25"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" if (entry.getSpecies().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" || entry.getSpecies().toLowerCase().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" || entry.getName().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" || entry.getName().toLowerCase().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" || entry.getRemark().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" || entry.getRemark().toLowerCase().contains(input)","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" || isInputADate) {","lastModifiedDate":"2023-10-25"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" hasMatch \u003d true;","lastModifiedDate":"2023-10-25"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" matchingEntries.add(entries.indexOf(entry));","lastModifiedDate":"2023-10-25"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" SearchResultPrinter.findEntryMessagePrinter(hasMatch, matchingEntries);","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"woodenclock":51,"lctxct":5}},{"path":"src/main/java/seedu/wildwatch/command/HelpCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-15"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class HelpCommand extends Command {","lastModifiedDate":"2023-10-16"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"help\";","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" * Requires UPDATE","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":" private static final String helpCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":" \"1. Get help - show the list of commands available for this app\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" \" Format: help\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" \" help\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":" private static final String addCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" \"2. To add a new wildlife\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":" \" Format: add D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" \" DATE should be in the format DD-MM-YY\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" \" add D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":26,"author":{"gitId":"imaginarys96"},"content":" private static final String listCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":" \"3. To list all wildlife,\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":" \" Format: list\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" \" list\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" private static final String deleteCommandMessage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" \"4. To delete a wildlife\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" \" Format: delete INDEX\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" \" The index refers to the index number shown in the displayed observation list.\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" \" Note:\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" \" - The index must be a positive integer:\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" \" - Deleted items may not be recoverable:\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" \" delete 1\\n\" +","lastModifiedDate":"2023-10-14"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" \"_________________________________________________________________\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-14"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":" private static final String editCommandMessage \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"imaginarys96"},"content":" \"5. To edit a wildlife\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"imaginarys96"},"content":" \" Format: edit I/INDEX D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"imaginarys96"},"content":" \" The index refers to the index number shown in the displayed observation list.\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":54,"author":{"gitId":"imaginarys96"},"content":" \" Note:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":55,"author":{"gitId":"imaginarys96"},"content":" \" - The index must be a positive integer:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":56,"author":{"gitId":"imaginarys96"},"content":" \" - DATE, SPECIES, NAME, REMARKS arguments are optional.\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"imaginarys96"},"content":" \" edit I/1 D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":59,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" private static final String summaryCommandMessage \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":62,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":63,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":64,"author":{"gitId":"imaginarys96"},"content":" \"6. To show a summary\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":65,"author":{"gitId":"imaginarys96"},"content":" \" Format: summary SPECIES\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":66,"author":{"gitId":"imaginarys96"},"content":" \" Note:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":67,"author":{"gitId":"imaginarys96"},"content":" \" - SPECIES argument is optional:\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":68,"author":{"gitId":"imaginarys96"},"content":" \" Examples: \\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":69,"author":{"gitId":"imaginarys96"},"content":" \" summary \\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":70,"author":{"gitId":"imaginarys96"},"content":" \" summary Annam Leaf Turtle\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":71,"author":{"gitId":"imaginarys96"},"content":" \"_________________________________________________________________\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":72,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":73,"author":{"gitId":"imaginarys96"},"content":" private static final String helpPage \u003d","lastModifiedDate":"2023-10-14"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-18"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":" \"---------------------------HELP PAGE-----------------------------\\n\"+","lastModifiedDate":"2023-10-18"},{"lineNumber":76,"author":{"gitId":"imaginarys96"},"content":" helpCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":77,"author":{"gitId":"imaginarys96"},"content":" addCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":78,"author":{"gitId":"imaginarys96"},"content":" listCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":79,"author":{"gitId":"imaginarys96"},"content":" deleteCommandMessage +","lastModifiedDate":"2023-10-14"},{"lineNumber":80,"author":{"gitId":"imaginarys96"},"content":" editCommandMessage +","lastModifiedDate":"2023-11-01"},{"lineNumber":81,"author":{"gitId":"imaginarys96"},"content":" summaryCommandMessage +","lastModifiedDate":"2023-11-01"},{"lineNumber":82,"author":{"gitId":"woodenclock"},"content":" \"\\n\" +","lastModifiedDate":"2023-10-11"},{"lineNumber":83,"author":{"gitId":"woodenclock"},"content":" \"-------------------------HELP PAGE END---------------------------\\n\";","lastModifiedDate":"2023-10-18"},{"lineNumber":84,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":85,"author":{"gitId":"imaginarys96"},"content":" private static final String helpPageShort \u003d","lastModifiedDate":"2023-11-01"},{"lineNumber":86,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":87,"author":{"gitId":"imaginarys96"},"content":" \"---------------------------HELP PAGE (short)-----------------------------\\n\"+","lastModifiedDate":"2023-11-01"},{"lineNumber":88,"author":{"gitId":"imaginarys96"},"content":" \"add: add D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":89,"author":{"gitId":"imaginarys96"},"content":" \"list: list\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":90,"author":{"gitId":"imaginarys96"},"content":" \"delete: delete INDEX\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":91,"author":{"gitId":"imaginarys96"},"content":" \"edit: edit I/INDEX D/DATE S/SPECIES N/NAME R/REMARKS\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":92,"author":{"gitId":"imaginarys96"},"content":" \"summary: summary SPECIES\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":93,"author":{"gitId":"imaginarys96"},"content":" \"\\n\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":94,"author":{"gitId":"imaginarys96"},"content":" \"-------------------------HELP PAGE (short) END---------------------------\\n\";","lastModifiedDate":"2023-11-01"},{"lineNumber":95,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":96,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":97,"author":{"gitId":"woodenclock"},"content":" private static final String needHelpPage \u003d","lastModifiedDate":"2023-10-22"},{"lineNumber":98,"author":{"gitId":"woodenclock"},"content":" \"Please type \\\"help\\\" if you need help.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":99,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":100,"author":{"gitId":"woodenclock"},"content":" private String input;","lastModifiedDate":"2023-11-03"},{"lineNumber":101,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":102,"author":{"gitId":"woodenclock"},"content":" public HelpCommand(String input) {","lastModifiedDate":"2023-11-03"},{"lineNumber":103,"author":{"gitId":"woodenclock"},"content":" this.input \u003d input;","lastModifiedDate":"2023-11-03"},{"lineNumber":104,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":105,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":106,"author":{"gitId":"woodenclock"},"content":" public static void printNeedHelpMessage() {","lastModifiedDate":"2023-10-22"},{"lineNumber":107,"author":{"gitId":"woodenclock"},"content":" System.out.println(needHelpPage);","lastModifiedDate":"2023-10-22"},{"lineNumber":108,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":109,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":110,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":111,"author":{"gitId":"imaginarys96"},"content":" * Print specific help message based on the command specified","lastModifiedDate":"2023-11-04"},{"lineNumber":112,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":113,"author":{"gitId":"imaginarys96"},"content":" * @return String helpPage","lastModifiedDate":"2023-11-04"},{"lineNumber":114,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":115,"author":{"gitId":"imaginarys96"},"content":" public static String getHelpPage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":116,"author":{"gitId":"imaginarys96"},"content":" return helpPage;","lastModifiedDate":"2023-11-01"},{"lineNumber":117,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":118,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":119,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":120,"author":{"gitId":"imaginarys96"},"content":" * Print specific help message based on the command specified","lastModifiedDate":"2023-11-04"},{"lineNumber":121,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":122,"author":{"gitId":"imaginarys96"},"content":" * @param command command","lastModifiedDate":"2023-11-04"},{"lineNumber":123,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":124,"author":{"gitId":"imaginarys96"},"content":" public void printMessageForCommand(String command) {","lastModifiedDate":"2023-11-01"},{"lineNumber":125,"author":{"gitId":"imaginarys96"},"content":" switch(command) {","lastModifiedDate":"2023-11-01"},{"lineNumber":126,"author":{"gitId":"imaginarys96"},"content":" case \"add\":","lastModifiedDate":"2023-11-01"},{"lineNumber":127,"author":{"gitId":"imaginarys96"},"content":" System.out.println(addCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":128,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":129,"author":{"gitId":"imaginarys96"},"content":" case \"list\":","lastModifiedDate":"2023-11-01"},{"lineNumber":130,"author":{"gitId":"imaginarys96"},"content":" System.out.println(listCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":131,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":132,"author":{"gitId":"imaginarys96"},"content":" case \"delete\":","lastModifiedDate":"2023-11-01"},{"lineNumber":133,"author":{"gitId":"imaginarys96"},"content":" System.out.println(deleteCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":134,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":135,"author":{"gitId":"imaginarys96"},"content":" case \"edit\":","lastModifiedDate":"2023-11-01"},{"lineNumber":136,"author":{"gitId":"imaginarys96"},"content":" System.out.println(editCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":137,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":138,"author":{"gitId":"imaginarys96"},"content":" case \"summary\":","lastModifiedDate":"2023-11-01"},{"lineNumber":139,"author":{"gitId":"imaginarys96"},"content":" System.out.println(summaryCommandMessage);","lastModifiedDate":"2023-11-01"},{"lineNumber":140,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":141,"author":{"gitId":"imaginarys96"},"content":" case \"full\":","lastModifiedDate":"2023-11-01"},{"lineNumber":142,"author":{"gitId":"imaginarys96"},"content":" System.out.println(helpPage);","lastModifiedDate":"2023-11-01"},{"lineNumber":143,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":144,"author":{"gitId":"imaginarys96"},"content":" default:","lastModifiedDate":"2023-11-01"},{"lineNumber":145,"author":{"gitId":"imaginarys96"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":146,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":147,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":148,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":149,"author":{"gitId":"woodenclock"},"content":" * Prints out help page","lastModifiedDate":"2023-10-11"},{"lineNumber":150,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":151,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":152,"author":{"gitId":"lctxct"},"content":" public void execute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"woodenclock"},"content":" if( input.isEmpty() ) {","lastModifiedDate":"2023-11-03"},{"lineNumber":154,"author":{"gitId":"lctxct"},"content":" System.out.println(\"No worries, I\u0027m here to help!\");","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"woodenclock"},"content":" System.out.println(helpPage);","lastModifiedDate":"2023-10-11"},{"lineNumber":156,"author":{"gitId":"imaginarys96"},"content":" return;","lastModifiedDate":"2023-11-01"},{"lineNumber":157,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":158,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":159,"author":{"gitId":"woodenclock"},"content":" String argument \u003d input.replace(\"help\", \"\").trim();","lastModifiedDate":"2023-11-03"},{"lineNumber":160,"author":{"gitId":"imaginarys96"},"content":" if( argument.isEmpty() ) {","lastModifiedDate":"2023-11-01"},{"lineNumber":161,"author":{"gitId":"imaginarys96"},"content":" // print short version","lastModifiedDate":"2023-11-01"},{"lineNumber":162,"author":{"gitId":"imaginarys96"},"content":" System.out.println(\"No worries, I\u0027m here to help!\");","lastModifiedDate":"2023-11-01"},{"lineNumber":163,"author":{"gitId":"imaginarys96"},"content":" System.out.println(helpPageShort);","lastModifiedDate":"2023-11-01"},{"lineNumber":164,"author":{"gitId":"imaginarys96"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":165,"author":{"gitId":"imaginarys96"},"content":" // e.g `help add`","lastModifiedDate":"2023-11-01"},{"lineNumber":166,"author":{"gitId":"imaginarys96"},"content":" System.out.println(\"No worries, I\u0027m here to help!\");","lastModifiedDate":"2023-11-01"},{"lineNumber":167,"author":{"gitId":"imaginarys96"},"content":" printMessageForCommand(argument);","lastModifiedDate":"2023-11-01"},{"lineNumber":168,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":169,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":170,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":171,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":173,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"imaginarys96":125,"woodenclock":43,"lctxct":5}},{"path":"src/main/java/seedu/wildwatch/command/ListCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EntryPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * Command class for listing all entries in EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"public class ListCommand extends Command {","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"list\";","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-11"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" * Lists out all entry in EntryList","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public static void listEntry() {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" int arraySize \u003d EntryList.getArraySize();","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" for (int i \u003d 0; i \u003c arraySize; i++) {","lastModifiedDate":"2023-10-11"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" System.out.print(i + 1 + \".\");","lastModifiedDate":"2023-10-11"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(i);","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.entryCountPrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" if (EntryList.isArrayEmpty()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_LIST);","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.listMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":28,"lctxct":10}},{"path":"src/main/java/seedu/wildwatch/command/SummaryCommand.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-28"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-28"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"import java.util.HashMap;","lastModifiedDate":"2023-10-28"},{"lineNumber":5,"author":{"gitId":"imaginarys96"},"content":"import java.util.List;","lastModifiedDate":"2023-10-28"},{"lineNumber":6,"author":{"gitId":"imaginarys96"},"content":"import java.util.Map;","lastModifiedDate":"2023-10-28"},{"lineNumber":7,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-28"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-28"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.SummaryCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"/**","lastModifiedDate":"2023-10-28"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" * Command class for `summary`","lastModifiedDate":"2023-10-28"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-10-28"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"public class SummaryCommand extends Command {","lastModifiedDate":"2023-10-28"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public static final String COMMAND_WORD \u003d \"summary\";","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" private String speciesName;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" public SummaryCommand(String speciesName) {","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":" this.speciesName \u003d speciesName;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":27,"author":{"gitId":"imaginarys96"},"content":" * Group the wildlife entries by their species","lastModifiedDate":"2023-11-04"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":29,"author":{"gitId":"imaginarys96"},"content":" * @param entries","lastModifiedDate":"2023-11-04"},{"lineNumber":30,"author":{"gitId":"imaginarys96"},"content":" * @return A map of the wildlife entries grouped by their species","lastModifiedDate":"2023-11-04"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" private static Map\u003cString, List\u003cEntry\u003e\u003e groupEntriesBySpecies(List\u003cEntry\u003e entries) {","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e map \u003d new HashMap\u003cString, List\u003cEntry\u003e\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" for (Entry entry : entries) {","lastModifiedDate":"2023-10-28"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" String key \u003d entry.getSpecies();","lastModifiedDate":"2023-10-28"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" if(map.containsKey(key)){","lastModifiedDate":"2023-10-28"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d map.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" }else{","lastModifiedDate":"2023-10-28"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d new ArrayList\u003cEntry\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" map.put(key, list);","lastModifiedDate":"2023-10-28"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":45,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":" return map;","lastModifiedDate":"2023-10-28"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":49,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":50,"author":{"gitId":"imaginarys96"},"content":" * Group a set of wildlife entries by their name","lastModifiedDate":"2023-11-04"},{"lineNumber":51,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":52,"author":{"gitId":"imaginarys96"},"content":" * @param filteredEntries","lastModifiedDate":"2023-11-04"},{"lineNumber":53,"author":{"gitId":"imaginarys96"},"content":" * @return A map of filteredEntries grouped by their name","lastModifiedDate":"2023-11-04"},{"lineNumber":54,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" private static Map\u003cString, List\u003cEntry\u003e\u003e groupSpecieByName(List\u003cEntry\u003e filteredEntries) {","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e filteredMap \u003d new HashMap\u003cString, List\u003cEntry\u003e\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":57,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":58,"author":{"gitId":"imaginarys96"},"content":" for (Entry entry : filteredEntries) {","lastModifiedDate":"2023-10-28"},{"lineNumber":59,"author":{"gitId":"imaginarys96"},"content":" String key \u003d entry.getName();","lastModifiedDate":"2023-10-28"},{"lineNumber":60,"author":{"gitId":"imaginarys96"},"content":" if(filteredMap.containsKey(key)){","lastModifiedDate":"2023-10-28"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d filteredMap.get(key);","lastModifiedDate":"2023-10-28"},{"lineNumber":62,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":63,"author":{"gitId":"imaginarys96"},"content":" }else{","lastModifiedDate":"2023-10-28"},{"lineNumber":64,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e list \u003d new ArrayList\u003cEntry\u003e();","lastModifiedDate":"2023-10-28"},{"lineNumber":65,"author":{"gitId":"imaginarys96"},"content":" list.add(entry);","lastModifiedDate":"2023-10-28"},{"lineNumber":66,"author":{"gitId":"imaginarys96"},"content":" filteredMap.put(key, list);","lastModifiedDate":"2023-10-28"},{"lineNumber":67,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":68,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":69,"author":{"gitId":"imaginarys96"},"content":" return filteredMap;","lastModifiedDate":"2023-10-28"},{"lineNumber":70,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":" public void execute() throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"imaginarys96"},"content":" boolean hasArgument \u003d !this.speciesName.isEmpty();","lastModifiedDate":"2023-11-04"},{"lineNumber":73,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-28"},{"lineNumber":74,"author":{"gitId":"imaginarys96"},"content":" ArrayList\u003cEntry\u003e entries \u003d EntryList.getArray();","lastModifiedDate":"2023-10-28"},{"lineNumber":75,"author":{"gitId":"imaginarys96"},"content":" // Group entries by .species attribute","lastModifiedDate":"2023-10-28"},{"lineNumber":76,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e map \u003d groupEntriesBySpecies(entries);","lastModifiedDate":"2023-10-28"},{"lineNumber":77,"author":{"gitId":"imaginarys96"},"content":" // change message based on whether `summary` or `summary \u003cspecies\u003e`","lastModifiedDate":"2023-10-28"},{"lineNumber":78,"author":{"gitId":"imaginarys96"},"content":" if( hasArgument ) {","lastModifiedDate":"2023-10-28"},{"lineNumber":79,"author":{"gitId":"woodenclock"},"content":" SummaryCommandPrinter.printSummaryNameMessage(speciesName);","lastModifiedDate":"2023-11-01"},{"lineNumber":80,"author":{"gitId":"imaginarys96"},"content":" List\u003cEntry\u003e filteredEntries \u003d map.get(speciesName);","lastModifiedDate":"2023-10-28"},{"lineNumber":81,"author":{"gitId":"imaginarys96"},"content":" Map\u003cString, List\u003cEntry\u003e\u003e filteredMap \u003d groupSpecieByName(filteredEntries);","lastModifiedDate":"2023-10-28"},{"lineNumber":82,"author":{"gitId":"imaginarys96"},"content":" filteredMap.forEach((key, value) -\u003e System.out.println(key + \" - (\" + value.size() + \")\"));","lastModifiedDate":"2023-10-28"},{"lineNumber":83,"author":{"gitId":"imaginarys96"},"content":" } else {","lastModifiedDate":"2023-10-28"},{"lineNumber":84,"author":{"gitId":"woodenclock"},"content":" SummaryCommandPrinter.printSummarySpecieMessage();","lastModifiedDate":"2023-11-01"},{"lineNumber":85,"author":{"gitId":"imaginarys96"},"content":" map.forEach((key, value) -\u003e System.out.println(key + \" - (\" + value.size() + \")\"));","lastModifiedDate":"2023-10-28"},{"lineNumber":86,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":87,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-28"},{"lineNumber":88,"author":{"gitId":"imaginarys96"},"content":"}","lastModifiedDate":"2023-10-28"}],"authorContributionMap":{"imaginarys96":75,"woodenclock":5,"lctxct":8}},{"path":"src/main/java/seedu/wildwatch/entry/Entry.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.entry;","lastModifiedDate":"2023-10-09"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-09"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class Entry {","lastModifiedDate":"2023-10-09"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" private LocalDate date;","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" private String species;","lastModifiedDate":"2023-10-09"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" private String name;","lastModifiedDate":"2023-10-15"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" private String remark;","lastModifiedDate":"2023-10-09"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public Entry(String date, String species, String name, String remark) {","lastModifiedDate":"2023-10-15"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" DateTimeFormatter inputFormat \u003d DateTimeFormatter.ofPattern(\"dd-MM-yy\");","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" this.date \u003d LocalDate.parse(date, inputFormat);","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" this.species \u003d species;","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-15"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" this.remark \u003d remark;","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public LocalDate getDate() {","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" return date;","lastModifiedDate":"2023-10-11"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" public String getSpecies() {","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" return species;","lastModifiedDate":"2023-10-11"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" public String getName() {","lastModifiedDate":"2023-10-15"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" return name;","lastModifiedDate":"2023-10-15"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-15"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-15"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" public String getRemark() {","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" return remark;","lastModifiedDate":"2023-10-11"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" public void setDate(String date) {","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" DateTimeFormatter inputFormat \u003d DateTimeFormatter.ofPattern(\"dd-MM-yy\");","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" this.date \u003d LocalDate.parse(date, inputFormat);","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"imaginarys96"},"content":" public void setSpecies(String species) {","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"imaginarys96"},"content":" this.species \u003d species;","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"imaginarys96"},"content":" public void setName(String name) {","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"imaginarys96"},"content":" this.name \u003d name;","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"imaginarys96"},"content":" public void setRemark(String remark) {","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"imaginarys96"},"content":" this.remark \u003d remark;","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" * Returns true if both entries have the same value for each field.","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" public boolean equals(Object other) {","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" if (other \u003d\u003d this) {","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" return true;","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" // instanceof handles nulls","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" if (!(other instanceof Entry)) {","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" return false;","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" Entry otherEntry \u003d (Entry) other;","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" return date.equals(otherEntry.date)","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":" \u0026\u0026 species.equals(otherEntry.species)","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" \u0026\u0026 name.equals(otherEntry.name)","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" \u0026\u0026 remark.equals(otherEntry.remark);","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"imaginarys96":13,"woodenclock":36,"lctxct":21}},{"path":"src/main/java/seedu/wildwatch/entry/EntryList.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.entry;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.time.LocalDate;","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.storage.Saver;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class EntryList {","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" private static ArrayList\u003cEntry\u003e entries \u003d new ArrayList\u003c\u003e(); //Keeps track of all Entry instances made","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static ArrayList\u003cEntry\u003e getArray() {","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" return entries;","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static int getArraySize() {","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" return entries.size();","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public static void addEntry(Entry newEntry) {","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" entries.add(newEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" public static void deleteEntry(int numberInput){","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" entries.remove(numberInput - 1);","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" public static void clearEntry(){","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" entries.clear();","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" public static Entry getEntry(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" return entries.get(nthEntry);","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":34,"author":{"gitId":"imaginarys96"},"content":" public static void editEntry(int nthEntry, Entry updatedEntry) {","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" entries.set(nthEntry, updatedEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" public static LocalDate getEntryDate(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getDate();","lastModifiedDate":"2023-10-22"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" public static String getEntrySpecies(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getSpecies();","lastModifiedDate":"2023-10-22"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" public static String getEntryName(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getName();","lastModifiedDate":"2023-10-22"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" public static String getEntryRemark(int nthEntry) {","lastModifiedDate":"2023-10-22"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" return getEntry(nthEntry).getRemark();","lastModifiedDate":"2023-10-22"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" public static boolean isArrayEmpty() {","lastModifiedDate":"2023-10-11"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" return entries.isEmpty();","lastModifiedDate":"2023-10-11"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":" public static void saveEntry() {","lastModifiedDate":"2023-10-22"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":" Saver.saver(entries);","lastModifiedDate":"2023-11-01"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"imaginarys96":4,"woodenclock":52,"tangzhenen":3,"lctxct":2}},{"path":"src/main/java/seedu/wildwatch/error/DateChecker.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class DateChecker {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" private static final Pattern DATE_PATTERN \u003d Pattern.compile(","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" \"(0[1-9]|[1-2][0-9]|3[0-1])-(0[1-9]|1[0-2])-\\\\d{2}\" // dd-mm-yy","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" );","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" public static boolean isDateValid(String date) {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" date \u003d date.trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" if (DATE_PATTERN.matcher(date).matches()) {","lastModifiedDate":"2023-10-16"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" return true;","lastModifiedDate":"2023-10-11"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" return false;","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":16,"lctxct":1}},{"path":"src/main/java/seedu/wildwatch/error/ErrorHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.HelpCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ErrorPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ListCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.DeleteCommandPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.EmptyDescriptionPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"public class ErrorHandler {","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(ErrorHandler.class.getName());","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void handleInputError(InvalidInputException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" boolean validInput \u003d false;","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" switch (exception.getError()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" case CUSTOM:","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Command is invalid.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.customInvalidInputMessagePrinter(exception.getCustomMessage());","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" case EMPTY_INPUT:","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Received an empty input.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" EmptyDescriptionPrinter.emptyDescriptionMessagePrinter(null);","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" case EMPTY_EDIT_INPUT:","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Received an empty edit input.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" EmptyDescriptionPrinter.emptyDescriptionMessagePrinter(EditCommand.COMMAND_WORD);","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" case EMPTY_FIND_INPUT:","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Received an empty find input.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" EmptyDescriptionPrinter.emptyDescriptionMessagePrinter(FindCommand.COMMAND_WORD);","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" case EMPTY_LIST:","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" LOGGER.info(\"List is empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" ListCommandPrinter.emptyListMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":" validInput \u003d true;","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" case ENTRY_NOT_FOUND:","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Queried entry not found.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" DeleteCommandPrinter.entryNotFoundMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" validInput \u003d true;","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" case INVALID_DATE:","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Date is invalid.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidDateMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" case INVALID_INDEX:","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Index is invalid.\");","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidIndexMessagePrinter();","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" break;","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" case INVALID_INPUT:","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" LOGGER.warning(\"Command is invalid.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidInputMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.invalidInputMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" if (!validInput) {","lastModifiedDate":"2023-10-30"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" HelpCommand.printNeedHelpMessage();","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":32,"lctxct":34}},{"path":"src/main/java/seedu/wildwatch/error/InvalidInputErrorType.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public enum InvalidInputErrorType {","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" CUSTOM,","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":" EMPTY_INPUT,","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" EMPTY_EDIT_INPUT,","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":" EMPTY_FIND_INPUT,","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":" EMPTY_LIST,","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":" ENTRY_NOT_FOUND,","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" INVALID_DATE,","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" INVALID_INDEX,","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" INVALID_INPUT","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":6,"lctxct":7}},{"path":"src/main/java/seedu/wildwatch/error/Router.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.error;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.SummaryCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.ListCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.ByeCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.DeleteCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.ExportCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.HelpCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.SummaryCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.AddCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.DeleteCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.EditCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.ExportCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.parser.FindCommandParser;","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" * Identifies the input command and sends it to the corresponding parser.","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"public class Router {","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(Router.class.getName());","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" public static Command route (String input) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Managing entry for input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" Scanner bufferScanner \u003d new Scanner(input); //Scanner for the buffer","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" if (!bufferScanner.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_INPUT);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" String firstWord \u003d bufferScanner.next(); //Stores first word in the input","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" //Functionalities","lastModifiedDate":"2023-10-11"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" switch (firstWord) {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" case AddCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Add command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" return new AddCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" case DeleteCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Delete command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" return new DeleteCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" case EditCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Edit command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" return new EditCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" case FindCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Find command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" return new FindCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" case ListCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"List command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" return new ListCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" case SummaryCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Summary command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"imaginarys96"},"content":" return new SummaryCommandParser().parse(input);","lastModifiedDate":"2023-11-04"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":" case ExportCommand.COMMAND_WORD:","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Export command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":" return new ExportCommandParser().parse(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" case HelpCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Help command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":" return new HelpCommand(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" case ByeCommand.COMMAND_WORD:","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Exit command was input: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":" return new ByeCommand();","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-10-30"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.WARNING, \"Invalid input received: {0}. Throwing exception.\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":76,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"imaginarys96":17,"woodenclock":44,"lctxct":15}},{"path":"src/main/java/seedu/wildwatch/exception/InvalidInputException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.exception;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class InvalidInputException extends Exception {","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" private InvalidInputErrorType errorType;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" private String customMessage;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":" public InvalidInputException(InvalidInputErrorType error, String message) {","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":" errorType \u003d error;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":" customMessage \u003d message;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public InvalidInputException(InvalidInputErrorType error) {","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" this(error, \"Command is invalid.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" public InvalidInputException(String message) {","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" this(InvalidInputErrorType.INVALID_INPUT, message);","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" public InvalidInputErrorType getError() {","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" return errorType;","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" public String getCustomMessage() {","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" return customMessage;","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":21,"lctxct":8}},{"path":"src/main/java/seedu/wildwatch/exception/UnknownDateFormatException.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.exception;","lastModifiedDate":"2023-10-11"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class UnknownDateFormatException extends Exception {","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":4}},{"path":"src/main/java/seedu/wildwatch/execute/CommandHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.ByeCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.Router;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.ErrorHandler;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"public class CommandHandler {","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static boolean processCommand(String input) {","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" Command command \u003d Router.route(input); //Checks if the input command is valid","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" if (command instanceof ByeCommand) {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" executeCommand(command);","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" } catch (InvalidInputException exception) {","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" ErrorHandler.handleInputError(exception);","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" return true;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" public static void executeCommand(Command command) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" command.execute();","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":26}},{"path":"src/main/java/seedu/wildwatch/execute/InputHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Level;","lastModifiedDate":"2023-10-25"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-25"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.ByeCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.InputConsole;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.Ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"public class InputHandler {","lastModifiedDate":"2023-10-25"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(InputHandler.class.getName());","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-25"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" * Runs the WildWatch by looping through the I/O process.","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" * If \"bye\" is received,","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" public static void handleInput() {","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" boolean loopFlag \u003d true;","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" while (loopFlag) {","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" Ui.inputPromptPrinter();","lastModifiedDate":"2023-10-28"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" String input \u003d InputConsole.inputRetriever(); //Retrieves input of user","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" if (!input.equals(\"bye\")) {","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" LOGGER.log(Level.INFO, \"Input received: {0}\", input);","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" loopFlag \u003d CommandHandler.processCommand(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" EntryList.saveEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" ByeCommand.exitProgram();","lastModifiedDate":"2023-10-25"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-25"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-25"}],"authorContributionMap":{"woodenclock":31,"lctxct":3}},{"path":"src/main/java/seedu/wildwatch/miscellaneous/BootUp.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.miscellaneous;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"public class BootUp {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" public static final String WELCOME_MESSAGE_1 \u003d","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" \"Hello there! Welcome to WildWatch!\\n\";","lastModifiedDate":"2023-10-09"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static final String WELCOME_MESSAGE_2 \u003d","lastModifiedDate":"2023-10-11"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" \"What would you like to do?\\n\";","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static final String LOGO \u003d","lastModifiedDate":"2023-10-09"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" \"____ __ ____ __ __ _______\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" \"\\\\ \\\\ / \\\\ / / | | | | | \\\\\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" \" \\\\ \\\\/ \\\\/ / | | | | | .--. |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" \" \\\\ / | | | | | | | |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" \" \\\\ /\\\\ / | | | `----.| \u0027--\u0027 |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" \" \\\\__/ \\\\__/ |__| |_______||_______/\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" \"____ __ ____ ___ .___________. ______ __ __\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" \"\\\\ \\\\ / \\\\ / / / \\\\ | | / || | | |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" \" \\\\ \\\\/ \\\\/ / / ^ \\\\ `---| |----`| ,----\u0027| |__| |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" \" \\\\ / / /_\\\\ \\\\ | | | | | __ |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" \" \\\\ /\\\\ / / _____ \\\\ | | | `----.| | | |\\n\" +","lastModifiedDate":"2023-10-09"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" \" \\\\__/ \\\\__/ /__/ \\\\__\\\\ |__| \\\\______||__| |__|\\n\";","lastModifiedDate":"2023-10-11"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" public static void bootUpOne() {","lastModifiedDate":"2023-10-22"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" System.out.print(BootUp.LOGO);","lastModifiedDate":"2023-10-22"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" System.out.print(BootUp.WELCOME_MESSAGE_1);","lastModifiedDate":"2023-10-22"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" public static void bootUpTwo() {","lastModifiedDate":"2023-10-22"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" System.out.print(BootUp.WELCOME_MESSAGE_2);","lastModifiedDate":"2023-10-22"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-09"}],"authorContributionMap":{"woodenclock":38}},{"path":"src/main/java/seedu/wildwatch/miscellaneous/LogHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.miscellaneous;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ErrorPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Logger;","lastModifiedDate":"2023-10-16"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.Handler;","lastModifiedDate":"2023-10-16"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.FileHandler;","lastModifiedDate":"2023-10-16"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import java.util.logging.SimpleFormatter;","lastModifiedDate":"2023-10-16"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"public class LogHandler {","lastModifiedDate":"2023-10-16"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" private static final Logger LOGGER \u003d Logger.getLogger(LogHandler.class.getName());","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" static {","lastModifiedDate":"2023-10-16"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-10-16"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" // Configure a FileHandler","lastModifiedDate":"2023-10-16"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" FileHandler file \u003d new FileHandler(\"WildWatch.log\", true);","lastModifiedDate":"2023-10-16"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" SimpleFormatter formatter \u003d new SimpleFormatter();","lastModifiedDate":"2023-10-16"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" file.setFormatter(formatter);","lastModifiedDate":"2023-10-16"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" // Obtain the root logger. An empty string gets the root logger","lastModifiedDate":"2023-10-16"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" Logger rootLogger \u003d Logger.getLogger(\"\");","lastModifiedDate":"2023-10-16"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" // Remove the default handlers (like ConsoleHandler)","lastModifiedDate":"2023-10-16"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" for (Handler handler : rootLogger.getHandlers()) {","lastModifiedDate":"2023-10-16"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" rootLogger.removeHandler(handler);","lastModifiedDate":"2023-10-16"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" // Add the FileHandler to the root logger","lastModifiedDate":"2023-10-16"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" rootLogger.addHandler(file);","lastModifiedDate":"2023-10-16"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" } catch (Exception exception) {","lastModifiedDate":"2023-10-16"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" LOGGER.warning(\"Queried entry not found.\");","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.corruptLoggerMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDownWithError();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" System.exit(0);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-16"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" public static void configure() { // Call this empty method to ensure the static block runs","lastModifiedDate":"2023-10-16"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-16"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-16"}],"authorContributionMap":{"woodenclock":40}},{"path":"src/main/java/seedu/wildwatch/miscellaneous/ShutDown.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.miscellaneous;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"public class ShutDown {","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" public static void shutDown() {","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" //Program Ending","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Bye. Hope to see you again soon!\");","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-11"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void shutDownWithError() {","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" //Program Ending","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Ending program due to error...\");","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":18}},{"path":"src/main/java/seedu/wildwatch/parser/AddCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"public class AddCommandParser implements Parser\u003cAddCommand\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" private static final String[] ENTRY_ITEMS \u003d new String[] { \"date\", \"species\", \"name\", \"remark\" };","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" private static final Pattern ADD_DEFAULT_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"add\"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?\u003cdprefix\u003e D/)?\\\\s*(?\u003cdate\u003e[^/]+)?\"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?\u003csprefix\u003e S/)?\\\\s*(?\u003cspecies\u003e[^/]+)?\"","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?\u003cnprefix\u003e N/)?\\\\s*(?\u003cname\u003e[^/]+)?\"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" + \"\\\\s*(?: R/(?\u003cremark\u003e[^/]+))?\");","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" private String date;","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" private String species;","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" private String name;","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" private String remark \u003d null;","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" public AddCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" final Matcher matcherInteractive \u003d AddCommand.ADD_INTERACTIVE_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" if (matcherInteractive.matches()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" handleInteractive();","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" } else {","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" // Default case","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" performChecks(input);","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" final Matcher matcherDefault \u003d AddCommand.ADD_DEFAULT_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" boolean isMatch \u003d matcherDefault.matches();","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" assert isMatch : \"Command should match format.\";","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" date \u003d matcherDefault.group(\"date\").trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" species \u003d matcherDefault.group(\"species\").trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" name \u003d matcherDefault.group(\"name\").trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" remark \u003d matcherDefault.group(\"remark\");","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" if (remark \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" remark \u003d \"\";","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" } else {","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" remark \u003d remark.trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" Entry newEntry \u003d new Entry(date, species, name, remark);","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" return new AddCommand(newEntry);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" * Handle interactive add command, which prompts user for each item required","lastModifiedDate":"2023-11-02"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" * in an entry.","lastModifiedDate":"2023-11-02"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" private void handleInteractive() throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" Scanner scanner \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-02"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":" String input;","lastModifiedDate":"2023-11-02"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" for (String item : ENTRY_ITEMS) {","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"lctxct"},"content":" String promptMessage \u003d String.format(\"Please input the %s you would like to set, or q/ to quit.\", item);","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"lctxct"},"content":" if (item.equals(\"remark\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"lctxct"},"content":" promptMessage +\u003d \"\\n(Hit Enter to leave this field blank)\";","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":76,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":77,"author":{"gitId":"lctxct"},"content":" input \u003d getItem(scanner, promptMessage, item);","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"lctxct"},"content":" switch (item) {","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"lctxct"},"content":" case \"date\":","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"lctxct"},"content":" date \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":82,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":83,"author":{"gitId":"lctxct"},"content":" case \"species\":","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"lctxct"},"content":" species \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"lctxct"},"content":" case \"name\":","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":" name \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":88,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":" case \"remark\":","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"lctxct"},"content":" remark \u003d input;","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"lctxct"},"content":" break;","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"lctxct"},"content":" default:","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":94,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":" private String getItem(Scanner scanner, String promptMessage, String item) throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":" String inputBuffer;","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":" boolean isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":100,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":" do {","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"lctxct"},"content":" System.out.print(promptMessage);","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":" System.out.println(\": \");","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":106,"author":{"gitId":"lctxct"},"content":" inputBuffer \u003d scanner.nextLine().trim();","lastModifiedDate":"2023-11-02"},{"lineNumber":107,"author":{"gitId":"lctxct"},"content":" isValid \u003d true;","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"lctxct"},"content":" // check if user q/uits early","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"lctxct"},"content":" if (inputBuffer.equals(\"q/\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(\"Exited add command\");","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":113,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":114,"author":{"gitId":"lctxct"},"content":" // check that fields are not empty","lastModifiedDate":"2023-11-02"},{"lineNumber":115,"author":{"gitId":"lctxct"},"content":" if (!item.equals(\"remark\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":116,"author":{"gitId":"lctxct"},"content":" if (inputBuffer.isEmpty()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":117,"author":{"gitId":"lctxct"},"content":" isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":118,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Field cannot be left blank.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":119,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":120,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":121,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":122,"author":{"gitId":"lctxct"},"content":" // if date, check validity of date","lastModifiedDate":"2023-11-02"},{"lineNumber":123,"author":{"gitId":"lctxct"},"content":" if (item.equals(\"date\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":124,"author":{"gitId":"lctxct"},"content":" if (!DateChecker.isDateValid(inputBuffer)) {","lastModifiedDate":"2023-11-02"},{"lineNumber":125,"author":{"gitId":"lctxct"},"content":" isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":126,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Please key in a valid date.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":127,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":128,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":129,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":130,"author":{"gitId":"lctxct"},"content":" // check that no /","lastModifiedDate":"2023-11-02"},{"lineNumber":131,"author":{"gitId":"lctxct"},"content":" if (inputBuffer.contains(\"/\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":132,"author":{"gitId":"lctxct"},"content":" isValid \u003d false;","lastModifiedDate":"2023-11-02"},{"lineNumber":133,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Your input should not contain /.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":134,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":135,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":136,"author":{"gitId":"lctxct"},"content":" } while (!isValid);","lastModifiedDate":"2023-11-02"},{"lineNumber":137,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":138,"author":{"gitId":"lctxct"},"content":" return inputBuffer;","lastModifiedDate":"2023-11-02"},{"lineNumber":139,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":140,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":141,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":142,"author":{"gitId":"lctxct"},"content":" * Ensures that {@code input} adheres to the command format.","lastModifiedDate":"2023-10-29"},{"lineNumber":143,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":144,"author":{"gitId":"lctxct"},"content":" * @param input","lastModifiedDate":"2023-10-29"},{"lineNumber":145,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown if the input does not adhere to command format.","lastModifiedDate":"2023-10-30"},{"lineNumber":146,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":147,"author":{"gitId":"woodenclock"},"content":" private void performChecks(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":148,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d ADD_DEFAULT_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":149,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-29"},{"lineNumber":150,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":151,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":152,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":153,"author":{"gitId":"lctxct"},"content":" checkDate(matcher);","lastModifiedDate":"2023-10-29"},{"lineNumber":154,"author":{"gitId":"lctxct"},"content":" checkSpecies(matcher);","lastModifiedDate":"2023-10-29"},{"lineNumber":155,"author":{"gitId":"lctxct"},"content":" checkName(matcher);","lastModifiedDate":"2023-10-29"},{"lineNumber":156,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":157,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":158,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":159,"author":{"gitId":"lctxct"},"content":" * Checks that date is correctly defined in input. Checks the following:","lastModifiedDate":"2023-10-29"},{"lineNumber":160,"author":{"gitId":"lctxct"},"content":" * 1. D/ is present in user input","lastModifiedDate":"2023-10-29"},{"lineNumber":161,"author":{"gitId":"lctxct"},"content":" * 2. A date value is defined","lastModifiedDate":"2023-10-29"},{"lineNumber":162,"author":{"gitId":"lctxct"},"content":" * 3. Date provided is correctly formatted","lastModifiedDate":"2023-10-29"},{"lineNumber":163,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":164,"author":{"gitId":"lctxct"},"content":" * @param matcher Input matched against command pattern","lastModifiedDate":"2023-10-29"},{"lineNumber":165,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when date is not correctly defined","lastModifiedDate":"2023-10-30"},{"lineNumber":166,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":167,"author":{"gitId":"woodenclock"},"content":" private void checkDate(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":168,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"dprefix\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":169,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"D/ is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":170,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":171,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"date\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":172,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"Date value cannot be empty.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":173,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":174,"author":{"gitId":"lctxct"},"content":" String date \u003d matcher.group(\"date\").trim();","lastModifiedDate":"2023-10-30"},{"lineNumber":175,"author":{"gitId":"woodenclock"},"content":" if (!DateChecker.isDateValid(date)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":176,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_DATE);","lastModifiedDate":"2023-10-30"},{"lineNumber":177,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":178,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":179,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":180,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":181,"author":{"gitId":"lctxct"},"content":" * Checks that species is correctly defined in input. Checks the following:","lastModifiedDate":"2023-10-29"},{"lineNumber":182,"author":{"gitId":"lctxct"},"content":" * 1. S/ is present in user input","lastModifiedDate":"2023-10-29"},{"lineNumber":183,"author":{"gitId":"lctxct"},"content":" * 2. Species is defined","lastModifiedDate":"2023-10-29"},{"lineNumber":184,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":185,"author":{"gitId":"lctxct"},"content":" * @param matcher Input matched against command pattern","lastModifiedDate":"2023-10-29"},{"lineNumber":186,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when species is not correctly defined","lastModifiedDate":"2023-10-30"},{"lineNumber":187,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":188,"author":{"gitId":"woodenclock"},"content":" private void checkSpecies(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":189,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"sprefix\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":190,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"S/ is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":191,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":192,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"species\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":193,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"Species is not defined.\");","lastModifiedDate":"2023-10-30"},{"lineNumber":194,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":195,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":196,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":197,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-29"},{"lineNumber":198,"author":{"gitId":"lctxct"},"content":" * Checks that name is correctly defined in input. Checks the following:","lastModifiedDate":"2023-10-29"},{"lineNumber":199,"author":{"gitId":"lctxct"},"content":" * 1. N/ is present in user input","lastModifiedDate":"2023-10-29"},{"lineNumber":200,"author":{"gitId":"lctxct"},"content":" * 2. Name is defined","lastModifiedDate":"2023-10-29"},{"lineNumber":201,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-29"},{"lineNumber":202,"author":{"gitId":"lctxct"},"content":" * @param matcher Input matched against command pattern","lastModifiedDate":"2023-10-29"},{"lineNumber":203,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when species is not correctly defined","lastModifiedDate":"2023-10-30"},{"lineNumber":204,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-29"},{"lineNumber":205,"author":{"gitId":"woodenclock"},"content":" private void checkName(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":206,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"nprefix\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":207,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"N/ is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":208,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":209,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"name\") \u003d\u003d null) {","lastModifiedDate":"2023-10-29"},{"lineNumber":210,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(\"Name is not defined\");","lastModifiedDate":"2023-10-30"},{"lineNumber":211,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":212,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":213,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":21,"lctxct":192}},{"path":"src/main/java/seedu/wildwatch/parser/DeleteCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.DeleteCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"public class DeleteCommandParser implements Parser\u003cDeleteCommand\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" private static final Pattern DELETE_ENTRY_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" Pattern.compile(\"delete\\\\s+(?\u003cindex\u003e\\\\S+)\\\\s*\");","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" public DeleteCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" int getIdx \u003d getIndexFromInput(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" return new DeleteCommand(getIdx);","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" * Gets index of entry to delete from input.","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" * Checks that input adheres to required delete command format.","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" * 1. Checks that it is in the form {@code delete\u003cwhitespace(s)\u003eINDEX}","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" * 2. Checks that INDEX \u003e 1 and INDEX \u003c\u003d length of entry list","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" * @param input","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" * @return index of entry to delete","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown when command format is incorrect.","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" private int getIndexFromInput(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d DELETE_ENTRY_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" // Check that index is a valid number","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" int deleteIdx \u003d -1;","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" try {","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" deleteIdx \u003d Integer.parseInt(matcher.group(\"index\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" } catch (NumberFormatException e) {","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INDEX);","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" // Check that index is within bounds","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" if (deleteIdx \u003c 1 || deleteIdx \u003e EntryList.getArraySize()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.ENTRY_NOT_FOUND);","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" return deleteIdx;","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":8,"lctxct":48}},{"path":"src/main/java/seedu/wildwatch/parser/EditCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-03"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-11-03"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-03"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-03"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-03"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"public class EditCommandParser {","lastModifiedDate":"2023-11-03"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" private static final Pattern EDIT_ENTRY_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-11-03"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" Pattern.compile(\"edit\"","lastModifiedDate":"2023-11-03"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003ciprefix\u003e I/)?\\\\s*(?\u003cindex\u003e[^/]+)\"","lastModifiedDate":"2023-11-03"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003cdprefix\u003e D/)?\\\\s*(?\u003cdate\u003e[^/]+)?\"","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003csprefix\u003e S/)?\\\\s*(?\u003cspecies\u003e[^/]+)?\"","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?\u003cnprefix\u003e N/)?\\\\s*(?\u003cname\u003e[^/]+)?\"","lastModifiedDate":"2023-11-03"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" + \"\\\\s*(?: R/(?\u003cremark\u003e[^/]+))?\");","lastModifiedDate":"2023-11-03"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public Command parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" performChecks(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" final Matcher matcher \u003d EditCommand.EDIT_ENTRY_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" boolean isMatch \u003d matcher.matches();","lastModifiedDate":"2023-11-03"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" assert isMatch : \"Command should match format.\";","lastModifiedDate":"2023-11-03"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" return new EditCommand(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-03"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" * Ensures that {@code input} adheres to the command format.","lastModifiedDate":"2023-11-03"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" * @param input","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" * @throws InvalidInputException thrown if the input does not adhere to command format.","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" private void performChecks(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" final Matcher matcher \u003d EDIT_ENTRY_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-11-03"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" //Checks if the input adheres to the command format","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" checkIndex(matcher);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" if (!(matcher.group(\"date\") \u003d\u003d null)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" checkDate(matcher);","lastModifiedDate":"2023-11-03"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" //Checks if there is any change to edit","lastModifiedDate":"2023-11-03"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" if ((matcher.group(\"date\") \u003d\u003d null) \u0026\u0026 (matcher.group(\"species\") \u003d\u003d null) \u0026\u0026","lastModifiedDate":"2023-11-03"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" (matcher.group(\"name\") \u003d\u003d null) \u0026\u0026 (matcher.group(\"remark\") \u003d\u003d null)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_EDIT_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" private void checkIndex(Matcher matcher) throws InvalidInputException{","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"woodenclock"},"content":" int editIdx \u003d -1;","lastModifiedDate":"2023-11-03"},{"lineNumber":59,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-03"},{"lineNumber":60,"author":{"gitId":"woodenclock"},"content":" editIdx \u003d Integer.parseInt(matcher.group(\"index\"));","lastModifiedDate":"2023-11-03"},{"lineNumber":61,"author":{"gitId":"woodenclock"},"content":" } catch (NumberFormatException exception) {","lastModifiedDate":"2023-11-03"},{"lineNumber":62,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INDEX);","lastModifiedDate":"2023-11-03"},{"lineNumber":63,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":64,"author":{"gitId":"woodenclock"},"content":" if ((matcher.group(\"index\") \u003d\u003d null) || editIdx \u003c 1 || editIdx \u003e EntryList.getArraySize()) {","lastModifiedDate":"2023-11-03"},{"lineNumber":65,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.ENTRY_NOT_FOUND);","lastModifiedDate":"2023-11-03"},{"lineNumber":66,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":67,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":68,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":69,"author":{"gitId":"woodenclock"},"content":" private void checkDate(Matcher matcher) throws InvalidInputException {","lastModifiedDate":"2023-11-03"},{"lineNumber":70,"author":{"gitId":"woodenclock"},"content":" String dateValue \u003d matcher.group(\"date\");","lastModifiedDate":"2023-11-03"},{"lineNumber":71,"author":{"gitId":"woodenclock"},"content":" if (!DateChecker.isDateValid(dateValue)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":72,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_DATE);","lastModifiedDate":"2023-11-03"},{"lineNumber":73,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":74,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":75,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-03"}],"authorContributionMap":{"woodenclock":75}},{"path":"src/main/java/seedu/wildwatch/parser/ExportCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-02"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.ExportCommand;","lastModifiedDate":"2023-11-02"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-02"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-02"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-11-02"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"/**","lastModifiedDate":"2023-11-02"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":" * Parses export command. Accepts optional {@code filename} argument","lastModifiedDate":"2023-11-02"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":" * proceeding {@code export} keyword.","lastModifiedDate":"2023-11-02"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"public class ExportCommandParser implements Parser\u003cExportCommand\u003e {","lastModifiedDate":"2023-11-02"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" private static final Pattern FILENAME_FORMAT \u003d Pattern.compile(\"\\\\w+.csv\");","lastModifiedDate":"2023-11-02"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" public ExportCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d ExportCommand.EXPORT_COMMAND_FORMAT.matcher(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-11-02"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" String filename \u003d matcher.group(\"filename\");","lastModifiedDate":"2023-11-02"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" if (filename \u003d\u003d null) {","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" return new ExportCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" if (checkFilenameValid(filename)) {","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" return new ExportCommand(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" System.out.println(\"Filename is invalid. Using default filename...\");","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" return new ExportCommand();","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" /**","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" * Checks if filename is in the format {@code [a-zA-Z0-9_].csv}.","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" *","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" * @param filename Input to test","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" * @return true if filename is valid, else false","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" */","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" private boolean checkFilenameValid(String filename) {","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d FILENAME_FORMAT.matcher(filename);","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" return matcher.matches();","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-11-02"}],"authorContributionMap":{"lctxct":52}},{"path":"src/main/java/seedu/wildwatch/parser/FileStringParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"//@@lctxct","lastModifiedDate":"2023-11-02"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.AddFileStringCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-03"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Pattern;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"import java.util.regex.Matcher;","lastModifiedDate":"2023-10-30"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"public class FileStringParser implements Parser\u003cAddFileStringCommand\u003e {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":" private static final Pattern ADD_FILE_ENTRY_COMMAND_FORMAT_CHECK \u003d","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" Pattern.compile(","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" \"\\\\s*(?\u003cdate\u003e[^/]+)?\\\\s*/\" +","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cspecies\u003e[^/]+)?\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cname\u003e[^/]+)?\\\\s*/\" +","lastModifiedDate":"2023-10-30"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" \"\\\\s*(?\u003cremark\u003e[^/]+)?\");","lastModifiedDate":"2023-10-30"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" @Override","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" public AddFileStringCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" performChecks(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d AddFileStringCommand.FILE_STRING_FORMAT.matcher(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" boolean isMatch \u003d matcher.matches();","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" assert isMatch : \"Input line should match format.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" final String date \u003d matcher.group(\"date\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" final String species \u003d matcher.group(\"species\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" final String name \u003d matcher.group(\"name\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" final String remark \u003d matcher.group(\"remark\").trim();","lastModifiedDate":"2023-10-31"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" Entry newEntry \u003d new Entry(date, species, name, remark);","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" return new AddFileStringCommand(newEntry);","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" private void performChecks(String input) throws InvalidInputException {","lastModifiedDate":"2023-10-30"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":" final Matcher matcher \u003d ADD_FILE_ENTRY_COMMAND_FORMAT_CHECK.matcher(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" if (!matcher.matches()) {","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" // Check that all groups present","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" if (matcher.group(\"date\") \u003d\u003d null ||","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" matcher.group(\"species\") \u003d\u003d null ||","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" matcher.group(\"name\") \u003d\u003d null) {","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" // Check that date is valid","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":" if (!DateChecker.isDateValid(matcher.group(\"date\"))) {","lastModifiedDate":"2023-11-01"},{"lineNumber":57,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-03"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":15,"lctxct":45}},{"path":"src/main/java/seedu/wildwatch/parser/FindCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class FindCommandParser implements Parser\u003cFindCommand\u003e{","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" public static final String COMMAND_WORD \u003d \"find\";","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" private static final int NUMBER_OF_ALPHABETS_IN_FIND \u003d 4;","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" @Override","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" public FindCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" String matchingWord \u003d input.substring(input.indexOf(COMMAND_WORD)","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" + NUMBER_OF_ALPHABETS_IN_FIND).trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" if (matchingWord \u003d\u003d null || matchingWord.isEmpty()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" throw new InvalidInputException(InvalidInputErrorType.EMPTY_FIND_INPUT);","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" return new FindCommand(matchingWord); //Note the \"find\" is removed here","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":20}},{"path":"src/main/java/seedu/wildwatch/parser/Parser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.Command;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Returns a specific command object as defined in the command package.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * @param \u003cT\u003e","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"lctxct"},"content":"public interface Parser\u003cT extends Command\u003e {","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" T parse(String input) throws InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"woodenclock":7,"lctxct":6}},{"path":"src/main/java/seedu/wildwatch/parser/SummaryCommandParser.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"imaginarys96"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-11-04"},{"lineNumber":2,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":3,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.command.SummaryCommand;","lastModifiedDate":"2023-11-04"},{"lineNumber":4,"author":{"gitId":"imaginarys96"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-04"},{"lineNumber":5,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":6,"author":{"gitId":"imaginarys96"},"content":"public class SummaryCommandParser implements Parser\u003cSummaryCommand\u003e {","lastModifiedDate":"2023-11-04"},{"lineNumber":7,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":8,"author":{"gitId":"imaginarys96"},"content":" private static final String COMMAND_WORD \u003d \"summary\";","lastModifiedDate":"2023-11-04"},{"lineNumber":9,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":" @Override","lastModifiedDate":"2023-11-04"},{"lineNumber":11,"author":{"gitId":"imaginarys96"},"content":" public SummaryCommand parse(String input) throws InvalidInputException {","lastModifiedDate":"2023-11-04"},{"lineNumber":12,"author":{"gitId":"imaginarys96"},"content":" String speciesName \u003d getArgumentFromInput(input);","lastModifiedDate":"2023-11-04"},{"lineNumber":13,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":14,"author":{"gitId":"imaginarys96"},"content":" return new SummaryCommand(speciesName);","lastModifiedDate":"2023-11-04"},{"lineNumber":15,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":16,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-04"},{"lineNumber":17,"author":{"gitId":"imaginarys96"},"content":" /**","lastModifiedDate":"2023-11-04"},{"lineNumber":18,"author":{"gitId":"imaginarys96"},"content":" * Gets the argument (species name) if specified.","lastModifiedDate":"2023-11-04"},{"lineNumber":19,"author":{"gitId":"imaginarys96"},"content":" *","lastModifiedDate":"2023-11-04"},{"lineNumber":20,"author":{"gitId":"imaginarys96"},"content":" * @param input","lastModifiedDate":"2023-11-04"},{"lineNumber":21,"author":{"gitId":"imaginarys96"},"content":" * @return species name if specified, otherwise an empty string.","lastModifiedDate":"2023-11-04"},{"lineNumber":22,"author":{"gitId":"imaginarys96"},"content":" */","lastModifiedDate":"2023-11-04"},{"lineNumber":23,"author":{"gitId":"imaginarys96"},"content":" protected String getArgumentFromInput(String input) {","lastModifiedDate":"2023-11-04"},{"lineNumber":24,"author":{"gitId":"imaginarys96"},"content":" return input.replace(\"summary\", \"\").trim();","lastModifiedDate":"2023-11-04"},{"lineNumber":25,"author":{"gitId":"imaginarys96"},"content":" }","lastModifiedDate":"2023-11-04"},{"lineNumber":26,"author":{"gitId":"imaginarys96"},"content":"}","lastModifiedDate":"2023-11-04"}],"authorContributionMap":{"imaginarys96":26}},{"path":"src/main/java/seedu/wildwatch/storage/EntryToStringConverter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-02"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"public class EntryToStringConverter {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" private static final DateTimeFormatter STD_FORMAT \u003d DateTimeFormatter.ofPattern(\"dd-MM-yy\");","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Returns String that is in the format to be written to file.","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * @param entry Entry of interest.","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" * @return String.","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" * @throws IOException when there is problem with formatting the task.","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" public static String toFileString(Entry entry) throws IOException {","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" assert entry !\u003d null : \"Trying to convert a null entry to file string.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" String date \u003d entry.getDate().format(STD_FORMAT);","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" String species \u003d entry.getSpecies();","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" String name \u003d entry.getName();","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" String remark \u003d entry.getRemark();","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" return String.format(\"%s / %s / %s / %s\", date, species, name, remark);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":" public static String toCSVString(Entry entry, int id, ArrayList\u003cString\u003e columns) {","lastModifiedDate":"2023-11-02"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" assert entry !\u003d null : \"Trying to convert a null entry to file string.\";","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":" String items \u003d String.format(\"%d\", id);","lastModifiedDate":"2023-11-02"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"date\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" String date \u003d entry.getDate().format(STD_FORMAT);","lastModifiedDate":"2023-11-02"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, date);","lastModifiedDate":"2023-11-02"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"species\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":" String species \u003d entry.getSpecies();","lastModifiedDate":"2023-11-02"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, species);","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"name\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" String name \u003d entry.getName();","lastModifiedDate":"2023-11-02"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, name);","lastModifiedDate":"2023-11-02"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" if (columns.contains(\"remark\")) {","lastModifiedDate":"2023-11-02"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" String remark \u003d entry.getRemark();","lastModifiedDate":"2023-11-02"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":" items \u003d String.join(\",\", items, remark);","lastModifiedDate":"2023-11-02"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":" return items + \"\\n\";","lastModifiedDate":"2023-11-02"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-11-02"},{"lineNumber":56,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":27,"lctxct":29}},{"path":"src/main/java/seedu/wildwatch/storage/ExistenceChecker.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.FilePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class ExistenceChecker {","lastModifiedDate":"2023-10-31"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-10-31"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * Checks if file exists. Opens file if the file exists.","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @return true if file exists; false if not.","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static boolean checkFileExistence(String filePath) {","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.print(System.lineSeparator());","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" FilePrinter.checkingIfFileExistsMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" assert filePath !\u003d null : \"File path should not be null.\";","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" if (!file.exists()) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" return false;","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" return true;","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":25}},{"path":"src/main/java/seedu/wildwatch/storage/FileCreater.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.FilePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public class FileCreater {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" * Creates new file with filename specified by {@code FILE_PATH}.","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" public static File createFile(String filePath) throws IOException {","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" File file \u003d new File(filePath);","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" if (file.createNewFile()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" FilePrinter.createNewFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" return file;","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" throw new IOException();","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":21}},{"path":"src/main/java/seedu/wildwatch/storage/FileHandler.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"//@@woodenclock","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.ListCommand;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.BootUp;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.miscellaneous.ShutDown;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.FilePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-10-22"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"public class FileHandler {","lastModifiedDate":"2023-10-22"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" private static final String FILE_PATH \u003d \"./WildWatch.txt\";","lastModifiedDate":"2023-10-22"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" private static File openedFile; //File to save the entries","lastModifiedDate":"2023-10-22"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-22"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" public static void handleFile() {","lastModifiedDate":"2023-10-22"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" if (ExistenceChecker.checkFileExistence(FILE_PATH)) {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" FilePrinter.fileExistMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" openedFile \u003d new File(FILE_PATH);","lastModifiedDate":"2023-10-31"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" FileLoader.loadFile(openedFile); // Loads entries from file","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" assert openedFile !\u003d null : \"Trying to read from a non-initialized file.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" FilePrinter.taskLoadedMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-23"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" // Lists entries loaded from file","lastModifiedDate":"2023-10-23"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" ListCommand.listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" } catch (FileNotFoundException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" FilePrinter.noFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" } catch (InvalidInputException e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" FilePrinter.corruptFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDownWithError();","lastModifiedDate":"2023-11-03"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" System.exit(0);","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" } else { // File does not exist","lastModifiedDate":"2023-10-23"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" FilePrinter.noFileMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" openedFile \u003d FileCreater.createFile(FILE_PATH);","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" } catch (IOException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" FilePrinter.fileCreationFailMessagePrinter();","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" ShutDown.shutDownWithError();","lastModifiedDate":"2023-11-03"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" System.exit(0);","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" assert openedFile.exists() : \"File was supposed to be created but it doesn\u0027t exist.\";","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" BootUp.bootUpTwo(); //Welcome prompt message","lastModifiedDate":"2023-10-23"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-22"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-22"}],"authorContributionMap":{"woodenclock":43,"lctxct":7}},{"path":"src/main/java/seedu/wildwatch/storage/FileLoader.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import java.io.File;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.io.FileNotFoundException;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.parser.FileStringParser;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"public class FileLoader {","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Loads tasks from file into the TaskList.","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" public static void loadFile(File openedFile) throws FileNotFoundException, InvalidInputException {","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" Scanner fileReader \u003d new Scanner(openedFile); // create a Scanner using the File as the source","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" while (fileReader.hasNext()) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" String lineOfFile \u003d fileReader.nextLine();","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" new FileStringParser().parse(lineOfFile).execute(); // Creates new entry from line in file","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":23}},{"path":"src/main/java/seedu/wildwatch/storage/Saver.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.storage;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.ErrorPrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import java.io.FileWriter;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import java.io.IOException;","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"public class Saver {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" private static final String FILE_PATH \u003d \"./WildWatch.txt\";","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" * Manages the storage of tasks in a file.","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * Write each task in the desired format to the file.","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void saver(ArrayList\u003cEntry\u003e entries) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" assert entries !\u003d null : \"Trying to save a null list of entries.\";","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" try {","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" FileWriter writer \u003d new FileWriter(FILE_PATH);","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" for (Entry entry : entries) {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" writer.write(EntryToStringConverter.toFileString(entry) + \"\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" writer.close();","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" } catch (IOException exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" ErrorPrinter.errorMessagePrinter(exception);","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":29}},{"path":"src/main/java/seedu/wildwatch/ui/AddCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class AddCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void entryAddedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The following entry has been added:\");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":7}},{"path":"src/main/java/seedu/wildwatch/ui/DeleteCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class DeleteCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void entryRemovedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The entry has been deleted.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void entryDeletionConfirmationPrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Are you sure you want to delete this entry? (yes/no): \");","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static void entryNotDeletedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The entry was not deleted.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when nth entry input by the user is not found.","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public static void entryNotFoundMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The entry number could not be found :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":24}},{"path":"src/main/java/seedu/wildwatch/ui/EditCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class EditCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void entryEditedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"The following entry has been edited:\");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":7}},{"path":"src/main/java/seedu/wildwatch/ui/EmptyDescriptionPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.DeleteCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.EditCommand;","lastModifiedDate":"2023-11-03"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.command.FindCommand;","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"public class EmptyDescriptionPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void emptyDescriptionMessagePrinter(String description) {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" if (description \u003d\u003d null) {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(AddCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of an add command cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(DeleteCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of a delete command cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(EditCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-03"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of an edit command cannot be empty. :-(\");","lastModifiedDate":"2023-11-03"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" } else if (description.equals(FindCommand.COMMAND_WORD)) {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description of a find command cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! The description cannot be empty. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":24}},{"path":"src/main/java/seedu/wildwatch/ui/EntryPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import java.time.format.DateTimeFormatter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"public class EntryPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * Prints the nth entry of the wildlife data stored in WildWatch.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @param nthEntry","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void printEntry(int nthEntry) {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Date: [\" +","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" EntryList.getEntryDate(nthEntry).format(DateTimeFormatter.ofPattern(\"dd-MM-yyyy\")) + \"] | \");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Species: [\" + EntryList.getEntrySpecies(nthEntry) + \"] | \");","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Name: [\" + EntryList.getEntryName(nthEntry) + \"] | \");","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"Remark: [\" + EntryList.getEntryRemark(nthEntry) + \"]\");","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" System.out.print(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":21}},{"path":"src/main/java/seedu/wildwatch/ui/ErrorPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class ErrorPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void corruptLoggerMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Logger is corrupted.\\nUnable to be configured\");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" public static void customInvalidInputMessagePrinter(String e) {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" System.out.println(e);","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" * Prints an error message to the console.","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" * @param exception The exception that occurred.","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void errorMessagePrinter(Exception exception) {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"An error occurred: \" + exception.getMessage());","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when invalid input is typed into the program.","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" public static void invalidInputMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Format of command is incorrect.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when the input date is invalid","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" public static void invalidDateMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Invalid Date input :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" public static void invalidIndexMessagePrinter() {","lastModifiedDate":"2023-11-03"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Invalid Index input :-(\");","lastModifiedDate":"2023-11-03"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-03"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":38}},{"path":"src/main/java/seedu/wildwatch/ui/FilePrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class FilePrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when file is corrupt","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" public static void corruptFileMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File is corrupted.\\nUnable to read file\");","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" * Prints out message after a new file has been created.","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public static void createNewFileMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Creating new file...\\nFile created successfully.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when creation of new file failed","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" public static void fileCreationFailMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File creation failed.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when file already exists.","lastModifiedDate":"2023-11-01"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" public static void fileExistMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File already exists.\\nOpening existing file...\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when no file found.","lastModifiedDate":"2023-11-01"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" * Home directory meaning where WildWatch.jar file is residing.","lastModifiedDate":"2023-11-01"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":" public static void noFileMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"File does not exist.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when checking if file exists","lastModifiedDate":"2023-11-01"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" public static void checkingIfFileExistsMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Checking if \\\"WildWatch.txt\\\" already exists...\");","lastModifiedDate":"2023-11-01"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when tasks are loaded","lastModifiedDate":"2023-11-01"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" public static void taskLoadedMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"These are tasks loaded from before: \");","lastModifiedDate":"2023-11-01"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":53}},{"path":"src/main/java/seedu/wildwatch/ui/InputConsole.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.Scanner;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class InputConsole {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" private static Scanner in \u003d new Scanner(System.in);","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" * Returns input of the user from the console.","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @return The user\u0027s input as a trimmed string.","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static String inputRetriever() {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" return in.nextLine().trim();","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":16}},{"path":"src/main/java/seedu/wildwatch/ui/LinePrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class LinePrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" private static final int NUMBER_OF_UNDERSCORES \u003d 60;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints horizontal lines that segment the output and input in the UI.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void printHorizontalLines() {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" for (int i \u003d 0; i \u003c NUMBER_OF_UNDERSCORES; i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"_\");","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" System.out.print(System.lineSeparator());","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":15}},{"path":"src/main/java/seedu/wildwatch/ui/ListCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class ListCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate message when there is no entries to list.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public static void emptyListMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"OOPS!!! Nothing to list. :-(\");","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void listMessagePrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here are the entries in your list: \");","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" public static void entryCountPrinter() {","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Now you have \" + (EntryList.getArraySize()) + \" entries in the list.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":20}},{"path":"src/main/java/seedu/wildwatch/ui/SearchResultPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import java.util.ArrayList;","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"public class SearchResultPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" /**","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints out the entries that match the search key word.","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" * If no match, prints out appropriate message that there was no match found.","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" *","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" * @param hasMatch","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" * @param matchingTasks","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-11-01"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" public static void findEntryMessagePrinter(boolean hasMatch, ArrayList\u003cInteger\u003e matchingTasks) {","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" if (!hasMatch) {","lastModifiedDate":"2023-11-01"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"No matching tasks found.\");","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" } else {","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here are the matching tasks in your list:\");","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" for (int i \u003d 0; i \u003c matchingTasks.size(); i++) {","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" System.out.print((i+1) + \".\");","lastModifiedDate":"2023-11-01"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" EntryPrinter.printEntry(matchingTasks.get(i));","lastModifiedDate":"2023-11-01"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":24}},{"path":"src/main/java/seedu/wildwatch/ui/SummaryCommandPrinter.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"public class SummaryCommandPrinter {","lastModifiedDate":"2023-11-01"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" public static void printSummarySpecieMessage() {","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here are the species recorded: \");","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" public static void printSummaryNameMessage(String speciesName) {","lastModifiedDate":"2023-11-01"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Here is the data for the \" + speciesName + \", grouped by their names\");","lastModifiedDate":"2023-11-01"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-11-01"}],"authorContributionMap":{"woodenclock":11}},{"path":"src/main/java/seedu/wildwatch/ui/Ui.java","fileType":"functional-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.ui;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-11"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"/**","lastModifiedDate":"2023-10-11"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":" * This is the Ui class that is in-charge of interaction with the user","lastModifiedDate":"2023-10-11"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":" * Represents the user interface of the application.","lastModifiedDate":"2023-10-11"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":" * Provides methods to interact with the user and display messages.","lastModifiedDate":"2023-10-11"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":" * Prints out appropriate messages such as errors and tasks added","lastModifiedDate":"2023-10-11"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":" */","lastModifiedDate":"2023-10-11"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"public class Ui {","lastModifiedDate":"2023-10-11"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":" public static void inputPromptPrinter() {","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" System.out.print(\"\u003e\u003e\u003e \");","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"woodenclock":14}},{"path":"src/test/java/seedu/wildwatch/WildWatchTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch;","lastModifiedDate":"2023-10-09"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2023-10-09"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"public class WildWatchTest {","lastModifiedDate":"2023-10-09"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"-"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":" public void isMainValid() {","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"-"},"content":" assertTrue(true);","lastModifiedDate":"2023-10-12"},{"lineNumber":11,"author":{"gitId":"-"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"-"},"content":"}","lastModifiedDate":"2020-05-24"}],"authorContributionMap":{"woodenclock":4,"-":8}},{"path":"src/test/java/seedu/wildwatch/command/DeleteCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"tangzhenen"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayInputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"import java.io.InputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"tangzhenen"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"tangzhenen"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"tangzhenen"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.addEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.clearEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.EntryList;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"tangzhenen"},"content":"public class DeleteCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"tangzhenen"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"tangzhenen"},"content":" private final ByteArrayOutputStream mockOutput \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"tangzhenen"},"content":" private InputStream originalIn;","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" private ByteArrayInputStream mockInput;","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" void redirectSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" System.setOut(new PrintStream(mockOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"tangzhenen"},"content":" originalIn \u003d System.in;","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"tangzhenen"},"content":" @AfterEach","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"tangzhenen"},"content":" void restoreSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"tangzhenen"},"content":" System.setIn(originalIn);","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"tangzhenen"},"content":" void testExecuteConfirmation() {","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Lion\", \"Simba\", \"This is Simba.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"tangzhenen"},"content":" // Prepare user input \"yes\" for confirmation","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"tangzhenen"},"content":" mockInput \u003d new ByteArrayInputStream(\"yes\\n\".getBytes());","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"tangzhenen"},"content":" System.setIn(mockInput);","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"tangzhenen"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"tangzhenen"},"content":" deleteCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"tangzhenen"},"content":" // Assert: Verify the confirmation message and that the entry is removed","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"Are you sure you want to delete this entry? (yes/no):\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"The entry has been deleted.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"tangzhenen"},"content":" void testExecuteCancellation() {","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Lion\", \"Simba\", \"This is Simba.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"tangzhenen"},"content":" // Prepare user input \"no\" for cancellation","lastModifiedDate":"2023-10-29"},{"lineNumber":63,"author":{"gitId":"tangzhenen"},"content":" mockInput \u003d new ByteArrayInputStream(\"no\\n\".getBytes());","lastModifiedDate":"2023-10-29"},{"lineNumber":64,"author":{"gitId":"tangzhenen"},"content":" System.setIn(mockInput);","lastModifiedDate":"2023-10-29"},{"lineNumber":65,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":66,"author":{"gitId":"tangzhenen"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(1);","lastModifiedDate":"2023-10-29"},{"lineNumber":67,"author":{"gitId":"tangzhenen"},"content":" deleteCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":68,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":69,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":70,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":71,"author":{"gitId":"tangzhenen"},"content":" // Assert: Verify the confirmation message and that the entry is not removed","lastModifiedDate":"2023-10-29"},{"lineNumber":72,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"Are you sure you want to delete this entry? (yes/no):\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":73,"author":{"gitId":"tangzhenen"},"content":" assertTrue(consoleOutput.contains(\"The entry was not deleted.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":74,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":75,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":76,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":77,"author":{"gitId":"tangzhenen"},"content":" public void testDeleteCommandWithInvalidIndex(){","lastModifiedDate":"2023-10-29"},{"lineNumber":78,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":79,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"09-11-23\", \"Lion\", \"Simba\", \"This is Simba\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":80,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":81,"author":{"gitId":"tangzhenen"},"content":" DeleteCommand deleteCommand \u003d new DeleteCommand(2);","lastModifiedDate":"2023-10-29"},{"lineNumber":82,"author":{"gitId":"tangzhenen"},"content":" deleteCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":83,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":84,"author":{"gitId":"tangzhenen"},"content":" int entryListSizeAfter \u003d EntryList.getArraySize();","lastModifiedDate":"2023-10-29"},{"lineNumber":85,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":86,"author":{"gitId":"tangzhenen"},"content":" assertEquals(1,entryListSizeAfter,\"Entry count should remain the same due to deletion of an invalid index\");","lastModifiedDate":"2023-10-29"},{"lineNumber":87,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":88,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":89,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"tangzhenen":89}},{"path":"src/test/java/seedu/wildwatch/command/HelpCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"tangzhenen"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"imaginarys96"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"tangzhenen"},"content":"public class HelpCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"tangzhenen"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"tangzhenen"},"content":" private final ByteArrayOutputStream mockOutput \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"tangzhenen"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"tangzhenen"},"content":" void redirectSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"tangzhenen"},"content":" System.setOut(new PrintStream(mockOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"tangzhenen"},"content":" @AfterEach","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"tangzhenen"},"content":" void restoreSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"tangzhenen"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" void testExecute() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"imaginarys96"},"content":" HelpCommand helpCommand \u003d new HelpCommand(\"\");","lastModifiedDate":"2023-11-01"},{"lineNumber":29,"author":{"gitId":"tangzhenen"},"content":" helpCommand.execute();","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"imaginarys96"},"content":" String expectedMessage \u003d HelpCommand.getHelpPage();","lastModifiedDate":"2023-11-01"},{"lineNumber":32,"author":{"gitId":"imaginarys96"},"content":"","lastModifiedDate":"2023-11-01"},{"lineNumber":33,"author":{"gitId":"tangzhenen"},"content":" // Normalize the line separators in the actual and expected output to ignore differences","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" String actualOutput \u003d mockOutput.toString().replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"imaginarys96"},"content":" String expectedOutput \u003d expectedMessage.replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-11-01"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"imaginarys96"},"content":" // Assert: Verify the printed output contains the expected message.","lastModifiedDate":"2023-11-01"},{"lineNumber":38,"author":{"gitId":"imaginarys96"},"content":" assertTrue(actualOutput.contains(expectedOutput));","lastModifiedDate":"2023-11-01"},{"lineNumber":39,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"imaginarys96":7,"tangzhenen":33}},{"path":"src/test/java/seedu/wildwatch/command/ListCommandTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"tangzhenen"},"content":"package seedu.wildwatch.command;","lastModifiedDate":"2023-10-29"},{"lineNumber":2,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":3,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.AfterEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":4,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-29"},{"lineNumber":5,"author":{"gitId":"tangzhenen"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-29"},{"lineNumber":6,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":7,"author":{"gitId":"tangzhenen"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-29"},{"lineNumber":8,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":9,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.addEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":10,"author":{"gitId":"tangzhenen"},"content":"import static seedu.wildwatch.entry.EntryList.clearEntry;","lastModifiedDate":"2023-10-29"},{"lineNumber":11,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":12,"author":{"gitId":"tangzhenen"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-29"},{"lineNumber":13,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":14,"author":{"gitId":"tangzhenen"},"content":"import java.io.ByteArrayOutputStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":15,"author":{"gitId":"tangzhenen"},"content":"import java.io.PrintStream;","lastModifiedDate":"2023-10-29"},{"lineNumber":16,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":17,"author":{"gitId":"tangzhenen"},"content":"class ListCommandTest {","lastModifiedDate":"2023-10-29"},{"lineNumber":18,"author":{"gitId":"tangzhenen"},"content":" private final PrintStream originalOut \u003d System.out;","lastModifiedDate":"2023-10-29"},{"lineNumber":19,"author":{"gitId":"tangzhenen"},"content":" private final ByteArrayOutputStream mockOutput \u003d new ByteArrayOutputStream();","lastModifiedDate":"2023-10-29"},{"lineNumber":20,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":21,"author":{"gitId":"tangzhenen"},"content":" @BeforeEach","lastModifiedDate":"2023-10-29"},{"lineNumber":22,"author":{"gitId":"tangzhenen"},"content":" void redirectSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":23,"author":{"gitId":"tangzhenen"},"content":" System.setOut(new PrintStream(mockOutput));","lastModifiedDate":"2023-10-29"},{"lineNumber":24,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":25,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":26,"author":{"gitId":"tangzhenen"},"content":" @AfterEach","lastModifiedDate":"2023-10-29"},{"lineNumber":27,"author":{"gitId":"tangzhenen"},"content":" void restoreSystemOut() {","lastModifiedDate":"2023-10-29"},{"lineNumber":28,"author":{"gitId":"tangzhenen"},"content":" System.setOut(originalOut);","lastModifiedDate":"2023-10-29"},{"lineNumber":29,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":30,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":31,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":32,"author":{"gitId":"tangzhenen"},"content":" void listEntry() {","lastModifiedDate":"2023-10-29"},{"lineNumber":33,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":34,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Lion\", \"Simba\", \"This is Simba.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":35,"author":{"gitId":"tangzhenen"},"content":" addEntry(new Entry(\"28-10-23\", \"Tiger\", \"Tigger\", \"This is Tigger.\"));","lastModifiedDate":"2023-10-29"},{"lineNumber":36,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":37,"author":{"gitId":"tangzhenen"},"content":" ListCommand.listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":38,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":39,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":40,"author":{"gitId":"tangzhenen"},"content":" String expectedOutput \u003d \"1.Date: [28-10-2023] | Species: [Lion] | Name: [Simba] | Remark: [This is Simba.]\"","lastModifiedDate":"2023-10-29"},{"lineNumber":41,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\"","lastModifiedDate":"2023-10-29"},{"lineNumber":42,"author":{"gitId":"tangzhenen"},"content":" + \"2.Date: [28-10-2023] | Species: [Tiger] | Name: [Tigger] | Remark: [This is Tigger.]\"","lastModifiedDate":"2023-10-29"},{"lineNumber":43,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\"","lastModifiedDate":"2023-10-29"},{"lineNumber":44,"author":{"gitId":"tangzhenen"},"content":" + \"Now you have 2 entries in the list.\"","lastModifiedDate":"2023-10-29"},{"lineNumber":45,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\";","lastModifiedDate":"2023-10-29"},{"lineNumber":46,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":47,"author":{"gitId":"tangzhenen"},"content":" consoleOutput \u003d consoleOutput.replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-10-29"},{"lineNumber":48,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":49,"author":{"gitId":"tangzhenen"},"content":" assertEquals(expectedOutput, consoleOutput);","lastModifiedDate":"2023-10-29"},{"lineNumber":50,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":51,"author":{"gitId":"tangzhenen"},"content":"","lastModifiedDate":"2023-10-29"},{"lineNumber":52,"author":{"gitId":"tangzhenen"},"content":" @Test","lastModifiedDate":"2023-10-29"},{"lineNumber":53,"author":{"gitId":"tangzhenen"},"content":" void listEntryWithZeroEntry() {","lastModifiedDate":"2023-10-29"},{"lineNumber":54,"author":{"gitId":"tangzhenen"},"content":" clearEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":55,"author":{"gitId":"tangzhenen"},"content":" ListCommand.listEntry();","lastModifiedDate":"2023-10-29"},{"lineNumber":56,"author":{"gitId":"tangzhenen"},"content":" String consoleOutput \u003d mockOutput.toString();","lastModifiedDate":"2023-10-29"},{"lineNumber":57,"author":{"gitId":"tangzhenen"},"content":" String expectedOutput \u003d \"Now you have 0 entries in the list.\"","lastModifiedDate":"2023-10-29"},{"lineNumber":58,"author":{"gitId":"tangzhenen"},"content":" + \"\\n\";","lastModifiedDate":"2023-10-29"},{"lineNumber":59,"author":{"gitId":"tangzhenen"},"content":" consoleOutput \u003d consoleOutput.replace(System.lineSeparator(), \"\\n\");","lastModifiedDate":"2023-10-29"},{"lineNumber":60,"author":{"gitId":"tangzhenen"},"content":" assertEquals(expectedOutput, consoleOutput);","lastModifiedDate":"2023-10-29"},{"lineNumber":61,"author":{"gitId":"tangzhenen"},"content":" }","lastModifiedDate":"2023-10-29"},{"lineNumber":62,"author":{"gitId":"tangzhenen"},"content":"}","lastModifiedDate":"2023-10-29"}],"authorContributionMap":{"tangzhenen":62}},{"path":"src/test/java/seedu/wildwatch/execute/DateCheckerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-12"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.DateChecker;","lastModifiedDate":"2023-11-01"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.ui.LinePrinter;","lastModifiedDate":"2023-11-01"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertFalse;","lastModifiedDate":"2023-10-12"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertTrue;","lastModifiedDate":"2023-10-12"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-12"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"public class DateCheckerTest {","lastModifiedDate":"2023-11-01"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-12"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":" public void testDateHandler() {","lastModifiedDate":"2023-10-12"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" System.out.println(\"Testing whether date is valid...\");","lastModifiedDate":"2023-10-12"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" LinePrinter.printHorizontalLines();","lastModifiedDate":"2023-11-01"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" assertTrue(DateChecker.isDateValid(\"09-11-23\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":" assertFalse(DateChecker.isDateValid(\"9-11-23\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" assertFalse(DateChecker.isDateValid(\"99-11-23\"));","lastModifiedDate":"2023-11-01"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-12"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-12"}],"authorContributionMap":{"woodenclock":20}},{"path":"src/test/java/seedu/wildwatch/execute/EntryHandlerTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"woodenclock"},"content":"package seedu.wildwatch.execute;","lastModifiedDate":"2023-11-01"},{"lineNumber":2,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":3,"author":{"gitId":"woodenclock"},"content":"import org.junit.jupiter.api.BeforeEach;","lastModifiedDate":"2023-10-31"},{"lineNumber":4,"author":{"gitId":"woodenclock"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-31"},{"lineNumber":5,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-10-31"},{"lineNumber":6,"author":{"gitId":"woodenclock"},"content":"import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;","lastModifiedDate":"2023-10-31"},{"lineNumber":7,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-11-03"},{"lineNumber":8,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.Router;","lastModifiedDate":"2023-11-03"},{"lineNumber":9,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-31"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"public class EntryHandlerTest {","lastModifiedDate":"2023-10-31"},{"lineNumber":12,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":13,"author":{"gitId":"woodenclock"},"content":" @BeforeEach","lastModifiedDate":"2023-10-31"},{"lineNumber":14,"author":{"gitId":"woodenclock"},"content":" public void setUp() {","lastModifiedDate":"2023-10-31"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":" // Set up necessary mocks, initial data, etc.","lastModifiedDate":"2023-10-31"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":17,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":18,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":" public void testAddEntryFromFile() {","lastModifiedDate":"2023-10-31"},{"lineNumber":20,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel_2 R/Injured left flipper\";","lastModifiedDate":"2023-10-31"},{"lineNumber":21,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":22,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":23,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":24,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":25,"author":{"gitId":"woodenclock"},"content":" public void testAddEntryNotFromFile() {","lastModifiedDate":"2023-10-31"},{"lineNumber":26,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel_2 R/Injured left flipper\";","lastModifiedDate":"2023-10-31"},{"lineNumber":27,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":28,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":29,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":30,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":31,"author":{"gitId":"woodenclock"},"content":" public void testDeleteEntryWithValidNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":32,"author":{"gitId":"woodenclock"},"content":" CommandHandler.processCommand(\"add D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\");","lastModifiedDate":"2023-10-31"},{"lineNumber":33,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"delete 1\"; // 1 is a valid entry number.","lastModifiedDate":"2023-10-31"},{"lineNumber":34,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":35,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":36,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":37,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":38,"author":{"gitId":"woodenclock"},"content":" public void testDeleteEntryWithInvalidNumber() {","lastModifiedDate":"2023-10-31"},{"lineNumber":39,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"delete -5\"; // Negative numbers should be invalid.","lastModifiedDate":"2023-10-31"},{"lineNumber":40,"author":{"gitId":"woodenclock"},"content":" assertThrows(InvalidInputException.class, () -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":41,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":42,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":43,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":44,"author":{"gitId":"woodenclock"},"content":" public void testListEntry() {","lastModifiedDate":"2023-10-31"},{"lineNumber":45,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"list\";","lastModifiedDate":"2023-10-31"},{"lineNumber":46,"author":{"gitId":"woodenclock"},"content":" assertDoesNotThrow(() -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":47,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":48,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"},{"lineNumber":49,"author":{"gitId":"woodenclock"},"content":" @Test","lastModifiedDate":"2023-10-31"},{"lineNumber":50,"author":{"gitId":"woodenclock"},"content":" public void testInvalidCommand() {","lastModifiedDate":"2023-10-31"},{"lineNumber":51,"author":{"gitId":"woodenclock"},"content":" String input \u003d \"invalidCommand\";","lastModifiedDate":"2023-10-31"},{"lineNumber":52,"author":{"gitId":"woodenclock"},"content":" assertThrows(InvalidInputException.class, () -\u003e Router.route(input));","lastModifiedDate":"2023-11-03"},{"lineNumber":53,"author":{"gitId":"woodenclock"},"content":" }","lastModifiedDate":"2023-10-31"},{"lineNumber":54,"author":{"gitId":"woodenclock"},"content":"}","lastModifiedDate":"2023-10-31"},{"lineNumber":55,"author":{"gitId":"woodenclock"},"content":"","lastModifiedDate":"2023-10-31"}],"authorContributionMap":{"woodenclock":55}},{"path":"src/test/java/seedu/wildwatch/parser/AddCommandParserTest.java","fileType":"test-code","lines":[{"lineNumber":1,"author":{"gitId":"lctxct"},"content":"package seedu.wildwatch.parser;","lastModifiedDate":"2023-10-30"},{"lineNumber":2,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":3,"author":{"gitId":"lctxct"},"content":"import org.junit.jupiter.api.Test;","lastModifiedDate":"2023-10-30"},{"lineNumber":4,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.command.AddCommand;","lastModifiedDate":"2023-10-30"},{"lineNumber":5,"author":{"gitId":"lctxct"},"content":"import seedu.wildwatch.entry.Entry;","lastModifiedDate":"2023-10-30"},{"lineNumber":6,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":7,"author":{"gitId":"lctxct"},"content":"import static org.junit.jupiter.api.Assertions.assertEquals;","lastModifiedDate":"2023-10-30"},{"lineNumber":8,"author":{"gitId":"lctxct"},"content":"import static org.junit.jupiter.api.Assertions.assertThrows;","lastModifiedDate":"2023-11-02"},{"lineNumber":9,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":10,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.exception.InvalidInputException;","lastModifiedDate":"2023-10-30"},{"lineNumber":11,"author":{"gitId":"woodenclock"},"content":"import seedu.wildwatch.error.InvalidInputErrorType;","lastModifiedDate":"2023-11-01"},{"lineNumber":12,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":13,"author":{"gitId":"lctxct"},"content":"public class AddCommandParserTest {","lastModifiedDate":"2023-10-30"},{"lineNumber":14,"author":{"gitId":"lctxct"},"content":" private final AddCommandParser parser \u003d new AddCommandParser();","lastModifiedDate":"2023-10-30"},{"lineNumber":15,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":16,"author":{"gitId":"lctxct"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":17,"author":{"gitId":"lctxct"},"content":" public void parse_success() throws Exception {","lastModifiedDate":"2023-10-30"},{"lineNumber":18,"author":{"gitId":"lctxct"},"content":" String input;","lastModifiedDate":"2023-10-30"},{"lineNumber":19,"author":{"gitId":"lctxct"},"content":" AddCommand expected;","lastModifiedDate":"2023-11-02"},{"lineNumber":20,"author":{"gitId":"lctxct"},"content":" AddCommand actual;","lastModifiedDate":"2023-11-02"},{"lineNumber":21,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":22,"author":{"gitId":"lctxct"},"content":" // add command with remark","lastModifiedDate":"2023-10-30"},{"lineNumber":23,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-10-30"},{"lineNumber":24,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":25,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":26,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":27,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":28,"author":{"gitId":"lctxct"},"content":" \"Injured left flipper\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":29,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":30,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":31,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-10-30"},{"lineNumber":32,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":33,"author":{"gitId":"lctxct"},"content":" // add command without remark","lastModifiedDate":"2023-10-30"},{"lineNumber":34,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/Ariel\";","lastModifiedDate":"2023-10-30"},{"lineNumber":35,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":36,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":37,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":38,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":39,"author":{"gitId":"lctxct"},"content":" \"\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":40,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":41,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-11-02"},{"lineNumber":42,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-11-02"},{"lineNumber":43,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":44,"author":{"gitId":"lctxct"},"content":" // add command with spacings between prefix and values","lastModifiedDate":"2023-10-30"},{"lineNumber":45,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/ 02-03-23 S/ Annam Leaf Turtle N/ Ariel R/ Injured left flipper\";","lastModifiedDate":"2023-10-30"},{"lineNumber":46,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":47,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":48,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":49,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":50,"author":{"gitId":"lctxct"},"content":" \"Injured left flipper\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":51,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":52,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":53,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-10-30"},{"lineNumber":54,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":55,"author":{"gitId":"lctxct"},"content":" // add command with extra spacings after definitions","lastModifiedDate":"2023-10-30"},{"lineNumber":56,"author":{"gitId":"lctxct"},"content":" input \u003d \"add D/ 02-03-23 S/ Annam Leaf Turtle N/ Ariel R/ Injured left flipper \";","lastModifiedDate":"2023-10-30"},{"lineNumber":57,"author":{"gitId":"lctxct"},"content":" expected \u003d new AddCommand(","lastModifiedDate":"2023-10-30"},{"lineNumber":58,"author":{"gitId":"lctxct"},"content":" new Entry(\"02-03-23\",","lastModifiedDate":"2023-10-30"},{"lineNumber":59,"author":{"gitId":"lctxct"},"content":" \"Annam Leaf Turtle\",","lastModifiedDate":"2023-10-30"},{"lineNumber":60,"author":{"gitId":"lctxct"},"content":" \"Ariel\",","lastModifiedDate":"2023-10-30"},{"lineNumber":61,"author":{"gitId":"lctxct"},"content":" \"Injured left flipper\"));","lastModifiedDate":"2023-10-30"},{"lineNumber":62,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":63,"author":{"gitId":"lctxct"},"content":" actual \u003d parser.parse(input);","lastModifiedDate":"2023-10-30"},{"lineNumber":64,"author":{"gitId":"lctxct"},"content":" assertEquals(actual, expected);","lastModifiedDate":"2023-10-30"},{"lineNumber":65,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":66,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":67,"author":{"gitId":"lctxct"},"content":" @Test","lastModifiedDate":"2023-10-30"},{"lineNumber":68,"author":{"gitId":"lctxct"},"content":" public void parse_exceptionThrown() throws Exception {","lastModifiedDate":"2023-10-30"},{"lineNumber":69,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":70,"author":{"gitId":"lctxct"},"content":" // D/ prefix is not present","lastModifiedDate":"2023-10-30"},{"lineNumber":71,"author":{"gitId":"lctxct"},"content":" final String testInput1 \u003d \"add S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":72,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception1 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput1));","lastModifiedDate":"2023-11-02"},{"lineNumber":73,"author":{"gitId":"lctxct"},"content":" assertEquals(exception1.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":74,"author":{"gitId":"lctxct"},"content":" assertEquals(exception1.getCustomMessage(), \"D/ is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":75,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":76,"author":{"gitId":"lctxct"},"content":" // date is not specified","lastModifiedDate":"2023-10-30"},{"lineNumber":77,"author":{"gitId":"lctxct"},"content":" final String testInput2 \u003d \"add D/ S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":78,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception2 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput2));","lastModifiedDate":"2023-11-02"},{"lineNumber":79,"author":{"gitId":"lctxct"},"content":" assertEquals(exception2.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":80,"author":{"gitId":"lctxct"},"content":" assertEquals(exception2.getCustomMessage(), \"Date value cannot be empty.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":81,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":82,"author":{"gitId":"lctxct"},"content":" // date is not in a correct format","lastModifiedDate":"2023-10-30"},{"lineNumber":83,"author":{"gitId":"lctxct"},"content":" final String testInput3 \u003d \"add D/1 S/Annam Leaf Turtle N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":84,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception3 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput3));","lastModifiedDate":"2023-11-02"},{"lineNumber":85,"author":{"gitId":"lctxct"},"content":" assertEquals(exception3.getError(), InvalidInputErrorType.INVALID_DATE);","lastModifiedDate":"2023-11-02"},{"lineNumber":86,"author":{"gitId":"lctxct"},"content":" assertEquals(exception3.getCustomMessage(), \"Command is invalid.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":87,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":88,"author":{"gitId":"lctxct"},"content":" // S/ prefix is not present","lastModifiedDate":"2023-10-30"},{"lineNumber":89,"author":{"gitId":"lctxct"},"content":" final String testInput4 \u003d \"add D/02-03-23 N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":90,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception4 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput4));","lastModifiedDate":"2023-11-02"},{"lineNumber":91,"author":{"gitId":"lctxct"},"content":" assertEquals(exception4.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":92,"author":{"gitId":"lctxct"},"content":" assertEquals(exception4.getCustomMessage(), \"S/ is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":93,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":94,"author":{"gitId":"lctxct"},"content":" // species is not specified","lastModifiedDate":"2023-10-30"},{"lineNumber":95,"author":{"gitId":"lctxct"},"content":" final String testInput5 \u003d \"add D/02-03-23 S/ N/Ariel R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":96,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception5 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput5));","lastModifiedDate":"2023-11-02"},{"lineNumber":97,"author":{"gitId":"lctxct"},"content":" assertEquals(exception5.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":98,"author":{"gitId":"lctxct"},"content":" assertEquals(exception5.getCustomMessage(), \"Species is not defined.\");","lastModifiedDate":"2023-11-02"},{"lineNumber":99,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":100,"author":{"gitId":"lctxct"},"content":" // N/ prefix is not present","lastModifiedDate":"2023-10-30"},{"lineNumber":101,"author":{"gitId":"lctxct"},"content":" final String testInput6 \u003d \"add D/02-03-23 S/Annam Leaf Turtle R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":102,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception6 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput6));","lastModifiedDate":"2023-11-02"},{"lineNumber":103,"author":{"gitId":"lctxct"},"content":" assertEquals(exception6.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":104,"author":{"gitId":"lctxct"},"content":" assertEquals(exception6.getCustomMessage(), \"N/ is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":105,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-10-30"},{"lineNumber":106,"author":{"gitId":"lctxct"},"content":" // name is not specified","lastModifiedDate":"2023-10-30"},{"lineNumber":107,"author":{"gitId":"lctxct"},"content":" final String testInput7 \u003d \"add D/02-03-23 S/Annam Leaf Turtle N/ R/Injured left flipper\";","lastModifiedDate":"2023-11-02"},{"lineNumber":108,"author":{"gitId":"lctxct"},"content":" InvalidInputException exception7 \u003d assertThrows(InvalidInputException.class, () -\u003e parser.parse(testInput7));","lastModifiedDate":"2023-11-02"},{"lineNumber":109,"author":{"gitId":"lctxct"},"content":" assertEquals(exception7.getError(), InvalidInputErrorType.INVALID_INPUT);","lastModifiedDate":"2023-11-02"},{"lineNumber":110,"author":{"gitId":"lctxct"},"content":" assertEquals(exception7.getCustomMessage(), \"Name is not defined\");","lastModifiedDate":"2023-11-02"},{"lineNumber":111,"author":{"gitId":"lctxct"},"content":"","lastModifiedDate":"2023-11-02"},{"lineNumber":112,"author":{"gitId":"lctxct"},"content":" }","lastModifiedDate":"2023-10-30"},{"lineNumber":113,"author":{"gitId":"lctxct"},"content":"}","lastModifiedDate":"2023-10-30"}],"authorContributionMap":{"woodenclock":2,"lctxct":111}},{"path":"text-ui-test/runtest.bat","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"@echo off","lastModifiedDate":"2020-05-24"},{"lineNumber":2,"author":{"gitId":"-"},"content":"setlocal enableextensions","lastModifiedDate":"2020-05-24"},{"lineNumber":3,"author":{"gitId":"-"},"content":"pushd %~dp0","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":5,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":6,"author":{"gitId":"-"},"content":"call gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":8,"author":{"gitId":"-"},"content":"cd build\\libs","lastModifiedDate":"2020-05-24"},{"lineNumber":9,"author":{"gitId":"-"},"content":"for /f \"tokens\u003d*\" %%a in (","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":" \u0027dir /b *.jar\u0027","lastModifiedDate":"2020-05-24"},{"lineNumber":11,"author":{"gitId":"-"},"content":") do (","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":" set jarloc\u003d%%a","lastModifiedDate":"2020-05-24"},{"lineNumber":13,"author":{"gitId":"-"},"content":")","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":15,"author":{"gitId":"-"},"content":"java -jar %jarloc% \u003c ..\\..\\text-ui-test\\input.txt \u003e ..\\..\\text-ui-test\\ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":16,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-24"},{"lineNumber":17,"author":{"gitId":"-"},"content":"cd ..\\..\\text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":18,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"woodenclock"},"content":"FC ACTUAL.TXT ACTUAL.TXT \u0026\u0026 ECHO Test passed! || Echo Test failed!","lastModifiedDate":"2023-10-11"}],"authorContributionMap":{"woodenclock":1,"-":18}},{"path":"text-ui-test/runtest.sh","fileType":"other","lines":[{"lineNumber":1,"author":{"gitId":"-"},"content":"#!/usr/bin/env bash","lastModifiedDate":"2020-05-25"},{"lineNumber":2,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":3,"author":{"gitId":"-"},"content":"# change to script directory","lastModifiedDate":"2020-05-24"},{"lineNumber":4,"author":{"gitId":"-"},"content":"cd \"${0%/*}\"","lastModifiedDate":"2020-05-24"},{"lineNumber":5,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":6,"author":{"gitId":"-"},"content":"cd ..","lastModifiedDate":"2020-05-24"},{"lineNumber":7,"author":{"gitId":"-"},"content":"./gradlew clean shadowJar","lastModifiedDate":"2020-05-24"},{"lineNumber":8,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":9,"author":{"gitId":"-"},"content":"cd text-ui-test","lastModifiedDate":"2020-05-24"},{"lineNumber":10,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":11,"author":{"gitId":"-"},"content":"java -jar $(find ../build/libs/ -mindepth 1 -print -quit) \u003c input.txt \u003e ACTUAL.TXT","lastModifiedDate":"2020-05-24"},{"lineNumber":12,"author":{"gitId":"-"},"content":"","lastModifiedDate":"2020-05-25"},{"lineNumber":13,"author":{"gitId":"-"},"content":"cp EXPECTED.TXT EXPECTED-UNIX.TXT","lastModifiedDate":"2020-05-25"},{"lineNumber":14,"author":{"gitId":"-"},"content":"dos2unix EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2023-10-09"},{"lineNumber":15,"author":{"gitId":"woodenclock"},"content":"# diff EXPECTED-UNIX.TXT ACTUAL.TXT","lastModifiedDate":"2023-10-11"},{"lineNumber":16,"author":{"gitId":"woodenclock"},"content":"diff ACTUAL.TXT ACTUAL.TXT","lastModifiedDate":"2023-10-11"},{"lineNumber":17,"author":{"gitId":"-"},"content":"if [ $? -eq 0 ]","lastModifiedDate":"2020-05-25"},{"lineNumber":18,"author":{"gitId":"-"},"content":"then","lastModifiedDate":"2020-05-25"},{"lineNumber":19,"author":{"gitId":"-"},"content":" echo \"Test passed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":20,"author":{"gitId":"-"},"content":" exit 0","lastModifiedDate":"2020-05-25"},{"lineNumber":21,"author":{"gitId":"-"},"content":"else","lastModifiedDate":"2020-05-25"},{"lineNumber":22,"author":{"gitId":"-"},"content":" echo \"Test failed!\"","lastModifiedDate":"2020-05-24"},{"lineNumber":23,"author":{"gitId":"-"},"content":" exit 1","lastModifiedDate":"2020-05-25"},{"lineNumber":24,"author":{"gitId":"-"},"content":"fi","lastModifiedDate":"2020-05-25"}],"authorContributionMap":{"woodenclock":2,"-":22}}] diff --git a/AY2324S1-CS2113T-W11-2_tp_master/commits.json b/AY2324S1-CS2113T-W11-2_tp_master/commits.json index 98f0f33..5b7a356 100644 --- a/AY2324S1-CS2113T-W11-2_tp_master/commits.json +++ b/AY2324S1-CS2113T-W11-2_tp_master/commits.json @@ -1 +1 @@ -{"authorDailyContributionsMap":{"imaginarys96":[{"date":"2023-10-14","commitResults":[{"hash":"ec58ce88cfc6d13389719ba5c71f25eca9a9a801","isMergeCommit":false,"messageTitle":"Updated help command for v1 features - help, add, list, delete","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":43}}},{"hash":"bf15d755cbc672977eb38b6001162424834580fc","isMergeCommit":true,"messageTitle":"Merge pull request #31 from imaginarys96/master","messageBody":"Updated help command for v1 features - help, add, list, delete","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"d99f0c79eee52e1af97c186c829392ef8e30f8aa","isMergeCommit":false,"messageTitle":"Implemented SummaryCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":80,"deletions":4}}},{"hash":"5fd5ddccef1e9c4294df3f1b749d059f20811590","isMergeCommit":true,"messageTitle":"Merge pull request #77 from imaginarys96/master","messageBody":"Implemented SummaryCommand","fileTypesAndContributionMap":{}},{"hash":"e9872b87ea07ed2f4cfae8208a6b7b9c85b19f80","isMergeCommit":false,"messageTitle":"reordered help command in UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":55,"deletions":55}}},{"hash":"4c5d7b7b18fb4ddc69c360e904b408a2dbf760d5","isMergeCommit":true,"messageTitle":"Merge pull request #78 from imaginarys96/master","messageBody":"reordered help command in UserGuide","fileTypesAndContributionMap":{}},{"hash":"8dfcebc71e11c422e383ebe2a57adf7c36d807a3","isMergeCommit":false,"messageTitle":"reordered table of contents in UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"7f53d8a203e66ce0c1ce0ff7df0065910b5995cc","isMergeCommit":true,"messageTitle":"Merge pull request #79 from imaginarys96/master","messageBody":"reordered table of contents in UserGuide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"b2370db38fdd6b8d98b86c2367444f6337266906","isMergeCommit":false,"messageTitle":"Implemented EditCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":93,"deletions":9}}},{"hash":"fa22d1545a218794419f1d0a67cec37502a5d8bd","isMergeCommit":false,"messageTitle":"Updated UserGuide to include summary and edit commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":60,"deletions":7}}},{"hash":"6cdbd2c30fdeef268e33fb981ecd3b576b3b2d3b","isMergeCommit":true,"messageTitle":"Merge pull request #89 from imaginarys96/master","messageBody":"Added `edit` command, updated UserGuide to include `edit` and `summary` commands","fileTypesAndContributionMap":{}},{"hash":"b26d8338e0a7b492c5168c089f28059631573218","isMergeCommit":false,"messageTitle":"fix gradle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":5}}},{"hash":"7ea0fc9a05bd1bf0189f19626dcf36b60f769d6f","isMergeCommit":true,"messageTitle":"Merge pull request #91 from imaginarys96/master","messageBody":"fix gradle errors","fileTypesAndContributionMap":{}},{"hash":"5c47056fa698a2c75cc2089a9ee983c81a3acacb","isMergeCommit":false,"messageTitle":"added edit, summary table of contents to include link to github pages. updated FAQ to have Q\u0026A on separate lines","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":4}}},{"hash":"144e360d92e10d6eadfd15dab9e913ca17060554","isMergeCommit":true,"messageTitle":"Merge pull request #92 from imaginarys96/master","messageBody":"added edit, summary table of contents to include link to github pages…","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"ebd61c62b989518b77bf393e41e2ffa1ad10b863","isMergeCommit":false,"messageTitle":"Create Sequence Diagram for HelpCommand using PlantUML (first draft -- needs to be worked on)","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":37,"deletions":0}}},{"hash":"29ca80cf78f1b9dc6b77f29d895a02b35b05175c","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cd8dd63e045b1e3c6623202a8dbe4ca6e2d81910","isMergeCommit":false,"messageTitle":"Updated helpMessage, modified help command to display short version by default, and supports help COMMAND now","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":91,"deletions":3},"docs":{"insertions":3,"deletions":2},"test-code":{"insertions":3,"deletions":1}}},{"hash":"d37745e0f5f5308803f575a1cdd44894f7759685","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"85c2d84bff0ef537356e43487d689f23bab9b2a0","isMergeCommit":false,"messageTitle":"move HelpCommand.puml to diagrams folder","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":0}}},{"hash":"5714364c1e2e61d5ffc7ba23a3d5bc202bd1ac36","isMergeCommit":false,"messageTitle":"fix gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"d58fc7f29f2a9e6d2f5e842ae7f8c0e4c9f86881","isMergeCommit":false,"messageTitle":"modified HelpCommandTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":43}}},{"hash":"e51a16243e50f480039f124a9b4d3c15b7e89aaa","isMergeCommit":false,"messageTitle":"fix gradle import error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"43a667e60740c75f9a63dbd0114759c2f0e339dd","isMergeCommit":true,"messageTitle":"Merge pull request #111 from imaginarys96/master","messageBody":"Updated helpMessage, modified help command to display short version by default, and supports help COMMAND now","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"826ee91d25c39501770d3949aeb9173acbc8a4fb","isMergeCommit":false,"messageTitle":"Implement SummaryCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":63,"deletions":13}}},{"hash":"a6553d0fe3fdc74a6f84903b257ac66c0ee00d41","isMergeCommit":false,"messageTitle":"fix gradle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":9}}},{"hash":"b087a3c1ec4d7d92edd28b8a68af905067b9c09b","isMergeCommit":true,"messageTitle":"Merge pull request #177 from imaginarys96/master","messageBody":"Implement SummaryCommandParser","fileTypesAndContributionMap":{}}]}],"woodenclock":[{"date":"2023-10-04","commitResults":[{"hash":"773a8e43cb56142c5789ca6965e4db2986c5c57f","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-09","commitResults":[{"hash":"6077ba4a23bd1b9fc1e50fa53e3b872be5b6eb1e","isMergeCommit":false,"messageTitle":"Create AboutUs branch and leesungmin.md portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":7}}},{"hash":"a37fa65ccb6a1b62dfab0eb6f3457341f6d818fc","isMergeCommit":false,"messageTitle":"Update READ.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"c2fcafd4f8451047de38b018df37b1fe9c6f480a","isMergeCommit":true,"messageTitle":"Merge pull request #1 from woodenclock/LeeSungmin-AboutUs","messageBody":"Create AboutUs branch and leesungmin.md portfolio","fileTypesAndContributionMap":{}},{"hash":"3e9aca38ae0e03fd4a8ae621146d083c45409027","isMergeCommit":true,"messageTitle":"Merge branch \u0027LeeSungmin-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2d4101597f24823b23a9a5ef502aef5397288f1c","isMergeCommit":false,"messageTitle":"Rename Duke.java to WildWatch.java as per out project name","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"1abb04b6249ec7daf5a386a21773f3ddb077ac18","isMergeCommit":false,"messageTitle":"Revert \"Rename Duke.java to WildWatch.java as per out project name\"","messageBody":"This reverts commit 2d4101597f24823b23a9a5ef502aef5397288f1c.\n","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"244abfa479dd4619a399297ac397592315e08604","isMergeCommit":false,"messageTitle":"Create abstract class Animal","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":0}}},{"hash":"7663b3ecf3a8aa8aa508d8ca7edad59130e9c0eb","isMergeCommit":false,"messageTitle":"Rename project as WildWatch as per our project name","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":6,"deletions":6}}},{"hash":"b2e6806dddd0bf67b32c68655dd5236c7e9cc544","isMergeCommit":true,"messageTitle":"Merge pull request #4 from woodenclock/rename_project","messageBody":"Rename project from Duke to WildWatch as per our project name","fileTypesAndContributionMap":{}},{"hash":"c6242a7063a64aa4bb36350d575a875c50229edc","isMergeCommit":true,"messageTitle":"Merge branch \u0027rename_project\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a64a4c0cab96655ea728b5ac0f2f60751c8ed5a1","isMergeCommit":false,"messageTitle":"Create BootUp.java that contains welcome logo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":77,"deletions":0}}},{"hash":"1f3d3b8c4fc84585d1699c43d127d4a36da01587","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":114,"deletions":76}}},{"hash":"fe6e136acc5d593d19301effc6cc5f2641e1947e","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":8}}},{"hash":"6c2cafbaba2f9bb015357d95eff4dfaa5f5c4a69","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":21}}},{"hash":"6cf1720e89934b3c61ab1c0d8db3a7e239eacd36","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"b348ea5c36874f96a6b46c30290db939136d88fc","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"c4fb3ba9f397df9c3454cadc898b8829dd8553db","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"32d40d3e7e7046ccc3c3e596dc7c5b0b68073947","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"bfd809b962a596b58a7fc24c27f6b244735c571b","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"936492bd4e993987c0bd1fcae321f3493ab4b91e","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"429d316db795b18efa841f79d94336cea4f40331","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"fd7bfa9b414fe7ee9bfb841d84703aaf82e6ce7c","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":133},"other":{"insertions":1,"deletions":1}}},{"hash":"97689efd86b84f8ee0b3497014aea9426286baaa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into bootup","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ac3e8877e92b18280e3cd70bdadaf9310f81dff7","isMergeCommit":true,"messageTitle":"Merge pull request #6 from woodenclock/bootup","messageBody":"Update BootUp.java to fit within 120 wordline limit","fileTypesAndContributionMap":{}},{"hash":"c06e04b29d428439ccf8b280bd26d5482c96c8d3","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"31c6d46df982c3a0688f29f473887f21dc3ba1db","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":51}}},{"hash":"c6dff4fe86a6f3264235eadf60d8443e5e8f6a19","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/bootup\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"98d77c185330d024cf1a480c1d16eb5413f0f497","isMergeCommit":true,"messageTitle":"Merge branch \u0027bootup\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"95b5f9b53ffbc9c55aa75f230a8746872f8bee4c","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/bootup\u0027 into bootup","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9f4548643bc946e1e5906276338a280796b2cef9","isMergeCommit":false,"messageTitle":"Update project structure","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":39}}},{"hash":"e5a87bbe89f4a01b708f0f3327d195415909489c","isMergeCommit":true,"messageTitle":"Merge branch \u0027bootup\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"987dc591619e7c1b4cd557c06e21f6a68d607a4a","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"a5c52684a404e5205c5674689e949f782d79811c","isMergeCommit":false,"messageTitle":"Update BootUp.java to conform to coding quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"1f17fcaa275038ea365d6759055ab33f6c31e9aa","isMergeCommit":true,"messageTitle":"Merge pull request #12 from woodenclock/bootup","messageBody":"Update project structure","fileTypesAndContributionMap":{}},{"hash":"7145784bb155b969e48ff7e7010ea4c97c2aae75","isMergeCommit":false,"messageTitle":"Create Entry class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":2}}},{"hash":"f03352d7d7f269e18a0591384ba5a3c7cc4eb55a","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":8}}},{"hash":"96ac3b11547e3b2d2d4c6e14bdf22fd36aa76bba","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into entry","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5dac1732ee34244d4e59bf099e9261501710087d","isMergeCommit":true,"messageTitle":"Merge pull request #13 from woodenclock/entry","messageBody":"Create Entry class","fileTypesAndContributionMap":{}},{"hash":"945347d04572d7a9a11413580262329c992f14a5","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":2},"test-code":{"insertions":4,"deletions":2}}},{"hash":"3b7a601cd1b53fc7be7a2d1bedc42310cf1649e1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into test","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"be05363bad21706e61fab277cea8f999e2782b07","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"2e019b43aa866ada15a4ed25cd3d7885ac10cc4a","isMergeCommit":false,"messageTitle":"Create EntryList class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}},{"hash":"6d3073813fb40e7d90e3ab589849963683e1189a","isMergeCommit":true,"messageTitle":"Merge pull request #14 from woodenclock/test","messageBody":"Update WildWatchTest.java","fileTypesAndContributionMap":{}},{"hash":"f774cc61af7a812a27a5b8886299f5f7b1f8868d","isMergeCommit":true,"messageTitle":"Merge pull request #15 from woodenclock/entry-list","messageBody":"Create EntryList class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-11","commitResults":[{"hash":"fb23536d544f38c73460e96a5c8bd313abdf0871","isMergeCommit":false,"messageTitle":"Update Main.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"38254679c1a734c325e5dab8dcf333beef508b93","isMergeCommit":false,"messageTitle":"Update Entry","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":4}}},{"hash":"a3e6c2fd82eac65ab404abed9a60af89969b3303","isMergeCommit":true,"messageTitle":"Merge branch \u0027test\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1bade08d80d0e3eedb5160168e9cb74b4927402d","isMergeCommit":true,"messageTitle":"Merge branch \u0027entry-list\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d0e3391ae33de9f5e0a565830ac98df6cc4f313f","isMergeCommit":true,"messageTitle":"Merge branch \u0027entry\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4ee7626d1bc4413bf1ddef578903135c52b31969","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":1}}},{"hash":"9e1e349dc0473c94c82979f9b4205f2c7a5a2a0f","isMergeCommit":true,"messageTitle":"Merge pull request #17 from woodenclock/master","messageBody":"Update Main.java","fileTypesAndContributionMap":{}},{"hash":"641b2c736ec355c3848f2cbcbb041dc8338c9f26","isMergeCommit":false,"messageTitle":"Update Main.java to show welcome logo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"77fe5541e59e37f74e72d91231d710d0ed696be1","isMergeCommit":false,"messageTitle":"Update Welcome Logo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":13},"other":{"insertions":1,"deletions":1}}},{"hash":"6ea49076bd57c39603afcf927bf16466cdace61a","isMergeCommit":true,"messageTitle":"Merge pull request #18 from woodenclock/master","messageBody":"Update Main.java to show welcome logo","fileTypesAndContributionMap":{}},{"hash":"68be8887d8efee36a1ef4f109533033482dcd242","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"c2a56a8ff200897cfb897a15b2667cf694316c48","isMergeCommit":false,"messageTitle":"Merge operatingsystem and operation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":58,"deletions":6},"other":{"insertions":1,"deletions":1}}},{"hash":"b9d4ec4398a5423e8ba4e6cff7a0e21b6703d2de","isMergeCommit":false,"messageTitle":"Create Help.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":69,"deletions":1}}},{"hash":"139ddda6ac311b9fe600964084bedc30025b5c23","isMergeCommit":false,"messageTitle":"Create Ui.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":16}}},{"hash":"aa73f36ed0f867e9cc494712264bbcf74eb20acd","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"1b39f7d802f41be2b0972d434ac72ed2a5d174ea","isMergeCommit":false,"messageTitle":"Update Main.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":265,"deletions":12},"other":{"insertions":2,"deletions":2}}},{"hash":"2f5bb6fcc91de14d1cfdff6923d9cf4cbe8b586a","isMergeCommit":false,"messageTitle":"Rectify coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":7}}},{"hash":"3fe9e8732a78b643b213927cfc670a40841bc438","isMergeCommit":true,"messageTitle":"Merge pull request #19 from woodenclock/master","messageBody":"Update BootUp.java","fileTypesAndContributionMap":{}},{"hash":"768e729a01aa2ca563e5b753adfd4bb3fba53fe2","isMergeCommit":false,"messageTitle":"Create DateHandler.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":9}}},{"hash":"17a55f41fb4299dbafc4a11ce5132343f647ce8e","isMergeCommit":false,"messageTitle":"Update master","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":11}}},{"hash":"00f4e5be68faec38e3787643e978c85acd8a4140","isMergeCommit":false,"messageTitle":"Update DateHandler.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-12","commitResults":[{"hash":"854362b0cb347d3eef09cff390a2bc1ece81a933","isMergeCommit":false,"messageTitle":"Create UiTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":7},"test-code":{"insertions":23,"deletions":5}}},{"hash":"9219e532962e466897da973e62b635128a9537d7","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":6,"deletions":1}}},{"hash":"000704a61d0cf556f3659838c9f483cf4dc327b9","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":2}}},{"hash":"3bd708d0dc25b88e7467f88ebf02c13d04fad21a","isMergeCommit":true,"messageTitle":"Merge pull request #24 from woodenclock/JUnit","messageBody":"Create DateHandler.java","fileTypesAndContributionMap":{}},{"hash":"9269539e2e1b215c6abe2ce8299598f2ac7bbfc9","isMergeCommit":false,"messageTitle":"Update master","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":9},"test-code":{"insertions":23,"deletions":1}}},{"hash":"ec828890f2b2e762697dc08f3c59345057a75d6b","isMergeCommit":false,"messageTitle":"Update JUnit Testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"21885dd84c3a1eb10fc873bea34312d6cd5d3908","isMergeCommit":false,"messageTitle":"Create DateHandlerTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2},"test-code":{"insertions":45,"deletions":4}}},{"hash":"e62a99b83b1a86695fdd408c40fa647c6d55c395","isMergeCommit":false,"messageTitle":"Update JUnit Testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"a42c135198681cfb760500a9fb570cf655900b15","isMergeCommit":false,"messageTitle":"Update JUnit Testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":33}}},{"hash":"34c204943b75d986f3434990cc8a2a0d51785428","isMergeCommit":true,"messageTitle":"Merge pull request #26 from woodenclock/JUnit","messageBody":"Update JUnit Testing","fileTypesAndContributionMap":{}},{"hash":"f89a3376b6128b40c6fb6a0ac87ae67433c69718","isMergeCommit":false,"messageTitle":"Update master branch","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3},"test-code":{"insertions":30,"deletions":24}}}]},{"date":"2023-10-13","commitResults":[{"hash":"04bfb9cdcbb0e565b7728dff4ef37b9900ecaf01","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"c41766f63af1deec7f34501671e4ce7797dd8a7e","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"0824e77a201a68175ae07a2bd651b9a28d77bfae","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"155b4a5313622cf619386de79dac55fd1e6511d2","isMergeCommit":false,"messageTitle":"Update Team","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":6}}}]},{"date":"2023-10-14","commitResults":[{"hash":"a6771c27f6f02e0b583eab8a6b8b084dc2e2b613","isMergeCommit":true,"messageTitle":"Merge pull request #30 from tangzhenen/DeleteCommand","messageBody":"Delete command ","fileTypesAndContributionMap":{}},{"hash":"66a8c9a6cd5cac707a4f960ee6afbc999ae363dd","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"00c2201381e98033b496951aac6812238b46249b","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"7aa2d2e9e23cbaaa7c4d183901c9a80aeb4a050e","isMergeCommit":false,"messageTitle":"Delete docs/team/johndoe.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":6}}}]},{"date":"2023-10-15","commitResults":[{"hash":"d224fc9b93a7ab109c4bc7789325449fa98c4b31","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"610129370f63512b2b17ef46b9e9e9bba81ea8f2","isMergeCommit":false,"messageTitle":"Update ErrorHandler to be more defensive when handling invalid command input for delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":21}}},{"hash":"b0b42fe5a3c45ea96b5cb9f0231b763009ce75b1","isMergeCommit":false,"messageTitle":"Update Helper to HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":8},"other":{"insertions":2,"deletions":2}}},{"hash":"6fb4e2fce4321f4b3390687233fed35eaf984f33","isMergeCommit":true,"messageTitle":"Merge pull request #29 from woodenclock/master","messageBody":"Update docs/team","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"450da925b330879ecf333b82d2f23dd01f0ba7cf","isMergeCommit":true,"messageTitle":"Merge pull request #32 from lctxct/master","messageBody":"Add add command","fileTypesAndContributionMap":{}},{"hash":"cca01ddd9bafcd73bab5601d937d80176c768a4c","isMergeCommit":false,"messageTitle":"Add assertions for Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":10},"other":{"insertions":1,"deletions":0}}},{"hash":"be31165e3f29da49d974c06bfe456d9a86e14d5e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JUnit","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"46279ea4c95f206dddb4e551a2e1dbe2db2adc83","isMergeCommit":false,"messageTitle":"Update error handling to be more resilient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":19},"other":{"insertions":1,"deletions":1}}},{"hash":"7b23c414b16f87663f8d9ac8cbc379596256f30c","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":7}}},{"hash":"6bd0efebc07159b11dc261fff9f34374aba05eec","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":5}}},{"hash":"115693537e993d70f89024842dd6e170d584bf15","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"463587f2747ec71359e71c28e88259af383f0d2d","isMergeCommit":false,"messageTitle":"Update ErrorHandler.java to be more defensive","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"62cdd84658d7065539c5f991671b99913c12e384","isMergeCommit":false,"messageTitle":"Update Assertions and Logging for ErrorHandler.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":1}}},{"hash":"16b0525ef78374b54dc7b6b5e274909efef28325","isMergeCommit":true,"messageTitle":"Merge branch \u0027JUnit\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9bff5d167f55af981c3a47361f0ddd243349ef7e","isMergeCommit":false,"messageTitle":"Update gitignore","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":0}}},{"hash":"976434bb6d811e51a8be416ce003b805086dd8cc","isMergeCommit":true,"messageTitle":"Merge pull request #33 from woodenclock/JUnit","messageBody":"Add Assertions\u0026Logging for Parser.java \u0026 ErrorHandler.java","fileTypesAndContributionMap":{}},{"hash":"9cab20433568b43e3f97459a5abd399dc9d95fd6","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":4}}}]},{"date":"2023-10-18","commitResults":[{"hash":"1304354f67117f4b44f29fb50d395bff627f33ef","isMergeCommit":true,"messageTitle":"Merge pull request #35 from woodenclock/master","messageBody":"Create LogHandler.java","tags":["v1.0"],"fileTypesAndContributionMap":{}},{"hash":"f2bf7121a54988b8aae718966e9936168a1f78c9","isMergeCommit":false,"messageTitle":"Update HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":26}}},{"hash":"a775e5d8540fe1662258e81878bde359b7389aab","isMergeCommit":true,"messageTitle":"Merge pull request #37 from lctxct/master","messageBody":"Trim add command attributes","fileTypesAndContributionMap":{}},{"hash":"517a582de13b8da9c01cb9560e57eeb9cb900e04","isMergeCommit":true,"messageTitle":"Merge pull request #38 from woodenclock/master","messageBody":"Update HelpCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-21","commitResults":[{"hash":"3ba93ef829aeb9749839687d188d1e98665dcaf1","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"88f1e79af130134d0e69cd5fc8ac3f4ee7ba4250","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"1e3ece0f8c482bc9b9d69e58d5dfa1ec8bf9c719","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"4be4b3bc4c835b3f228e6664f56f7c45fc5b6929","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"7afb1c9045252a235b022ba229fba2f424758d0d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"a28bd140e9ef8dd83c307f1dd2cbaf6a85324c55","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"1452811275c11a608f8c8efecf997fffbe3fe359","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":2}}},{"hash":"6d645b691a546bc05707102ae2165ae79c140b68","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":0}}}]},{"date":"2023-10-22","commitResults":[{"hash":"931a82be6bb9716fce842f07f2a0634891c8d723","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fc1314dd5fd8272f25bb0f0c4062ab3ef124c3d4","isMergeCommit":false,"messageTitle":"Create FileHandler class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":262,"deletions":69},"other":{"insertions":24,"deletions":13}}},{"hash":"49953cd354913432aa4e3ae852bd71aa269bb5b2","isMergeCommit":false,"messageTitle":"Update to conform to coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":4}}},{"hash":"cdf125e1beca7bb3a4063330b725d59205edc5b2","isMergeCommit":true,"messageTitle":"Merge pull request #43 from woodenclock/feature/file-handler","messageBody":"Create FileHandler class","fileTypesAndContributionMap":{}},{"hash":"b8b831fd2eee00070db0641f2d18c427da06ae7e","isMergeCommit":false,"messageTitle":"Update HandlerTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":46,"deletions":4}}}]},{"date":"2023-10-25","commitResults":[{"hash":"71c60292bc89991caef1a3695436d09286562b0e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":132,"deletions":22}}},{"hash":"801e5200abe33a244de96df8786e2dbe7bfe8f46","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"de00a3076eb5eba44e4dcb92c1147683139bd577","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":6}}},{"hash":"a88ab74d5e7f56c212d229a48c3d1f69f4de57ad","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":8}}},{"hash":"8efa46d48a1f2460f950d0163096e1ed33dfb996","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":1}}},{"hash":"d62b0808a95f7e76fa753f360612e07f9e3104cd","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"70351e139f405fe75afebae3532b13cee21ac57f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"7212664e4176144796e87e3434f4ddd17759744d","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"999431233aacdb145349641f962902670d3956bc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":13}}},{"hash":"8523bb7ed471238502b710348b84528fd6da0c94","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"6300da7aa03d3bd34ee1cef1ac57da6cd146ee0e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"79ec23b44f524a07a16aa79097b4a71d4d5a361c","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"73c201d8f89d41325b3a74d623526c2b59ee31ee","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":7}}},{"hash":"fa7c26d503410ebeed06981e77762afd8973d192","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"1c91472ae7643a1e14d269f55a9b64be4e5b32d9","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"9e9fd85fe63e51e4f72921b8e924a9f22962e1e8","isMergeCommit":true,"messageTitle":"Merge pull request #44 from lctxct/decouple-filehandler","messageBody":"Decouple filehandler","fileTypesAndContributionMap":{}},{"hash":"9113b6d5796af11bb360ce27272ce4a43233193a","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1b69d279c88f149ead8710f208e350f538cb7a7d","isMergeCommit":false,"messageTitle":"Decouple the InputHandler class from EntryHandler class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":60,"deletions":47},"test-code":{"insertions":15,"deletions":33}}},{"hash":"2855de5b8de26166236c54831261d772078f2896","isMergeCommit":false,"messageTitle":"Create FindComamand Operation class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":78,"deletions":3}}},{"hash":"f9c00b1fc91dabeaea48bcf7b66939df2a5cadc0","isMergeCommit":false,"messageTitle":"Fixed bug in FindCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":7}}},{"hash":"a2fef8e3b29c5a04fbe63d90fbef45e22fb3039d","isMergeCommit":false,"messageTitle":"Update to conform to coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"4dcafe9b3f12f35844fdae882657ff74e7ff973c","isMergeCommit":false,"messageTitle":"Delete EntryHandlerTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":35}}},{"hash":"4d2cf0c635b94b39afd5686685817389a8f7a11f","isMergeCommit":true,"messageTitle":"Merge pull request #45 from woodenclock/master","messageBody":"Decouple the InputHandler class from EntryHandler class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"d1790785abfc81cd517c6a30ae354f83829f31b3","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"f14878ef43b32d4f6ace8902a325b3d0f673cc65","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"fc7c5b14c74f279c9949f6a0c75adbd57fe64add","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"ef087c4e7da75d66c8ddb2bfe7fdbb7fbc43fc85","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":4}}},{"hash":"594921c73d45b19c90ee33995dacd59893d330c9","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"e4a22d783560b1ed2f05ce2d7475a1de8240abdc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"5a1e50d52da7261382aaf1afff40e2dd41dd18b6","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"9d8b5f5499e762f794e8e4a9546a3ab5abac8c64","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b1a6375766d87c2cb0ee8f581008919daf1597fb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"1e48ee6e8ccb0f62d4986a65d48f952d5abc08ad","isMergeCommit":false,"messageTitle":"Update FindCommand.java, erased print used for debugging","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":4}}},{"hash":"5bc23eba9fb6ccbf703de844153e9d8a70326f49","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"2aabe5252b8721b13c6f1bc01343f366c7d4bba0","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"5b144293727c9669eef4fb7a3fb130262de7dc77","isMergeCommit":true,"messageTitle":"Merge pull request #47 from woodenclock/master","messageBody":"Update FindCommand.java, erased print used for debugging","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"57ea655be0101904e4e4896a56d269eb269d5659","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"9d5948c7728238f746ab462036e8e7228052fd03","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"c91cdfa7f37882e01a42b7c55cc1cd84bbc75bee","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"e8a7f527f27279ffc60b7044e6c6490253813216","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"2d94603aaf7ac8b4268f03c0727a9f069f989d45","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"16a5a67761528c9b8fbe8648b51df1ff88e64704","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"74787f82bda0e7105cf06e16571b87d8dbf03b55","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-28","commitResults":[{"hash":"6ce9fbaa24fdd842c8f291108986b2deac66553a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":8}}},{"hash":"eb0321b813089f0868700ccc31bb5438385f7ce7","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"d80b65a2c7a0e70d829823382e7b7a7c3e36cde2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":22}}}]},{"date":"2023-10-29","commitResults":[{"hash":"ce4fcce49515f712cf651b6eecbb20dd61571cef","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":1}}},{"hash":"611a90c0c6fd9da1d06889d18dbb296cdeac2c6b","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"2eac7e89b4fed923b03fcada875c4be390c53a60","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":3}}},{"hash":"a14b8b479b1006cc4d0aa7618e9a36324737a973","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":2}}},{"hash":"181ad4cb23ddc381e4e2a29efc3bdb9c63a413e8","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e1080b16b1e920bbc2abb08d554b8ba251104dce","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"2597af2a2f0e64029f5480e4326f93117bbf6af5","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"2ae2724282d1109842a73b773892eb3a07e573ca","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":4}}},{"hash":"8d9383af337d9471ed9a049aab43bb8ac12c1aa7","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"060385fd1e89ec1a4729a5dbd533f1b9f4f608e4","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"073a4ec309a9d9008fdab4b5f106a50761797fed","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":71}}},{"hash":"a9eb2742b0b5f8cc3f8d284f714496f3b0fa9730","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"76bb482a8343fce5d1d158b0ce7e21f852a58141","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"2345e47ffc5eb68f8197b68a7b1665ed961835fb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":14}}},{"hash":"e89f82832e022ae7c468b919e083722c59abebf2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"50bdcd1c15c534c15a4eeaf9d8daa35f0a210426","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6d81e802214fa27ed2d28e36f2d9ca53888ca912","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"6c00c908a887a0c8992443e7bdb240362efeb426","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"651039e21d0b65fe705af36b25f647e8fb56f054","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"70cc7886454dd7ba9a79eba19b4b8a56b9c9201f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"58842c5494dc812495e8bbfe34d22d213114215c","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"9c6571ba3ce9c6ad1ec531daf4aecc56cb171351","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b01023f7a8aa1c8bb26f59ceb0103cb8e34b2456","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":2}}},{"hash":"72fb57b99c225cc3897679785e4efdec99ce5060","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":1}}},{"hash":"a947305e86c2914fa7875290926c682a676a485b","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"2f7520d069bfc07162a715eb4c3cb1d596122597","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"163f996f0404d39155c01eddbbced0794592605b","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":3}}},{"hash":"ac83aa125df999e0b0619336f401ca3fad7e5495","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"1205b0fd11249db616a705a739936d38d5b8a02b","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"f35c6acfd6a7325d24e7eed72a409a83f412d5dc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"df487785b54bf1a14003b3de8a1f1ef2fb8c37a2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":3}}},{"hash":"f266228b0a2c6f7b009d15956cdd31ee930f0ffb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"b59f34187079ec906132e0281e33061260c03259","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":3}}},{"hash":"6f268e710f65006826bf9e9aa6c114ad00e4b976","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6eec5bad8d3db469c47df5c937821f6228a45e86","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e203ad818030487b48ff07d998aa4313a965d2bd","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":7}}},{"hash":"65d6b05a1cd59431924a51c1ab2c7aa5003cf731","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"93cccaccfec882329c3008f9cb3f86626b1e13d3","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":5}}},{"hash":"9ab358dea1759da20e17f6e69afa226a9ce3f4c0","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"59d29f98700b1c20d3bd76807074d011fc163c91","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":6}}},{"hash":"21adb7eb14887f7a43ad1fe69039db0627306e87","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"8eb136dd8247e797cb702261f987fe5a55a0663f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b0f714da3077dff001078572afa19c6105538437","isMergeCommit":false,"messageTitle":"Create ByeCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":0,"deletions":0}}},{"hash":"a853fe4ad9734a26cd67884fcf2edbbd604ddf82","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":2}}},{"hash":"7578737d271c9ff421224e23b2de063bc8cbd1f5","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"87aaf65189640f6b9b97ce46d2e133a0d4626713","isMergeCommit":false,"messageTitle":"Delete ByeCommandTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":7},"test-code":{"insertions":0,"deletions":0}}},{"hash":"1b3cffa905b350db82491dfae33c8535d5e56530","isMergeCommit":true,"messageTitle":"Merge pull request #96 from woodenclock/master","messageBody":"Create ByeCommandTest.java","fileTypesAndContributionMap":{}},{"hash":"d8ab73416e2eead55c3bb2d0229df9bdd86d707f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"b4eb9042ebebf577e7d91ae043a9e4515b90256e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"9872e9287dfacb27feb7ff47d5102e5abb54873a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"5549e41d14b7ed410337651d7180e6bb68156cea","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":12}}},{"hash":"57f7664df8c710b8732bfd7bc8deb3b37a743631","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"9af0aa0b63b439cd2d603ea8ff478881814a853d","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":19}}},{"hash":"25889acdac7630a56075f0afe7249a8492279445","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":26,"deletions":3}}},{"hash":"384b78c6a79bcba376d376e84b096cca7d540806","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"19ae2556bccf3f607148d54a17387e6a2b72a3fa","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a8bbfe87e249d519ddb832ca7f5619a1ebc9ffe7","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":2}}},{"hash":"b2071b21ed984093067e28c63e012629e88bc64b","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":9}}},{"hash":"7fe21c9b0d08cd1451d79b62f8088d2145836c31","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":9}}}]},{"date":"2023-10-30","commitResults":[{"hash":"1e03e48232c16bcd0cd2507d625e3889b35f89ce","isMergeCommit":false,"messageTitle":"Update Reposense","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"92d47ff54422abda7071b09304cfca9b55586e34","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/wildwatch/operation/ErrorHandler.java\n","fileTypesAndContributionMap":{}},{"hash":"3b729c1cf742ca2c715cdd1d19c0f277b84135fe","isMergeCommit":false,"messageTitle":"Merge upstream with local master","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":102,"deletions":111},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":10,"deletions":10}}},{"hash":"f668a078b4c7883a4a776e9ecef08e0ce532a7ba","isMergeCommit":false,"messageTitle":"Update InvalidInputException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5}}},{"hash":"75141f277c5dc949f8b6167f39ec4bfc791d2490","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"23194774e29d414825cfc3b1be77d53a8d318c9e","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"22bfec4d00cd65d98739279245627a571cb47aa4","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":21}}},{"hash":"361d61b097d10749d5d5eaf4817fe817369307cc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e9082feac8de5c808b3170706aadda982dc2ed40","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"3fddd71f0d125ad1b85f54ae648373365d319977","isMergeCommit":false,"messageTitle":"Update according to Muzfirah\u0027s comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":15}}},{"hash":"258be3c7b7069964accd8dd2a6a77cd14a8e10a3","isMergeCommit":false,"messageTitle":"Update OOP according to comments from Muzfirah","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":21}}},{"hash":"0e0d206704f6cedd1af1787d3c34f5e1cf3a5608","isMergeCommit":true,"messageTitle":"Merge pull request #104 from woodenclock/master","messageBody":"Merge upstream with local master","fileTypesAndContributionMap":{}},{"hash":"fc60829de540dd1b7be647e086ce3e0de8bd78df","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":0}}},{"hash":"07676f9067a1a3fffd63be03106edda08fef05da","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"737c4c4415c885e09a4351031ce872af2d57ed9d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"e86c9b1234cdc3d713f24bd59d87267ce06e32c0","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"a1a6584851e8c3014b127d038fa4d1a05929e7b9","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":30,"deletions":1}}},{"hash":"40b6e657a713f16e30eeb8777192dc8725a6da5a","isMergeCommit":false,"messageTitle":"Add assertions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"c82844d21bad59d72108e785b8a243bf1e5c5db9","isMergeCommit":false,"messageTitle":"Update assertions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"cd7d08344498c709858dd31a7efa80fc8f525136","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"2a0119be88d84e990c211468a5bba841c3af0694","isMergeCommit":false,"messageTitle":"Create storage package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"other":{"insertions":4,"deletions":1},"test-code":{"insertions":53,"deletions":0}}},{"hash":"d0a44ea3dd7b6aa6d8b4810e7b3b1ecd0c749ecf","isMergeCommit":false,"messageTitle":"Update ExistenceChecker","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":22}}},{"hash":"a48d8b80280b6073d2d47549838a2db123e4285b","isMergeCommit":false,"messageTitle":"Fix bug: FileStringParser could not extract the data in isolation without whitespaces","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":7}}},{"hash":"5afaaaf26cf0a38eb9a6ffcd77fba2f5a11c1fa0","isMergeCommit":false,"messageTitle":"Fix bug: CommandHandler ending the program after one command.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":5}}},{"hash":"2e6199f6af080633c4322f1d650eb3b66af6e7f3","isMergeCommit":false,"messageTitle":"Fix bug: InputHandler only saves if bye command is used","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":10}}},{"hash":"a550344bdd5065ca60c426554223fc0570ccc044","isMergeCommit":false,"messageTitle":"Rename IncorrectInputException to InvalidInputException","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":4}}},{"hash":"da1fe3dc4f841e75f2294ae4343a802f7d75a51f","isMergeCommit":false,"messageTitle":"Update EntryHandlerTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":8}}},{"hash":"ce73c6760c837468f6c7b089fcf3dbc0db66fb9c","isMergeCommit":false,"messageTitle":"Update testDeleteEntryWithValidNumber() such that there will always be at least one entry","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"a457678375ce83faf6b9133ecca035626c00b285","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a5bc7655db9137b9b4b84c99432b0c74aa9ef66b","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":3}}},{"hash":"02fedc9b4b67eaeddb42591c98ce0bbb46369068","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"45bf883e16ca960eb9ec3d04304f975b7867352e","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"b8e44e0109364d120209150e09fadcbd4c0613a4","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":3}}},{"hash":"d6875ce5af653a63d4d04617ebf7191f7d8f1bcd","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":56}}},{"hash":"a931a53e1423163a6c50dcbab2fd623e90e285ed","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":2}}},{"hash":"0c05e4fed8d8072d489d4931d6670163dcec0813","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"11cb55fe4cc5cd1dc63216ab0c5e55e2227d68ef","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":3}}},{"hash":"989d7656ce99c64ca6e42cdf5890e8ff3398fec4","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b61c04bb0d03740c2db170ec9d34d5d8621ff168","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"3a140c9f3d5b6e5094661ab332786c4b0d42c0d3","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"c476bab6888227ba3fe403dc9e4a6fedeeb20212","isMergeCommit":false,"messageTitle":"Separate out FileHandler, more OOP!","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":22}}},{"hash":"87b79fd563f839c65b00a3ce471f9692389acabc","isMergeCommit":false,"messageTitle":"Remove unsed imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":5}}},{"hash":"741ab79b0a537ccfdecf736d1ebcbf0e25005dbe","isMergeCommit":true,"messageTitle":"Merge pull request #106 from woodenclock/master","messageBody":"Separate out FileHandler, more OOP!","fileTypesAndContributionMap":{}},{"hash":"bbd95d48246ee6bedbe1e0a378f21ed048e23078","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"f911b393a0c2fc061947ee3db60e061754395d65","isMergeCommit":false,"messageTitle":"Separate out FileCreater class, more OOP!","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":18}}},{"hash":"8a04291513bafe71d291396b6d37535d48ed6d50","isMergeCommit":false,"messageTitle":"Create FindCommandParser class This class checks if the find command is valid","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":156,"deletions":202},"other":{"insertions":25,"deletions":12},"test-code":{"insertions":7,"deletions":6}}},{"hash":"1f4d35158c7585f0ed4d7fc4f3a17534a6b0286f","isMergeCommit":false,"messageTitle":"Delete unused imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5}}},{"hash":"e17831122b9ad078c3c154ef3f5d6e48fec9c7ac","isMergeCommit":false,"messageTitle":"Fix indentation error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"c6cfde1441e05d11f5c2dedaca1f7ecf5199b0a6","isMergeCommit":true,"messageTitle":"Merge pull request #112 from woodenclock/master","messageBody":"Separate out FileCreater class, more OOP!","fileTypesAndContributionMap":{}},{"hash":"391ba5fff7a6c45291a524ed837ea18a87762c03","isMergeCommit":false,"messageTitle":"Organize all classes into their respective packages for modularity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":22},"other":{"insertions":40,"deletions":36},"test-code":{"insertions":1,"deletions":1}}},{"hash":"76c556e252c27e271bee09cd3b543affb521c774","isMergeCommit":false,"messageTitle":"Separate Ui class, more OOP!","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":331,"deletions":284},"test-code":{"insertions":3,"deletions":3}}},{"hash":"af7851b847d205bc674060a5eaa0528bbdc65e65","isMergeCommit":true,"messageTitle":"Merge pull request #113 from woodenclock/master","messageBody":"Organize all classes into their respective packages for modularity","fileTypesAndContributionMap":{}},{"hash":"1c48c26527b76117c8acc0bd227d72500d6b9636","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"020d80d2c015174c2a7a15ec358bcf5e543ed52e","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"71f63eecdeca0ab5a168277da13cd71a285deb23","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"60ad02fa704deb527f3725d4681279a3ff33ce5c","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b6e4667c249d5d19e6766e7dd26b417fa58e961d","isMergeCommit":false,"messageTitle":"Rename classes for better clarity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"other":{"insertions":7,"deletions":7}}},{"hash":"3e4b3a7579fb7700773a1254624f847c39ca32df","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":1}}},{"hash":"1b438e1071ac559e3e6da1ec41dfb81d72a6e4cb","isMergeCommit":true,"messageTitle":"Merge pull request #114 from woodenclock/master","messageBody":"Rename classes for better clarity","fileTypesAndContributionMap":{}},{"hash":"9184989f3c288fb984c5ca2c72d5519cabf6a818","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":11}}}]},{"date":"2023-11-03","commitResults":[{"hash":"8b2fb828588543cfab47a4a32d62bb615df000c9","isMergeCommit":false,"messageTitle":"Create EditCommandParser class for more robust exception handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":148,"deletions":68},"docs":{"insertions":3,"deletions":3}}},{"hash":"e4d616a6b2651f5783e47652c0e3944c421fde1a","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/wildwatch/error/ErrorChecker.java\n#\tsrc/main/java/seedu/wildwatch/error/ErrorHandler.java\n#\tsrc/main/java/seedu/wildwatch/error/InvalidInputErrorType.java\n#\tsrc/main/java/seedu/wildwatch/parser/AddCommandParser.java\n","fileTypesAndContributionMap":{}},{"hash":"f79ae464e2ff6ed71d2d94a92f4b0126f2e512c6","isMergeCommit":true,"messageTitle":"Merge pull request #130 from woodenclock/master","messageBody":"Create EditCommandParser class for more robust exception handling","fileTypesAndContributionMap":{}},{"hash":"0809353b57b8bccb052fa8a0c057ba130ad7dcf9","isMergeCommit":false,"messageTitle":"Rename ErrorChecker to Router","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":16},"other":{"insertions":3,"deletions":3},"test-code":{"insertions":8,"deletions":7}}},{"hash":"36b9d921980c8d34c2b8ae64767553edffc19621","isMergeCommit":false,"messageTitle":"Update EditCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"358ba67653a7b08c01668e4e33d2be2afd0aeb25","isMergeCommit":true,"messageTitle":"Merge pull request #131 from woodenclock/master","messageBody":"Rename ErrorChecker to Router","tags":["v2.0"],"fileTypesAndContributionMap":{}},{"hash":"d496982423df331d938cb22e862ebbf938dc53b8","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"a77f806d6298dfd0fa03544eec7a9aefb1362e13","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":4}}},{"hash":"0c1c30c5c48aa1232a2301aafc1426f9c491777a","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":18}}},{"hash":"937b554599dc7a1f4aba9da218179709346b26f8","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-04","commitResults":[{"hash":"72996885a31f6849bae96ff23d7b1417cb915d4c","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"518a3cb23b8a68586a01be985ec0cdf219bcc615","isMergeCommit":false,"messageTitle":"Update lctxct.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"289bb4a6b6f0fdbfcd9abbf66eb5906655262fd7","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":1}}},{"hash":"22a9b1cffd520b0416332da91ea8c4c42f23c004","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":4}}},{"hash":"6e6fbac476d11163975a8e1c78d938d096254b3e","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"43b7482b646c13ab7ca7be7c8b4f05993cf6dcdc","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"aaf2a21527fa5bdece3ec64e83845200b5195689","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]}],"tangzhenen":[{"date":"2023-10-13","commitResults":[{"hash":"533b7989a5a1ab5bb5320352563ef8ec26703a36","isMergeCommit":false,"messageTitle":"Add delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":4}}},{"hash":"5a8687f571cd1e27f76be6509dbe561301672ebf","isMergeCommit":false,"messageTitle":"Update entry list","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"972d977c09e7acc98f20d0f7126538392192348f","isMergeCommit":false,"messageTitle":"Update Ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}},{"hash":"3d2b111b51993622d4ee5a3533f64719aa479814","isMergeCommit":false,"messageTitle":"Bug fixes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":2}}},{"hash":"3294660fadf18a4228e61b926bdb7d1374e63746","isMergeCommit":false,"messageTitle":"Bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-29","commitResults":[{"hash":"9e176d18484505711f4040c5ed8c19799c56ef32","isMergeCommit":false,"messageTitle":"update aboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"a4b0f1a8ed42cdc2230395cdad3661cdef7bc58e","isMergeCommit":false,"messageTitle":"Delete command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":3},"test-code":{"insertions":39,"deletions":0}}},{"hash":"65c3f395560267925a4062ef616a8f407780d2d7","isMergeCommit":false,"messageTitle":"Add list command test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":62,"deletions":0}}},{"hash":"458f95225ed5fb0c085a998a5adb432be8b44179","isMergeCommit":false,"messageTitle":"Add help command test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":76,"deletions":0}}},{"hash":"82a3b7fa9bd659457daad31eeb4b376f1d0c7182","isMergeCommit":false,"messageTitle":"Add user confirmation when deleting entry","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":4}}},{"hash":"e4790ccd72b01c5b9bdc81cc5fd387ccd5e6aff2","isMergeCommit":false,"messageTitle":"update delete command testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":57,"deletions":12}}},{"hash":"374462d22c6457e37185fcf96f1c36e2ffae575c","isMergeCommit":false,"messageTitle":"update delete command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":6,"deletions":2}}},{"hash":"b599f17afa22d30fe0febf5b8fc691a410d52090","isMergeCommit":false,"messageTitle":"bug fixes","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":2}}},{"hash":"e428fd3e5b4c0f5cbd78b932042185ce11b4738a","isMergeCommit":false,"messageTitle":"bug fix","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"3844616655c954f11c64374fa2e382e065580c39","isMergeCommit":true,"messageTitle":"Merge pull request #97 from tangzhenen/master","messageBody":"Add testing for list, delete, help and extend delete command","fileTypesAndContributionMap":{}}]}],"lctxct":[{"date":"2023-10-16","commitResults":[{"hash":"c0a6facf1ef9e936416052a7d76eaf23255016fd","isMergeCommit":false,"messageTitle":"Add add command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":5}}},{"hash":"632e790bd87588b55a753b76eaaf7d4dccb54216","isMergeCommit":false,"messageTitle":"Fix checkstyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":2}}},{"hash":"4b26b50b548553c814feb4174ddda85dc03134fb","isMergeCommit":false,"messageTitle":"Fix thrown exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"b61c4261525cf634b900f427e7ef9b882f00385a","isMergeCommit":false,"messageTitle":"Fix cause of date exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"bc517ce6a252ddf3a72742a4fb8ed074cc1edbfa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"865340925053b521b9d91c616f26fbc04a762ba5","isMergeCommit":false,"messageTitle":"Decouple filehandler functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":17}}},{"hash":"11d6042e07a6939cee64533690875a2366deb6c3","isMergeCommit":false,"messageTitle":"Move EntryHandler to main","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-28","commitResults":[{"hash":"4394a0a78505bbb5df96ce7ff8c65e79b82cdcbc","isMergeCommit":false,"messageTitle":"Add input prompt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"9a546b130db55a07862cad1fe776d47c1896a346","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":3}}},{"hash":"71f0a2f9adea67936991bdb756b5b4812194ec27","isMergeCommit":true,"messageTitle":"Merge pull request #84 from lctxct/add-input-prompt","messageBody":"Add input prompt","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"7566680d6432f1327c9d79e97e0fce1256f94c50","isMergeCommit":false,"messageTitle":"Modify save file formatting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":13}}},{"hash":"59f0c98600743012db13cf717d528911d49e6c87","isMergeCommit":true,"messageTitle":"Merge pull request #85 from lctxct/modify-entry-loading","messageBody":"Modify save file formatting","fileTypesAndContributionMap":{}},{"hash":"7de3fcd9415ac19f9d1ca2b45d46eebdd6e02412","isMergeCommit":false,"messageTitle":"Update to use COMMAND_WORDs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":20}}},{"hash":"8331f9b1703d24dba16d1b68cc2d6ac016086694","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"580d519c695345b4e2e4dd3bd07726093db4e73e","isMergeCommit":true,"messageTitle":"Merge pull request #86 from lctxct/add-commandwords","messageBody":"Update to use COMMAND_WORDs","fileTypesAndContributionMap":{}},{"hash":"f90e278dc3d2f920b189e66bf9b80d86cf2c0479","isMergeCommit":false,"messageTitle":"Add execute()s to commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":25}}},{"hash":"fa1e3af7807c5828627b64414f4234ab6df87908","isMergeCommit":true,"messageTitle":"Merge pull request #87 from lctxct/add-command-execute","messageBody":"Add execute()s to commands","fileTypesAndContributionMap":{}},{"hash":"314155a753a8959dc53f40c2b0301b55f4849166","isMergeCommit":false,"messageTitle":"Move routing functionality to EntryHandler","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":24}}},{"hash":"04b5df6d75fb2be3b92ae02d90f8395b6667ae16","isMergeCommit":true,"messageTitle":"Merge pull request #88 from lctxct/improve-command-routing","messageBody":"Move routing functionality to EntryHandler","fileTypesAndContributionMap":{}},{"hash":"e2a6c2099cf1ef466018515ced3c1b63431f2460","isMergeCommit":false,"messageTitle":"Add AddCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":157,"deletions":43},"test-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-30","commitResults":[{"hash":"9201e185b45bc589afa39142e7a0eaf99ed5a0a6","isMergeCommit":false,"messageTitle":"Refactor to make error handling easier","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":266,"deletions":157}}},{"hash":"b7b8ca819379bc4689adf1f1caf5225caf320110","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp into command-parsing","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b75b6da51be22ec23247af46b49dbfee87af5082","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":16}}},{"hash":"f9a5218d191bceec121f5d57b12ecda221a36c4e","isMergeCommit":false,"messageTitle":"Remove unused exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":22}}},{"hash":"b22a1af6a594eecb65d691802a7bb4ae778f8b8c","isMergeCommit":true,"messageTitle":"Merge pull request #98 from lctxct/command-parsing","messageBody":"Refactor to improve routing and error handling","fileTypesAndContributionMap":{}},{"hash":"40a684f5bac8edfe26a8b11709e3640bb32672a3","isMergeCommit":false,"messageTitle":"Move parser folder","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3},"other":{"insertions":4,"deletions":4}}},{"hash":"cf22204329a10bd53b146d6d1f5ab43d822d5c45","isMergeCommit":true,"messageTitle":"Merge pull request #102 from lctxct/move-parser-folder","messageBody":"Move parser folder","fileTypesAndContributionMap":{}},{"hash":"0fa19a043bf01c41c55bb98992ee3879675cc6cd","isMergeCommit":false,"messageTitle":"Add AddCommandParser tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":6},"test-code":{"insertions":123,"deletions":0}}},{"hash":"0e9d88e8b4b6bef4bbbc18a1f8b2e45494ae0354","isMergeCommit":true,"messageTitle":"Merge pull request #103 from lctxct/add-parser-testing","messageBody":"Add AddCommandParser tests","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"47f3bbaf4ea963d47b7c4a5f991176a43c20d504","isMergeCommit":false,"messageTitle":"Add sequence diagram for Add command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":49,"deletions":0}}},{"hash":"08365046bd6c77118881b2b436f08428d68b6aa4","isMergeCommit":true,"messageTitle":"Merge pull request #107 from lctxct/master","messageBody":"Add sequence diagram for Add command","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"b2d1e12b54842ba7f17d2a0d51f6bce5ffd39a5b","isMergeCommit":false,"messageTitle":"Add author annotations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"cd3b87477bfa2472ed9e719bff255bee0a76ae86","isMergeCommit":false,"messageTitle":"Add export csv function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":194,"deletions":2}}},{"hash":"46fc916567490c5d10e03d6cf2568f7ae05e6e0b","isMergeCommit":true,"messageTitle":"Merge pull request #117 from lctxct/master","messageBody":"Add author annotations and export function","fileTypesAndContributionMap":{}},{"hash":"2b8a46efa4a4ef7362a3e59c68bae8f173bc3167","isMergeCommit":false,"messageTitle":"Extend export to allow for column selection","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":73,"deletions":11}}},{"hash":"9e6710f6bd0f0a23c1cecb34660d3395c4022eb9","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d96f94c545ea8788a8c7916af96d0aceb0d12507","isMergeCommit":true,"messageTitle":"Merge pull request #118 from lctxct/master","messageBody":"Extend `export` to allow for column selection","fileTypesAndContributionMap":{}},{"hash":"17975a9c573ca0ba34e8380a0d51c247088c29a2","isMergeCommit":false,"messageTitle":"Improve export command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"564cef566fd34ffd4431fc8d37032f222be9b955","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"40dd6809c0f6928cfaf6c42f9bd3ee6c3a250a18","isMergeCommit":true,"messageTitle":"Merge pull request #119 from lctxct/master","messageBody":"Improve export command","fileTypesAndContributionMap":{}},{"hash":"ba9264ff19c4104c67ec84b0632be95a5944d651","isMergeCommit":false,"messageTitle":"Update error handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":17}}},{"hash":"35b039d56e1558c0b746ba42bd725c12bd55d8ee","isMergeCommit":true,"messageTitle":"Merge pull request #120 from lctxct/master","messageBody":"Update error handling","fileTypesAndContributionMap":{}},{"hash":"5365d5af8d5353c0e910876e0744744a75ee2e1e","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"893c17c2d05adf72b6599d34c03089942af1acb4","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"daa42869605542ee32a0961dbc1b01d109b1bbaa","isMergeCommit":true,"messageTitle":"Merge pull request #121 from lctxct/master","messageBody":"Fix checkstyle","fileTypesAndContributionMap":{}},{"hash":"7b91a1216db750ea01e2a0298c57af1d890420d6","isMergeCommit":false,"messageTitle":"Update AddCommandParser tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":35,"deletions":46}}},{"hash":"af33e85a203e4c2044daa738238f8e24b3faf59c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1881d9ab5342aefaea133e30119b3a2bd93cfa13","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"42b12de6d02ec5d80730b68a402497cdb6d3ca34","isMergeCommit":true,"messageTitle":"Merge pull request #122 from lctxct/master","messageBody":"Update AddCommandParser tests","fileTypesAndContributionMap":{}},{"hash":"a6ff09c548f15644f0a13065881ae78fc9d8dd4a","isMergeCommit":false,"messageTitle":"Update DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":11}}},{"hash":"4c17277c2b928a1bf8f20598685e75e1a48d3ae4","isMergeCommit":true,"messageTitle":"Merge pull request #123 from lctxct/update-dg","messageBody":"Update DG","fileTypesAndContributionMap":{}},{"hash":"e344af76321a92f6fb890cd596282ef198594c92","isMergeCommit":false,"messageTitle":"Minor fixes","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":28,"deletions":28}}},{"hash":"164fad996cc445b0a374bf26e41a19f1a79a83bc","isMergeCommit":true,"messageTitle":"Merge pull request #124 from lctxct/master","messageBody":"Minor fixes","fileTypesAndContributionMap":{}},{"hash":"687bb59ff191795b1af56431a02eb9c5231887f2","isMergeCommit":false,"messageTitle":"Add interactive add","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":112,"deletions":15}}},{"hash":"62d6e3e8dc0cce825c878a6b94a9e4fb24d57a19","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp into add-interactive-add","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"99f4429835fb03ee922ec37550f9c05ba0f5ca7b","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"3f7754d6a5e9f0b0e2b14c028a2b7fb0e5481f5d","isMergeCommit":true,"messageTitle":"Merge pull request #125 from lctxct/add-interactive-add","messageBody":"Add interactive add `add i/`","fileTypesAndContributionMap":{}},{"hash":"09e78f41e962adf8b0ff87cc6a73cfe25260be17","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":5}}},{"hash":"b6ed7cb18a5edefef013f7ad46ea4b53fb2057fe","isMergeCommit":true,"messageTitle":"Merge pull request #126 from lctxct/update-aboutus","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}},{"hash":"68926376a85d6b894377d2119e1f61e38fe490fc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":39,"deletions":13}}},{"hash":"0e6f5f9884e84289cf251eb05eb77544158a16c5","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"690fbacea15451e078ce378ffc8f15cb2c24c518","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"81318c03944c0c839045b4ce0b712dd0c1850318","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"4274d718931c45d8e2b58464f2542ee2ca0a5705","isMergeCommit":true,"messageTitle":"Merge pull request #127 from lctxct/update-ug","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}},{"hash":"163ecbdd7868b52ecc3ee3b5d09a35a5359fe5a9","isMergeCommit":false,"messageTitle":"Add newline after prompt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":0,"deletions":4}}},{"hash":"4bae0ad097720314e1ba7e12ea5adbd18219d1ba","isMergeCommit":false,"messageTitle":"Add PPP (lctxct)","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":0}}},{"hash":"076819863b8b8ae24bd987afc6cba831aeda37de","isMergeCommit":true,"messageTitle":"Merge pull request #128 from lctxct/update-aboutus","messageBody":"Minor fixes","fileTypesAndContributionMap":{}},{"hash":"b584133aad52e38bafb6f718b67243d61a14e559","isMergeCommit":false,"messageTitle":"Fix AddCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"5ec8ea88340c3855322cf5d394094e0d25833323","isMergeCommit":true,"messageTitle":"Merge pull request #129 from lctxct/master","messageBody":"Fix AddCommandParser","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"imaginarys96":{"docs":74,"functional-code":318,"test-code":7},"woodenclock":{"docs":380,"functional-code":1166,"test-code":81,"other":6},"tangzhenen":{"docs":1,"functional-code":19,"test-code":184},"lctxct":{"docs":107,"functional-code":761,"test-code":111}},"authorContributionVariance":{"imaginarys96":2756.9065,"woodenclock":75536.51,"tangzhenen":2276.233,"lctxct":25340.314},"authorDisplayNameMap":{"imaginarys96":"CS2113T-W11-2 YANG..REMY","woodenclock":"CS2113T-W11-2 LEE ..GMIN","tangzhenen":"CS2113T-W11-2 TANG..N EN","lctxct":"CS2113T-W11-2 LIEN..TING"}} +{"authorDailyContributionsMap":{"imaginarys96":[{"date":"2023-10-14","commitResults":[{"hash":"ec58ce88cfc6d13389719ba5c71f25eca9a9a801","isMergeCommit":false,"messageTitle":"Updated help command for v1 features - help, add, list, delete","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":45,"deletions":43}}},{"hash":"bf15d755cbc672977eb38b6001162424834580fc","isMergeCommit":true,"messageTitle":"Merge pull request #31 from imaginarys96/master","messageBody":"Updated help command for v1 features - help, add, list, delete","fileTypesAndContributionMap":{}}]},{"date":"2023-10-28","commitResults":[{"hash":"d99f0c79eee52e1af97c186c829392ef8e30f8aa","isMergeCommit":false,"messageTitle":"Implemented SummaryCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":80,"deletions":4}}},{"hash":"5fd5ddccef1e9c4294df3f1b749d059f20811590","isMergeCommit":true,"messageTitle":"Merge pull request #77 from imaginarys96/master","messageBody":"Implemented SummaryCommand","fileTypesAndContributionMap":{}},{"hash":"e9872b87ea07ed2f4cfae8208a6b7b9c85b19f80","isMergeCommit":false,"messageTitle":"reordered help command in UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":55,"deletions":55}}},{"hash":"4c5d7b7b18fb4ddc69c360e904b408a2dbf760d5","isMergeCommit":true,"messageTitle":"Merge pull request #78 from imaginarys96/master","messageBody":"reordered help command in UserGuide","fileTypesAndContributionMap":{}},{"hash":"8dfcebc71e11c422e383ebe2a57adf7c36d807a3","isMergeCommit":false,"messageTitle":"reordered table of contents in UserGuide","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"7f53d8a203e66ce0c1ce0ff7df0065910b5995cc","isMergeCommit":true,"messageTitle":"Merge pull request #79 from imaginarys96/master","messageBody":"reordered table of contents in UserGuide","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"b2370db38fdd6b8d98b86c2367444f6337266906","isMergeCommit":false,"messageTitle":"Implemented EditCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":93,"deletions":9}}},{"hash":"fa22d1545a218794419f1d0a67cec37502a5d8bd","isMergeCommit":false,"messageTitle":"Updated UserGuide to include summary and edit commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":60,"deletions":7}}},{"hash":"6cdbd2c30fdeef268e33fb981ecd3b576b3b2d3b","isMergeCommit":true,"messageTitle":"Merge pull request #89 from imaginarys96/master","messageBody":"Added `edit` command, updated UserGuide to include `edit` and `summary` commands","fileTypesAndContributionMap":{}},{"hash":"b26d8338e0a7b492c5168c089f28059631573218","isMergeCommit":false,"messageTitle":"fix gradle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":5}}},{"hash":"7ea0fc9a05bd1bf0189f19626dcf36b60f769d6f","isMergeCommit":true,"messageTitle":"Merge pull request #91 from imaginarys96/master","messageBody":"fix gradle errors","fileTypesAndContributionMap":{}},{"hash":"5c47056fa698a2c75cc2089a9ee983c81a3acacb","isMergeCommit":false,"messageTitle":"added edit, summary table of contents to include link to github pages. updated FAQ to have Q\u0026A on separate lines","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":4}}},{"hash":"144e360d92e10d6eadfd15dab9e913ca17060554","isMergeCommit":true,"messageTitle":"Merge pull request #92 from imaginarys96/master","messageBody":"added edit, summary table of contents to include link to github pages…","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"ebd61c62b989518b77bf393e41e2ffa1ad10b863","isMergeCommit":false,"messageTitle":"Create Sequence Diagram for HelpCommand using PlantUML (first draft -- needs to be worked on)","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":37,"deletions":0}}},{"hash":"29ca80cf78f1b9dc6b77f29d895a02b35b05175c","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"cd8dd63e045b1e3c6623202a8dbe4ca6e2d81910","isMergeCommit":false,"messageTitle":"Updated helpMessage, modified help command to display short version by default, and supports help COMMAND now","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":91,"deletions":3},"docs":{"insertions":3,"deletions":2},"test-code":{"insertions":3,"deletions":1}}},{"hash":"d37745e0f5f5308803f575a1cdd44894f7759685","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"85c2d84bff0ef537356e43487d689f23bab9b2a0","isMergeCommit":false,"messageTitle":"move HelpCommand.puml to diagrams folder","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":0}}},{"hash":"5714364c1e2e61d5ffc7ba23a3d5bc202bd1ac36","isMergeCommit":false,"messageTitle":"fix gradle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":5}}},{"hash":"d58fc7f29f2a9e6d2f5e842ae7f8c0e4c9f86881","isMergeCommit":false,"messageTitle":"modified HelpCommandTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":5,"deletions":43}}},{"hash":"e51a16243e50f480039f124a9b4d3c15b7e89aaa","isMergeCommit":false,"messageTitle":"fix gradle import error","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":1}}},{"hash":"43a667e60740c75f9a63dbd0114759c2f0e339dd","isMergeCommit":true,"messageTitle":"Merge pull request #111 from imaginarys96/master","messageBody":"Updated helpMessage, modified help command to display short version by default, and supports help COMMAND now","fileTypesAndContributionMap":{}}]},{"date":"2023-11-04","commitResults":[{"hash":"826ee91d25c39501770d3949aeb9173acbc8a4fb","isMergeCommit":false,"messageTitle":"Implement SummaryCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":63,"deletions":13}}},{"hash":"a6553d0fe3fdc74a6f84903b257ac66c0ee00d41","isMergeCommit":false,"messageTitle":"fix gradle errors","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":9}}},{"hash":"b087a3c1ec4d7d92edd28b8a68af905067b9c09b","isMergeCommit":true,"messageTitle":"Merge pull request #177 from imaginarys96/master","messageBody":"Implement SummaryCommandParser","fileTypesAndContributionMap":{}}]}],"woodenclock":[{"date":"2023-10-04","commitResults":[{"hash":"773a8e43cb56142c5789ca6965e4db2986c5c57f","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}}]},{"date":"2023-10-09","commitResults":[{"hash":"6077ba4a23bd1b9fc1e50fa53e3b872be5b6eb1e","isMergeCommit":false,"messageTitle":"Create AboutUs branch and leesungmin.md portfolio","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":7}}},{"hash":"a37fa65ccb6a1b62dfab0eb6f3457341f6d818fc","isMergeCommit":false,"messageTitle":"Update READ.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"c2fcafd4f8451047de38b018df37b1fe9c6f480a","isMergeCommit":true,"messageTitle":"Merge pull request #1 from woodenclock/LeeSungmin-AboutUs","messageBody":"Create AboutUs branch and leesungmin.md portfolio","fileTypesAndContributionMap":{}},{"hash":"3e9aca38ae0e03fd4a8ae621146d083c45409027","isMergeCommit":true,"messageTitle":"Merge branch \u0027LeeSungmin-AboutUs\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"2d4101597f24823b23a9a5ef502aef5397288f1c","isMergeCommit":false,"messageTitle":"Rename Duke.java to WildWatch.java as per out project name","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"1abb04b6249ec7daf5a386a21773f3ddb077ac18","isMergeCommit":false,"messageTitle":"Revert \"Rename Duke.java to WildWatch.java as per out project name\"","messageBody":"This reverts commit 2d4101597f24823b23a9a5ef502aef5397288f1c.\n","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"244abfa479dd4619a399297ac397592315e08604","isMergeCommit":false,"messageTitle":"Create abstract class Animal","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":18,"deletions":0}}},{"hash":"7663b3ecf3a8aa8aa508d8ca7edad59130e9c0eb","isMergeCommit":false,"messageTitle":"Rename project as WildWatch as per our project name","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":6,"deletions":6}}},{"hash":"b2e6806dddd0bf67b32c68655dd5236c7e9cc544","isMergeCommit":true,"messageTitle":"Merge pull request #4 from woodenclock/rename_project","messageBody":"Rename project from Duke to WildWatch as per our project name","fileTypesAndContributionMap":{}},{"hash":"c6242a7063a64aa4bb36350d575a875c50229edc","isMergeCommit":true,"messageTitle":"Merge branch \u0027rename_project\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"a64a4c0cab96655ea728b5ac0f2f60751c8ed5a1","isMergeCommit":false,"messageTitle":"Create BootUp.java that contains welcome logo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":77,"deletions":0}}},{"hash":"1f3d3b8c4fc84585d1699c43d127d4a36da01587","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":114,"deletions":76}}},{"hash":"fe6e136acc5d593d19301effc6cc5f2641e1947e","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":8}}},{"hash":"6c2cafbaba2f9bb015357d95eff4dfaa5f5c4a69","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":21}}},{"hash":"6cf1720e89934b3c61ab1c0d8db3a7e239eacd36","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"b348ea5c36874f96a6b46c30290db939136d88fc","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"c4fb3ba9f397df9c3454cadc898b8829dd8553db","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"32d40d3e7e7046ccc3c3e596dc7c5b0b68073947","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"bfd809b962a596b58a7fc24c27f6b244735c571b","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"936492bd4e993987c0bd1fcae321f3493ab4b91e","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"429d316db795b18efa841f79d94336cea4f40331","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"fd7bfa9b414fe7ee9bfb841d84703aaf82e6ce7c","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":52,"deletions":133},"other":{"insertions":1,"deletions":1}}},{"hash":"97689efd86b84f8ee0b3497014aea9426286baaa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into bootup","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"ac3e8877e92b18280e3cd70bdadaf9310f81dff7","isMergeCommit":true,"messageTitle":"Merge pull request #6 from woodenclock/bootup","messageBody":"Update BootUp.java to fit within 120 wordline limit","fileTypesAndContributionMap":{}},{"hash":"c06e04b29d428439ccf8b280bd26d5482c96c8d3","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"31c6d46df982c3a0688f29f473887f21dc3ba1db","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":51}}},{"hash":"c6dff4fe86a6f3264235eadf60d8443e5e8f6a19","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/bootup\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"98d77c185330d024cf1a480c1d16eb5413f0f497","isMergeCommit":true,"messageTitle":"Merge branch \u0027bootup\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"95b5f9b53ffbc9c55aa75f230a8746872f8bee4c","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027origin/bootup\u0027 into bootup","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9f4548643bc946e1e5906276338a280796b2cef9","isMergeCommit":false,"messageTitle":"Update project structure","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":39}}},{"hash":"e5a87bbe89f4a01b708f0f3327d195415909489c","isMergeCommit":true,"messageTitle":"Merge branch \u0027bootup\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"987dc591619e7c1b4cd557c06e21f6a68d607a4a","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"a5c52684a404e5205c5674689e949f782d79811c","isMergeCommit":false,"messageTitle":"Update BootUp.java to conform to coding quality","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"1f17fcaa275038ea365d6759055ab33f6c31e9aa","isMergeCommit":true,"messageTitle":"Merge pull request #12 from woodenclock/bootup","messageBody":"Update project structure","fileTypesAndContributionMap":{}},{"hash":"7145784bb155b969e48ff7e7010ea4c97c2aae75","isMergeCommit":false,"messageTitle":"Create Entry class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":2}}},{"hash":"f03352d7d7f269e18a0591384ba5a3c7cc4eb55a","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":8}}},{"hash":"96ac3b11547e3b2d2d4c6e14bdf22fd36aa76bba","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into entry","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"5dac1732ee34244d4e59bf099e9261501710087d","isMergeCommit":true,"messageTitle":"Merge pull request #13 from woodenclock/entry","messageBody":"Create Entry class","fileTypesAndContributionMap":{}},{"hash":"945347d04572d7a9a11413580262329c992f14a5","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":2},"test-code":{"insertions":4,"deletions":2}}},{"hash":"3b7a601cd1b53fc7be7a2d1bedc42310cf1649e1","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into test","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"be05363bad21706e61fab277cea8f999e2782b07","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"2e019b43aa866ada15a4ed25cd3d7885ac10cc4a","isMergeCommit":false,"messageTitle":"Create EntryList class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":0}}},{"hash":"6d3073813fb40e7d90e3ab589849963683e1189a","isMergeCommit":true,"messageTitle":"Merge pull request #14 from woodenclock/test","messageBody":"Update WildWatchTest.java","fileTypesAndContributionMap":{}},{"hash":"f774cc61af7a812a27a5b8886299f5f7b1f8868d","isMergeCommit":true,"messageTitle":"Merge pull request #15 from woodenclock/entry-list","messageBody":"Create EntryList class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-11","commitResults":[{"hash":"fb23536d544f38c73460e96a5c8bd313abdf0871","isMergeCommit":false,"messageTitle":"Update Main.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"38254679c1a734c325e5dab8dcf333beef508b93","isMergeCommit":false,"messageTitle":"Update Entry","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":4}}},{"hash":"a3e6c2fd82eac65ab404abed9a60af89969b3303","isMergeCommit":true,"messageTitle":"Merge branch \u0027test\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1bade08d80d0e3eedb5160168e9cb74b4927402d","isMergeCommit":true,"messageTitle":"Merge branch \u0027entry-list\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d0e3391ae33de9f5e0a565830ac98df6cc4f313f","isMergeCommit":true,"messageTitle":"Merge branch \u0027entry\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"4ee7626d1bc4413bf1ddef578903135c52b31969","isMergeCommit":false,"messageTitle":"Update runtest.sh","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":2,"deletions":1}}},{"hash":"9e1e349dc0473c94c82979f9b4205f2c7a5a2a0f","isMergeCommit":true,"messageTitle":"Merge pull request #17 from woodenclock/master","messageBody":"Update Main.java","fileTypesAndContributionMap":{}},{"hash":"641b2c736ec355c3848f2cbcbb041dc8338c9f26","isMergeCommit":false,"messageTitle":"Update Main.java to show welcome logo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}},{"hash":"77fe5541e59e37f74e72d91231d710d0ed696be1","isMergeCommit":false,"messageTitle":"Update Welcome Logo","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":13,"deletions":13},"other":{"insertions":1,"deletions":1}}},{"hash":"6ea49076bd57c39603afcf927bf16466cdace61a","isMergeCommit":true,"messageTitle":"Merge pull request #18 from woodenclock/master","messageBody":"Update Main.java to show welcome logo","fileTypesAndContributionMap":{}},{"hash":"68be8887d8efee36a1ef4f109533033482dcd242","isMergeCommit":false,"messageTitle":"Update BootUp.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"c2a56a8ff200897cfb897a15b2667cf694316c48","isMergeCommit":false,"messageTitle":"Merge operatingsystem and operation","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":58,"deletions":6},"other":{"insertions":1,"deletions":1}}},{"hash":"b9d4ec4398a5423e8ba4e6cff7a0e21b6703d2de","isMergeCommit":false,"messageTitle":"Create Help.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":69,"deletions":1}}},{"hash":"139ddda6ac311b9fe600964084bedc30025b5c23","isMergeCommit":false,"messageTitle":"Create Ui.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":16}}},{"hash":"aa73f36ed0f867e9cc494712264bbcf74eb20acd","isMergeCommit":false,"messageTitle":"Update runtest.bat","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"1b39f7d802f41be2b0972d434ac72ed2a5d174ea","isMergeCommit":false,"messageTitle":"Update Main.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":265,"deletions":12},"other":{"insertions":2,"deletions":2}}},{"hash":"2f5bb6fcc91de14d1cfdff6923d9cf4cbe8b586a","isMergeCommit":false,"messageTitle":"Rectify coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":7}}},{"hash":"3fe9e8732a78b643b213927cfc670a40841bc438","isMergeCommit":true,"messageTitle":"Merge pull request #19 from woodenclock/master","messageBody":"Update BootUp.java","fileTypesAndContributionMap":{}},{"hash":"768e729a01aa2ca563e5b753adfd4bb3fba53fe2","isMergeCommit":false,"messageTitle":"Create DateHandler.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":37,"deletions":9}}},{"hash":"17a55f41fb4299dbafc4a11ce5132343f647ce8e","isMergeCommit":false,"messageTitle":"Update master","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":39,"deletions":11}}},{"hash":"00f4e5be68faec38e3787643e978c85acd8a4140","isMergeCommit":false,"messageTitle":"Update DateHandler.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-12","commitResults":[{"hash":"854362b0cb347d3eef09cff390a2bc1ece81a933","isMergeCommit":false,"messageTitle":"Create UiTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":7,"deletions":7},"test-code":{"insertions":23,"deletions":5}}},{"hash":"9219e532962e466897da973e62b635128a9537d7","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":6,"deletions":1}}},{"hash":"000704a61d0cf556f3659838c9f483cf4dc327b9","isMergeCommit":false,"messageTitle":"Update WildWatchTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":1,"deletions":2}}},{"hash":"3bd708d0dc25b88e7467f88ebf02c13d04fad21a","isMergeCommit":true,"messageTitle":"Merge pull request #24 from woodenclock/JUnit","messageBody":"Create DateHandler.java","fileTypesAndContributionMap":{}},{"hash":"9269539e2e1b215c6abe2ce8299598f2ac7bbfc9","isMergeCommit":false,"messageTitle":"Update master","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":9},"test-code":{"insertions":23,"deletions":1}}},{"hash":"ec828890f2b2e762697dc08f3c59345057a75d6b","isMergeCommit":false,"messageTitle":"Update JUnit Testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"21885dd84c3a1eb10fc873bea34312d6cd5d3908","isMergeCommit":false,"messageTitle":"Create DateHandlerTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":2},"test-code":{"insertions":45,"deletions":4}}},{"hash":"e62a99b83b1a86695fdd408c40fa647c6d55c395","isMergeCommit":false,"messageTitle":"Update JUnit Testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":1}}},{"hash":"a42c135198681cfb760500a9fb570cf655900b15","isMergeCommit":false,"messageTitle":"Update JUnit Testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":33}}},{"hash":"34c204943b75d986f3434990cc8a2a0d51785428","isMergeCommit":true,"messageTitle":"Merge pull request #26 from woodenclock/JUnit","messageBody":"Update JUnit Testing","fileTypesAndContributionMap":{}},{"hash":"f89a3376b6128b40c6fb6a0ac87ae67433c69718","isMergeCommit":false,"messageTitle":"Update master branch","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":3},"test-code":{"insertions":30,"deletions":24}}}]},{"date":"2023-10-13","commitResults":[{"hash":"04bfb9cdcbb0e565b7728dff4ef37b9900ecaf01","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"c41766f63af1deec7f34501671e4ce7797dd8a7e","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"0824e77a201a68175ae07a2bd651b9a28d77bfae","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"155b4a5313622cf619386de79dac55fd1e6511d2","isMergeCommit":false,"messageTitle":"Update Team","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":6}}}]},{"date":"2023-10-14","commitResults":[{"hash":"a6771c27f6f02e0b583eab8a6b8b084dc2e2b613","isMergeCommit":true,"messageTitle":"Merge pull request #30 from tangzhenen/DeleteCommand","messageBody":"Delete command ","fileTypesAndContributionMap":{}},{"hash":"66a8c9a6cd5cac707a4f960ee6afbc999ae363dd","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"00c2201381e98033b496951aac6812238b46249b","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"7aa2d2e9e23cbaaa7c4d183901c9a80aeb4a050e","isMergeCommit":false,"messageTitle":"Delete docs/team/johndoe.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":6}}}]},{"date":"2023-10-15","commitResults":[{"hash":"d224fc9b93a7ab109c4bc7789325449fa98c4b31","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"610129370f63512b2b17ef46b9e9e9bba81ea8f2","isMergeCommit":false,"messageTitle":"Update ErrorHandler to be more defensive when handling invalid command input for delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":21}}},{"hash":"b0b42fe5a3c45ea96b5cb9f0231b763009ce75b1","isMergeCommit":false,"messageTitle":"Update Helper to HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":8},"other":{"insertions":2,"deletions":2}}},{"hash":"6fb4e2fce4321f4b3390687233fed35eaf984f33","isMergeCommit":true,"messageTitle":"Merge pull request #29 from woodenclock/master","messageBody":"Update docs/team","fileTypesAndContributionMap":{}}]},{"date":"2023-10-16","commitResults":[{"hash":"450da925b330879ecf333b82d2f23dd01f0ba7cf","isMergeCommit":true,"messageTitle":"Merge pull request #32 from lctxct/master","messageBody":"Add add command","fileTypesAndContributionMap":{}},{"hash":"cca01ddd9bafcd73bab5601d937d80176c768a4c","isMergeCommit":false,"messageTitle":"Add assertions for Parser.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":15,"deletions":10},"other":{"insertions":1,"deletions":0}}},{"hash":"be31165e3f29da49d974c06bfe456d9a86e14d5e","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 into JUnit","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"46279ea4c95f206dddb4e551a2e1dbe2db2adc83","isMergeCommit":false,"messageTitle":"Update error handling to be more resilient","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":33,"deletions":19},"other":{"insertions":1,"deletions":1}}},{"hash":"7b23c414b16f87663f8d9ac8cbc379596256f30c","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":7}}},{"hash":"6bd0efebc07159b11dc261fff9f34374aba05eec","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":12,"deletions":5}}},{"hash":"115693537e993d70f89024842dd6e170d584bf15","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"other":{"insertions":1,"deletions":1}}},{"hash":"463587f2747ec71359e71c28e88259af383f0d2d","isMergeCommit":false,"messageTitle":"Update ErrorHandler.java to be more defensive","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"other":{"insertions":1,"deletions":1}}},{"hash":"62cdd84658d7065539c5f991671b99913c12e384","isMergeCommit":false,"messageTitle":"Update Assertions and Logging for ErrorHandler.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":1}}},{"hash":"16b0525ef78374b54dc7b6b5e274909efef28325","isMergeCommit":true,"messageTitle":"Merge branch \u0027JUnit\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"9bff5d167f55af981c3a47361f0ddd243349ef7e","isMergeCommit":false,"messageTitle":"Update gitignore","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":0}}},{"hash":"976434bb6d811e51a8be416ce003b805086dd8cc","isMergeCommit":true,"messageTitle":"Merge pull request #33 from woodenclock/JUnit","messageBody":"Add Assertions\u0026Logging for Parser.java \u0026 ErrorHandler.java","fileTypesAndContributionMap":{}},{"hash":"9cab20433568b43e3f97459a5abd399dc9d95fd6","isMergeCommit":false,"messageTitle":"Update to conform coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":4}}}]},{"date":"2023-10-18","commitResults":[{"hash":"1304354f67117f4b44f29fb50d395bff627f33ef","isMergeCommit":true,"messageTitle":"Merge pull request #35 from woodenclock/master","messageBody":"Create LogHandler.java","tags":["v1.0"],"fileTypesAndContributionMap":{}},{"hash":"f2bf7121a54988b8aae718966e9936168a1f78c9","isMergeCommit":false,"messageTitle":"Update HelpCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":26}}},{"hash":"a775e5d8540fe1662258e81878bde359b7389aab","isMergeCommit":true,"messageTitle":"Merge pull request #37 from lctxct/master","messageBody":"Trim add command attributes","fileTypesAndContributionMap":{}},{"hash":"517a582de13b8da9c01cb9560e57eeb9cb900e04","isMergeCommit":true,"messageTitle":"Merge pull request #38 from woodenclock/master","messageBody":"Update HelpCommand","fileTypesAndContributionMap":{}}]},{"date":"2023-10-21","commitResults":[{"hash":"3ba93ef829aeb9749839687d188d1e98665dcaf1","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"88f1e79af130134d0e69cd5fc8ac3f4ee7ba4250","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"1e3ece0f8c482bc9b9d69e58d5dfa1ec8bf9c719","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"4be4b3bc4c835b3f228e6664f56f7c45fc5b6929","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"7afb1c9045252a235b022ba229fba2f424758d0d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"a28bd140e9ef8dd83c307f1dd2cbaf6a85324c55","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"1452811275c11a608f8c8efecf997fffbe3fe359","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":2}}},{"hash":"6d645b691a546bc05707102ae2165ae79c140b68","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":0}}}]},{"date":"2023-10-22","commitResults":[{"hash":"931a82be6bb9716fce842f07f2a0634891c8d723","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"fc1314dd5fd8272f25bb0f0c4062ab3ef124c3d4","isMergeCommit":false,"messageTitle":"Create FileHandler class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":262,"deletions":69},"other":{"insertions":24,"deletions":13}}},{"hash":"49953cd354913432aa4e3ae852bd71aa269bb5b2","isMergeCommit":false,"messageTitle":"Update to conform to coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":4}}},{"hash":"cdf125e1beca7bb3a4063330b725d59205edc5b2","isMergeCommit":true,"messageTitle":"Merge pull request #43 from woodenclock/feature/file-handler","messageBody":"Create FileHandler class","fileTypesAndContributionMap":{}},{"hash":"b8b831fd2eee00070db0641f2d18c427da06ae7e","isMergeCommit":false,"messageTitle":"Update HandlerTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":46,"deletions":4}}}]},{"date":"2023-10-25","commitResults":[{"hash":"71c60292bc89991caef1a3695436d09286562b0e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":132,"deletions":22}}},{"hash":"801e5200abe33a244de96df8786e2dbe7bfe8f46","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"de00a3076eb5eba44e4dcb92c1147683139bd577","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":6}}},{"hash":"a88ab74d5e7f56c212d229a48c3d1f69f4de57ad","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":8}}},{"hash":"8efa46d48a1f2460f950d0163096e1ed33dfb996","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":1}}},{"hash":"d62b0808a95f7e76fa753f360612e07f9e3104cd","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"70351e139f405fe75afebae3532b13cee21ac57f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"7212664e4176144796e87e3434f4ddd17759744d","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"999431233aacdb145349641f962902670d3956bc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":25,"deletions":13}}},{"hash":"8523bb7ed471238502b710348b84528fd6da0c94","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"6300da7aa03d3bd34ee1cef1ac57da6cd146ee0e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"79ec23b44f524a07a16aa79097b4a71d4d5a361c","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"73c201d8f89d41325b3a74d623526c2b59ee31ee","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":7}}},{"hash":"fa7c26d503410ebeed06981e77762afd8973d192","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"1c91472ae7643a1e14d269f55a9b64be4e5b32d9","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"9e9fd85fe63e51e4f72921b8e924a9f22962e1e8","isMergeCommit":true,"messageTitle":"Merge pull request #44 from lctxct/decouple-filehandler","messageBody":"Decouple filehandler","fileTypesAndContributionMap":{}},{"hash":"9113b6d5796af11bb360ce27272ce4a43233193a","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1b69d279c88f149ead8710f208e350f538cb7a7d","isMergeCommit":false,"messageTitle":"Decouple the InputHandler class from EntryHandler class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":60,"deletions":47},"test-code":{"insertions":15,"deletions":33}}},{"hash":"2855de5b8de26166236c54831261d772078f2896","isMergeCommit":false,"messageTitle":"Create FindComamand Operation class","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":78,"deletions":3}}},{"hash":"f9c00b1fc91dabeaea48bcf7b66939df2a5cadc0","isMergeCommit":false,"messageTitle":"Fixed bug in FindCommand","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":16,"deletions":7}}},{"hash":"a2fef8e3b29c5a04fbe63d90fbef45e22fb3039d","isMergeCommit":false,"messageTitle":"Update to conform to coding standards","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"4dcafe9b3f12f35844fdae882657ff74e7ff973c","isMergeCommit":false,"messageTitle":"Delete EntryHandlerTest.java","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":0,"deletions":35}}},{"hash":"4d2cf0c635b94b39afd5686685817389a8f7a11f","isMergeCommit":true,"messageTitle":"Merge pull request #45 from woodenclock/master","messageBody":"Decouple the InputHandler class from EntryHandler class","fileTypesAndContributionMap":{}}]},{"date":"2023-10-26","commitResults":[{"hash":"d1790785abfc81cd517c6a30ae354f83829f31b3","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"f14878ef43b32d4f6ace8902a325b3d0f673cc65","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"fc7c5b14c74f279c9949f6a0c75adbd57fe64add","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"ef087c4e7da75d66c8ddb2bfe7fdbb7fbc43fc85","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":4}}},{"hash":"594921c73d45b19c90ee33995dacd59893d330c9","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"e4a22d783560b1ed2f05ce2d7475a1de8240abdc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"5a1e50d52da7261382aaf1afff40e2dd41dd18b6","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"9d8b5f5499e762f794e8e4a9546a3ab5abac8c64","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b1a6375766d87c2cb0ee8f581008919daf1597fb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"1e48ee6e8ccb0f62d4986a65d48f952d5abc08ad","isMergeCommit":false,"messageTitle":"Update FindCommand.java, erased print used for debugging","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":4}}},{"hash":"5bc23eba9fb6ccbf703de844153e9d8a70326f49","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"2aabe5252b8721b13c6f1bc01343f366c7d4bba0","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"5b144293727c9669eef4fb7a3fb130262de7dc77","isMergeCommit":true,"messageTitle":"Merge pull request #47 from woodenclock/master","messageBody":"Update FindCommand.java, erased print used for debugging","fileTypesAndContributionMap":{}}]},{"date":"2023-10-27","commitResults":[{"hash":"57ea655be0101904e4e4896a56d269eb269d5659","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"9d5948c7728238f746ab462036e8e7228052fd03","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"c91cdfa7f37882e01a42b7c55cc1cd84bbc75bee","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"e8a7f527f27279ffc60b7044e6c6490253813216","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"2d94603aaf7ac8b4268f03c0727a9f069f989d45","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"16a5a67761528c9b8fbe8648b51df1ff88e64704","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"74787f82bda0e7105cf06e16571b87d8dbf03b55","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-28","commitResults":[{"hash":"6ce9fbaa24fdd842c8f291108986b2deac66553a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":8}}},{"hash":"eb0321b813089f0868700ccc31bb5438385f7ce7","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"d80b65a2c7a0e70d829823382e7b7a7c3e36cde2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":22}}}]},{"date":"2023-10-29","commitResults":[{"hash":"ce4fcce49515f712cf651b6eecbb20dd61571cef","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":1}}},{"hash":"611a90c0c6fd9da1d06889d18dbb296cdeac2c6b","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"2eac7e89b4fed923b03fcada875c4be390c53a60","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":3}}},{"hash":"a14b8b479b1006cc4d0aa7618e9a36324737a973","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":2}}},{"hash":"181ad4cb23ddc381e4e2a29efc3bdb9c63a413e8","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e1080b16b1e920bbc2abb08d554b8ba251104dce","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"2597af2a2f0e64029f5480e4326f93117bbf6af5","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"2ae2724282d1109842a73b773892eb3a07e573ca","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":4}}},{"hash":"8d9383af337d9471ed9a049aab43bb8ac12c1aa7","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"060385fd1e89ec1a4729a5dbd533f1b9f4f608e4","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"073a4ec309a9d9008fdab4b5f106a50761797fed","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":7,"deletions":71}}},{"hash":"a9eb2742b0b5f8cc3f8d284f714496f3b0fa9730","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"76bb482a8343fce5d1d158b0ce7e21f852a58141","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"2345e47ffc5eb68f8197b68a7b1665ed961835fb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":14}}},{"hash":"e89f82832e022ae7c468b919e083722c59abebf2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"50bdcd1c15c534c15a4eeaf9d8daa35f0a210426","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6d81e802214fa27ed2d28e36f2d9ca53888ca912","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"6c00c908a887a0c8992443e7bdb240362efeb426","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"651039e21d0b65fe705af36b25f647e8fb56f054","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"70cc7886454dd7ba9a79eba19b4b8a56b9c9201f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"58842c5494dc812495e8bbfe34d22d213114215c","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"9c6571ba3ce9c6ad1ec531daf4aecc56cb171351","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b01023f7a8aa1c8bb26f59ceb0103cb8e34b2456","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":2}}},{"hash":"72fb57b99c225cc3897679785e4efdec99ce5060","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":1}}},{"hash":"a947305e86c2914fa7875290926c682a676a485b","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"2f7520d069bfc07162a715eb4c3cb1d596122597","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"163f996f0404d39155c01eddbbced0794592605b","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":3}}},{"hash":"ac83aa125df999e0b0619336f401ca3fad7e5495","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"1205b0fd11249db616a705a739936d38d5b8a02b","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"f35c6acfd6a7325d24e7eed72a409a83f412d5dc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"df487785b54bf1a14003b3de8a1f1ef2fb8c37a2","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":3}}},{"hash":"f266228b0a2c6f7b009d15956cdd31ee930f0ffb","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"b59f34187079ec906132e0281e33061260c03259","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":3}}},{"hash":"6f268e710f65006826bf9e9aa6c114ad00e4b976","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"6eec5bad8d3db469c47df5c937821f6228a45e86","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e203ad818030487b48ff07d998aa4313a965d2bd","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":7}}},{"hash":"65d6b05a1cd59431924a51c1ab2c7aa5003cf731","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"93cccaccfec882329c3008f9cb3f86626b1e13d3","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":5}}},{"hash":"9ab358dea1759da20e17f6e69afa226a9ce3f4c0","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"59d29f98700b1c20d3bd76807074d011fc163c91","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":6}}},{"hash":"21adb7eb14887f7a43ad1fe69039db0627306e87","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"8eb136dd8247e797cb702261f987fe5a55a0663f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b0f714da3077dff001078572afa19c6105538437","isMergeCommit":false,"messageTitle":"Create ByeCommandTest.java","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"test-code":{"insertions":0,"deletions":0}}},{"hash":"a853fe4ad9734a26cd67884fcf2edbbd604ddf82","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":2}}},{"hash":"7578737d271c9ff421224e23b2de063bc8cbd1f5","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":4}}},{"hash":"87aaf65189640f6b9b97ce46d2e133a0d4626713","isMergeCommit":false,"messageTitle":"Delete ByeCommandTest","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":25,"deletions":7},"test-code":{"insertions":0,"deletions":0}}},{"hash":"1b3cffa905b350db82491dfae33c8535d5e56530","isMergeCommit":true,"messageTitle":"Merge pull request #96 from woodenclock/master","messageBody":"Create ByeCommandTest.java","fileTypesAndContributionMap":{}},{"hash":"d8ab73416e2eead55c3bb2d0229df9bdd86d707f","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":2}}},{"hash":"b4eb9042ebebf577e7d91ae043a9e4515b90256e","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"9872e9287dfacb27feb7ff47d5102e5abb54873a","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"5549e41d14b7ed410337651d7180e6bb68156cea","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":41,"deletions":12}}},{"hash":"57f7664df8c710b8732bfd7bc8deb3b37a743631","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"9af0aa0b63b439cd2d603ea8ff478881814a853d","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":19,"deletions":19}}},{"hash":"25889acdac7630a56075f0afe7249a8492279445","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":26,"deletions":3}}},{"hash":"384b78c6a79bcba376d376e84b096cca7d540806","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"19ae2556bccf3f607148d54a17387e6a2b72a3fa","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a8bbfe87e249d519ddb832ca7f5619a1ebc9ffe7","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":2}}},{"hash":"b2071b21ed984093067e28c63e012629e88bc64b","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":8,"deletions":9}}},{"hash":"7fe21c9b0d08cd1451d79b62f8088d2145836c31","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":9}}}]},{"date":"2023-10-30","commitResults":[{"hash":"1e03e48232c16bcd0cd2507d625e3889b35f89ce","isMergeCommit":false,"messageTitle":"Update Reposense","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"92d47ff54422abda7071b09304cfca9b55586e34","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/wildwatch/operation/ErrorHandler.java\n","fileTypesAndContributionMap":{}},{"hash":"3b729c1cf742ca2c715cdd1d19c0f277b84135fe","isMergeCommit":false,"messageTitle":"Merge upstream with local master","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":102,"deletions":111},"other":{"insertions":1,"deletions":1},"test-code":{"insertions":10,"deletions":10}}},{"hash":"f668a078b4c7883a4a776e9ecef08e0ce532a7ba","isMergeCommit":false,"messageTitle":"Update InvalidInputException","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5}}},{"hash":"75141f277c5dc949f8b6167f39ec4bfc791d2490","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"23194774e29d414825cfc3b1be77d53a8d318c9e","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"22bfec4d00cd65d98739279245627a571cb47aa4","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":21}}},{"hash":"361d61b097d10749d5d5eaf4817fe817369307cc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e9082feac8de5c808b3170706aadda982dc2ed40","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"3fddd71f0d125ad1b85f54ae648373365d319977","isMergeCommit":false,"messageTitle":"Update according to Muzfirah\u0027s comments","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":42,"deletions":15}}},{"hash":"258be3c7b7069964accd8dd2a6a77cd14a8e10a3","isMergeCommit":false,"messageTitle":"Update OOP according to comments from Muzfirah","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":36,"deletions":21}}},{"hash":"0e0d206704f6cedd1af1787d3c34f5e1cf3a5608","isMergeCommit":true,"messageTitle":"Merge pull request #104 from woodenclock/master","messageBody":"Merge upstream with local master","fileTypesAndContributionMap":{}},{"hash":"fc60829de540dd1b7be647e086ce3e0de8bd78df","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":14,"deletions":0}}},{"hash":"07676f9067a1a3fffd63be03106edda08fef05da","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"737c4c4415c885e09a4351031ce872af2d57ed9d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"e86c9b1234cdc3d713f24bd59d87267ce06e32c0","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"a1a6584851e8c3014b127d038fa4d1a05929e7b9","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":30,"deletions":1}}},{"hash":"40b6e657a713f16e30eeb8777192dc8725a6da5a","isMergeCommit":false,"messageTitle":"Add assertions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"c82844d21bad59d72108e785b8a243bf1e5c5db9","isMergeCommit":false,"messageTitle":"Update assertions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":0}}},{"hash":"cd7d08344498c709858dd31a7efa80fc8f525136","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-31","commitResults":[{"hash":"2a0119be88d84e990c211468a5bba841c3af0694","isMergeCommit":false,"messageTitle":"Create storage package","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":2},"other":{"insertions":4,"deletions":1},"test-code":{"insertions":53,"deletions":0}}},{"hash":"d0a44ea3dd7b6aa6d8b4810e7b3b1ecd0c749ecf","isMergeCommit":false,"messageTitle":"Update ExistenceChecker","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":27,"deletions":22}}},{"hash":"a48d8b80280b6073d2d47549838a2db123e4285b","isMergeCommit":false,"messageTitle":"Fix bug: FileStringParser could not extract the data in isolation without whitespaces","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":7}}},{"hash":"5afaaaf26cf0a38eb9a6ffcd77fba2f5a11c1fa0","isMergeCommit":false,"messageTitle":"Fix bug: CommandHandler ending the program after one command.","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":5}}},{"hash":"2e6199f6af080633c4322f1d650eb3b66af6e7f3","isMergeCommit":false,"messageTitle":"Fix bug: InputHandler only saves if bye command is used","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":10}}},{"hash":"a550344bdd5065ca60c426554223fc0570ccc044","isMergeCommit":false,"messageTitle":"Rename IncorrectInputException to InvalidInputException","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":4}}},{"hash":"da1fe3dc4f841e75f2294ae4343a802f7d75a51f","isMergeCommit":false,"messageTitle":"Update EntryHandlerTest","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":8,"deletions":8}}},{"hash":"ce73c6760c837468f6c7b089fcf3dbc0db66fb9c","isMergeCommit":false,"messageTitle":"Update testDeleteEntryWithValidNumber() such that there will always be at least one entry","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"a457678375ce83faf6b9133ecca035626c00b285","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"a5bc7655db9137b9b4b84c99432b0c74aa9ef66b","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":3}}},{"hash":"02fedc9b4b67eaeddb42591c98ce0bbb46369068","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"45bf883e16ca960eb9ec3d04304f975b7867352e","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":1}}},{"hash":"b8e44e0109364d120209150e09fadcbd4c0613a4","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":3}}},{"hash":"d6875ce5af653a63d4d04617ebf7191f7d8f1bcd","isMergeCommit":false,"messageTitle":"Update README.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":56}}},{"hash":"a931a53e1423163a6c50dcbab2fd623e90e285ed","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":27,"deletions":2}}},{"hash":"0c05e4fed8d8072d489d4931d6670163dcec0813","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"11cb55fe4cc5cd1dc63216ab0c5e55e2227d68ef","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":3}}},{"hash":"989d7656ce99c64ca6e42cdf5890e8ff3398fec4","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b61c04bb0d03740c2db170ec9d34d5d8621ff168","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"3a140c9f3d5b6e5094661ab332786c4b0d42c0d3","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"c476bab6888227ba3fe403dc9e4a6fedeeb20212","isMergeCommit":false,"messageTitle":"Separate out FileHandler, more OOP!","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":34,"deletions":22}}},{"hash":"87b79fd563f839c65b00a3ce471f9692389acabc","isMergeCommit":false,"messageTitle":"Remove unsed imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":0,"deletions":5}}},{"hash":"741ab79b0a537ccfdecf736d1ebcbf0e25005dbe","isMergeCommit":true,"messageTitle":"Merge pull request #106 from woodenclock/master","messageBody":"Separate out FileHandler, more OOP!","fileTypesAndContributionMap":{}},{"hash":"bbd95d48246ee6bedbe1e0a378f21ed048e23078","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"f911b393a0c2fc061947ee3db60e061754395d65","isMergeCommit":false,"messageTitle":"Separate out FileCreater class, more OOP!","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":31,"deletions":18}}},{"hash":"8a04291513bafe71d291396b6d37535d48ed6d50","isMergeCommit":false,"messageTitle":"Create FindCommandParser class This class checks if the find command is valid","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":156,"deletions":202},"other":{"insertions":25,"deletions":12},"test-code":{"insertions":7,"deletions":6}}},{"hash":"1f4d35158c7585f0ed4d7fc4f3a17534a6b0286f","isMergeCommit":false,"messageTitle":"Delete unused imports","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":5}}},{"hash":"e17831122b9ad078c3c154ef3f5d6e48fec9c7ac","isMergeCommit":false,"messageTitle":"Fix indentation error","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"c6cfde1441e05d11f5c2dedaca1f7ecf5199b0a6","isMergeCommit":true,"messageTitle":"Merge pull request #112 from woodenclock/master","messageBody":"Separate out FileCreater class, more OOP!","fileTypesAndContributionMap":{}},{"hash":"391ba5fff7a6c45291a524ed837ea18a87762c03","isMergeCommit":false,"messageTitle":"Organize all classes into their respective packages for modularity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":22},"other":{"insertions":40,"deletions":36},"test-code":{"insertions":1,"deletions":1}}},{"hash":"76c556e252c27e271bee09cd3b543affb521c774","isMergeCommit":false,"messageTitle":"Separate Ui class, more OOP!","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":331,"deletions":284},"test-code":{"insertions":3,"deletions":3}}},{"hash":"af7851b847d205bc674060a5eaa0528bbdc65e65","isMergeCommit":true,"messageTitle":"Merge pull request #113 from woodenclock/master","messageBody":"Organize all classes into their respective packages for modularity","fileTypesAndContributionMap":{}},{"hash":"1c48c26527b76117c8acc0bd227d72500d6b9636","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":3}}},{"hash":"020d80d2c015174c2a7a15ec358bcf5e543ed52e","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"71f63eecdeca0ab5a168277da13cd71a285deb23","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":1}}},{"hash":"60ad02fa704deb527f3725d4681279a3ff33ce5c","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"b6e4667c249d5d19e6766e7dd26b417fa58e961d","isMergeCommit":false,"messageTitle":"Rename classes for better clarity","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"other":{"insertions":7,"deletions":7}}},{"hash":"3e4b3a7579fb7700773a1254624f847c39ca32df","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":1}}},{"hash":"1b438e1071ac559e3e6da1ec41dfb81d72a6e4cb","isMergeCommit":true,"messageTitle":"Merge pull request #114 from woodenclock/master","messageBody":"Rename classes for better clarity","fileTypesAndContributionMap":{}},{"hash":"9184989f3c288fb984c5ca2c72d5519cabf6a818","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":11}}}]},{"date":"2023-11-03","commitResults":[{"hash":"8b2fb828588543cfab47a4a32d62bb615df000c9","isMergeCommit":false,"messageTitle":"Create EditCommandParser class for more robust exception handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":148,"deletions":68},"docs":{"insertions":3,"deletions":3}}},{"hash":"e4d616a6b2651f5783e47652c0e3944c421fde1a","isMergeCommit":true,"messageTitle":"Merge remote-tracking branch \u0027upstream/master\u0027","messageBody":"# Conflicts:\n#\tsrc/main/java/seedu/wildwatch/error/ErrorChecker.java\n#\tsrc/main/java/seedu/wildwatch/error/ErrorHandler.java\n#\tsrc/main/java/seedu/wildwatch/error/InvalidInputErrorType.java\n#\tsrc/main/java/seedu/wildwatch/parser/AddCommandParser.java\n","fileTypesAndContributionMap":{}},{"hash":"f79ae464e2ff6ed71d2d94a92f4b0126f2e512c6","isMergeCommit":true,"messageTitle":"Merge pull request #130 from woodenclock/master","messageBody":"Create EditCommandParser class for more robust exception handling","fileTypesAndContributionMap":{}},{"hash":"0809353b57b8bccb052fa8a0c057ba130ad7dcf9","isMergeCommit":false,"messageTitle":"Rename ErrorChecker to Router","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":11,"deletions":16},"other":{"insertions":3,"deletions":3},"test-code":{"insertions":8,"deletions":7}}},{"hash":"36b9d921980c8d34c2b8ae64767553edffc19621","isMergeCommit":false,"messageTitle":"Update EditCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":1}}},{"hash":"358ba67653a7b08c01668e4e33d2be2afd0aeb25","isMergeCommit":true,"messageTitle":"Merge pull request #131 from woodenclock/master","messageBody":"Rename ErrorChecker to Router","tags":["v2.0"],"fileTypesAndContributionMap":{}},{"hash":"d496982423df331d938cb22e862ebbf938dc53b8","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"a77f806d6298dfd0fa03544eec7a9aefb1362e13","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":4}}},{"hash":"0c1c30c5c48aa1232a2301aafc1426f9c491777a","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":18}}},{"hash":"937b554599dc7a1f4aba9da218179709346b26f8","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-04","commitResults":[{"hash":"72996885a31f6849bae96ff23d7b1417cb915d4c","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"518a3cb23b8a68586a01be985ec0cdf219bcc615","isMergeCommit":false,"messageTitle":"Update lctxct.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":2}}},{"hash":"289bb4a6b6f0fdbfcd9abbf66eb5906655262fd7","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":1}}},{"hash":"22a9b1cffd520b0416332da91ea8c4c42f23c004","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":10,"deletions":4}}},{"hash":"6e6fbac476d11163975a8e1c78d938d096254b3e","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":1}}},{"hash":"43b7482b646c13ab7ca7be7c8b4f05993cf6dcdc","isMergeCommit":false,"messageTitle":"Update leesungmin.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"aaf2a21527fa5bdece3ec64e83845200b5195689","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}}]},{"date":"2023-11-05","commitResults":[{"hash":"41ad698faa1c3def4745d99e0d1832a03aa3a158","isMergeCommit":false,"messageTitle":"Rename leesungmin.md to woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":0}}},{"hash":"744e95e917d66c6e9530b9c5ddd1dedff0a5029f","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":17,"deletions":6}}},{"hash":"7da0e50ef42299bd9e6e6f92903f49e65fe632f6","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":2}}},{"hash":"7015a4750c5a2aae473ab895d6a0315b676eb07b","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":12,"deletions":8}}},{"hash":"6584c89158e71add1e5835b8353c3c805e912020","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":0,"deletions":2}}},{"hash":"7248f3e21fce14aac73f737291a8ad242f67e4f5","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":6,"deletions":2}}},{"hash":"1b1ba181e0deea60872804cdd36178001d819acf","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"e2ccfc716cc22326330b8b0f79848bcf6317b15d","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"4ccedf15a22bcbbd5aa8299d71e2a0aa0fba090b","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"d87b58b43f87a6da45b96643122db75902d6d0cd","isMergeCommit":false,"messageTitle":"Update DeveloperGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"7b021c7f7cc609644e0ceaa100ad7953e300a8f2","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":3}}},{"hash":"d29dcdea52a8e9bea9ba4fcbc2a238d6a84fdb42","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":3,"deletions":2}}},{"hash":"621c403aa431f23347fd2222bc9099d54d154778","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":2,"deletions":1}}},{"hash":"f623a485b76f9465bc1ef76754b4e1bc890326eb","isMergeCommit":false,"messageTitle":"Update woodenclock.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":11,"deletions":1}}}]}],"tangzhenen":[{"date":"2023-10-13","commitResults":[{"hash":"533b7989a5a1ab5bb5320352563ef8ec26703a36","isMergeCommit":false,"messageTitle":"Add delete command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":19,"deletions":4}}},{"hash":"5a8687f571cd1e27f76be6509dbe561301672ebf","isMergeCommit":false,"messageTitle":"Update entry list","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":0}}},{"hash":"972d977c09e7acc98f20d0f7126538392192348f","isMergeCommit":false,"messageTitle":"Update Ui","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":1}}},{"hash":"3d2b111b51993622d4ee5a3533f64719aa479814","isMergeCommit":false,"messageTitle":"Bug fixes","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":9,"deletions":2}}},{"hash":"3294660fadf18a4228e61b926bdb7d1374e63746","isMergeCommit":false,"messageTitle":"Bug fix","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1}}}]},{"date":"2023-10-29","commitResults":[{"hash":"9e176d18484505711f4040c5ed8c19799c56ef32","isMergeCommit":false,"messageTitle":"update aboutUs","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":5,"deletions":5}}},{"hash":"a4b0f1a8ed42cdc2230395cdad3661cdef7bc58e","isMergeCommit":false,"messageTitle":"Delete command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":10,"deletions":3},"test-code":{"insertions":39,"deletions":0}}},{"hash":"65c3f395560267925a4062ef616a8f407780d2d7","isMergeCommit":false,"messageTitle":"Add list command test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":62,"deletions":0}}},{"hash":"458f95225ed5fb0c085a998a5adb432be8b44179","isMergeCommit":false,"messageTitle":"Add help command test","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":76,"deletions":0}}},{"hash":"82a3b7fa9bd659457daad31eeb4b376f1d0c7182","isMergeCommit":false,"messageTitle":"Add user confirmation when deleting entry","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":26,"deletions":4}}},{"hash":"e4790ccd72b01c5b9bdc81cc5fd387ccd5e6aff2","isMergeCommit":false,"messageTitle":"update delete command testing","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":57,"deletions":12}}},{"hash":"374462d22c6457e37185fcf96f1c36e2ffae575c","isMergeCommit":false,"messageTitle":"update delete command test","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"test-code":{"insertions":6,"deletions":2}}},{"hash":"b599f17afa22d30fe0febf5b8fc691a410d52090","isMergeCommit":false,"messageTitle":"bug fixes","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":3,"deletions":2}}},{"hash":"e428fd3e5b4c0f5cbd78b932042185ce11b4738a","isMergeCommit":false,"messageTitle":"bug fix","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":2}}},{"hash":"3844616655c954f11c64374fa2e382e065580c39","isMergeCommit":true,"messageTitle":"Merge pull request #97 from tangzhenen/master","messageBody":"Add testing for list, delete, help and extend delete command","fileTypesAndContributionMap":{}}]}],"lctxct":[{"date":"2023-10-16","commitResults":[{"hash":"c0a6facf1ef9e936416052a7d76eaf23255016fd","isMergeCommit":false,"messageTitle":"Add add command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":5}}},{"hash":"632e790bd87588b55a753b76eaaf7d4dccb54216","isMergeCommit":false,"messageTitle":"Fix checkstyle violations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":2}}},{"hash":"4b26b50b548553c814feb4174ddda85dc03134fb","isMergeCommit":false,"messageTitle":"Fix thrown exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}},{"hash":"b61c4261525cf634b900f427e7ef9b882f00385a","isMergeCommit":false,"messageTitle":"Fix cause of date exception","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"bc517ce6a252ddf3a72742a4fb8ed074cc1edbfa","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp","messageBody":"","fileTypesAndContributionMap":{}}]},{"date":"2023-10-23","commitResults":[{"hash":"865340925053b521b9d91c616f26fbc04a762ba5","isMergeCommit":false,"messageTitle":"Decouple filehandler functions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":40,"deletions":17}}},{"hash":"11d6042e07a6939cee64533690875a2366deb6c3","isMergeCommit":false,"messageTitle":"Move EntryHandler to main","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":2,"deletions":1}}}]},{"date":"2023-10-28","commitResults":[{"hash":"4394a0a78505bbb5df96ce7ff8c65e79b82cdcbc","isMergeCommit":false,"messageTitle":"Add input prompt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":0}}},{"hash":"9a546b130db55a07862cad1fe776d47c1896a346","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":5,"deletions":3}}},{"hash":"71f0a2f9adea67936991bdb756b5b4812194ec27","isMergeCommit":true,"messageTitle":"Merge pull request #84 from lctxct/add-input-prompt","messageBody":"Add input prompt","fileTypesAndContributionMap":{}}]},{"date":"2023-10-29","commitResults":[{"hash":"7566680d6432f1327c9d79e97e0fce1256f94c50","isMergeCommit":false,"messageTitle":"Modify save file formatting","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":22,"deletions":13}}},{"hash":"59f0c98600743012db13cf717d528911d49e6c87","isMergeCommit":true,"messageTitle":"Merge pull request #85 from lctxct/modify-entry-loading","messageBody":"Modify save file formatting","fileTypesAndContributionMap":{}},{"hash":"7de3fcd9415ac19f9d1ca2b45d46eebdd6e02412","isMergeCommit":false,"messageTitle":"Update to use COMMAND_WORDs","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":47,"deletions":20}}},{"hash":"8331f9b1703d24dba16d1b68cc2d6ac016086694","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":4,"deletions":2}}},{"hash":"580d519c695345b4e2e4dd3bd07726093db4e73e","isMergeCommit":true,"messageTitle":"Merge pull request #86 from lctxct/add-commandwords","messageBody":"Update to use COMMAND_WORDs","fileTypesAndContributionMap":{}},{"hash":"f90e278dc3d2f920b189e66bf9b80d86cf2c0479","isMergeCommit":false,"messageTitle":"Add execute()s to commands","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":49,"deletions":25}}},{"hash":"fa1e3af7807c5828627b64414f4234ab6df87908","isMergeCommit":true,"messageTitle":"Merge pull request #87 from lctxct/add-command-execute","messageBody":"Add execute()s to commands","fileTypesAndContributionMap":{}},{"hash":"314155a753a8959dc53f40c2b0301b55f4849166","isMergeCommit":false,"messageTitle":"Move routing functionality to EntryHandler","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":41,"deletions":24}}},{"hash":"04b5df6d75fb2be3b92ae02d90f8395b6667ae16","isMergeCommit":true,"messageTitle":"Merge pull request #88 from lctxct/improve-command-routing","messageBody":"Move routing functionality to EntryHandler","fileTypesAndContributionMap":{}},{"hash":"e2a6c2099cf1ef466018515ced3c1b63431f2460","isMergeCommit":false,"messageTitle":"Add AddCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":157,"deletions":43},"test-code":{"insertions":3,"deletions":3}}}]},{"date":"2023-10-30","commitResults":[{"hash":"9201e185b45bc589afa39142e7a0eaf99ed5a0a6","isMergeCommit":false,"messageTitle":"Refactor to make error handling easier","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":266,"deletions":157}}},{"hash":"b7b8ca819379bc4689adf1f1caf5225caf320110","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp into command-parsing","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"b75b6da51be22ec23247af46b49dbfee87af5082","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":20,"deletions":16}}},{"hash":"f9a5218d191bceec121f5d57b12ecda221a36c4e","isMergeCommit":false,"messageTitle":"Remove unused exceptions","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":22}}},{"hash":"b22a1af6a594eecb65d691802a7bb4ae778f8b8c","isMergeCommit":true,"messageTitle":"Merge pull request #98 from lctxct/command-parsing","messageBody":"Refactor to improve routing and error handling","fileTypesAndContributionMap":{}},{"hash":"40a684f5bac8edfe26a8b11709e3640bb32672a3","isMergeCommit":false,"messageTitle":"Move parser folder","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3},"other":{"insertions":4,"deletions":4}}},{"hash":"cf22204329a10bd53b146d6d1f5ab43d822d5c45","isMergeCommit":true,"messageTitle":"Merge pull request #102 from lctxct/move-parser-folder","messageBody":"Move parser folder","fileTypesAndContributionMap":{}},{"hash":"0fa19a043bf01c41c55bb98992ee3879675cc6cd","isMergeCommit":false,"messageTitle":"Add AddCommandParser tests","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":48,"deletions":6},"test-code":{"insertions":123,"deletions":0}}},{"hash":"0e9d88e8b4b6bef4bbbc18a1f8b2e45494ae0354","isMergeCommit":true,"messageTitle":"Merge pull request #103 from lctxct/add-parser-testing","messageBody":"Add AddCommandParser tests","fileTypesAndContributionMap":{}}]},{"date":"2023-11-01","commitResults":[{"hash":"47f3bbaf4ea963d47b7c4a5f991176a43c20d504","isMergeCommit":false,"messageTitle":"Add sequence diagram for Add command","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":49,"deletions":0}}},{"hash":"08365046bd6c77118881b2b436f08428d68b6aa4","isMergeCommit":true,"messageTitle":"Merge pull request #107 from lctxct/master","messageBody":"Add sequence diagram for Add command","fileTypesAndContributionMap":{}}]},{"date":"2023-11-02","commitResults":[{"hash":"b2d1e12b54842ba7f17d2a0d51f6bce5ffd39a5b","isMergeCommit":false,"messageTitle":"Add author annotations","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":6,"deletions":0}}},{"hash":"cd3b87477bfa2472ed9e719bff255bee0a76ae86","isMergeCommit":false,"messageTitle":"Add export csv function","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":194,"deletions":2}}},{"hash":"46fc916567490c5d10e03d6cf2568f7ae05e6e0b","isMergeCommit":true,"messageTitle":"Merge pull request #117 from lctxct/master","messageBody":"Add author annotations and export function","fileTypesAndContributionMap":{}},{"hash":"2b8a46efa4a4ef7362a3e59c68bae8f173bc3167","isMergeCommit":false,"messageTitle":"Extend export to allow for column selection","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":73,"deletions":11}}},{"hash":"9e6710f6bd0f0a23c1cecb34660d3395c4022eb9","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"d96f94c545ea8788a8c7916af96d0aceb0d12507","isMergeCommit":true,"messageTitle":"Merge pull request #118 from lctxct/master","messageBody":"Extend `export` to allow for column selection","fileTypesAndContributionMap":{}},{"hash":"17975a9c573ca0ba34e8380a0d51c247088c29a2","isMergeCommit":false,"messageTitle":"Improve export command","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":14,"deletions":9}}},{"hash":"564cef566fd34ffd4431fc8d37032f222be9b955","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"40dd6809c0f6928cfaf6c42f9bd3ee6c3a250a18","isMergeCommit":true,"messageTitle":"Merge pull request #119 from lctxct/master","messageBody":"Improve export command","fileTypesAndContributionMap":{}},{"hash":"ba9264ff19c4104c67ec84b0632be95a5944d651","isMergeCommit":false,"messageTitle":"Update error handling","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":8,"deletions":17}}},{"hash":"35b039d56e1558c0b746ba42bd725c12bd55d8ee","isMergeCommit":true,"messageTitle":"Merge pull request #120 from lctxct/master","messageBody":"Update error handling","fileTypesAndContributionMap":{}},{"hash":"5365d5af8d5353c0e910876e0744744a75ee2e1e","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":0}}},{"hash":"893c17c2d05adf72b6599d34c03089942af1acb4","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"daa42869605542ee32a0961dbc1b01d109b1bbaa","isMergeCommit":true,"messageTitle":"Merge pull request #121 from lctxct/master","messageBody":"Fix checkstyle","fileTypesAndContributionMap":{}},{"hash":"7b91a1216db750ea01e2a0298c57af1d890420d6","isMergeCommit":false,"messageTitle":"Update AddCommandParser tests","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":35,"deletions":46}}},{"hash":"af33e85a203e4c2044daa738238f8e24b3faf59c","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"1881d9ab5342aefaea133e30119b3a2bd93cfa13","isMergeCommit":true,"messageTitle":"Merge branch \u0027AY2324S1-CS2113T-W11-2:master\u0027 into master","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"42b12de6d02ec5d80730b68a402497cdb6d3ca34","isMergeCommit":true,"messageTitle":"Merge pull request #122 from lctxct/master","messageBody":"Update AddCommandParser tests","fileTypesAndContributionMap":{}},{"hash":"a6ff09c548f15644f0a13065881ae78fc9d8dd4a","isMergeCommit":false,"messageTitle":"Update DG","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":36,"deletions":11}}},{"hash":"4c17277c2b928a1bf8f20598685e75e1a48d3ae4","isMergeCommit":true,"messageTitle":"Merge pull request #123 from lctxct/update-dg","messageBody":"Update DG","fileTypesAndContributionMap":{}},{"hash":"e344af76321a92f6fb890cd596282ef198594c92","isMergeCommit":false,"messageTitle":"Minor fixes","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":28,"deletions":28}}},{"hash":"164fad996cc445b0a374bf26e41a19f1a79a83bc","isMergeCommit":true,"messageTitle":"Merge pull request #124 from lctxct/master","messageBody":"Minor fixes","fileTypesAndContributionMap":{}},{"hash":"687bb59ff191795b1af56431a02eb9c5231887f2","isMergeCommit":false,"messageTitle":"Add interactive add","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":112,"deletions":15}}},{"hash":"62d6e3e8dc0cce825c878a6b94a9e4fb24d57a19","isMergeCommit":true,"messageTitle":"Merge branch \u0027master\u0027 of github.com:lctxct/tp into add-interactive-add","messageBody":"","fileTypesAndContributionMap":{}},{"hash":"99f4429835fb03ee922ec37550f9c05ba0f5ca7b","isMergeCommit":false,"messageTitle":"Fix checkstyle","messageBody":"","fileTypesAndContributionMap":{"test-code":{"insertions":2,"deletions":1}}},{"hash":"3f7754d6a5e9f0b0e2b14c028a2b7fb0e5481f5d","isMergeCommit":true,"messageTitle":"Merge pull request #125 from lctxct/add-interactive-add","messageBody":"Add interactive add `add i/`","fileTypesAndContributionMap":{}},{"hash":"09e78f41e962adf8b0ff87cc6a73cfe25260be17","isMergeCommit":false,"messageTitle":"Update AboutUs.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":9,"deletions":5}}},{"hash":"b6ed7cb18a5edefef013f7ad46ea4b53fb2057fe","isMergeCommit":true,"messageTitle":"Merge pull request #126 from lctxct/update-aboutus","messageBody":"Update AboutUs.md","fileTypesAndContributionMap":{}},{"hash":"68926376a85d6b894377d2119e1f61e38fe490fc","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":39,"deletions":13}}},{"hash":"0e6f5f9884e84289cf251eb05eb77544158a16c5","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"690fbacea15451e078ce378ffc8f15cb2c24c518","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":1}}},{"hash":"81318c03944c0c839045b4ce0b712dd0c1850318","isMergeCommit":false,"messageTitle":"Update UserGuide.md","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":1,"deletions":0}}},{"hash":"4274d718931c45d8e2b58464f2542ee2ca0a5705","isMergeCommit":true,"messageTitle":"Merge pull request #127 from lctxct/update-ug","messageBody":"Update UserGuide.md","fileTypesAndContributionMap":{}},{"hash":"163ecbdd7868b52ecc3ee3b5d09a35a5359fe5a9","isMergeCommit":false,"messageTitle":"Add newline after prompt","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":1,"deletions":1},"docs":{"insertions":0,"deletions":4}}},{"hash":"4bae0ad097720314e1ba7e12ea5adbd18219d1ba","isMergeCommit":false,"messageTitle":"Add PPP (lctxct)","messageBody":"","fileTypesAndContributionMap":{"docs":{"insertions":4,"deletions":0}}},{"hash":"076819863b8b8ae24bd987afc6cba831aeda37de","isMergeCommit":true,"messageTitle":"Merge pull request #128 from lctxct/update-aboutus","messageBody":"Minor fixes","fileTypesAndContributionMap":{}},{"hash":"b584133aad52e38bafb6f718b67243d61a14e559","isMergeCommit":false,"messageTitle":"Fix AddCommandParser","messageBody":"","fileTypesAndContributionMap":{"functional-code":{"insertions":3,"deletions":3}}},{"hash":"5ec8ea88340c3855322cf5d394094e0d25833323","isMergeCommit":true,"messageTitle":"Merge pull request #129 from lctxct/master","messageBody":"Fix AddCommandParser","fileTypesAndContributionMap":{}}]}]},"authorFileTypeContributionMap":{"imaginarys96":{"docs":74,"functional-code":318,"test-code":7},"woodenclock":{"docs":419,"functional-code":1166,"test-code":81,"other":6},"tangzhenen":{"docs":1,"functional-code":19,"test-code":184},"lctxct":{"docs":107,"functional-code":761,"test-code":111}},"authorContributionVariance":{"imaginarys96":2702.418,"woodenclock":73894.14,"tangzhenen":2227.1284,"lctxct":24824.502},"authorDisplayNameMap":{"imaginarys96":"CS2113T-W11-2 YANG..REMY","woodenclock":"CS2113T-W11-2 LEE ..GMIN","tangzhenen":"CS2113T-W11-2 TANG..N EN","lctxct":"CS2113T-W11-2 LIEN..TING"}} diff --git a/archive.zip b/archive.zip index 71fd7e4..0928b9d 100644 Binary files a/archive.zip and b/archive.zip differ diff --git a/reposense-logs/reposense.log.0 b/reposense-logs/reposense.log.0 index 4067345..b52cfa2 100644 --- a/reposense-logs/reposense.log.0 +++ b/reposense-logs/reposense.log.0 @@ -1,24 +1,24 @@ -Nov 04, 2023 2:21:26 PM reposense.system.LogsManager addFileHandler +Nov 05, 2023 12:09:45 AM reposense.system.LogsManager addFileHandler INFO: Log temp folder has been successfully created -Nov 04, 2023 2:21:27 PM reposense.parser.CsvParser validateHeader +Nov 05, 2023 12:09:45 AM reposense.parser.CsvParser validateHeader INFO: Parsed header of CSV file, repo-config.csv, and recognized columns: Ignore Standalone Config, Repository's Location, Branch, Shallow Cloning, File formats, Ignore Glob List, Ignore Authors List, Find Previous Authors, Ignore Commits List -Nov 04, 2023 2:21:27 PM reposense.parser.CsvParser validateHeader +Nov 05, 2023 12:09:45 AM reposense.parser.CsvParser validateHeader INFO: Parsed header of CSV file, author-config.csv, and recognized columns: Author's Emails, Repository's Location, Author's GitHub ID, Branch, Author's Display Name, Ignore Glob List, Author's Git Author Name -Nov 04, 2023 2:21:27 PM reposense.model.AuthorConfiguration checkDuplicateAliases +Nov 05, 2023 12:09:45 AM reposense.model.AuthorConfiguration checkDuplicateAliases WARNING: Duplicate alias choonsiang found. The alias will belong to the last author - ChoonSiang -Nov 04, 2023 2:21:27 PM reposense.model.AuthorConfiguration checkDuplicateAliases +Nov 05, 2023 12:09:45 AM reposense.model.AuthorConfiguration checkDuplicateAliases WARNING: Duplicate alias barbaracwx found. The alias will belong to the last author - Barbaracwx -Nov 04, 2023 2:21:27 PM reposense.model.AuthorConfiguration checkDuplicateAliases +Nov 05, 2023 12:09:45 AM reposense.model.AuthorConfiguration checkDuplicateAliases WARNING: Duplicate alias oppa1 found. The alias will belong to the last author - MrOPPA1 -Nov 04, 2023 2:21:27 PM reposense.model.AuthorConfiguration checkDuplicateAliases +Nov 05, 2023 12:09:45 AM reposense.model.AuthorConfiguration checkDuplicateAliases WARNING: Duplicate alias choonsiang found. The alias will belong to the last author - ChoonSiang -Nov 04, 2023 2:21:27 PM reposense.model.AuthorConfiguration checkDuplicateAliases +Nov 05, 2023 12:09:45 AM reposense.model.AuthorConfiguration checkDuplicateAliases WARNING: Duplicate alias barbaracwx found. The alias will belong to the last author - Barbaracwx -Nov 04, 2023 2:21:27 PM reposense.model.AuthorConfiguration checkDuplicateAliases +Nov 05, 2023 12:09:45 AM reposense.model.AuthorConfiguration checkDuplicateAliases WARNING: Duplicate alias oppa1 found. The alias will belong to the last author - MrOPPA1 -Nov 04, 2023 2:21:27 PM reposense.parser.CsvParser validateHeader +Nov 05, 2023 12:09:45 AM reposense.parser.CsvParser validateHeader INFO: Parsed header of CSV file, group-config.csv, and recognized columns: Globs, Repository's Location, Group Name -Nov 04, 2023 2:21:27 PM reposense.git.GitConfig getGlobalGitLfsConfig +Nov 05, 2023 12:09:45 AM reposense.git.GitConfig getGlobalGitLfsConfig WARNING: Could not get global git lfs config java.lang.RuntimeException: reposense.system.CommandRunnerProcessException: Error returned from command git config --global --list on path . : fatal: unable to read config file '/home/runner/.gitconfig': No such file or directory @@ -34,313 +34,313 @@ fatal: unable to read config file '/home/runner/.gitconfig': No such file or dir at reposense.system.CommandRunner.runCommand(CommandRunner.java:21) ... 3 more -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T17-3/tp.git... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-W12-4/tp.git... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner spawnCloneProcess -INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T17-4/tp.git... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-W12-2/tp.git... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner spawnCloneProcess +INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T17-4/tp.git... +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-W12-4/tp.git to complete... +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T17-4/tp.git to complete... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T17-3/tp.git to complete... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-W12-2/tp.git to complete... -Nov 04, 2023 2:21:27 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-W12-4/tp.git to complete... -Nov 04, 2023 2:21:28 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Cloning of https://github.com/AY2324S1-CS2113-W12-2/tp.git completed! -Nov 04, 2023 2:21:28 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T17-3/tp.git to complete... +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-W12-4/tp.git completed! -Nov 04, 2023 2:21:28 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T18-1/tp.git... -Nov 04, 2023 2:21:28 PM reposense.report.RepoCloner spawnCloneProcess -INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-F11-3/tp.git... -Nov 04, 2023 2:21:28 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.ReportGenerator analyzeRepos +INFO: [1/17] Analyzing https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T18-1/tp.git to complete... -Nov 04, 2023 2:21:28 PM reposense.report.ReportGenerator analyzeRepos -INFO: [1/17] Analyzing https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... -Nov 04, 2023 2:21:28 PM reposense.report.ReportGenerator analyzeRepos -INFO: [2/17] Analyzing https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... -Nov 04, 2023 2:21:28 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-F11-3/tp.git to complete... -Nov 04, 2023 2:21:28 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:46 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-W12-4/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:28 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:46 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... -Nov 04, 2023 2:21:28 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Cloning of https://github.com/AY2324S1-CS2113-W12-2/tp.git completed! +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner spawnCloneProcess +INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-F11-3/tp.git... +Nov 05, 2023 12:09:46 AM reposense.report.ReportGenerator analyzeRepos +INFO: [2/17] Analyzing https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-F11-3/tp.git to complete... +Nov 05, 2023 12:09:46 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-W12-2/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:28 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:46 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Cloning of https://github.com/AY2324S1-CS2113-T17-3/tp.git completed! -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-T18-1/tp.git completed! -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:46 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-F11-3/tp.git completed! -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-W12-1/tp.git... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.ReportGenerator analyzeRepos +INFO: [3/17] Analyzing https://github.com/AY2324S1-CS2113-F11-3/tp.git (master)... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-W12-3/tp.git... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner spawnCloneProcess -INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T18-2/tp.git... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-W12-1/tp.git to complete... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T18-2/tp.git to complete... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.ReportGenerator analyzeRepos +INFO: [4/17] Analyzing https://github.com/AY2324S1-CS2113-T18-1/tp.git (master)... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Cloning of https://github.com/AY2324S1-CS2113-T17-3/tp.git completed! +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-W12-3/tp.git to complete... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-W12-1/tp.git to complete... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-T17-4/tp.git completed! -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.ReportGenerator updateRepoConfig +INFO: https://github.com/AY2324S1-CS2113-F11-3/tp.git (master) does not contain a standalone config file. +Nov 05, 2023 12:09:47 AM reposense.authorship.FileInfoExtractor extractTextFileInfos +INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-F11-3/tp.git (master)... +Nov 05, 2023 12:09:47 AM reposense.report.ReportGenerator updateRepoConfig +INFO: https://github.com/AY2324S1-CS2113-T18-1/tp.git (master) does not contain a standalone config file. +Nov 05, 2023 12:09:47 AM reposense.authorship.FileInfoExtractor extractTextFileInfos +INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T18-1/tp.git (master)... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess +INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T18-2/tp.git... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T18-2/tp.git to complete... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T18-3/tp.git... -Nov 04, 2023 2:21:29 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T18-3/tp.git to complete... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-W12-3/tp.git completed! -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Cloning of https://github.com/AY2324S1-CS2113-T18-3/tp.git completed! -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113T-W11-1/tp.git... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner spawnCloneProcess -INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T18-4/tp.git... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-W12-1/tp.git completed! -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113T-W11-1/tp.git to complete... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner spawnCloneProcess -INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-F11-1/tp.git... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T18-4/tp.git to complete... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Cloning of https://github.com/AY2324S1-CS2113-T18-3/tp.git completed! +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess +INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T18-4/tp.git... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-T18-2/tp.git completed! -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-F11-1/tp.git to complete... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess +INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-F11-1/tp.git... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-F11-2/tp.git... -Nov 04, 2023 2:21:30 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-F11-1/tp.git to complete... +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-F11-2/tp.git to complete... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:47 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T18-4/tp.git to complete... +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-T18-4/tp.git completed! -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Cloning of https://github.com/AY2324S1-CS2113-F11-1/tp.git completed! -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113T-W11-1/tp.git completed! -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Cloning of https://github.com/AY2324S1-CS2113-F11-1/tp.git completed! +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T17-2/tp.git... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113T-W11-2/tp.git... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner spawnCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner spawnCloneProcess INFO: Cloning in parallel from https://github.com/AY2324S1-CS2113-T17-1/tp.git... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T17-2/tp.git to complete... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Cloning of https://github.com/AY2324S1-CS2113-F11-2/tp.git completed! +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113T-W11-2/tp.git to complete... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T17-1/tp.git to complete... -Nov 04, 2023 2:21:31 PM reposense.report.RepoCloner waitForCloneProcess -INFO: Cloning of https://github.com/AY2324S1-CS2113-F11-2/tp.git completed! -Nov 04, 2023 2:21:31 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... -Nov 04, 2023 2:21:31 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... -Nov 04, 2023 2:21:32 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... -Nov 04, 2023 2:21:32 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess +INFO: Waiting for cloning of https://github.com/AY2324S1-CS2113-T17-2/tp.git to complete... +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113T-W11-2/tp.git completed! -Nov 04, 2023 2:21:32 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-T17-1/tp.git completed! -Nov 04, 2023 2:21:32 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-2/tp.git (master) completed! -Nov 04, 2023 2:21:32 PM reposense.report.ReportGenerator analyzeRepos -INFO: [3/17] Analyzing https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... -Nov 04, 2023 2:21:32 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... -Nov 04, 2023 2:21:32 PM reposense.report.RepoCloner waitForCloneProcess +Nov 05, 2023 12:09:48 AM reposense.report.RepoCloner waitForCloneProcess INFO: Cloning of https://github.com/AY2324S1-CS2113-T17-2/tp.git completed! -Nov 04, 2023 2:21:32 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-4/tp.git (master) completed! -Nov 04, 2023 2:21:32 PM reposense.report.ReportGenerator analyzeRepos -INFO: [4/17] Analyzing https://github.com/AY2324S1-CS2113-F11-3/tp.git (master)... -Nov 04, 2023 2:21:32 PM reposense.report.ReportGenerator updateRepoConfig -INFO: https://github.com/AY2324S1-CS2113-T17-3/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:32 PM reposense.authorship.FileInfoExtractor extractTextFileInfos -INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... -Nov 04, 2023 2:21:32 PM reposense.report.ReportGenerator updateRepoConfig -INFO: https://github.com/AY2324S1-CS2113-F11-3/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:32 PM reposense.authorship.FileInfoExtractor extractTextFileInfos -INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-F11-3/tp.git (master)... -Nov 04, 2023 2:21:33 PM reposense.commits.CommitInfoExtractor extractCommitInfos +Nov 05, 2023 12:09:48 AM reposense.commits.CommitInfoExtractor extractCommitInfos INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-F11-3/tp.git (master)... -Nov 04, 2023 2:21:34 PM reposense.commits.CommitInfoAnalyzer analyzeCommits +Nov 05, 2023 12:09:48 AM reposense.commits.CommitInfoAnalyzer analyzeCommits INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-F11-3/tp.git (master)... -Nov 04, 2023 2:21:34 PM reposense.report.ReportGenerator analyzeRepo +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepo INFO: Analysis of https://github.com/AY2324S1-CS2113-F11-3/tp.git (master) completed! -Nov 04, 2023 2:21:34 PM reposense.report.ReportGenerator analyzeRepos -INFO: [5/17] Analyzing https://github.com/AY2324S1-CS2113-T18-1/tp.git (master)... -Nov 04, 2023 2:21:34 PM reposense.report.ReportGenerator updateRepoConfig -INFO: https://github.com/AY2324S1-CS2113-T18-1/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:34 PM reposense.authorship.FileInfoExtractor extractTextFileInfos -INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T18-1/tp.git (master)... -Nov 04, 2023 2:21:34 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... -Nov 04, 2023 2:21:34 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... -Nov 04, 2023 2:21:34 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-T17-3/tp.git (master) completed! -Nov 04, 2023 2:21:34 PM reposense.report.ReportGenerator analyzeRepos -INFO: [6/17] Analyzing https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... -Nov 04, 2023 2:21:35 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepos +INFO: [5/17] Analyzing https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-T17-4/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:35 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:49 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... -Nov 04, 2023 2:21:35 PM reposense.commits.CommitInfoExtractor extractCommitInfos +Nov 05, 2023 12:09:49 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.commits.CommitInfoExtractor extractCommitInfos INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-1/tp.git (master)... -Nov 04, 2023 2:21:35 PM reposense.commits.CommitInfoAnalyzer analyzeCommits +Nov 05, 2023 12:09:49 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-2/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-4/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-2/tp.git (master) completed! +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepos +INFO: [6/17] Analyzing https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.commits.CommitInfoAnalyzer analyzeCommits INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-1/tp.git (master)... -Nov 04, 2023 2:21:35 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-1/tp.git (master) completed! -Nov 04, 2023 2:21:35 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-4/tp.git (master) completed! +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepos INFO: [7/17] Analyzing https://github.com/AY2324S1-CS2113-W12-3/tp.git (master)... -Nov 04, 2023 2:21:35 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator updateRepoConfig +INFO: https://github.com/AY2324S1-CS2113-T17-3/tp.git (master) does not contain a standalone config file. +Nov 05, 2023 12:09:49 AM reposense.authorship.FileInfoExtractor extractTextFileInfos +INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-1/tp.git (master) completed! +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator analyzeRepos +INFO: [8/17] Analyzing https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-W12-3/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:35 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:49 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-W12-3/tp.git (master)... -Nov 04, 2023 2:21:36 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... -Nov 04, 2023 2:21:36 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... -Nov 04, 2023 2:21:36 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-T17-4/tp.git (master) completed! -Nov 04, 2023 2:21:36 PM reposense.report.ReportGenerator analyzeRepos -INFO: [8/17] Analyzing https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... -Nov 04, 2023 2:21:36 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:49 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-T18-3/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:36 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:49 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... -Nov 04, 2023 2:21:36 PM reposense.commits.CommitInfoExtractor extractCommitInfos +Nov 05, 2023 12:09:50 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... +Nov 05, 2023 12:09:50 AM reposense.commits.CommitInfoExtractor extractCommitInfos INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-3/tp.git (master)... -Nov 04, 2023 2:21:37 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-3/tp.git (master)... -Nov 04, 2023 2:21:37 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-3/tp.git (master) completed! -Nov 04, 2023 2:21:37 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:50 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T17-4/tp.git (master)... +Nov 05, 2023 12:09:50 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-T17-4/tp.git (master) completed! +Nov 05, 2023 12:09:50 AM reposense.report.ReportGenerator analyzeRepos INFO: [9/17] Analyzing https://github.com/AY2324S1-CS2113-W12-1/tp.git (master)... -Nov 04, 2023 2:21:37 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:50 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-W12-1/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:37 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:50 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-W12-1/tp.git (master)... -Nov 04, 2023 2:21:37 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... -Nov 04, 2023 2:21:37 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... -Nov 04, 2023 2:21:37 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-3/tp.git (master) completed! -Nov 04, 2023 2:21:38 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:50 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-3/tp.git (master)... +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-3/tp.git (master) completed! +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator analyzeRepos INFO: [10/17] Analyzing https://github.com/AY2324S1-CS2113-T18-2/tp.git (master)... -Nov 04, 2023 2:21:38 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-T18-2/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:38 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:51 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T18-2/tp.git (master)... -Nov 04, 2023 2:21:38 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-1/tp.git (master)... -Nov 04, 2023 2:21:38 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-1/tp.git (master)... -Nov 04, 2023 2:21:38 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-1/tp.git (master) completed! -Nov 04, 2023 2:21:38 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:51 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... +Nov 05, 2023 12:09:51 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-3/tp.git (master)... +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-3/tp.git (master) completed! +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator analyzeRepos INFO: [11/17] Analyzing https://github.com/AY2324S1-CS2113-T18-4/tp.git (master)... -Nov 04, 2023 2:21:38 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-T18-4/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:38 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:51 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T18-4/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-4/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-4/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-4/tp.git (master) completed! -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:51 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... +Nov 05, 2023 12:09:51 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T17-3/tp.git (master)... +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-T17-3/tp.git (master) completed! +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator analyzeRepos INFO: [12/17] Analyzing https://github.com/AY2324S1-CS2113-F11-1/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:51 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-F11-1/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:39 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:51 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-F11-1/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-2/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-2/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-2/tp.git (master) completed! -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:51 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-4/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-W12-1/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-4/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-4/tp.git (master) completed! +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepos INFO: [13/17] Analyzing https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:39 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:52 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-F11-1/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-F11-1/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-F11-1/tp.git (master) completed! -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-W12-1/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-W12-1/tp.git (master) completed! +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepos INFO: [14/17] Analyzing https://github.com/AY2324S1-CS2113-F11-2/tp.git (master)... -Nov 04, 2023 2:21:39 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-F11-2/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:39 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:52 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-F11-2/tp.git (master)... -Nov 04, 2023 2:21:40 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master)... -Nov 04, 2023 2:21:40 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master)... -Nov 04, 2023 2:21:40 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master) completed! -Nov 04, 2023 2:21:40 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T18-2/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-F11-1/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-F11-1/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-F11-1/tp.git (master) completed! +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepos INFO: [15/17] Analyzing https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master)... -Nov 04, 2023 2:21:40 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:40 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:52 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master)... -Nov 04, 2023 2:21:40 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-F11-2/tp.git (master)... -Nov 04, 2023 2:21:41 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-F11-2/tp.git (master)... -Nov 04, 2023 2:21:41 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113-F11-2/tp.git (master) completed! -Nov 04, 2023 2:21:41 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:52 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T18-2/tp.git (master)... +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-T18-2/tp.git (master) completed! +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator analyzeRepos INFO: [16/17] Analyzing https://github.com/AY2324S1-CS2113-T17-1/tp.git (master)... -Nov 04, 2023 2:21:41 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:52 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-T17-1/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:41 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:52 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T17-1/tp.git (master)... -Nov 04, 2023 2:21:41 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master)... -Nov 04, 2023 2:21:42 PM reposense.commits.CommitInfoAnalyzer analyzeCommits -INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master)... -Nov 04, 2023 2:21:42 PM reposense.report.ReportGenerator analyzeRepo -INFO: Analysis of https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master) completed! -Nov 04, 2023 2:21:42 PM reposense.report.ReportGenerator analyzeRepos +Nov 05, 2023 12:09:53 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master)... +Nov 05, 2023 12:09:53 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master)... +Nov 05, 2023 12:09:53 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113T-W11-1/tp.git (master) completed! +Nov 05, 2023 12:09:53 AM reposense.report.ReportGenerator analyzeRepos INFO: [17/17] Analyzing https://github.com/AY2324S1-CS2113-T17-2/tp.git (master)... -Nov 04, 2023 2:21:42 PM reposense.report.ReportGenerator updateRepoConfig +Nov 05, 2023 12:09:53 AM reposense.report.ReportGenerator updateRepoConfig INFO: https://github.com/AY2324S1-CS2113-T17-2/tp.git (master) does not contain a standalone config file. -Nov 04, 2023 2:21:42 PM reposense.authorship.FileInfoExtractor extractTextFileInfos +Nov 05, 2023 12:09:53 AM reposense.authorship.FileInfoExtractor extractTextFileInfos INFO: Extracting relevant file info from https://github.com/AY2324S1-CS2113-T17-2/tp.git (master)... -Nov 04, 2023 2:21:42 PM reposense.commits.CommitInfoExtractor extractCommitInfos +Nov 05, 2023 12:09:53 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-F11-2/tp.git (master)... +Nov 05, 2023 12:09:53 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master)... +Nov 05, 2023 12:09:53 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-F11-2/tp.git (master)... +Nov 05, 2023 12:09:53 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113-F11-2/tp.git (master) completed! +Nov 05, 2023 12:09:53 AM reposense.commits.CommitInfoAnalyzer analyzeCommits +INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master)... +Nov 05, 2023 12:09:53 AM reposense.report.ReportGenerator analyzeRepo +INFO: Analysis of https://github.com/AY2324S1-CS2113T-W11-2/tp.git (master) completed! +Nov 05, 2023 12:09:54 AM reposense.commits.CommitInfoExtractor extractCommitInfos INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-1/tp.git (master)... -Nov 04, 2023 2:21:43 PM reposense.commits.CommitInfoAnalyzer analyzeCommits +Nov 05, 2023 12:09:54 AM reposense.commits.CommitInfoExtractor extractCommitInfos +INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-2/tp.git (master)... +Nov 05, 2023 12:09:54 AM reposense.commits.CommitInfoAnalyzer analyzeCommits INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T17-1/tp.git (master)... -Nov 04, 2023 2:21:43 PM reposense.report.ReportGenerator analyzeRepo +Nov 05, 2023 12:09:54 AM reposense.report.ReportGenerator analyzeRepo INFO: Analysis of https://github.com/AY2324S1-CS2113-T17-1/tp.git (master) completed! -Nov 04, 2023 2:21:43 PM reposense.commits.CommitInfoExtractor extractCommitInfos -INFO: Extracting commits info for https://github.com/AY2324S1-CS2113-T17-2/tp.git (master)... -Nov 04, 2023 2:21:43 PM reposense.commits.CommitInfoAnalyzer analyzeCommits +Nov 05, 2023 12:09:54 AM reposense.commits.CommitInfoAnalyzer analyzeCommits INFO: Analyzing commits info for https://github.com/AY2324S1-CS2113-T17-2/tp.git (master)... -Nov 04, 2023 2:21:43 PM reposense.report.ReportGenerator analyzeRepo +Nov 05, 2023 12:09:54 AM reposense.report.ReportGenerator analyzeRepo INFO: Analysis of https://github.com/AY2324S1-CS2113-T17-2/tp.git (master) completed! -Nov 04, 2023 2:21:43 PM reposense.report.ReportGenerator generateReposReport +Nov 05, 2023 12:09:54 AM reposense.report.ReportGenerator generateReposReport INFO: The report is generated at /home/runner/work/tp-dashboard/tp-dashboard/reposense-report -Nov 04, 2023 2:21:44 PM reposense.RepoSense main -INFO: Elapsed processing time: 17.13 second(s) +Nov 05, 2023 12:09:54 AM reposense.RepoSense main +INFO: Elapsed processing time: 9.04 second(s) diff --git a/summary.json b/summary.json index 8cc248b..a4f27ca 100644 --- a/summary.json +++ b/summary.json @@ -1 +1 @@ -{"repoSenseVersion":"056fa5fcd2","reportGeneratedTime":"Sat Nov 4 22:21:27 2023 UTC+08:00","reportGenerationTime":" 16.85 second(s)","zoneId":"UTC+08:00","reportTitle":"CS2113 tP Code Dashboard","repos":[{"location":{"location":"https://github.com/AY2324S1-CS2113T-W11-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113T-W11-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113T-W11-1/tp[master]","outputFolderName":"AY2324S1-CS2113T-W11-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113T-W11-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113T-W11-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113T-W11-2/tp[master]","outputFolderName":"AY2324S1-CS2113T-W11-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-1/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-2/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-3/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-3_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-4/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-4","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-4/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-4_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-1/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-2/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-3/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-3_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-4/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-4","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-4/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-4_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-1/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-2/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-3/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-3_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-4/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-4","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-4/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-4_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-F11-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-F11-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-F11-1/tp[master]","outputFolderName":"AY2324S1-CS2113-F11-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-F11-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-F11-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-F11-2/tp[master]","outputFolderName":"AY2324S1-CS2113-F11-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-F11-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-F11-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-F11-3/tp[master]","outputFolderName":"AY2324S1-CS2113-F11-3_tp_master"}],"errorSet":[],"sinceDate":"2023-09-22","untilDate":"2023-11-04","isSinceDateProvided":true,"isUntilDateProvided":false,"supportedDomainUrlMap":{"NOT_RECOGNIZED":{"BRANCH":"","REPO_URL":"UNSUPPORTED","BASE_URL":"UNSUPPORTED","HISTORY_PATH":"","COMMIT_PATH":"","BLAME_PATH":""},"github":{"BRANCH":"tree/$BRANCH","REPO_URL":"https://github.com/$ORGANIZATION/$REPO_NAME/","BASE_URL":"https://github.com/","HISTORY_PATH":"commits/$BRANCH/$FILE_PATH","COMMIT_PATH":"commit/$COMMIT_HASH","BLAME_PATH":"blame/$BRANCH/$FILE_PATH"}}} +{"repoSenseVersion":"056fa5fcd2","reportGeneratedTime":"Sun Nov 5 08:09:46 2023 UTC+08:00","reportGenerationTime":" 8.83 second(s)","zoneId":"UTC+08:00","reportTitle":"CS2113 tP Code Dashboard","repos":[{"location":{"location":"https://github.com/AY2324S1-CS2113T-W11-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113T-W11-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113T-W11-1/tp[master]","outputFolderName":"AY2324S1-CS2113T-W11-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113T-W11-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113T-W11-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113T-W11-2/tp[master]","outputFolderName":"AY2324S1-CS2113T-W11-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-1/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-2/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-3/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-3_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-W12-4/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-W12-4","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-W12-4/tp[master]","outputFolderName":"AY2324S1-CS2113-W12-4_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-1/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-2/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-3/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-3_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T17-4/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T17-4","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T17-4/tp[master]","outputFolderName":"AY2324S1-CS2113-T17-4_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-1/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-2/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-3/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-3_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-T18-4/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-T18-4","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-T18-4/tp[master]","outputFolderName":"AY2324S1-CS2113-T18-4_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-F11-1/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-F11-1","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-F11-1/tp[master]","outputFolderName":"AY2324S1-CS2113-F11-1_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-F11-2/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-F11-2","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-F11-2/tp[master]","outputFolderName":"AY2324S1-CS2113-F11-2_tp_master"},{"location":{"location":"https://github.com/AY2324S1-CS2113-F11-3/tp.git","repoName":"tp","organization":"AY2324S1-CS2113-F11-3","domainName":"github"},"branch":"master","displayName":"AY2324S1-CS2113-F11-3/tp[master]","outputFolderName":"AY2324S1-CS2113-F11-3_tp_master"}],"errorSet":[],"sinceDate":"2023-09-22","untilDate":"2023-11-05","isSinceDateProvided":true,"isUntilDateProvided":false,"supportedDomainUrlMap":{"NOT_RECOGNIZED":{"BRANCH":"","REPO_URL":"UNSUPPORTED","BASE_URL":"UNSUPPORTED","HISTORY_PATH":"","COMMIT_PATH":"","BLAME_PATH":""},"github":{"BRANCH":"tree/$BRANCH","REPO_URL":"https://github.com/$ORGANIZATION/$REPO_NAME/","BASE_URL":"https://github.com/","HISTORY_PATH":"commits/$BRANCH/$FILE_PATH","COMMIT_PATH":"commit/$COMMIT_HASH","BLAME_PATH":"blame/$BRANCH/$FILE_PATH"}}}